Skip to content

Add :root { color-scheme: light dark; } to http.server directory list and error pages #123430

Closed
@YorikHansen

Description

@YorikHansen

Feature or enhancement

Proposal:

Allow browsers to apply light or dark themes to the http.server directory list according to the users prefered color scheme.

This can be done by adding the CSS color-scheme property to :root with the value light dark.

:root {
    color-scheme: light dark;
}

Has this already been discussed elsewhere?

This is a minor feature, which does not need previous discussion elsewhere

Links to previous discussion of this feature:

Something similar was discussed previously in #95812. There it was rejected, as "[t]he listing [should] not contain any hardcoded colors".

I agree with this statement, but I think the page should allow browsers to select their own color scheme and don't see it as a "a problem either with [the] configuration or with the browser", as long as the color-scheme property is not set properly.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    stdlibPython modules in the Lib dirtype-featureA feature request or enhancement

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions