Andy Clarke的CSS命名建议

2009年3月23日 | 分类: Web前端 | 标签:

如下:

#container

Page container (usually a <div>)

#branding
Used for a header or banner to brand the site.
#branding-logo
Used for a site logo
#branding-tagline
Used for a strapline or tagline to define the site’s purpose
#nav or #navigation
Used to contain a navigation device
#nav-main
Main or primary navigation
#nav-section
Navigation to pages within the current site section
#nav-external
Navigation to pages outside the site
#nav-supplementary or #nav-supp
A supplementary list of links, perhaps in a footer. This can replace the common, but presentational #footer
#nav-(whatever)
A list of links named at a designer’s descretion
#search
Related to search interface and search results
#search-input
A search form
#search-output
Search results which could include a <div> or other markup including definition lists
#content
Used for content rather than for another purpose such as navigation
#content-main
The main content area
#content-news
News related content
#content-(whatever)
Could include any form of content, including #content-related, #content-quote etc.
#siteinfo
Used for various site related information
#siteinfo-legal
Copyright information etc.
#siteinfo-credits
Designer or other credits
E-commerce related
#content-products
An overall area containing products
.products
Referring to individual products
.products-prices
Prices, discounts, special offers etc.
.products-description
A summary or longer description of a product
.products-review
A customer review
.products-(whatever)
Could include any form of product related content
原文连接:

http://www.stuffandnonsense.co.uk/archives/whats_in_a_name_pt2.html

目前还没有任何评论.
注意: 评论者允许使用'@user:'的方式将自己的评论通知另外评论者。例如, ABC是本文的评论者之一,则使用'@ABC:'(不包括单引号)将会自动将您的评论发送给ABC。请务必注意user必须和评论者名相匹配(大小写一致)。