useFilePicker icon indicating copy to clipboard operation
useFilePicker copied to clipboard

feat: make openFilePicker function return a promise, add detection of picker cancellation

Open MrKampla opened this issue 6 months ago • 1 comments

Summary:

  • Adds long awaited return values to the opneFilePicker function, mentioned in #56
  • Adds reliable detection of picker cancellation, mentioned in #88

Adds a new prop called "detectCancellation" that can be set to "promiseResultOnly", "promiseResultAndHookState" or false. Allows to define if the cancellation detection should be shown and when (only in the result type or also in hook state). Default is false because in most use cases we don't care about the cancelled selections.

MrKampla avatar Aug 08 '25 17:08 MrKampla