Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add dark theme #1432

Open
vitaly-zdanevich opened this issue Feb 19, 2020 · 6 comments
Open

Add dark theme #1432

vitaly-zdanevich opened this issue Feb 19, 2020 · 6 comments

Comments

@vitaly-zdanevich
Copy link

Save our eyes. And batteries. Do not ignore this property of useragent https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme

@pedrorijo91
Copy link
Member

Hey @vitaly-zdanevich

Thanks for raising this issue. We have a long effort for a re-design on #1179. @jasonlong :)

@BerndHme
Copy link

BerndHme commented Aug 8, 2023

I agree. Save our eyes. Please add a dark theme.

@h-shokri
Copy link

I really have problem with the light theme. Your website is so painful for most of users.

@sudoforge
Copy link

sudoforge commented Aug 7, 2024

i use qutebrowser and it has an in-built dark mode renderer:

colors.webpage.darkmode.enabled = true

this helps provide a dark mode for websites that don't respect colors.webpage.preferred_color_scheme = "dark". it also supports a couple different ways to approach changing the display of images in the DOM (see colors.webpage.darkmode.policy.images).

both of these fail to render git-scm.com in a dark mode -- more specifically, it works for text and many other elements, like anchor links, but fails with others because of the background images set via CSS using the background property (e.g. the masthead, and body background).

to get around this, i wrote a very tiny greasmonkey script and placed it in ~/.local/share/qutebrowser/greasmonkey/git-scm-background.js:

// ==UserScript==
// @name        Qutebrowser dark mode overrides for git-scm.com
// @version     0.0.0-alpha
// @author      sudoforge
// @license     Apache 2.0
// @include     https://git-scm.com/*
// @run-at      document-end
// ==/UserScript==

// I do this even though i have colors.webpage.darkmode enabled, because
// git-scm.com has a CSS property that sets the `background` prop using a
// light-colored image.
document.body.style.background = "#181818";

// This `background` prop for this element is originally set to transparent,
// with a light colored image.
masthead = document.getElementById("masthead");
if (masthead != null) {
    masthead.style.background = "#242424";
}

this is not a comprehensive rewrite at all. as you can see, it's just getting rid of the two largest annoyances for me. hope it helps.

@sudoforge
Copy link

there's also a large WIP effort to refactor away from RoR to a static site built with hugo (#1804), after which, it will hopefully be much easier for the team to add a native dark mode.

@dscho
Copy link
Member

dscho commented Sep 11, 2024

there's also a large WIP effort to refactor away from RoR to a static site built with hugo (#1804), after which, it will hopefully be much easier for the team to add a native dark mode.

That is my hope as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants
@dscho @pedrorijo91 @vitaly-zdanevich @sudoforge @h-shokri @BerndHme and others