• Firefox 69 was the first to implement selector feature queries, but other browsers are following suit. I’ll show you how it works, and how to start using this new feature query right away.

    View on Mozilla Developer »

    There are many ways to start using a new feature in CSS without waiting for full cross-browser support, but “feature queries” are the most clear and explicit. We can use them to test for browser support, and provide targeted styles only where they are supported. Now we can do the same with new selectors, like ::marker or :focus-visible!

    Selector queries allow us to finesse browser-support in new ways

    mozilla developer’ orgs

    Mozilla Developer

    DevRel Contractor: Videos, articles, & tools from Mozilla (and OddBird)

    11 ‘mozilla developer’ episodes

    2019

    Overflow-Wrap in CSS @ Mozilla Developer

    | video

    Horizontal text overflow has always been difficult to manage on the web. The default visible overflow is designed to make sure content remains accessible no matter the size of a containing box, but it’s not our only option.

    Scroll Snap in CSS @ Mozilla Developer

    | video

    When we’re scrolling down a page, or through a gallery of images, snap-targets can help guide us from one section or image to the next. In the past, developers have used JavaScript to hijack scrolling, but now we can manage scroll alignment directly in CSS with only a few lines of code.

    Inner & Outer Values of the Display Property @ Mozilla Developer

    | video

    The display property has been in CSS from the beginning, handling everything from block and inline boxes to list-items and full layout systems like flexbox or grid. Now the display syntax is getting an upgrade to match it’s multiple uses.

    Why isn’t this CSS doing anything? @ Mozilla Developer

    | video

    There are a number of property & value combinations that can lead to CSS being inactive, and now Firefox will tell you why. Open the developer tools, and look for the greyed-out property with an info-box on hover.

    Laying out Forms using Subgrid @ Mozilla Developer

    | video

    It’s a common pattern to align form labels and inputs in grid-like layout. I’ll show you how to do it quickly using CSS subgrid, with several quick fallbacks.

    Subgrid for Better Card Layouts @ Mozilla Developer

    | video

    Card layouts are popular on the web, rows and columns of boxes with similar content. CSS grids can help align those cards, but it’s still be hard to line-up content inside the cards – headers and footers that might need more or less room.

    Faster Layouts with CSS Grid @ Mozilla Developer

    | video

    For years, we’ve struggled to build resilient layouts on the web, but CSS Grid promises to change all that – and you can start using it now, with only a few properties and basic concepts.

    CSS Revert @ Mozilla Developer

    | video

    I’ve often used initial and unset in my CSS – global keywords that can be applied to any property. The difference is small, but important: unset allows inheritance, while initial does not. But then Firefox implemented revert and I was confused – how is this one different from the others?!

    Why is CSS so Weird? @ Mozilla Developer

    | video

    CSS is the design language of the web – one of three core web languages – but it also seems to be the most contentious and often perplexing. It’s too easy and too hard, too fragile and too resilient. Love it or hate it, CSS is weird: not quite markup, not quite programming in the imperative sense, and nothing like the design programs we use for print. How did we get here?

    Styling Lists in CSS @ Mozilla Developer

    | video

    When you create lists in HTML, browsers add bullet-points or numbers we call list markers. Now CSS gives us the tools to style those list markers, and even create our own!