Skip to content
This repository was archived by the owner on Sep 11, 2024. It is now read-only.

Commit de154ff

Browse files
authored
Fix space topic jumping on hover/focus (#12377)
Signed-off-by: Michael Telatynski <[email protected]>
1 parent ddadbf6 commit de154ff

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/components/views/elements/RoomTopic.tsx

+2-4
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ interface IProps extends React.HTMLProps<HTMLDivElement> {
3636
room: Room;
3737
}
3838

39-
export default function RoomTopic({ room, ...props }: IProps): JSX.Element {
39+
export default function RoomTopic({ room, className, ...props }: IProps): JSX.Element {
4040
const client = useContext(MatrixClientContext);
4141
const ref = useRef<HTMLDivElement>(null);
4242

@@ -110,15 +110,13 @@ export default function RoomTopic({ room, ...props }: IProps): JSX.Element {
110110
}
111111
});
112112

113-
const className = classNames(props.className, "mx_RoomTopic");
114-
115113
return (
116114
<TooltipTarget
117115
{...props}
118116
ref={ref}
119117
onClick={onClick}
120118
dir="auto"
121-
tooltipTargetClassName={className}
119+
tooltipTargetClassName={classNames(className, "mx_RoomTopic")}
122120
label={_t("room|read_topic")}
123121
alignment={Alignment.Bottom}
124122
ignoreHover={ignoreHover}

0 commit comments

Comments
 (0)