From 3dbc00cd67c1a88fbe8a23c676b50d4d3cd02963 Mon Sep 17 00:00:00 2001 From: Ivan Enderlin Date: Thu, 24 Aug 2023 10:36:04 +0200 Subject: [PATCH] feat(ui): Reduce the `batch_size` of `invites` in `RoomListService`. This patch changes the `batch_size` of the sliding sync list `invites` for `RoomListService`. Previous value was 100, new value is 20. For accounts that have a large number of invites, it won't slow the rendering of `visible_rooms`. --- crates/matrix-sdk-ui/src/room_list_service/state.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/matrix-sdk-ui/src/room_list_service/state.rs b/crates/matrix-sdk-ui/src/room_list_service/state.rs index c1be2f148..490195ea4 100644 --- a/crates/matrix-sdk-ui/src/room_list_service/state.rs +++ b/crates/matrix-sdk-ui/src/room_list_service/state.rs @@ -155,7 +155,7 @@ impl Action for AddInvitesList { sliding_sync .add_list( SlidingSyncList::builder(INVITES_LIST_NAME) - .sync_mode(SlidingSyncMode::new_growing(100)) + .sync_mode(SlidingSyncMode::new_growing(20)) .timeline_limit(0) .required_state(vec![ (StateEventType::RoomAvatar, "".to_owned()),