[Glitch] Add ability to middle-mouse click posts in web UI

Port 683db3ab25 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
Eugen Rochko
2024-11-20 16:56:35 +01:00
committed by Claire
parent d65f6c2f8a
commit d2fd51691a
3 changed files with 30 additions and 28 deletions

View File

@@ -319,7 +319,7 @@ class StatusContent extends PureComponent {
element = element.parentNode;
}
if (deltaX + deltaY < 5 && e.button === 0 && this.props.onClick) {
if (deltaX + deltaY < 5 && (e.button === 0 || e.button === 1) && this.props.onClick) {
this.props.onClick(e);
}