Skip to content
Snippets Groups Projects
BatchParametersComponent.js 403 B
Newer Older
Gareth Hughes's avatar
Gareth Hughes committed
import React from "react";

const handleFocus = (event) => event.target.select();

export default function BatchParametersComponent(props) {

    const { param, setParam, label } = props;

    return (
        <div>
            <label>{label}</label>
            &emsp;&emsp;
            <input value={param} onChange={evt => setParam(evt.target.value)} onFocus={handleFocus}/>
        </div>
    );

}