primevue icon indicating copy to clipboard operation
primevue copied to clipboard

FileUpload v4.0.0-beta.3: Subsequent file selections no longer possible in basic mode (regression from v4.0.0-beta.2)

Open sceee opened this issue 1 year ago • 1 comments

Describe the bug

After choosing a file in FileUpload basic, you can no longer make a different selection after the first selection was made as the file chooser does no longer open if you click the Choose button after a file was chosen initially.

This is a regression from v4.0.0-beta.2 I think this is the change causing this: https://github.com/primefaces/primevue/commit/63d04f0788950d5e4fc22e7710bed752aa682882#diff-f7197e6585649dd533bfb0f3a1a19e25a1b9bfc436d4b7cb370c221cbb006004R101 If this.hasFiles === true, the input is no longer triggered.

Reproducer

https://stackblitz.com/edit/primevue-create-vue-typescript-issue-template-cepbjp?file=src%2FApp.vue

PrimeVue version

4.0.0-beta.3

Vue version

3.x

Language

TypeScript

Build / Runtime

Vite

Browser(s)

No response

Steps to reproduce the behavior

  1. Open the attached stackblitz (or the demo at https://v4.primevue.org/fileupload/#basic )
  2. Click the button to select a file
  3. Choose a file in the file picker
  4. Click the choose button again -> Nothing happens

Expected behavior

When clicking the choose button again after a file was selected, we can make a new file selection that replaces the previous selection.

sceee avatar May 15 '24 14:05 sceee

Same thing. The basic component is useless with custom uploading now.

ArchiDevil avatar Jun 22 '24 12:06 ArchiDevil