RC RANDOM CHAOS

Safari 27.3 Auto-Transforms Bright Sites to Dark Mode

· via Hacker News

Original source

Safari introduces Adaptive Dark Mode in 27.3

Hacker News →

Safari 27.3 introduces Adaptive Dark Mode, which automatically applies dark styling to websites lacking native support. The feature highlights a significant market mismatch—40% of page loads come from dark mode users, but only 10% of page loads visit sites providing native dark mode. Websites declaring dark mode support via the color-scheme meta tag or CSS property are exempt from transformation.

When active, Adaptive Dark Mode analyzes page colors to determine brightness, then transforms them while preserving hue relationships through an inverted-luminosity color matrix. The system targets a WCAG 4.5:1 contrast ratio for text readability. Different content types receive tailored handling: SVG images undergo color inspection, simple black-and-white logos receive pixel-histogram analysis for contrast preservation, and canvas elements remain untouched due to their unpredictable content.

To protect privacy, Safari blocks JavaScript from detecting when Adaptive Dark Mode is active. CSS color queries return original authored values rather than transformed ones, preventing fingerprinting exploitation. Developers retain control through adoption of modern practices—SVG graphics for logos, CSS properties for effects and gradients, and semantic color-scheme declarations.

Read the full article

Continue reading at Hacker News →

This is an AI-generated summary. Read the original for the full story.