google-developer-training / basic-android-kotlin-compose-training-tip-calculator

Apache License 2.0
61 stars 93 forks source link

Calculate a custom tip: Android Basics with Compose: Alignment issue #170

Open Andy-Cuong opened 8 months ago

Andy-Cuong commented 8 months ago

URL of codelab

Step 6

In substep 8: In the Switch composable, add this modifier to align the Switch composable to the end of the screen:

The modifier passed to be Switch should be a new instance, not the instance passed down from the Composable parameter (Modifier, not modifier), otherwise, the Switch will be incorrectly aligned inside the RoundTheTipRow Composable

Additional information With modifier: image

With Modifier: image