5 ms·
I was so disappointed that every color picker website nowadays uses flash/zeroclipboard to only copy HEX color value (6 letters!). It's so slow and inefficient.
by zserge 11y ago
I was so disappointed that every color picker website nowadays uses flash/zeroclipboard to only copy HEX color value (6 letters!). It's so slow and inefficient. I ended up making my own one using this clipboard API - http://0xrgb.com http://0xrgb.com
Glad to see that FF now supports this API, too!
- M4v3R 11y agoIt fails silently on Safari, though.
- zserge 11y agoSorry, I don't have a Mac here to test, could you please file an issue here: https://github.com/zserge/palette https://github.com/zserge/palette (yes, 0xrgb.com is open source). By "fails" - you mean it doesn't select/highlight the color string, nor it does copy it to clipboard?
- Raphmedia 11y agoDoesn't copy. No errors in console.
- zserge 11y agoMight be fixed now. Can anyone confirm please?
- pipework 11y agoOn a mac, works for me.
- elithrar 11y agoStill fails silently in Safari 8.0.7 (10600.7.12) on Yosemite. (I had to load it in Chrome to understand what the intended behaviour was).
- Raphmedia 11y agoStill doesn't work. I have noticed that the click doesn't even trigger the animation of the color box too.
- Apofis 11y agoSafari is available for Windows...
- ck2 11y agoYup it wipes out whatever important info I was saving in my clipboard without warning me what-so-ever I guess I could put a megabytes into anyone's clipboard now when they click on any link on a website.
- anjanb 11y agoNo, you can't do that. from the mozilla link, "Google Chrome and Internet Explorer both also support this API. Chrome uses the same restriction as Firefox (that it must be run in a user-initiated callback). Internet Explorer allows it to be called at any time, except it first prompts the user with a dialog, asking for permission to access the clipboard."
- MichaelGG 11y agoClicking a link is a user-initiated callback. So yes, he can do exactly that. I wonder if mouse move is also user-initiated.