Skip to content

File Selection and Section Input Validation #139

Description

@bhumulanandinireddy

Issue Description

  1. File Selection Behavior:

    • When a user removes a selected file by pressing the cross (✖) icon, the file name is not getting replaced correctly.
    • Single File Selection: If only one file is selected and removed, the UI should replace the file name with "No file chosen."
    • Multiple File Selection: If multiple files are uploaded and one is removed, the remaining selected files should still be displayed along with the "Choose File" text to indicate that more files can be added.
  2. Number of Sections Input Validation:

    • The input field for "Number of Sections" is currently accepting all characters, including letters and special symbols.
    • It should only accept integer values to prevent invalid inputs.
    • The placeholder text or error message should clearly state that only numeric (integer) values are allowed for better user understanding.

Current Status

  • The text "Choose File" is not appearing beside the selected file name.
  • When a user clicks the cross icon to remove a file, the previously selected file name is still visible instead of being replaced with "No file chosen."
  • When multiple files are uploaded and one is removed, the UI does not indicate that additional files can still be added.
  • The "Number of Sections" input field is accepting non-numeric values (letters and symbols), leading to potential errors.

Acceptance Criteria

  • For File Selection:

  • When a file is selected, the UI should display the file name along with the "Choose File" text beside it.

  • Single File Selection: If the user removes the only selected file, the file name should be replaced with "No file chosen."

  • Multiple File Selection: If a user removes one file, the remaining selected files should still be displayed.

  • The "Choose File" text should remain visible beside the selected files, allowing the user to upload more files.

  • The UI should update dynamically without requiring a page refresh.

  • For Number of Sections Input:

  • The input field should accept only integer values (positive whole numbers).

  • If a user enters non-numeric characters, an error message should be displayed.

  • The placeholder text or label should clearly indicate that only integers are allowed (e.g., "Enter a whole number (e.g., 1, 2, 3)").

Activity

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions