資源描述:
《補(bǔ)充資料開發(fā)中的css命名規(guī)范.doc》由會員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在教育資源-天天文庫。
1、開發(fā)中的css命名規(guī)范n在程序代碼中常用的欄目命名如下:專欄:column元素:element頁頭:header登錄條:loginbar標(biāo)志:logo側(cè)欄:sidebar廣告:banner導(dǎo)航:nav子導(dǎo)航:subnav菜單:menu子菜單:submenu搜索:search滾動:scroll頁面主體:main內(nèi)容:content標(biāo)簽頁:tab文章列表:list提示信息:msg小技巧:tips欄目標(biāo)題:title加入:joinus指南:guide服務(wù):service熱點(diǎn):hot新聞:news下載:download注冊:register狀態(tài):status按鈕:btn投票:vote合作伙伴:
2、partner友情鏈接:friendlink頁腳:footer版權(quán):copyrightn常用的CSS命名規(guī)則:頭:header內(nèi)容:content/container尾:footer導(dǎo)航:nav側(cè)欄:sidebar欄目:column頁面外圍控制整體布局寬度:wrapper左右中:leftrightcenter登錄條:loginbar標(biāo)志:logo廣告:banner頁面主體:main熱點(diǎn):hot新聞:news下載:download子導(dǎo)航:subnav菜單:menu子菜單:submenu搜索:search友情鏈接:friendlink頁腳:footer版權(quán):copyright滾動:scro
3、ll內(nèi)容:content標(biāo)簽頁:tab文章列表:list提示信息:msg小技巧:tips欄目標(biāo)題:title加入:joinus指南:guild服務(wù):service注冊:regsiter狀態(tài):status投票:vote合作伙伴:partnernid的命名:(1)頁面結(jié)構(gòu)容器:container頁頭:header內(nèi)容:content/container頁面主體:main頁尾:footer導(dǎo)航:nav側(cè)欄:sidebar欄目:column頁面外圍控制整體布局寬度:wrapper左右中:leftrightcenter(2)導(dǎo)航導(dǎo)航:nav主導(dǎo)航:mainbav子導(dǎo)航:subnav頂導(dǎo)航:top
4、nav邊導(dǎo)航:sidebar左導(dǎo)航:leftsidebar右導(dǎo)航:rightsidebar菜單:menu子菜單:submenu標(biāo)題:title摘要:summary(3)功能標(biāo)志:logo廣告:banner登陸:login登錄條:loginbar注冊:regsiter搜索:search功能區(qū):shop標(biāo)題:title加入:joinus狀態(tài):status按鈕:btn滾動:scroll標(biāo)簽頁:tab文章列表:list提示信息:msg當(dāng)前的:current小技巧:tips圖標(biāo):icon注釋:note指南:guild服務(wù):service熱點(diǎn):hot新聞:news下載:download投票:vot
5、e合作伙伴:partner友情鏈接:link版權(quán):copyrightnclass的命名:(1)顏色:使用顏色的名稱或者16進(jìn)制代碼,如.red{color:red;}.f60{color:#f60;}.ff8600{color:#ff8600;}(2)字體大小,直接使用"font+字體大小"作為名稱,如.font12px{font-size:12px;}.font9pt{font-size:9pt;}(3)對齊樣式,使用對齊目標(biāo)的英文名稱,如.left{float:left;}.bottom{float:bottom;}(4)標(biāo)題欄樣式,使用"類別+功能"的方式命名,如.barnews
6、{}.barproduct{}n注意事項(xiàng):1.一律小寫;2.盡量用英文;3.不加中杠和下劃線;4.盡量不縮寫,除非一看就明白的單詞.主要的master.css模塊module.css基本共用base.css布局,版面layout.css主題themes.css專欄columns.css文字font.css表單forms.css補(bǔ)丁mend.css打印print.css