frontend icon indicating copy to clipboard operation
frontend copied to clipboard

Add user prompts two file select window

Open YaleChen299 opened this issue 2 years ago • 1 comments

Behaviour as described in the title.

Reason: not investigated.

YaleChen299 avatar Aug 13 '22 12:08 YaleChen299

Just confirming: this is not resolved.

martin-henz avatar Mar 30 '24 07:03 martin-henz

Took a stab at the investigation, would be working on a PR soon.

Both <CSVReader> and <FileInput> components spawn a window when clicked.

The first window, spawned by <CSVReader> asks for a csv file. The second window, spawned by <FileInput>, accepts any kind of file. We should only be uploading the csv file to the first window since it will then be passed around by <CSVReader> into the validateCsvInput function.

      <CSVReader
        onUploadAccepted={(results: any) => validateCsvInput(results)}
        config={{
          delimiter: ',',
          skipEmptyLines: true
        }}
      >
        {({ getRootProps, acceptedFile, ProgressBar, getRemoveFileProps }: any) => (
          <>
            <FileInput text="Upload CSV" inputProps={getRootProps()} />
          <>
      )

cheehongw avatar Apr 15 '24 17:04 cheehongw