background preloader

CSS

Facebook Twitter

Essential considerations for crafting quality media queries. CSS3 media queries are dead simple, in terms of their syntax.

Essential considerations for crafting quality media queries

You’ve got an @media directive, a media type (which you already know from good ol’ CSS 2, like screen, print, all, etc.) and one or more media features (the characteristics we’re testing against). That’s it: @media screen and (max-width:500px) { } There are some additional little syntax details, but this is basically all you need to know to actually make a media query work. Once you memorize this short, simple syntax and the various media features that are available, you could technically say that you know how to use media queries. Designing web layouts with media queries is a process. This article is just as much for me as it is for you—it can be hard to keep track of all the different configuration variations you can use! How to include your media queries: embedded vs. external There are two ways to include media queries in your site: embed them within a style sheet or include them in a call to a separate, external sheet.

CSS-Tricks. FFFFALLBACK - A simple tool for bulletproof web typography.

Webfonts

Box shadow. Transition. Mobile. Background. CSS3 animated button demo. 3D Text Using Just CSS · Deep Thoughts by Mark Otto. Type study: An all CSS button. This is part of a series of guest posts covering tips and tricks for working with fonts on the web.

Type study: An all CSS button

Today’s post was written by Dan Cederholm of SimpleBits. A few years ago I gave a talk about why a button made a great place to bring in type from a branding element (such as a logo). My point was that if the type in your logo was an image, and stylish buttons were also often images, then why not align the fonts in both to bring some cohesiveness to the typography. This was probably four years ago, and we’ve come a long way since. Now, in certain situations, CSS can replace the inflexible image buttons we used in the past. The button is also a great place to showcase many of the new CSS3 properties in one place, which is another reason I’m particularly taken with buttons at the moment.

Let’s build a button, friends. The markup I’m going to use a hyperlink in this example, but the styles we’re going to add could just as easily be applied to a <button> or <input> element as well. And voilà. Media Queries. Css-discuss.org. Css-discuss: last 40 messages. CSS Template Layout Module. Abstract A grid with four slots defined by ‘display: "aaaaaaa" "bccccdd"’.

CSS Template Layout Module

CSS is a simple, declarative language for creating style sheets that specify the rendering of HTML and other structured documents. This module contains CSS features to describe layouts at a high level, meant for tasks such as the positioning and alignment of “widgets” in a graphical user interface or the layout grid for a page or a window. A layout grid or “template” defines one or more “slots” that an element's content can flow into.

This allows elements to have complex shapes and it allows the visual order to be different from the order of the elements in the source document. A ‘::slot’ selector allows elements to be styled differently based on which slot they appear in. Status of this document This section describes the status of this document at the time of its publication. Publication as a Working Draft does not imply endorsement by the W3C Membership. Table of contents 1. Selectors [SELECT] 2. Resp 3. 3.1. 3.2. 4.