From b64471e4f659adc3ad7b4713d4ecf599d49f8e6d Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Fri, 31 Jan 2025 15:47:32 +0000 Subject: [PATCH] Ensure switching rooms does not wrongly focus timeline search (#29153) This happened due to the focusRoomSearch param being stored for inactive rooms so it never got cleared Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> --- src/stores/right-panel/RightPanelStoreIPanelState.ts | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/stores/right-panel/RightPanelStoreIPanelState.ts b/src/stores/right-panel/RightPanelStoreIPanelState.ts index 1ee5f2a95d..d70f6606e9 100644 --- a/src/stores/right-panel/RightPanelStoreIPanelState.ts +++ b/src/stores/right-panel/RightPanelStoreIPanelState.ts @@ -38,8 +38,6 @@ export interface IRightPanelCardStateStored { initialEventId?: string; isInitialEventHighlighted?: boolean; initialEventScrollIntoView?: boolean; - // room summary card - focusRoomSearch?: boolean; } export interface IRightPanelCard { @@ -84,7 +82,6 @@ export function convertCardToStore(panelState: IRightPanelCard): IRightPanelCard memberInfoEventId: !!state?.memberInfoEvent?.getId() ? state.memberInfoEvent.getId() : undefined, initialEventId: !!state?.initialEvent?.getId() ? state.initialEvent.getId() : undefined, memberId: !!state?.member?.userId ? state.member.userId : undefined, - focusRoomSearch: state.focusRoomSearch, }; return { state: stateStored, phase: panelState.phase }; @@ -104,7 +101,6 @@ function convertStoreToCard(panelStateStore: IRightPanelCardStored, room: Room): : undefined, initialEvent: !!stateStored?.initialEventId ? room.findEventById(stateStored.initialEventId) : undefined, member: (!!stateStored?.memberId && room.getMember(stateStored.memberId)) || undefined, - focusRoomSearch: stateStored?.focusRoomSearch, }; return { state: state, phase: panelStateStore.phase };