
Product
Reachability for Ruby Now in Beta
Reachability analysis for Ruby is now in beta, helping teams identify which vulnerabilities are truly exploitable in their applications.
colorio is a color picker(eyedropper) GUI tool, implemented as a node.js module with a native macOS binary that represents GUI layer. It can be used in any stand-alone node.js or Electron.js applications running on macOS.

$ npm install colorio
Requires macOS 10.12 or later.
A minimalistic Electron based demo can be found by the following url:
59 kbconst pickColor = require('colorio').pickColor;
pickColor().then((res) => {
console.log(res);
//=> on color pick
// {
// "result": "picked",
// "color": {
// "r": 0.2980392156862745,
// "g": 0.6078431372549019,
// "b": 0.2980392156862745
// }
// }
//=> on hitting `Esc` key
// {
// "result": "canceled",
// }
});
NOTE: In Electrion applications this function should be called from the main process.
PromiseExecutes native binary file and returns a Promise for the result.
Fullfills when user picks color from the screen or aborts the action by hitting Esc key.
Type: string
Default: undefined
A custom path to the colorio's binary. Might be helpful in case of custom dev environment setup using webpack. If not set, path is resolved automatically based on __dirname with respect to app.asar.unpacked in case module is used in an Electron app.
Returns a promise with an object when promise is fullfilled. In case color is picked, the object will look like this, where color property contains r, g, b keys representing rgb color components in 0...1 range (0.0 -> 0, 1.0 => 255):
{
"result": "picked",
"color": {
"r": 0.2980392156862745,
"g": 0.6078431372549019,
"b": 0.2980392156862745
}
}
In case user cancels the action by hitting Esc key, the resulting object's result's key value will be set to canceled:
{
"result": "canceled"
}
Currently colorio doesn't support custom color spaces. Picked colors are converted via genericRGBColorSpace, thus the resulting colors might be a bit different from color pickers in other apps.
MIT
FAQs
Pick colors from the screen on macOS in Node or Electron.js applications
We found that colorio demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Reachability analysis for Ruby is now in beta, helping teams identify which vulnerabilities are truly exploitable in their applications.

Research
/Security News
Malicious npm packages use Adspect cloaking and fake CAPTCHAs to fingerprint visitors and redirect victims to crypto-themed scam sites.

Security News
Recent coverage mislabels the latest TEA protocol spam as a worm. Here’s what’s actually happening.