fix: виртуальный скролл для чейжлога в диалоге
This commit is contained in:
1 parent
97b22bdda3
commit
e82076447e
1 file changed
+12
-7
@@ -20,6 +20,7 @@ import androidx.compose.foundation.layout.Spacer
|
|||||||
import androidx.compose.foundation.layout.fillMaxSize
|
import androidx.compose.foundation.layout.fillMaxSize
|
||||||
import androidx.compose.foundation.layout.fillMaxWidth
|
import androidx.compose.foundation.layout.fillMaxWidth
|
||||||
import androidx.compose.foundation.layout.height
|
import androidx.compose.foundation.layout.height
|
||||||
|
import androidx.compose.foundation.layout.heightIn
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.foundation.layout.size
|
import androidx.compose.foundation.layout.size
|
||||||
import androidx.compose.foundation.layout.width
|
import androidx.compose.foundation.layout.width
|
||||||
@@ -320,13 +321,17 @@ private fun UpdateDialogs(viewModel: MainViewModel) {
|
|||||||
Text(stringResource(R.string.update_available, state.version))
|
Text(stringResource(R.string.update_available, state.version))
|
||||||
if (state.changelog.isNotEmpty()) {
|
if (state.changelog.isNotEmpty()) {
|
||||||
Spacer(Modifier.height(8.dp))
|
Spacer(Modifier.height(8.dp))
|
||||||
Text(
|
Column(
|
||||||
state.changelog,
|
modifier = Modifier
|
||||||
style = MaterialTheme.typography.bodySmall,
|
.heightIn(max = 200.dp)
|
||||||
color = MaterialTheme.colorScheme.onSurfaceVariant,
|
.verticalScroll(rememberScrollState())
|
||||||
maxLines = 10,
|
) {
|
||||||
overflow = TextOverflow.Ellipsis
|
Text(
|
||||||
)
|
state.changelog,
|
||||||
|
style = MaterialTheme.typography.bodySmall,
|
||||||
|
color = MaterialTheme.colorScheme.onSurfaceVariant
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in new issue
Block a user