Safari Technology Preview 240: Key WebKit Enhancements and Bug Fixes

By — min read
<article> <section id="introduction"> <p>The latest iteration of Apple's experimental browser, <strong>Safari Technology Preview 240</strong>, is now available for download on macOS Tahoe and macOS Sequoia. Existing users can update via System Settings under General → Software Update. This release incorporates a range of WebKit improvements from revisions 308418 to 309286, focusing on refining CSS, editing, forms, HTML, and media handling. Below, we break down the most notable changes and what they mean for developers and users alike.</p> </section> <section id="css-improvements"> <h2>CSS Enhancements</h2> <h3>New Features</h3> <p>A standout addition in this release is support for the <code>revert-rule</code> CSS keyword. This new keyword allows developers to roll back the cascade of a specific style rule, effectively making it as if the rule were never applied. This provides finer control over style inheritance and can simplify complex stylesheets by avoiding the need for elaborate specificity workarounds. (308733@main)</p><figure style="margin:20px 0"><img src="https://webkit.org/wp-content/themes/webkit/images/preview-card.jpg" alt="Safari Technology Preview 240: Key WebKit Enhancements and Bug Fixes" style="width:100%;height:auto;border-radius:8px" loading="lazy"><figcaption style="font-size:12px;color:#666;margin-top:5px">Source: webkit.org</figcaption></figure> <h3>Resolved Issues</h3> <p>Several CSS bugs have been addressed:</p> <ul> <li><strong>Custom scrollbar clipping on macOS:</strong> A fix ensures that custom CSS scrollbars are no longer cut off, and the scrollbar corner rectangle is now correctly sized. This resolves a visual glitch that affected aesthetic scrollbar designs. (309119@main)</li> <li><strong>Hanging punctuation for quotes:</strong> The <code>hanging-punctuation</code> property now correctly supports apostrophes (U+0027) and quotation marks (U+0022) as hangable characters, aligning with typographic expectations. (308597@main)</li> <li><strong>Ideographic space handling:</strong> The ideographic space character (U+3000) can now properly “hang” when used as the first value in <code>hanging-punctuation</code>. This improves text layout in CJK environments. (308605@main)</li> </ul> </section> <section id="editing-fixes"> <h2>Editing Improvements</h2> <p>The editing experience has received several critical fixes:</p> <ul> <li><strong>Font Picker usability:</strong> Previously, the Font Picker style selection became unresponsive after changing fonts during multi-line text edits. This bug has been resolved, ensuring a smooth workflow for content creators. (308562@main)</li> <li><strong>Emoji preservation across sites:</strong> Emoji images are now correctly preserved when copying and pasting content between different websites. This fix maintains visual consistency in cross-site content transfer. (309176@main)</li> <li><strong>Selection jumps with absolute positioning:</strong> Text selection no longer jumps unexpectedly when selecting absolutely-positioned elements inside a container with <code>user-select: none</code>. This enhances text selection reliability in complex layouts. (308451@main)</li> </ul> </section> <section id="forms-html"> <h2>Forms and HTML</h2> <h3>Forms</h3> <p>A single but impactful fix addresses keyboard tabbing: when a focused button becomes disabled, the tabbing position is no longer lost, preventing focus from resetting to the beginning of the page. This improves accessibility and form navigation. (308991@main)</p> <h3>HTML Parsing</h3> <ul> <li><strong>Viewport meta parsing:</strong> The viewport <code>&lt;meta&gt;</code> tag now correctly treats form feed as ASCII whitespace, as required by the HTML specification. This aligns Safari with standard parsing behavior. (309044@main)</li> <li><strong>Pixel-length margin attributes:</strong> Parsing of pixel-length margin attributes on <code>&lt;body&gt;</code>, <code>&lt;iframe&gt;</code>, and <code>&lt;frame&gt;</code> elements has been corrected, ensuring accurate rendering of these legacy attributes. (308526@main)</li> </ul> </section> <section id="media-updates"> <h2>Media Enhancements</h2> <p>The media subsystem received the most attention in this release, with numerous fixes targeting playback, decoding, and accessibility:</p> <ul> <li><strong>WebM audio with >2 channels:</strong> Decoding WebM audio files with more than two channels now works correctly, expanding support for multi-channel audio content. (308749@main)</li> <li><strong>VP8 in WebM support detection:</strong> <code>MediaCapabilities.decodingInfo()</code> no longer incorrectly reports VP8 in WebM as unsupported, helping developers accurately assess playback capabilities. (308789@main)</li> <li><strong>Opus in MP4 decoding:</strong> MP4 files containing Opus audio tracks can now be decoded with <code>decodeAudioData</code>, enhancing audio format compatibility. (309140@main)</li> <li><strong>Live Text in fullscreen video:</strong> Live Text selection is now available on paused fullscreen videos, allowing users to interact with text displayed in video frames. (308498@main)</li> <li><strong>FairPlay and VP9 via MediaSource:</strong> FairPlay-protected VP9 content now plays successfully when delivered via MediaSource, broadening DRM support. (308622@main)</li> <li><strong>Autoplay timing with text tracks:</strong> Autoplay no longer proceeds before default text tracks have finished loading, preventing playback issues with captions and subtitles. (308796@main)</li> <li><strong>currentTime getter fix:</strong> The <code>currentTime</code> getter now returns <code>defaultPlaybackStartPosition</code> when no media player exists, improving consistency in media element behavior. (308654@main)</li> <li><strong>timeupdate event reset:</strong> <code>HTMLMediaElement</code> now correctly fires a <code>timeupdate</code> event when resetting the playback position during media load, as required by the specification. This ensures developers receive proper playback state updates. (308695@main)</li> <li><strong>Preload attribute:</strong> An issue where the media player <code>preload</code> attribute was not being respected in certain scenarios has been fixed (details in the original changelog).</li> </ul> </section> <section id="summary"> <h2>Summary</h2> <p>Safari Technology Preview 240 brings a mix of meaningful CSS enhancements and targeted bug fixes across editing, forms, HTML, and media. For web developers, the <code>revert-rule</code> keyword offers new styling flexibility, while the media fixes improve compatibility with modern audio and video formats. The update is available now for macOS Tahoe and Sequoia, and we recommend downloading it to test your sites and applications against the latest WebKit changes.</p> </section> </article>
Tags: