sp-dev-fx-controls-react icon indicating copy to clipboard operation
sp-dev-fx-controls-react copied to clipboard

FilePicker: Single- or Mutltiselection Flag

Open kpfeuffer opened this issue 2 years ago • 10 comments

Thank you for reporting an issue, suggesting an enhancement, or asking a question. We appreciate your feedback - to help the team understand your needs please complete the below template to ensure we have the details to help. Thanks!

Please check out the Docs to see if your question is already addressed there. This will help us ensure our documentation covers the most frequent questions.

Category

  • [x] Enhancement
  • [ ] Bug
  • [ ] Question
  • [ ] Documentation gap/issue

Version

Please specify what version of the library you are using: [ 3.6.0 ]

Please specify what version(s) of SharePoint you are targeting: [ SPO ]

If you are not using the latest release, please update and see if the issue is resolved before submitting an issue.

Expected / Desired Behavior / Question

It would be great, if the Filepicker would allow to switch between single- and multi-selection. We currently need it for a project, where you can only pick a single image.

kpfeuffer avatar Mar 11 '22 12:03 kpfeuffer

Did you mean to submit this to the controls repo?

Edit: I can move the issue, just want to confirm my understanding. Thanks!

patrick-rodgers avatar Mar 11 '22 13:03 patrick-rodgers

Yes, please move this.

kpfeuffer avatar Mar 21 '22 06:03 kpfeuffer

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

ghost avatar Mar 21 '22 12:03 ghost

Hi @kpfeuffer

FilePicker control allow pick one or more files, the same for uploading. https://pnp.github.io/sp-dev-fx-controls-react/controls/FilePicker/

aaclage avatar Mar 22 '22 07:03 aaclage

Im aware of this, but it would be great if we could disable multi-selection. We are using it in a context, where multiple files make no sense and want to prevent confusing the users.

kpfeuffer avatar Mar 22 '22 10:03 kpfeuffer

Hi @kpfeuffer I think I understand the suggestion. You should be able to hide the multi-upload tab by using the hideLocalMultipleUploadTab property. This property is available, but seems to be missing from documentation. I just updated docs so should be published with the next release. Let us know if this does not solve your problem

image

joelfmrodrigues avatar Mar 22 '22 11:03 joelfmrodrigues

Hi,

this was more in reference to the recent, your org, stock images, and website-tabs as well. These seem to still allow for multiple picks when the hideLocalMultipleUploadTab option is set to true.

kpfeuffer avatar Mar 22 '22 12:03 kpfeuffer

@kpfeuffer I understand your need now. Unfortunately, the control does not currently have a property where we can specify the max number of files to be selected. If you would be interested in implementing this change, please let us know ☺️

joelfmrodrigues avatar Mar 22 '22 12:03 joelfmrodrigues

I can tackle this one.

ekapic avatar Aug 03 '22 07:08 ekapic

Hi, any update on this ticket

pratapraman avatar Mar 21 '24 05:03 pratapraman