fix join community button title

This commit is contained in:
ryanzhao 2022-09-14 14:46:29 +10:00
parent df669030ac
commit 65d615ef24
24 changed files with 29 additions and 7 deletions

View File

@ -53,7 +53,7 @@ final class JoinOpenGroupModal: Modal {
joinButton.backgroundColor = Colors.buttonBackground
joinButton.titleLabel!.font = .systemFont(ofSize: Values.smallFontSize)
joinButton.setTitleColor(Colors.text, for: UIControl.State.normal)
joinButton.setTitle("Join", for: UIControl.State.normal)
joinButton.setTitle("JOIN_COMMUNITY_BUTTON_TITLE".localized(), for: UIControl.State.normal)
joinButton.addTarget(self, action: #selector(joinOpenGroup), for: UIControl.Event.touchUpInside)
// Button stack view

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -714,3 +714,4 @@
/* New conversation screen*/
"vc_new_conversation_title" = "New Conversation";
"CREATE_GROUP_BUTTON_TITLE" = "Create";
"JOIN_COMMUNITY_BUTTON_TITLE" = "Join";

View File

@ -245,18 +245,18 @@ private final class EnterURLVC: UIViewController, UIGestureRecognizerDelegate, O
view.backgroundColor = .clear
// Next button
let nextButton = Button(style: .prominentOutline, size: .large)
nextButton.setTitle(NSLocalizedString("next", comment: ""), for: UIControl.State.normal)
nextButton.addTarget(self, action: #selector(joinOpenGroup), for: UIControl.Event.touchUpInside)
let joinButton = Button(style: .prominentOutline, size: .large)
joinButton.setTitle("JOIN_COMMUNITY_BUTTON_TITLE".localized(), for: UIControl.State.normal)
joinButton.addTarget(self, action: #selector(joinOpenGroup), for: UIControl.Event.touchUpInside)
let nextButtonContainer = UIView(
wrapping: nextButton,
let joinButtonContainer = UIView(
wrapping: joinButton,
withInsets: UIEdgeInsets(top: 0, leading: 80, bottom: 0, trailing: 80),
shouldAdaptForIPadWithWidth: Values.iPadButtonWidth
)
// Stack view
let stackView = UIStackView(arrangedSubviews: [ urlTextView, UIView.spacer(withHeight: Values.mediumSpacing), suggestionGridTitleLabel, UIView.spacer(withHeight: Values.mediumSpacing), suggestionGrid, UIView.vStretchingSpacer(), nextButtonContainer ])
let stackView = UIStackView(arrangedSubviews: [ urlTextView, UIView.spacer(withHeight: Values.mediumSpacing), suggestionGridTitleLabel, UIView.spacer(withHeight: Values.mediumSpacing), suggestionGrid, UIView.vStretchingSpacer(), joinButtonContainer ])
stackView.axis = .vertical
stackView.alignment = .fill
stackView.layoutMargins = UIEdgeInsets(uniform: Values.largeSpacing)