import React, { useState } from 'react'; import { CustomBigWigProps } from './types'; const CustomBigWig: React.FC = props => { const [ url, setUrl ] = useState("https://"); const [ title, setTitle ] = useState("title"); return ( <> add custom {props.text || "BigWig"}:  setUrl(e.target.value)} /> setTitle(e.target.value)} /> { props.onSubmit && props.onSubmit({ url, title }); }} /> ); } export default CustomBigWig;