Skip to content

Commit

Permalink
Make buttons take up full width when placed one under the another
Browse files Browse the repository at this point in the history
  • Loading branch information
StylianosGakis committed Nov 25, 2024
1 parent 8c846fd commit 398c16f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@ private fun SmallHorizontalPreferringButtons(
).lineCount > 1
}
val buttonConstraints = if (doNeedSecondLine) {
constraints.copy(minHeight = 0)
constraints.copy(minHeight = 0, minWidth = constraints.maxWidth)
} else {
val fixedWidth = constraints.maxWidth / 2 - (spaceBetween / 2).toPx().toInt()
constraints.copy(minHeight = 0, minWidth = fixedWidth, maxWidth = fixedWidth)
Expand Down

0 comments on commit 398c16f

Please sign in to comment.