Skip to content

Commit

Permalink
chore: make example main activity scrollable to access all buttons on…
Browse files Browse the repository at this point in the history
… small screen (#433)
  • Loading branch information
bubenheimer authored Oct 28, 2023
1 parent bb21036 commit 52d0342
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Spacer
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.rememberScrollState
import androidx.compose.foundation.verticalScroll
import androidx.compose.material.Button
import androidx.compose.material.MaterialTheme
import androidx.compose.material.Surface
Expand All @@ -45,7 +47,8 @@ class MainActivity : ComponentActivity() {
val context = LocalContext.current
Column(
Modifier
.fillMaxSize(),
.fillMaxSize()
.verticalScroll(rememberScrollState()),
horizontalAlignment = Alignment.CenterHorizontally
) {
Spacer(modifier = Modifier.padding(10.dp))
Expand Down

0 comments on commit 52d0342

Please sign in to comment.