Skip to content

Commit ac42953

Browse files
committed
doc(timeline): add extra documentation for HandleAggregationKind
1 parent 0675935 commit ac42953

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

crates/matrix-sdk-ui/src/timeline/event_handler.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,18 +123,26 @@ pub(super) struct TimelineEventContext {
123123
pub(super) should_add_new_items: bool,
124124
}
125125

126+
/// Which kind of aggregation (i.e. modification of a related event) are we
127+
/// going to handle?
126128
#[derive(Clone, Debug)]
127129
pub(super) enum HandleAggregationKind {
130+
/// Adding a reaction to the related event.
128131
Reaction { key: String },
129132

133+
/// Redacting (removing) the related event.
130134
Redaction,
131135

136+
/// Editing (replacing) the related event with another one.
132137
Edit { replacement: Replacement<RoomMessageEventContentWithoutRelation> },
133138

139+
/// Responding to the related poll event.
134140
PollResponse { answers: Vec<String> },
135141

142+
/// Editing a related poll event's description.
136143
PollEdit { replacement: Replacement<NewUnstablePollStartEventContentWithoutRelation> },
137144

145+
/// Ending a related poll.
138146
PollEnd,
139147
}
140148

0 commit comments

Comments
 (0)