improve button

This commit is contained in:
Evgeny @ SimpleX Chat
2026-07-11 22:28:23 +00:00
parent d468b34fd6
commit a526245634
2 changed files with 6 additions and 10 deletions
@@ -790,12 +790,10 @@ struct SetSimplexDomainView: View {
}
Section {
if editing {
if simplexName.isEmpty {
Button {
openBrowserAlert(uri: "https://github.com/simplex-chat/simplex-chat/blob/master/docs/guide/register-simplex-name.md")
} label: {
Text("Register a test name")
}
Button {
openBrowserAlert(uri: "https://github.com/simplex-chat/simplex-chat/blob/master/docs/guide/register-simplex-name.md")
} label: {
Text("Register a test name")
}
Button {
if let w = broadcastWarning, changed {
@@ -160,10 +160,8 @@ fun SetSimplexDomainView(
SectionDividerSpaced()
SectionView {
if (editing.value) {
if (name.value.isBlank()) {
SectionItemView({ openBrowserAlert("https://github.com/simplex-chat/simplex-chat/blob/master/docs/guide/register-simplex-name.md", uriHandler) }) {
Text(stringResource(MR.strings.register_test_name), color = MaterialTheme.colors.primary)
}
SectionItemView({ openBrowserAlert("https://github.com/simplex-chat/simplex-chat/blob/master/docs/guide/register-simplex-name.md", uriHandler) }) {
Text(stringResource(MR.strings.register_test_name), color = MaterialTheme.colors.primary)
}
SectionItemView({ if (broadcastWarning != null && !unchanged) AlertManager.shared.showAlertDialog(title = broadcastWarning, confirmText = generalGetString(MR.strings.save_verb), onConfirm = { doSave(close) }) else doSave(close) }, disabled = unchanged || saving.value || !isValid) {
Text(