We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8b340b8 commit 23b0e10Copy full SHA for 23b0e10
1 file changed
app/src/main/java/com/texthip/thip/ui/group/note/screen/GroupVoteCreateScreen.kt
@@ -44,11 +44,18 @@ fun GroupVoteCreateScreen() {
44
45
var isEligible by rememberSaveable { mutableStateOf(false) } // TODO: 서버 데이터?
46
47
+ // 완료 버튼 활성화 조건
48
+ val filledOptionsCount = options.count { it.isNotBlank() }
49
+ val isRightButtonEnabled =
50
+ (isGeneralReview || pageText.isNotBlank()) &&
51
+ title.isNotBlank() &&
52
+ filledOptionsCount >= 2
53
+
54
Box(modifier = Modifier.fillMaxSize()) {
55
Column {
56
InputTopAppBar(
57
title = stringResource(R.string.create_vote),
- isRightButtonEnabled = false,
58
+ isRightButtonEnabled = isRightButtonEnabled,
59
onLeftClick = { /* 뒤로가기 동작 */ },
60
onRightClick = { /* 완료 동작 */ }
61
)
0 commit comments