From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=MAILING_LIST_MULTI, NICE_REPLY_A,RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 30486 invoked from network); 22 Jan 2023 13:04:53 -0000 Received: from lists.zx2c4.com (165.227.139.114) by inbox.vuxu.org with ESMTPUTF8; 22 Jan 2023 13:04:53 -0000 Received: by lists.zx2c4.com (ZX2C4 Mail Server) with ESMTP id 3a3f582f; Sun, 22 Jan 2023 13:04:41 +0000 (UTC) Return-Path: Received: from smtpout-37.fbg1.glesys.net (smtpout-37.fbg1.glesys.net [2a02:751:100:1::37]) by lists.zx2c4.com (ZX2C4 Mail Server) with ESMTPS id 32d0c9f4 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO) for ; Sun, 22 Jan 2023 13:04:39 +0000 (UTC) X-Sender-ID: 5383c4d7-9a55-11ed-8498-371c8b8afd02 Date: Sun, 22 Jan 2023 14:04:37 +0100 From: Samuel =?ISO-8859-1?Q?Lid=E9n?= Borell To: cgit@lists.zx2c4.com Subject: Re: [PATCH v3] css: Support for dark mode Message-Id: <20230122140437.4b530f77458029e4ae43c229@kodafritt.se> In-Reply-To: <20230122122519.3D50F13F@badger.kodafritt.se> References: <20230122122519.3D50F13F@badger.kodafritt.se> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; aarch64-unknown-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-BeenThere: cgit@lists.zx2c4.com X-Mailman-Version: 2.1.30rc1 Precedence: list List-Id: List for cgit developers and users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: cgit-bounces@lists.zx2c4.com Sender: "CGit" On Sun, 22 Jan 2023 12:35:09 +0100, Samuel Lid=E9n Borell wrote: > Modern browsers have a "dark mode" preference, which enables alternate > styles on web sites that support this. >=20 > This patch adds a dark color scheme, that is automatically activated > via a CSS @media query. >=20 > Older browsers that do not support color schemes will simply show the > light scheme, but possibly without syntax highlighting. >=20 > Note that filters that use color (such as source highlighters) and > logotypes may need to be updated to work with a black background! > See the updated files in the filters/ directory. Just a description of the changes from the previous version of the patch: * Improved the dark color scheme * Fixed white pixels around code blocks in markdown pages * Fixed invisible text in formatters by wrapping even the light CSS in medi= a queries. Unfortunately this disables highlighting on old browsers, which = instead show black text. * Fixed CSS for highlight 3 * Added "only all and" to the dark media query, so it gets ignored by (extr= emely) old browsers. Tested on Firefox 102.7.0 ESR, Firefox 109, Chromium 109 and Netsurf 3.10. = Netsurf is a browser that does not support color schemes, and defaults to t= he light theme. Firefox has a "resist fingerprinting" mode, in which it alw= ays uses the light theme. Regards, Samuel