mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-03 16:10:20 +00:00
Fix glitches when loading the timeline: use locally generated stable identifiers for all possible timeline items
This commit is contained in:
committed by
Stefan Ceriu
parent
2146c71232
commit
ffa2644ed8
+1
-1
@@ -17,5 +17,5 @@
|
||||
import Foundation
|
||||
|
||||
struct PaginationIndicatorRoomTimelineItem: DecorationTimelineItemProtocol, Identifiable, Hashable {
|
||||
let id: String = UUID().uuidString
|
||||
let id = "paginationIndicatorTimelineItemIdentifier"
|
||||
}
|
||||
|
||||
+1
-1
@@ -17,5 +17,5 @@
|
||||
import Foundation
|
||||
|
||||
struct ReadMarkerRoomTimelineItem: DecorationTimelineItemProtocol, Identifiable, Hashable {
|
||||
let id: String = UUID().uuidString
|
||||
let id = "readMarkerTimelineItemIdentifier"
|
||||
}
|
||||
|
||||
+1
@@ -17,6 +17,7 @@
|
||||
import Foundation
|
||||
|
||||
struct SeparatorRoomTimelineItem: DecorationTimelineItemProtocol, Identifiable, Hashable {
|
||||
#warning("This should really be a stable identifier, ideally coming from the SDK, but unfortunately we receive duplicates for it at the moment, crashing our timeline data source")
|
||||
let id: String = UUID().uuidString
|
||||
let text: String
|
||||
}
|
||||
|
||||
+1
-1
@@ -17,6 +17,6 @@
|
||||
import Foundation
|
||||
|
||||
struct TimelineStartRoomTimelineItem: DecorationTimelineItemProtocol, Identifiable, Hashable {
|
||||
let id: String = UUID().uuidString
|
||||
let id = "timelineStartTimelineItemIdentifier"
|
||||
let name: String?
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user