JSFiddle - React, Tailwind, and code Playground
HTML
<div class="filefield">
<input type="file" name="myfile" id="fileinput" >
<button>Click this instead</button>
<span></span>
</div>
JavaScript
$( 'button' ).click(function(){
$( '#fileinput' ).click();
});
$( '#fileinput').change(function(){
$( 'span' ).text($( this ).val() );
});