Open lutien opened 4 months ago
So, looking at this, the spec is trying to compare a set of path strings to a set of selected files, which are structs with a filename, a file type and a body. That's obviously not going to work in the way it intends.
I can't see any way to get the full filesystem path from what's in the HTML spec, so it would take quite some effort to make that possible spec wise.
Since the only use case here is triggering a cancel event, I wonder if we shouldn't just have a specific input that always triggers the cancel event without updating the files list (e.g. just not providing a files
array or maybe something more explicit).
The Browser Testing and Tools Working Group just discussed Clarify when files set with "input.setFiles" command should be considered equal to the selected files
.
In
input.setFiles
command algorithm(https://w3c.github.io/webdriver-bidi/#command-input-setFiles) in the step 12, we have to identify intersection offiles
argument and the selected files of input element, for this we have to check if the files are equal, but the spec is not specific in which cases we should consider files equal. Maybe the spec should be more specific here.