mirror of
https://github.com/element-hq/element-web
synced 2024-11-27 19:56:47 +03:00
Merge pull request #4891 from matrix-org/t3chguy/room-list/111
Fix theme selector clicks bubbling out and causing context menu to float away
This commit is contained in:
commit
a475887c3e
1 changed files with 4 additions and 1 deletions
|
@ -130,7 +130,10 @@ export default class UserMenu extends React.Component<IProps, IState> {
|
||||||
this.setState({contextMenuPosition: null});
|
this.setState({contextMenuPosition: null});
|
||||||
};
|
};
|
||||||
|
|
||||||
private onSwitchThemeClick = () => {
|
private onSwitchThemeClick = (ev: React.MouseEvent) => {
|
||||||
|
ev.preventDefault();
|
||||||
|
ev.stopPropagation();
|
||||||
|
|
||||||
// Disable system theme matching if the user hits this button
|
// Disable system theme matching if the user hits this button
|
||||||
SettingsStore.setValue("use_system_theme", null, SettingLevel.DEVICE, false);
|
SettingsStore.setValue("use_system_theme", null, SettingLevel.DEVICE, false);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue