MicrosoftEdge / MicrosoftEdge/MSEdgeExplainers
Questions on the explainer.
Open
@BoCupp-Microsoft is already working on this.
Since Aug 17, 2020.
EyeDropper
- Dominant language
- HTML
- Stars
- 1.4k
- Forks
- 286
- Avg merge
- 3d 1h
- Merged PRs (30d)
- 8
Description
Very cool start! Excited for this conversation to move forward, and have lots of questions:
- Does the following code in the explainer imply that the
EyeDropperwouldn't have its own UI when "closed"?
// Enter eyedropper mode
let icon = document.getElementbyId("eyeDropperIcon")
icon.addEventListener('click', e => {
eyeDropper.open().then(
() => { console.log("entered eyedropper mode") },
() => { console.log("could not enter eyedropper mode") }
)
});
- While you make a great point about previous art leaning away from the use of an extended
<input>element, would you still see this as being an element (there's actually no reference to it actually being an element but for argument's sake) that would be "form associated"? Or would this be something more "over the top" where the resultante.valuewould be passed into ainput[type="color"]element, or similar, to support this? - The element or not question is also pertinent in regards to
no UI events except colorselect are dispatched to the web pagewhich implies that the event is triggered onwindowordocumentwhile the example listens oneyeDropper.addEventListenerwhich without being an element would need to be anEventTarget, which I'm not sure actually bubbles its events towindowet al. - By the statement
the colorselect event is only dispatched while the primary pointer is down, do you see thecolorselectevent as streaming while the pointer is down? Would you pair this with a final event (colorchange, etc) when the pointer is "up" again? Or, as the example implies, would it be for the developer to "decide" when the user is done, possibly through only caring about the first event? If we needed the paired event names, would it make sense to fall back to prior art here and match aninputevent with achangeevent for regularity across features? - Returning to
while the primary pointer is down, how would you expect this API to interact with keyboard only use cases? - Would this be a purely JS space feature, or do you see there being an HTML first approach to this?
- Whether there is "closed UI" or not, there is "opened UI" and that being so what sort of customization pattern do you see being best to deliver with this sort of functionality? More specifically, the reason similarly complex UI/X patterns seem to be repeated often in userspace (see the
<select>pattern) is the overly restrictive visual delivery of said patterns, how could this proposal head that issue off at the pass? The possibilities of a completely "headless" version of this experience would be quite interesting. - While I appreciate the complexity of submitting a color object model along with this proposal, do you see any short comings around only supporting hex colors? The specifically available color space of hex colors might be too restrictive. Could you see this supporting a
type="rgb|hex|hsl|etc"property, or multiple types by default (see the Chrome DevTools colors selectors) to allow for a more expressive color capture mechanism? - On the subject of color, in the browser space, there is some context of alpha that could be applied to this picker. Do you see this as being a purely WYSIWYG result (so the fully composited color) only, or is there room for more complex resolution? Maybe not in a v1 but I'd be interested in seeing a possible path to doing so.
- I'll share thoughts on scoping the parts of the page that the
EyeDropperhas access to in #382.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.