JetBrains / compose-multiplatform

Compose Multiplatform, a modern UI framework for Kotlin that makes building performant and beautiful user interfaces easy and enjoyable.
https://jetbrains.com/lp/compose-multiplatform
Apache License 2.0
15.91k stars 1.16k forks source link

Empty Material 3 TextField with label jumps when it gets focus #4570

Open GazimSoliev opened 5 months ago

GazimSoliev commented 5 months ago

Describe the bug Empty Material 3 TextField with label jumps when it gets focus Affected platforms

Versions

To Reproduce Steps and/or the code snippet to reproduce the behavior:

Box(
    modifier = Modifier.fillMaxSize(),
    contentAlignment = Alignment.Center
) {
    Column(
        verticalArrangement = Arrangement.spacedBy(8.dp),
        horizontalAlignment = Alignment.CenterHorizontally
    ) {
        Text("Hello")
        TextField(TextFieldValue(), {}, label = { Text("Label 1") })
        TextField(TextFieldValue(), {}, label = { Text("Label 2") })
    }
}

Expected behavior It doesn't jump when it gets focus

Video

https://github.com/JetBrains/compose-multiplatform/assets/63443274/8cdd3a82-ede1-4a40-b664-4882a65ba736

okushnikov commented 2 weeks ago

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.

Feinate commented 1 week ago

Same here. I don't know why.