quotemstr 7 days ago

The OP isn't really asking for a "dark mode" like a literal reading of his comment might suggest. He's asking for an officially supported dark mode that evolves with the site and doesn't break random functionality one day. It's easy to use Stylist or TamperMonkey to make a dark mode that works at one instant of time. It's much harder to maintain one indefinitely in the face of constant changes made by developers not concerned with breaking your work, which they probably don't even know about.

2
SoftTalker 7 days ago

I think there was a vision early in the evolution of the web that user-supplied stylesheets would be a lot more commonly used than they turned out to be.

Things like colors, contrast levels, font sizes, are often matters of personal preference, and the browser (in theory) is the common place to manage those. Each site should not have to reinvent this feature.

galaxyLogic 6 days ago

User-style-sheets sound great in theory, but CSS is Cascading Style Sheets which means it would be very easy for users to break functionality of web-sites. For instance make the cascade cascade so that the text-color is same as background color on some widget on some website and you might be missing a button.

A user's custom style-sheet might be good for one web-site, but not for every website.

The original web was much about self-expression of developer-users, but now the web is all about apps, which must not break because a user might want to use different colors.

And why should you need to customize colors? I can understand that different users need larger fonts which you can do by zooming in the browser. Colors should be good to go if the website is well-styled to begin with.

quotemstr 6 days ago

> User-style-sheets sound great in theory, but CSS is Cascading Style Sheets which means it would be very easy for users to break functionality of web-sites. For instance make the cascade cascade so that the text-color is same as background color on some widget on some website and you might be missing a button.

Pretty sure AI-driven style derivation will finally deliver the dream of custom stylesheets in a robust and automatic way.

zzo38computer 6 days ago

> Colors should be good to go if the website is well-styled to begin with.

What if it is not well-styled? Or, maybe some people think it is and others disagree and want something else. The end user should need to customize fonts (not only larger, but also if you want smaller fonts; I more often find the fonts on a web page are too big and want smaller fonts; however, also you might prefer a specific font typeface and not only the font size), colours (also for many reasons, including using a monochrome display or printer that the web page author might not have been aware of), animations (e.g. to disable them), margins, etc.

zzo38computer 6 days ago

I think that being able to make user stylesheets based not only on HTML but also on ARIA attributes and on existing CSS commands, might be helpful, to compensate for the problems. User settings could also be used to e.g. override (and/or disable) the meaning of specific CSS commands in the styles specified in the document, and to override the results of media queries. It could also perhaps help to make the rendering more efficient if inefficient commands are disabled by the user (I often find it slow due to inefficient use of CSS commands).

quotemstr 6 days ago

> ARIA attributes

That works today. No problem.

    [role="button"] {
      cursor: pointer;
    }
> on existing CSS commands

Not sure what you mean. Between the new selector combinators and attribute selectors, you can do a ton. You also have style-based container queries, which are probably close to what you want.

johnisgood 7 days ago

It is possible to have this feature built-in to the browser. I am surprised it has not been implemented yet (?).

randallsquared 7 days ago

Browsers used to commonly support user stylesheets. Chrome removed it a long time ago, and I'm not sure what the status of that is in Firefox now. The issue is that there's no single common use case for them, and if there were, it would be simpler to build it in. But maintaining that level of flexibility has a continuing cost...

johnisgood 7 days ago

I am referring to the fact that there are more or less simple algorithms you can use to determine the dark version of colors, or rather, perceptually darker variants (e.g. APCA). The browser could make the contrast threshold configurable.

johnisgood 5 days ago

Oh, and there is inverse(), but I have no idea how good that is.

SoftTalker 7 days ago

Firefox appears to support a light and dark mode, custom foreground and background colors, and setting a default font face and size. Nothing like full user stylesheet support, at least not without extensions.

saint_yossarian 6 days ago

It does support the userContent.css file in the profile, there's just no UI for it.

shwouchk 6 days ago

safari still supports it on mac

altairprime 7 days ago

There was a Chrome experiment for it when I looked last year; it worked well in some cases and was just as bad at Google Sheets as every other generic darkmode solution.

vinceguidry 7 days ago

> Each site should not have to reinvent this feature.

This would send me into peals of laughter if I weren't already crying. The time to make this argument was 30 years ago, when the web wasn't fragmenting into a billion different pieces. The browser can make exactly zero assumptions about any given site, so it could never be a place where user preferences about them could be actionable. Downvoters should get work as web developers sometime. You really want the browser making assumptions about your web design?

All it can do is pass a header and let the website do what it will with it.

rcarmo 6 days ago

None of those extensions work in app-embedded browsers.