JSFiddle - React, Tailwind, and code Playground
HTML
<input
placeholder="enter time"
type="time"
onChange={setTime(this)}
/>
JavaScript
function setTime(time) {
const today = new Date();
console.log(new Date(today.toDateString() + ' ' + time.value));
}