Skip to content

LightDarkImage issues in Payload docs #12769

Open
@bratvanov

Description

@bratvanov

The <LightDarkImage> component loads both the light and dark versions of an image when in dark mode.

On page load, the light image briefly flashes before being replaced by the dark image. Network logs confirm that both versions are requested.

Examples:

Additionally, when this page is opened directly in dark mode, only the light image is displayed. The dark image is never loaded. However, if you navigate to the page from another docs page, the dark image appears correctly.

Tested on the latest versions of Chrome, Safari, and Firefox on macOS 15.3.1 with system appearance set to "Dark". The issue does not occur when appearance is set to "Light" – only the light image is loaded, as expected.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions