Skip to content

Instantly share code, notes, and snippets.

View atomiomi's full-sized avatar
🏠
Working from home

Abylay atomiomi

🏠
Working from home
View GitHub Profile
/**
* Calculate the contrast of a color to determine the appropriate opposing text color.
* @author D. Condrey
* @param {string|object} - element background-color or element
* @return {string}
* white - if background is a dark shade color
* black - if background is a light shade color
*/
define(function() {
{
"applinks": {
"apps": [],
"details": [
{
"appID": "JFM85B4M73.de.nebenan.nebenan.dev",
"paths": [ "NOT *"]
}
]
}
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
addInput: (Component) =>
@inputs.push(Component) unless Component in @inputs
removeInput: (Component) =>
index = @inputs.indexOf(Component)
@inputs.splice(index, 1) if index >= 0