From 5301d421f2a295f81643b046109bfb7b10edf910 Mon Sep 17 00:00:00 2001 From: Andrey Shovkoplyas Date: Fri, 28 Feb 2020 14:59:26 +0100 Subject: [PATCH] [#10084] Make commands in chat available on Ropsten for e2e builds Signed-off-by: Churikova Tetiana --- .env.e2e | 1 + src/status_im/ui/screens/chat/input/input.cljs | 2 +- src/status_im/utils/config.cljs | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.env.e2e b/.env.e2e index 613798bfac..cf5fb81a44 100644 --- a/.env.e2e +++ b/.env.e2e @@ -20,3 +20,4 @@ CONTRACT_NODES=1 MOBILE_UI_FOR_DESKTOP=1 BLANK_PREVIEW=0 TOOLTIP_EVENTS=1 +COMMANDS_ENABLED=1 diff --git a/src/status_im/ui/screens/chat/input/input.cljs b/src/status_im/ui/screens/chat/input/input.cljs index 314af6931b..7fa3a994ba 100644 --- a/src/status_im/ui/screens/chat/input/input.cljs +++ b/src/status_im/ui/screens/chat/input/input.cljs @@ -173,7 +173,7 @@ [input-view {:single-line-input? single-line-input? :set-text set-text :state-text state-text}] (when (and input-text-empty? mainnet?) [stickers/button (= :stickers input-bottom-sheet)]) - (when (and one-to-one-chat? input-text-empty? mainnet?) + (when (and one-to-one-chat? input-text-empty? (or config/commands-enabled? mainnet?)) [extensions/button (= :extensions input-bottom-sheet)]) (when-not input-text-empty? (if platform/desktop? diff --git a/src/status_im/utils/config.cljs b/src/status_im/utils/config.cljs index 644b711d57..dc10cd3b0d 100644 --- a/src/status_im/utils/config.cljs +++ b/src/status_im/utils/config.cljs @@ -38,6 +38,7 @@ (def tooltip-events? (enabled? (get-config :TOOLTIP_EVENTS "0"))) (def nimbus-enabled? (enabled? (get-config :STATUS_GO_ENABLE_NIMBUS "0"))) (def waku-enabled? (enabled? (get-config :WAKU_ENABLED "0"))) +(def commands-enabled? (enabled? (get-config :COMMANDS_ENABLED "0"))) ;; CONFIG VALUES (def log-level