import * as React from 'react'; import JqxFormattedInput from 'jqwidgets-scripts/jqwidgets-react-tsx/jqxformattedinput'; import JqxPanel from 'jqwidgets-scripts/jqwidgets-react-tsx/jqxpanel'; class App extends React.PureComponent<{}> { private myPanel = React.createRef(); constructor(props: {}) { super(props); this.onOpen = this.onOpen.bind(this); this.onClose = this.onClose.bind(this); this.onChange = this.onChange.bind(this); this.onRadixChange = this.onRadixChange.bind(this); } public render() { return (
Events log:
); } private onOpen(event: any): void { this.myPanel.current!.append('' + event.type + '
'); }; private onClose(event: any): void { this.myPanel.current!.append('' + event.type + '
'); }; private onChange(event: any): void { const args = event.args; const newValue = args.value; const oldValue = args.oldValue; const radix = args.radix; this.myPanel.current!.append('' + event.type + '
' + 'value: ' + newValue + ', old value: ' + oldValue + ', radix: ' + radix + '
'); }; private onRadixChange(event: any): void { const args = event.args; const newRadix = args.radix; const oldRadix = args.oldRadix; const newValue = args.value; const oldValue = args.oldValue; this.myPanel.current!.append('' + event.type + '
' + 'radix: ' + newRadix + ', old radix: ' + oldRadix + '
value: ' + newValue + ', old value: ' + oldValue + '
'); }; } export default App;