Skip to content

Commit

Permalink
fix(fileuploaderdropcontainer): moved input out of label to fix a11y …
Browse files Browse the repository at this point in the history
…bug (#10444)

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
  • Loading branch information
Tanner Summers and kodiakhq[bot] authored Jan 24, 2022
1 parent bd73bc2 commit d02f94d
Showing 1 changed file with 15 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -116,22 +116,22 @@ function FileUploaderDropContainer({
<div className={dropareaClasses} role={role || 'button'}>
{labelText}
</div>
<input
type="file"
id={uid}
className={`${prefix}--file-input`}
ref={inputRef}
tabIndex="-1"
disabled={disabled}
accept={accept}
name={name}
multiple={multiple}
onChange={handleChange}
onClick={(evt) => {
evt.target.value = null;
}}
/>
</label>
<input
type="file"
id={uid}
className={`${prefix}--file-input`}
ref={inputRef}
tabIndex="-1"
disabled={disabled}
accept={accept}
name={name}
multiple={multiple}
onChange={handleChange}
onClick={(evt) => {
evt.target.value = null;
}}
/>
</div>
);
}
Expand Down

0 comments on commit d02f94d

Please sign in to comment.