import NumberPicker from '..'; import React from 'react'; import ReactDOM from 'react-dom'; interface PageStates { value: number; tip: string; } class App extends React.Component<{}, PageStates> { constructor(props) { super(props); this.state = { value: 0, tip: '', }; this.onChange = this.onChange.bind(this); } onChange(value) { let num = ''; if (value >= 0) { num = value; } else { num = `negative ${value * -1}`; } this.setState({ value, tip: `${num}`, }); } render() { const { value, tip } = this.state; return (