mirror of
https://github.com/Grasscutters/Cultivation.git
synced 2025-12-15 16:44:43 +01:00
language beginning
This commit is contained in:
@@ -7,18 +7,10 @@ interface IProps {
|
||||
id: string;
|
||||
}
|
||||
|
||||
interface IState {
|
||||
text: string;
|
||||
}
|
||||
|
||||
export default class BigButton extends React.Component<IProps, IState> {
|
||||
export default class BigButton extends React.Component<IProps, never> {
|
||||
constructor(props: IProps) {
|
||||
super(props)
|
||||
|
||||
this.state = {
|
||||
text: props.text
|
||||
}
|
||||
|
||||
this.handleClick = this.handleClick.bind(this)
|
||||
}
|
||||
|
||||
@@ -29,7 +21,7 @@ export default class BigButton extends React.Component<IProps, IState> {
|
||||
render() {
|
||||
return (
|
||||
<div className="BigButton" onClick={this.handleClick} id={this.props.id}>
|
||||
<div className="BigButtonText">{this.state.text}</div>
|
||||
<div className="BigButtonText">{this.props.text}</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user