diff --git a/src/status_im/ui/components/common/common.cljs b/src/status_im/ui/components/common/common.cljs index e26913e339..0fedcf0a2a 100644 --- a/src/status_im/ui/components/common/common.cljs +++ b/src/status_im/ui/components/common/common.cljs @@ -68,15 +68,22 @@ [react/view {:style (styles/logo-container size shadow?)} [icons/icon :icons/logo (styles/logo icon-size)]])) -(defn bottom-button [{:keys [label disabled? on-press forward? back? uppercase?] +(defn bottom-button [{:keys [accessibility-label + label + disabled? + on-press + forward? + back? + uppercase?] :or {uppercase? true}}] [react/touchable-highlight {:on-press on-press :disabled disabled?} [react/view (styles/bottom-button disabled?) (when back? [icons/icon :icons/back {:color colors/blue :container-style {:align-self :baseline}}]) - [react/text {:style styles/bottom-button-label - :uppercase? uppercase?} + [react/text {:style styles/bottom-button-label + :accessibility-label accessibility-label + :uppercase? uppercase?} (or label (i18n/label :t/next))] (when forward? [icons/icon :icons/forward {:color colors/blue}])]]) diff --git a/src/status_im/ui/screens/group/views.cljs b/src/status_im/ui/screens/group/views.cljs index c35b3bce2b..6ce9338ae0 100644 --- a/src/status_im/ui/screens/group/views.cljs +++ b/src/status_im/ui/screens/group/views.cljs @@ -108,13 +108,13 @@ (i18n/label :t/group-chat-no-contacts)] [buttons/secondary-button {:on-press handle-invite-friends-pressed} (i18n/label :t/invite-friends)]]) -(views/defview bottom-container [{:keys [on-press disabled label]}] +(views/defview bottom-container [{:keys [on-press disabled label accessibility-label]}] [react/view {:style main-tabs.styles/tabs-container} [react/view {:style components.styles/flex}] [react/view {:style styles/bottom-container} [components.common/bottom-button {:forward? true - :accessibility-label :next-button + :accessibility-label (or accessibility-label :next-button) :label label :disabled? disabled :on-press on-press}]]]) @@ -162,7 +162,8 @@ :enable-empty-sections true}]]] [bottom-container {:on-press #(re-frame/dispatch [:group-chats.ui/create-pressed group-name]) :disabled (string/blank? group-name) - :label (i18n/label :t/create-group-chat)}]]))) + :label (i18n/label :t/create-group-chat) + :accessibility-label :create-group-chat-button}]]))) ;; Add participants to existing group chat (views/defview add-participants-toggle-list [] diff --git a/test/appium/views/chat_view.py b/test/appium/views/chat_view.py index 9b1b1a297c..05738efe6e 100644 --- a/test/appium/views/chat_view.py +++ b/test/appium/views/chat_view.py @@ -203,7 +203,7 @@ class ProfileSendTransactionButton(BaseButton): class JoinChatButton(BaseButton): def __init__(self, driver): super(JoinChatButton, self).__init__(driver) - self.locator = self.Locator.text_part_selector('JOIN CHAT') + self.locator = self.Locator.text_part_selector('JOIN GROUP') class ChatElementByText(BaseText): diff --git a/test/appium/views/start_new_chat_view.py b/test/appium/views/start_new_chat_view.py index e8173903d7..7aa66d9fdc 100644 --- a/test/appium/views/start_new_chat_view.py +++ b/test/appium/views/start_new_chat_view.py @@ -47,7 +47,7 @@ class OpenButton(BaseButton): class CreateButton(BaseButton): def __init__(self, driver): super(CreateButton, self).__init__(driver) - self.locator = self.Locator.accessibility_id('create-button') + self.locator = self.Locator.accessibility_id('create-group-chat-button') def navigate(self): from views.chat_view import ChatView