Re: [w3ctag/design-reviews] EyeDropper API (#587)

> > Some of us were surprised by the [promise rejection when no selection is made](https://wicg.github.io/eyedropper-api/#eyedropper-interface) (vs resolving with `null`), since this is [ordinary use and not an unusual bad state](https://www.w3.org/2001/tag/doc/promises-guide#rejections-should-be-exceptional). Do you consider exiting without a color selection an error condition? Did you choose this design to be consistent with another API?
> 
> I was not involved at all, so can't speak for the authors, but as a data point the File System Access API likewise [throws an `AbortError`](https://wicg.github.io/file-system-access/#:~:text=their%20selection.-,if%20the%20user%20dismissed%20the%20prompt%20without%20making%20a%20selection%2C%20reject%20p%20with%20an%20aborterror%20and%20abort.,-Let%20entries) should the user cancel the picker.

Yup, this was mentioned in the discussion (and in https://github.com/w3ctag/design-principles/issues/55 ), hence the last question.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3ctag/design-reviews/issues/587#issuecomment-911742433

Received on Thursday, 2 September 2021 14:24:43 UTC