Skip to content

Commit fde1384

Browse files
committed
Prevent all copying from the hints/solution area
1 parent d4257d8 commit fde1384

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

frontend/src/Hints.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,12 @@ export const HintsPopup = ({hints, numHints, requestingSolution, solution}) => {
88
return null;
99
}
1010
return (
11-
<div className="custom-popup">
11+
<div className="custom-popup"
12+
onCopy={(event) => {
13+
alert("Copying from the hints/solution area is not allowed!");
14+
event.preventDefault();
15+
}}
16+
>
1217
<Popup
1318
trigger={<img src={hintIcon} className="hint-icon" alt="Hint button"/>}
1419
>

0 commit comments

Comments
 (0)