jarlg / melatonin Goto Github PK
View Code? Open in Web Editor NEWMelatonin, an F.lux-like extension for Chrome, intended for Chromebooks
Home Page: https://jarlg.github.io/melatonin
License: MIT License
Melatonin, an F.lux-like extension for Chrome, intended for Chromebooks
Home Page: https://jarlg.github.io/melatonin
License: MIT License
Hi.
This will yield much better simulation of a gamma adjusted/redshiftet display. You will avoid whitewashing images and text will remain a much higher contrast and readability.
overlay
{
/* existing overlay code */
background-color: rgb(255 98 0);
opacity: 0.5;
mix-blend-mode: hard-light;
}
@supports not (mix-blend-mode: hard-light)
{
overlay
{
/* fallback method */
background-color: rgba(255 98 0, 0.2);
opacity: 1;
}
dialog
{
display: block;
/* dialog telling user to enable chrome://flags#enable-experimental-canvas-features */
}
}
You have to use opacity
and not rgba
with mix-blend-mode
.
Opera i pretty much verbatim compatible with the Chrome Extension API. Slight differences in packaging.
Just noticed that it seems color keyframe interpolation has a bug when transitioning past local midnight.
Reduces risk of sites adding paddings, margins, or other styles to the overlay with selectors like body div
, body div:first-of-kind
, or even plain div
. Should make overlay more robust and predictable.
document.registerElement("melatonin-overlay");
document.createElement('melatonin-overlay');
…
Experienced buggy overlay colors when passing local midnight, should verify if bug exists by writing tests.
"run_at": "document_start";
Significantly reduces white flashes.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.