Visitar URL original
File Input: Loader spins indefinitely after selecting files with the same name in multiple inputs · Issue #4144 · uswds/uswds · GitHub
Skip to content

File Input: Loader spins indefinitely after selecting files with the same name in multiple inputs  #4144

Closed

Description

@jorgegonzalez

Describe the bug

When using multiple File Input components on the same page or form, subsequent selections of files with the same file name will cause those input forms to display the filename, but the loading icon remains permanently visible on the page.

This can be reproduced on the USWDS File input component demo page:

Steps to reproduce the bug

  1. Go to https://designsystem.digital.gov/components/file-input/
  2. Upload any text file to the first file input component in the form.
  3. Upload the same file to the second file input component in the form.
  4. The second file input will display the name of the newly uploaded file but, but the loader spins forever.

Expected behavior

The inputs should not remain in a loading state once the files are selected, regardless of a non-unique file names between inputs on the same page.

Screenshots

Screen Shot 2021-04-06 at 9 55 17 AM
Screen Shot 2021-04-06 at 9 54 17 AM

System setup

  • USWDS version: Found locally on version 2.9.0, and on the USWDS demo website
  • Device: MacBook Pro
  • Operating system: macOS 11.2.3
  • Browser and version: Safari 14, Edge 89

Additional context

Discovered while developing raft-tech/TANF-app#705

Activity

  1. mejiaj commented on Apr 6, 2021

    @mejiaj
    Contributor

    Thanks for the detailed report!

  2. added
    Package: File InputWork affecting File Input. Apply only when this area helps route or find the issue.
    on Jun 15, 2021
  3. added a commit that references this issue on Oct 25, 2021
    ef2d2fb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Context: JavaScriptIssue is in JavaScriptPackage: File InputWork affecting File Input. Apply only when this area helps route or find the issue.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions