Skip to content

Commit

Permalink
#803 improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
mateusmarquezini committed Aug 17, 2019
1 parent 9c243d6 commit 9750650
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions src/learn/math/drill/keyboard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ const Fab = require('@material-ui/core/Fab').default;
const PropTypes = require('prop-types');
const React = require('react');
const { Backspace, KeyboardReturn } = require('@material-ui/icons');
const Tooltip = require('@material-ui/core/Tooltip').default;

const buttonStyle = {
margin: '5px',
Expand Down Expand Up @@ -83,15 +84,17 @@ class Keyboard extends React.Component {
<div key={lay[0]}>
{
lay.slice(1).map((item) => {
const [content, key] = item;
const [content, title, click, key] = item;
return (
<Fab
key={key}
onClick={() => this.onClick(key)}
style={buttonStyle}
>
{content}
</Fab>
<Tooltip title={title}>
<Fab
key={key}
onClick={() => this.onClick(click)}
style={buttonStyle}
>
{content}
</Fab>
</Tooltip>
);
})
}
Expand Down

0 comments on commit 9750650

Please sign in to comment.