summaryrefslogtreecommitdiffstats
path: root/client/src/common/jsx/WithHover.jsx
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/common/jsx/WithHover.jsx')
-rw-r--r--client/src/common/jsx/WithHover.jsx13
1 files changed, 13 insertions, 0 deletions
diff --git a/client/src/common/jsx/WithHover.jsx b/client/src/common/jsx/WithHover.jsx
new file mode 100644
index 0000000..bb1a7f4
--- /dev/null
+++ b/client/src/common/jsx/WithHover.jsx
@@ -0,0 +1,13 @@
+import React from 'react';
+
+const WithHover = ({ children, setHover, message, classes }) => (
+ <div
+ onMouseEnter={()=>setHover(message)}
+ onMouseLeave={()=>setHover(null)}
+ className={classes}
+ >
+ {children}
+ </div>
+);
+
+export default WithHover;