-
-
Notifications
You must be signed in to change notification settings - Fork 833
Add a warning to the console to discourage attacks and encourage contributing #7608
Add a warning to the console to discourage attacks and encourage contributing #7608
Conversation
Signed-off-by: Šimon Brandner <[email protected]>
Signed-off-by: Šimon Brandner <[email protected]>
Signed-off-by: Šimon Brandner <[email protected]>
@@ -471,6 +477,35 @@ export default class MatrixChat extends React.PureComponent<IProps, IState> { | |||
if (this.accountPasswordTimer !== null) clearTimeout(this.accountPasswordTimer); | |||
} | |||
|
|||
private onKeyDown = (event: KeyboardEvent): void => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Args, I am notan idiot... Though I have no idea how to detect the console in another way...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could do it on viewport resize (unreliable way of detecting console state) but that's still far from ideal, maybe make a localStorage flag which enables debug log and otherwise hide non-critical/bug console.logs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not, only I am an idiot but I am also blind 🤦♂️
Thanks, will have a look
Closing in favour of #7673 |
Fixes element-hq/element-web#2803
Type: enhancement
Here's what your changelog entry will look like:
✨ Features