Created
January 26, 2021 21:47
-
-
Save gjorgiev/eb479e443aae375b3cbd242c54a3b0f6 to your computer and use it in GitHub Desktop.
Keypad Component
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.Keypad { | |
display: flex; | |
flex-wrap: wrap; | |
flex-direction: column; | |
height: 80%; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, {Component} from 'react'; | |
import "./Keypad.css"; | |
class Keypad extends Component { | |
render(){ | |
return( | |
<div className="Keypad"> | |
{/* We are using composition instead of inheritance. | |
read more: https://reactjs.org/docs/composition-vs-inheritance.html */} | |
{this.props.children} | |
</div> | |
); | |
} | |
} | |
export default Keypad; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment