Closed Bug 1914597 Opened 1 year ago Closed 1 year ago

Favicon not respecting (prefers-color-scheme) called from several <link>s

Categories

(Core :: General, defect)

Firefox 130
defect

Tracking

()

RESOLVED DUPLICATE of bug 1603885

People

(Reporter: contact, Unassigned)

Details

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:130.0) Gecko/20100101 Firefox/130.0

Steps to reproduce:

Trying this out in Firefox 130 on macOS 14.3.

Register two variants of a favicon using <link>s, one light and one dark:

´´´
<link rel="shortcut icon" href="img/favicon-white.png" media="(prefers-color-scheme: dark)"/>
<link rel="shortcut icon" href="img/favicon-black.png" media="(prefers-color-scheme: light)"/>
´´´

Actual results:

When switching to light or dark mode, the favicon stay the same, using it seems the latest declaration.

Expected results:

When switching to light or dark mode, the favicon should switch between the two versions. This is the behaviour on Chromium.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/link#conditionally_loading_resources_with_media_queries

The Bugbug bot thinks this bug should belong to the 'Core::Audio/Video' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → Audio/Video
Product: Firefox → Core
Component: Audio/Video → General

(In reply to BugBot [:suhaib / :marco/ :calixte] from comment #1)

The Bugbug bot thinks this bug should belong to the 'Core::Audio/Video' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

No I don’t think it is Audio/Video at all. I don’t know what it is, a mix of media query from CSS, and HTML attribute, and calling images.

Status: UNCONFIRMED → RESOLVED
Closed: 1 year ago
Duplicate of bug: 1603885
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.