Skip to content

Commit c0dffca

Browse files
committed
DROID-4115 fixes
1 parent b2c0fd0 commit c0dffca

File tree

1 file changed

+22
-14
lines changed
  • feature-chats/src/main/java/com/anytypeio/anytype/feature_chats/ui

1 file changed

+22
-14
lines changed

feature-chats/src/main/java/com/anytypeio/anytype/feature_chats/ui/Toolbars.kt

Lines changed: 22 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -154,22 +154,29 @@ fun ChatTopToolbar(
154154
}
155155

156156
if (header is ChatViewModel.HeaderView.Default && header.showDropDownMenu) {
157-
MaterialTheme(
158-
shapes = MaterialTheme.shapes.copy(
159-
medium = RoundedCornerShape(16.dp)
160-
),
161-
colors = MaterialTheme.colors.copy(
162-
surface = colorResource(id = R.color.background_secondary)
163-
)
157+
Box(
158+
modifier = Modifier
159+
.fillMaxWidth()
160+
.padding(top = 52.dp)
161+
.align(Alignment.TopEnd)
164162
) {
165-
DropdownMenu(
166-
offset = DpOffset(0.dp, 8.dp),
167-
expanded = showDropdownMenu,
168-
onDismissRequest = {
169-
showDropdownMenu = false
170-
},
171-
properties = PopupProperties(focusable = false)
163+
MaterialTheme(
164+
shapes = MaterialTheme.shapes.copy(
165+
medium = RoundedCornerShape(16.dp)
166+
),
167+
colors = MaterialTheme.colors.copy(
168+
surface = colorResource(id = R.color.background_secondary)
169+
)
172170
) {
171+
DropdownMenu(
172+
modifier = Modifier.align(Alignment.TopEnd),
173+
offset = DpOffset((-16).dp, 8.dp),
174+
expanded = showDropdownMenu,
175+
onDismissRequest = {
176+
showDropdownMenu = false
177+
},
178+
properties = PopupProperties(focusable = false)
179+
) {
173180
DropdownMenuItem(
174181
content = {
175182
Text(
@@ -229,6 +236,7 @@ fun ChatTopToolbar(
229236
}
230237
}
231238
}
239+
}
232240
}
233241

234242
@DefaultPreviews

0 commit comments

Comments
 (0)