Show the date on a room when the last message is older than today. (#484)

* Format the last message date correctly.
* Update room cell layout - fixes an issue where the longer the date got the smaller the last message width was.
This commit is contained in:
Doug
2023-01-24 11:02:51 +00:00
committed by GitHub
parent 7e1593d43d
commit b8e2d6f823
8 changed files with 197 additions and 69 deletions
@@ -35,16 +35,15 @@ struct HomeScreen: View {
}
if context.viewState.roomListMode == .skeletons {
LazyVStack {
LazyVStack(spacing: 0) {
ForEach(context.viewState.visibleRooms) { room in
HomeScreenRoomCell(room: room, context: context)
.redacted(reason: .placeholder)
.disabled(true)
}
}
.padding(.horizontal)
} else {
LazyVStack {
LazyVStack(spacing: 0) {
ForEach(context.viewState.visibleRooms) { room in
Group {
if room.isPlaceholder {
@@ -62,7 +61,6 @@ struct HomeScreen: View {
}
}
}
.padding(.horizontal)
.searchable(text: $context.searchQuery)
.disableAutocorrection(true)
}