mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-05-10 17:18:31 +00:00
ui: adjust create channel ui (#6950)
This commit is contained in:
@@ -338,6 +338,9 @@ struct AddChannelView: View {
|
||||
.compactSectionSpacing()
|
||||
|
||||
Section {
|
||||
Button("Cancel and delete channel", role: .destructive) {
|
||||
showCancelChannelAlert(gInfo)
|
||||
}
|
||||
Button("Continue") {
|
||||
if activeCount >= total {
|
||||
showLinkStep = true
|
||||
@@ -365,11 +368,6 @@ struct AddChannelView: View {
|
||||
}
|
||||
.navigationTitle("Creating channel")
|
||||
.navigationBarBackButtonHidden(true)
|
||||
.toolbar {
|
||||
ToolbarItem(placement: .navigationBarTrailing) {
|
||||
Button("Delete channel") { showCancelChannelAlert(gInfo) }
|
||||
}
|
||||
}
|
||||
.onDisappear {
|
||||
if !showLinkStep && m.creatingChannelId == gInfo.id {
|
||||
showCancelChannelAlert(gInfo)
|
||||
|
||||
+7
-2
@@ -281,8 +281,13 @@ fun GroupLinkLayout(
|
||||
)
|
||||
}
|
||||
if (creatingGroup && close != null) {
|
||||
Spacer(Modifier.height(DEFAULT_PADDING_HALF))
|
||||
ContinueButton(close)
|
||||
SettingsActionItem(
|
||||
painterResource(MR.images.ic_check),
|
||||
stringResource(MR.strings.continue_to_next_step),
|
||||
click = close,
|
||||
iconColor = MaterialTheme.colors.primary,
|
||||
textColor = MaterialTheme.colors.primary,
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+8
-6
@@ -404,11 +404,6 @@ private fun ProgressStepView(
|
||||
ModalView(
|
||||
close = { showCancelAlert() },
|
||||
showClose = false,
|
||||
endButtons = {
|
||||
TextButton(onClick = { showCancelAlert() }) {
|
||||
Text(generalGetString(MR.strings.button_delete_channel))
|
||||
}
|
||||
}
|
||||
) {
|
||||
ColumnWithScrollBar {
|
||||
AppBarTitle(generalGetString(MR.strings.creating_channel))
|
||||
@@ -481,9 +476,16 @@ private fun ProgressStepView(
|
||||
Spacer(Modifier.height(16.dp))
|
||||
|
||||
SectionView {
|
||||
SettingsActionItem(
|
||||
painterResource(MR.images.ic_delete),
|
||||
generalGetString(MR.strings.button_cancel_and_delete_channel),
|
||||
click = { showCancelAlert() },
|
||||
textColor = Color.Red,
|
||||
iconColor = Color.Red,
|
||||
)
|
||||
val enabled = activeCount > 0
|
||||
SettingsActionItem(
|
||||
painterResource(MR.images.ic_link),
|
||||
painterResource(MR.images.ic_check),
|
||||
generalGetString(MR.strings.continue_to_next_step),
|
||||
click = {
|
||||
if (activeCount >= total) {
|
||||
|
||||
@@ -1887,6 +1887,7 @@
|
||||
<string name="group_info_member_you">you: %1$s</string>
|
||||
<string name="button_delete_group">Delete group</string>
|
||||
<string name="button_delete_channel">Delete channel</string>
|
||||
<string name="button_cancel_and_delete_channel">Cancel and delete channel</string>
|
||||
<string name="button_delete_chat">Delete chat</string>
|
||||
<string name="delete_group_question">Delete group?</string>
|
||||
<string name="delete_channel_question">Delete channel?</string>
|
||||
|
||||
Reference in New Issue
Block a user