perf: 避免 floatingActionButton 遮挡

This commit is contained in:
lisonge 2024-03-04 19:36:58 +08:00
parent 03bb53999a
commit 1292bcf9b2
5 changed files with 13 additions and 2 deletions

View File

@ -165,6 +165,9 @@ fun AppConfigPage(appId: String) {
modifier = Modifier.fillMaxWidth(),
textAlign = TextAlign.Center
)
} else {
// 避免被 floatingActionButton 遮挡
Spacer(modifier = Modifier.height(40.dp))
}
}
}

View File

@ -253,6 +253,8 @@ fun AppItemPage(
modifier = Modifier.fillMaxWidth(),
textAlign = TextAlign.Center
)
} else if (editable) {
Spacer(modifier = Modifier.height(40.dp))
}
}
}

View File

@ -174,6 +174,8 @@ fun CategoryPage(subsItemId: Long) {
textAlign = TextAlign.Center,
modifier = Modifier.fillMaxWidth()
)
} else if (editable) {
Spacer(modifier = Modifier.height(40.dp))
}
}
}

View File

@ -224,6 +224,8 @@ fun GlobalRulePage(subsItemId: Long, focusGroupKey: Int? = null) {
modifier = Modifier.fillMaxWidth(),
textAlign = TextAlign.Center
)
} else if (editable) {
Spacer(modifier = Modifier.height(40.dp))
}
}
}

View File

@ -271,6 +271,8 @@ fun SubsPage(
modifier = Modifier.fillMaxWidth(),
textAlign = TextAlign.Center
)
} else if (editable) {
Spacer(modifier = Modifier.height(40.dp))
}
}
}
@ -282,13 +284,13 @@ fun SubsPage(
var source by remember {
mutableStateOf("")
}
AlertDialog(title = { Text(text = "添加APP规则") }, text = {
AlertDialog(title = { Text(text = "添加应用规则") }, text = {
OutlinedTextField(
value = source,
onValueChange = { source = it },
maxLines = 10,
modifier = Modifier.fillMaxWidth(),
placeholder = { Text(text = "请输入规则\nAPP规则已经存在则追加") },
placeholder = { Text(text = "请输入规则\n应用规则已经存在则追加") },
)
}, onDismissRequest = { showAddDlg = false }, confirmButton = {
TextButton(onClick = {