Skip to content

Commit feb3588

Browse files
authored
scaffold: be more explicit about alignment line check (#546)
1 parent 9a43ebc commit feb3588

File tree

1 file changed

+2
-1
lines changed
  • ui/src/androidMain/kotlin/kiwi/orbit/compose/ui/controls

1 file changed

+2
-1
lines changed

ui/src/androidMain/kotlin/kiwi/orbit/compose/ui/controls/Scaffold.kt

+2-1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ import androidx.compose.ui.Alignment
2424
import androidx.compose.ui.Modifier
2525
import androidx.compose.ui.graphics.Brush
2626
import androidx.compose.ui.graphics.Color
27+
import androidx.compose.ui.layout.AlignmentLine
2728
import androidx.compose.ui.layout.HorizontalAlignmentLine
2829
import androidx.compose.ui.layout.Layout
2930
import androidx.compose.ui.platform.LocalDensity
@@ -152,7 +153,7 @@ private fun ScaffoldLayout(
152153

153154
// Calculate the space for content and toast.
154155
val actionFadeHeight = actionPlaceables.firstOrNull()?.get(ActionFadeLine)
155-
?.takeIf { it >= 0 } ?: 0
156+
?.takeIf { it != AlignmentLine.Unspecified } ?: 0
156157
val actionHeight = actionPlaceables.maxOfOrNull { it.height } ?: 0
157158

158159
// If there is fade, let's do not subtract it, we want the content to be shown below it.

0 commit comments

Comments
 (0)