fix: hide compression slider for audio uploads
Audio has no compression support in MediaCompressor (falls through to no-op), so showing the compression quality slider for audio files is misleading. This removes audio from the slider visibility condition in ImageVideoDescription and wraps the unconditionally-shown slider in ChatFileUploadDialog with a media type check. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
+1
-1
@@ -277,7 +277,7 @@ fun ImageVideoDescription(
|
|||||||
|
|
||||||
val firstMedia = uris.first().media
|
val firstMedia = uris.first().media
|
||||||
|
|
||||||
if (firstMedia.isVideo() == true || firstMedia.isImage() == true || firstMedia.isAudio() == true) {
|
if (firstMedia.isVideo() == true || firstMedia.isImage() == true) {
|
||||||
Column(horizontalAlignment = Alignment.CenterHorizontally) {
|
Column(horizontalAlignment = Alignment.CenterHorizontally) {
|
||||||
Box(modifier = Modifier.fillMaxWidth()) {
|
Box(modifier = Modifier.fillMaxWidth()) {
|
||||||
Text(
|
Text(
|
||||||
|
|||||||
+4
@@ -234,6 +234,9 @@ private fun ImageVideoPostChat(
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
val firstMedia = fileUploadState.multiOrchestrator?.first()?.media
|
||||||
|
|
||||||
|
if (firstMedia?.isVideo() == true || firstMedia?.isImage() == true) {
|
||||||
Column(horizontalAlignment = Alignment.CenterHorizontally) {
|
Column(horizontalAlignment = Alignment.CenterHorizontally) {
|
||||||
Box(modifier = Modifier.fillMaxWidth()) {
|
Box(modifier = Modifier.fillMaxWidth()) {
|
||||||
Text(
|
Text(
|
||||||
@@ -256,6 +259,7 @@ private fun ImageVideoPostChat(
|
|||||||
steps = 2,
|
steps = 2,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
SettingSwitchItem(
|
SettingSwitchItem(
|
||||||
title = R.string.strip_location_metadata_label,
|
title = R.string.strip_location_metadata_label,
|
||||||
|
|||||||
Reference in New Issue
Block a user