Welcome back to another edition of What’s !important, rounding up the most compelling developments, discussions, and techniques produced by CSS developers and web platform engineers over the past couple of weeks. As autumn approaches, the web development ecosystem continues to push forward with innovative ways to solve longstanding interface challenges, bridge gaps between JavaScript and native HTML, and expand the expressive capabilities of modern stylesheets.
Rethinking Tooltip Interactions
One of the most nuanced discussions in user experience design recently centers around the behavior of tooltips. Abhishek Jakhar published a deep dive into why standard tooltips often frustrate users and argued that they should feature a delayed trigger followed by an instant dismissal. Essentially, a slight pause before the tooltip appears prevents accidental triggers as a user’s cursor sweeps across a crowded interface. However, once the tooltip is visible and the user moves away, it should vanish immediately to avoid lingering obstruction.
Abhishek demonstrated how to implement this pattern using web technologies, though a minor caveat remains: if the hoverable trigger region is too small, the tooltip can be de-triggered unintentionally during the initial delay window, meaning developers must carefully balance their delay timings based on target sizing.
Following this, Chris Coyier weighed in with a modern implementation utilizing interest invokers. This approach relies on two specific CSS properties: interest-delay-start and interest-delay-end. While browser support for interest invokers is currently limited to Chrome, the technique serves as a prime example of progressive enhancement in action, allowing advanced browsers to handle native interest tracking while falling back gracefully elsewhere.
The <geolocation> Element and Progressive Enhancement
Speaking of progressive enhancement, managing user location requests has historically been a friction-heavy endeavor. The traditional Geolocation API requires juggling external hardware inputs—including GPS satellites, Wi-Fi networks, and cellular towers—while handling complex permission states that can be notoriously frustrating to alter after the fact.
A newly proposed native HTML approach, the <geolocation> element, aims to streamline much of this complexity. By shifting location requests into a native element framework, developers can bypass some of the boilerplate JavaScript previously required. However, the introduction of <geolocation> also brings new quirks, most notably specific styling restrictions enforced by the browser.

Because support for the <geolocation> element is currently restricted to Chrome, developers are looking at hybrid approaches. Industry discussions have focused on strategies to implement <geolocation> alongside the legacy Geolocation API, ensuring that modern browsers can leverage the new element while maintaining cross-browser compatibility today.
MicroLighter and the ::highlight() API
Syntax highlighting on the web is undergoing a structural rethink thanks to modern CSS features. Dave Rupert recently introduced MicroLighter, a lightweight syntax highlighter built upon the Custom Highlight API and its accompanying ::highlight() pseudo-element. Rather than injecting a dense tree of nested <span> elements into the DOM for every token of code, the Custom Highlight API allows developers to style ranges of text programmatically via JavaScript ranges and CSS pseudo-elements. Dave shared details on how MicroLighter operates, while Geoff Graham and other community members highlighted its potential performance benefits for rendering code blocks on documentation and developer-focused sites.
Extracting CSS Grid Information into Custom Properties
Layout architecture took a step forward as Temani Afif demonstrated a technique for exposing CSS grid information directly into CSS custom properties. By capturing layout metrics such as the total number of rows and columns, alongside the specific x and y coordinates of individual grid cells, developers gain unprecedented programmatic awareness of their grid structures.
The primary condition for this current approach is that columns must maintain equal widths, but as the CSS specification continues its rapid evolution, community members anticipate even greater flexibility in the future. Temani illustrated the practical utility of this technique by using grid coordinate data to calculate hover proximity effects—a sophisticated interaction pattern achieved with surprisingly clean modern CSS.
The Dark Mode Toggle Debate: Two-State vs. Tri-State
The ongoing debate over how to handle user interface color themes reached a new peak, with prominent developers weighing in on user preference management. Lea Verou advocated for a streamlined two-state toggle system, while Bramus made a compelling case for a tri-state dark mode toggle that gives users explicit control over light, dark, and system-default operating states. Meanwhile, developer Vale.Rocks outlined an auto-until-overridden two-state approach, which respects the system OS setting by default but seamlessly remembers explicit user overrides when toggled manually.
Looking Ahead: The Class Prefix Selector and @supports named-feature()
Bramus also introduced the concept of the class prefix selector, a straightforward yet powerful syntax proposal designed to target multiple classes efficiently. Although not yet implemented in any browser, the proposed syntax allows developers to target class patterns cleanly without resorting to cumbersome attribute selectors.

In traditional CSS, selecting elements based on partial class matches requires attribute selectors such as [class^="something-"] or [class*="something-"], which can carry performance overhead and introduce unintended matches. The proposed prefix syntax offers a cleaner, more performant alternative, leading many in the community to expect swift interest from browser vendors.
In addition to the class prefix selector, Bramus highlighted the introduction of the @supports named-feature() function, currently supported in Chrome. This function expands the capability of feature queries by allowing developers to test for hyper-specific browser behaviors that were previously undetectable—such as verifying whether a specific browser implementation correctly respects CSS transforms when applied to anchor-positioned elements.
Balancing Wrapped Flex Items
Finally, layout control in Flexbox received an update with Chrome’s support for flex-wrap: balance. Function similarly to text-wrap: balance for typography, this new property value aims to distribute wrapped flex items more evenly across available rows or columns, preventing awkward layouts where a final wrapped row contains only a single stray element. Ahmad Shadeed explored the mechanics of flex-wrap: balance, detailing practical use cases for creating visually balanced component grids without relying on complex JavaScript calculations.
As these features move from proposal stages to browser implementations, the web development landscape continues to gain powerful new primitives for layout, state management, and user interaction.
Leave a Reply