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

Link relation for dark color scheme in alternate links #78

Open
mickael-menu opened this issue Feb 22, 2021 · 0 comments
Open

Link relation for dark color scheme in alternate links #78

mickael-menu opened this issue Feb 22, 2021 · 0 comments

Comments

@mickael-menu
Copy link
Member

In some cases, it could be useful to declare a "dark mode" variant of an alternate Link object. For example with the logo image in the OPDS Authentication Document.

For the sake of standardization, I suggest using the color-scheme-dark / color-scheme-light link relations. Inspired by the prefers-color-scheme media query.

"links": [
    {
        "href": "http://example.com/logo.jpg",
        "rel": "logo",
        "type": "image/jpeg",
        "alternate": [
            {
                "href": "http://example.com/logo-dark.jpg",
                "rel": "color-scheme-dark",
                "type": "image/jpeg"
            }
        ]
    },
]
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

1 participant