Limit search bar text to single line
This commit is contained in:
1 parent
fc6d0bd6ef
commit
ba3a41f0ee
1 file changed
+4
-2
@@ -227,12 +227,14 @@ fun SearchBarScreen(
|
||||
onExpandedChange = onExpandedChange,
|
||||
modifier = Modifier.widthIn(max = maxWidth - SearchBarHorizontalPadding * 2),
|
||||
label = title.ifNotNullThen {
|
||||
Text(title!!, overflow = TextOverflow.Ellipsis)
|
||||
Text(title!!, overflow = TextOverflow.Ellipsis, maxLines = 1)
|
||||
}.takeUnless {
|
||||
val contentActive by activeState.state
|
||||
expanded || contentActive || searchFieldState.text.isNotEmpty()
|
||||
},
|
||||
placeholder = searchFieldHint.ifNotNullThen { Text(searchFieldHint!!) },
|
||||
placeholder = searchFieldHint.ifNotNullThen {
|
||||
Text(searchFieldHint!!, overflow = TextOverflow.Ellipsis, maxLines = 1)
|
||||
},
|
||||
leadingIcon = {
|
||||
if (expanded) {
|
||||
IconButton(onClick = { hideSearchView() }) {
|
||||
|
||||
Reference in new issue
Block a user