Monday 21st of August 2017 02:40:10 AM

Style Guide

CSS Style Sheets & Tips

Library projects must use valid Cascading Style Sheets (CSS) to control typography, color, and other layout elements. Style Sheets must be linked in a way that accommodates the capabilities of new and old browsers.

CSS Guidelines 1, 2, 3
Introduction to CSS (with examples), CSS definitions and benefits, tips on authoring, plus extensive resources
Steal These Style Sheets!
Style Sheets for your use in Library projects
CSS Validation
Ensuring that your Style Sheets are error–free (same as XHTML validation)

A number of valid Style Sheets have been provided for your use. If you wish to create your own Style Sheets, please discuss your requirements with the Branch Library's Web Coordinator.

return later in the chapter.

Given the way colors are created on a monitor, it makes sense that agood way to let you set colors is to give you direct access to thosecolor levels, thereby determining your own mixture of the beams. Thismethod is a bit more complex, obviously, but the payoffs are worth itbecause you aren't limited to whichever colors have been named. Percentage colors

Since there is a color value defined by the browser for TABLE elements, it will take precedence over the inherited value. This is annoying and unnecessary, but it is an obstacle to be overcome. You can overcome it (usually) with selectors that list various table elements. For example, in order to get all your table content to be red along with your document's body, try this:

BODY, TABLE, TD, TH {color: red;}

This will often solve the problem. I say "often" because

As you can see, the order of the actual values doesn't reallymatter. The following three rules will yield exactly the same border,as illustrated in Figure 7-47:

H1 {border-bottom: 3px solid gray;}H2 {border-bottom: solid gray 3px;}H3 {border-bottom: 3px gray solid;}
Figure 7-47

Figure 7-47. Getting the same result in three different ways

You can also leave out some values and have their defaults kick in,like this: