jimschubert / NewTab-Redirect

NewTab Redirect! is an extension for Google Chrome which allows the user to replace the page displayed when creating a new tab.
MIT License
479 stars 88 forks source link

"Dark Theme" CSS (Incomplete) #187

Open alainbryden opened 3 years ago

alainbryden commented 3 years ago

To get the conversation started on #175, these are some minimal changes I've made to the CSS to get everything looking "nice", but in a dark theme (based on the colour scheme of other well-accepted dark themes).

image

image

image


I realize that the more difficult job is to make this configurable / togglable, so my apologies for not delving into that myself.

The most important aspect of this change is that when opening a new tab (in the few milliseconds before the redirect), the user does not get greeted with a flash of white before then transitioning to a dark destination site.

image

If you wanted to be real smooth, you could actually "remember" the body background-colour of the configured redirect site, and set that as the background, but I have no thoughts on you could implement that - just an idea.

All the best,

lucasrumney94 commented 3 years ago

If this really works and stops the white page flashing when I open up my new tab, I'd love to have this in the extension. I tried opening up my localdata folder and copying in the CSS myself, but Chrome recognized that it "corrupted" the extension (probably changed the hash and set off flares for security purposes). Any way I could get this change on my local install of the app? Thanks!

alainbryden commented 3 years ago

@lucasrumney94 The way I did this for myself was to fork the repo, make the changes in this PR, and then enable "developer mode" on the extensions tab to get an option to load my "unpacked extension". I also turned off the official one.

image

Hopefully some combination of these steps lets you use the modifications as well in the mean time.

lucasrumney94 commented 3 years ago

Great Extension, Great Fix

@alainbryden That worked, and it totally solved my white screen before my page load problem. I can't thank you enough for taking the time to provide clear visual instructions to enable this. I can browse with my custom new tab page at night without fear now. I happen to use Brave as my Chromium flavor of choice, but your instructions worked identically. - I might even further tune the CSS to match a darker greenish-grey that matches my landing page exactly.

Hopefully this change gets pulled into master and/or helps the next person looking for this. Personally, I believe that having a dark interstitial screen by default is the less aggressive of the two options, especially for night-time users of the internet.

Thanks again and have a great week!

Before

newtabBright

After

newtabDimmedCSS

EDIT: I can't post art this without attribution, the artist is Maciej Kuciara. https://kuciara.com/

0Chuches commented 11 months ago

@alainbryden Hello guys I am new to this platform and I am also interested in the dark mode, but i dont know how to work with the css files. Could you give me a link to download the file. Pls.

2001Y commented 7 months ago

@jimschubert

This proposal is fantastic, and I would love to see it merged into the master branch. It would be even better if there's an option to specify a background color.

I often work late at night, and the sudden white flash is quite bothersome. Fast New Tab Redirect helps solve this issue, but it's using manifest v2, and when I open a new window from a closed Chrome instance, it still displays a blank, meaningless screen.

Therefore, I would love to see NewTab-Redirect support dark mode!