Skip to content

Commit 6d5d5c9

Browse files
committed
feat(ui): Add the MemberHints state event type to the required state
This state event allows us to correctly calculate the room display name according to MSC4171. MSC: matrix-org/matrix-spec-proposals#4171
1 parent 3356e0c commit 6d5d5c9

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

crates/matrix-sdk-ui/src/room_list_service/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,8 @@ const DEFAULT_REQUIRED_STATE: &[(StateEventType, &str)] = &[
9292
// Those two events are required to properly compute room previews.
9393
(StateEventType::RoomCreate, ""),
9494
(StateEventType::RoomHistoryVisibility, ""),
95+
// Required to correctly calculate the room display name.
96+
(StateEventType::MemberHints, ""),
9597
];
9698

9799
/// The default `required_state` constant value for sliding sync room

crates/matrix-sdk-ui/tests/integration/room_list_service.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -365,6 +365,7 @@ async fn test_sync_all_states() -> Result<(), Error> {
365365
["m.room.join_rules", ""],
366366
["m.room.create", ""],
367367
["m.room.history_visibility", ""],
368+
["io.element.functional_members", ""],
368369
],
369370
"include_heroes": true,
370371
"filters": {
@@ -2232,6 +2233,7 @@ async fn test_room_subscription() -> Result<(), Error> {
22322233
["m.room.join_rules", ""],
22332234
["m.room.create", ""],
22342235
["m.room.history_visibility", ""],
2236+
["io.element.functional_members", ""],
22352237
["m.room.pinned_events", ""],
22362238
],
22372239
"timeline_limit": 20,
@@ -2272,6 +2274,7 @@ async fn test_room_subscription() -> Result<(), Error> {
22722274
["m.room.join_rules", ""],
22732275
["m.room.create", ""],
22742276
["m.room.history_visibility", ""],
2277+
["io.element.functional_members", ""],
22752278
["m.room.pinned_events", ""],
22762279
],
22772280
"timeline_limit": 20,

0 commit comments

Comments
 (0)