推薦base.css

學習《編寫高質量代碼--Web前端開發修煉之道》

?

/* CSS Document */
/*css reset*/
body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,form,fieldset,input,textarea,p,blockquote,th,td{margin:0;padding:0;}
table{ border-collapse:collapse;border-spacing:0;}
fieldest,img{border:0;}
address,caption,cite,code,dfn,em,strong,th,var{ font-style:normal;font-weight:normal;}
ol,ul{list-style:none;}
caption,th{text-align:left;}
h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:normal;}
p:before,q:after{content:''}
abbr,acronym{border:0;}


/*文字排版*/
.f12{font-size:12px;}
.f13{font-size:13px;}
.f14{font-size:14px;}
.f16{font-size:16px;}
.f20{font-size:20px;}
.fb{font-weight:bold;}
.fn{font-weight:normal;}
.t2{text-indent:2em;}
.lh150{line-height:150%;}
.lh180{line-height:180%;}
.lh200{line-height:200%;}
.unl{text-decoration:underline;}
.no_un{text-decoration:none;}


/*定位*/
.tl{text-align:left;}
.tc{text-align:center;}
.tr{text-align:right;}
.bc{margin-left:auto;margin-right:auto;}/*全稱是“。blockCenter”,作用為使塊級元素居中。直接試用她是不能使塊級元素居中的,還需設定寬度。*/
.fl{float:left;display:inline;}/*設置display:inline 為了解決IE6的雙外邊距bug。在IE6下,如果對元素設置了浮動,同時設置了margin-left或者margin-right,margin值會加倍,如設置margin-left:10px在IE6下會顯示為margin-left:20px。解決辦法就是設置display:inline。*/
.fr{float:right;display:inline;}
.cb{clear:both;}
.cl{clear:left;}
.cr{clear:right;}
.clearfix:after{content:".";display:block;height:0;clear:both;visibility:hidden;}
.clearfix{display:inline-block;}/*用于在父容器直接清除子元素浮動。*/
*html .clearfix{height:1%;}/*只在IE6中生效*/
.Clearfix{display:block;}
.vm{vertical-align:middle;}
.pr{position:relative;}
.pa{position:relative;}
.abs-right{position:absolute;right:0;}
.zoom{zoom:1;}/*(IE特有屬性)觸發hasLayout*/
.hidden{visibility:hidden;}
.none{display:none;}


/*長度高度*/
.w10{width:10px;}
.w20{width:20px;}
.w30{width:30px;}
.w40{width:40px;}
.w50{width:50px;}
.w60{width:60px;}
.w70{width:70px;}
.w80{width:80px;}
.w90{width:90px;}
.w100{width:100px;}
.w200{width:200px;}
.w250{width:250px;}
.w300{width:300px;}
.w400{width:400px;}
.w500{width:500px;}
.w600{width:600px;}
.w700{width:700px;}
.w800{width:800px;}
.w{width:100%;}
.h50{height:50px;}
.h80{height:80px;}
.h100{height:100px;}
.h200{height:200px;}
.h{height:100%;}


/*邊距*/
.m10{margin:10px;}
.m15{margin:15px;}
.m30{margin:30px;}
.mt5{margin-top:5px;}
.mt10{margin-top:10px;}
.mt15{margin-top:15px;}
.mt20{margin-top:20px;}
.mt30{margin-top:30px;}
.mt50{margin-top:50px;}
.mt100{margin-top:100px;}
.mb5{margin-bottom:5px;}
.mb10{margin-bottom:10px;}
.mb15{margin-bottom:15px;}
.mb20{margin-bottom:20px;}
.mb30{margin-bottom:30px;}
.mb50{margin-bottom:50px;}
.mb100{margin-bottom:100px;}
.ml5{margin-left:5px;}
.ml10{margin-left:10px;}
.ml15{margin-left:15px;}
.ml20{margin-left:20px;}
.ml30{margin-left:30px;}
.ml50{margin-left:50px;}
.ml100{margin-left:100px;}
.mr5{margin-right:5px;}
.mr10{margin-right:10px;}
.mr15{margin-right:15px;}
.mr20{margin-right:20px;}
.mr30{margin-right:30px;}
.mr50{margin-right:50px;}
.mr100{margin-right:100px;}


.p10{padding:10px;}
.p15{padding:15px;}
.p30{padding:30px;}
.pt5{padding-top:5px;}
.pt10{padding-top:10px;}
.pt15{padding-top:15px;}
.pt20{padding-top:20px;}
.pt30{padding-top:30px;}
.pt50{padding-top:50px;}
.pt100{padding-top:100px;}
.pb5{padding-bottom:5px;}
.pb10{padding-bottom:10px;}
.pb15{padding-bottom:15px;}
.pb20{padding-bottom:20px;}
.pb30{padding-bottom:30px;}
.pb50{padding-bottom:50px;}
.pb100{padding-bottom:100px;}
.pl5{padding-left:5px;}
.pl10{padding-left:10px;}
.pl15{padding-left:15px;}
.pl20{padding-left:20px;}
.pl30{padding-left:30px;}
.pl50{padding-left:50px;}
.pl100{padding-left:100px;}
.pr5{padding-right:5px;}
.pr10{padding-right:10px;}
.pr15{padding-right:15px;}
.pr20{padding-right:20px;}
.pr30{padding-right:30px;}
.pr50{padding-right:50px;}
.pr100{padding-right:100px;}

?

本文來自互聯網用戶投稿,該文觀點僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務,不擁有所有權,不承擔相關法律責任。
如若轉載,請注明出處:http://www.pswp.cn/news/247525.shtml
繁體地址,請注明出處:http://hk.pswp.cn/news/247525.shtml
英文地址,請注明出處:http://en.pswp.cn/news/247525.shtml

如若內容造成侵權/違法違規/事實不符,請聯系多彩編程網進行投訴反饋email:809451989@qq.com,一經查實,立即刪除!

相關文章

如何通過RFID開發來迎接第四次工業革命(轉)

我們都經歷了革命性的沖擊,自上世紀90年代初的互聯網沖擊了文化和商業,但很少人知道如何完成RFID開發來迎接第四次工業革命,在接下來的二十年里,智能工廠的出現將成為一個重要組成部分。制造業作為我國工業的主體,面臨…

對js數組去重的研究

1.利用es5 let arr [1, 2, 3, 4, 5, 6, 7, 1, 2, 3] const uniquearr>{ return Array.from(new Set(arr)) } console.log(unique(arr))2.通過雙層循環使用splice刪除 let arr [1, 2, 3, 4, 5, 6, 7, 1, 2, 3] const uniquearr>{ // return Array.from(new Se…

一些前端開發經典書籍推薦和下載鏈接分享

下面的這些書都是我曾看過或了解過的: 一.HTML 1.《HTML5權威指南》 非常全面的書,內容也很新,包含了HTML5CSS3JS DOM。 下載鏈接:http://pan.baidu.com/s/1qYGn1qW HTML我暫時沒看什么書,學會了大部分的標簽后我…

RFID圖書管理系統程序源代碼(轉)

RFID圖書管理系統程序源代碼https://wenku.baidu.com/view/5f4e47f0c9d376eeaeaad1f34693daef5ef713d9.html

UOJ310 黎明前的巧克力 FWT

傳送門 我們要求的是\([x^0]\prod\limits_{i1}^n (2x^{a_i}1)\),其中乘積定義為集合對稱差卷積。 這個直接做復雜度太高了,考慮優化。注意到在FWT之后,每一個序列中的值要么是\(3\),要么是\(-1\),而且這個只跟\(a_i\)有…

vue調用百度地圖API

安裝 $ npm install vue-baidu-map --save 全局注冊 在main.js 里面引入以下代碼 import BaiduMap from vue-baidu-mapVue.use(BaiduMap, {ak: 百度地圖密鑰AK }) 使用方法 <doc-preview><baidu-map class"map" style"display: flex; flex-direct…

mysql show processlist命令 詳解

SHOW PROCESSLIST顯示哪些線程正在運行。您也可以使用mysqladmin processlist語句得到此信息。如果您有SUPER權限&#xff0c;您可以看到所有線程。否則&#xff0c;您只能看到您自己的線程&#xff08;也就是&#xff0c;與您正在使用的MySQL賬戶相關的線程&#xff09;。請參…

JS 數據處理技巧及小算法匯總(轉載)

1、根據屬性來更新一個數組中的對象 const arr [ {id: 1, score: 1}, {id: 2, score: 2}, {id: 3, score: 4}]; //更新的值 const newValue {id: 3, score: 3} 更新數組中id為3的score值。 Es6 裝逼寫法如下&#xff1a; const result initial.map(x > x.id newValue.i…

讓行內元素(如圖片)在div中水平垂直居中 (干貨)

&#xff08;1&#xff09;第一種&#xff1a;用vertical-align <div class"method1"><span class"tiptop"></span><img class"test" src"img/Dota2.jpg" alt"dota2"> </div><style> …

對Canvas的研究

1。標簽定義圖形&#xff0c;比如圖表和其他圖像&#xff0c;您必須使用腳本來繪制圖形。 什么是 canvas? HTML5 <canvas> 元素用于圖形的繪制&#xff0c;通過腳本 (通常是JavaScript)來完成. <canvas> 標簽只是圖形容器&#xff0c;您必須使用腳本來繪制圖形。 …

Vue中watch的簡單應用

Vue.js 有一個方法 watch&#xff0c;它可以用來監測Vue實例上的數據變動。 如果對應一個對象&#xff0c;鍵是觀察表達式&#xff0c;值是對應回調&#xff0c;值也可以是方法名&#xff0c;或者是對象&#xff0c;包含選項。 下面寫兩個demo&#xff0c;參考demo來了解一下 …

小程序中textarea點擊按鈕事件

textarea 的 blur 事件會晚于頁面上的 tap 事件&#xff0c;如果需要在 button 的點擊事件獲取 textarea&#xff0c;可以使用 form 的 bindsubmit。 <view class"section"><form bindsubmit"bindFormSubmit"><textarea placeholder"f…

placeholder的兼容處理方法

placeholder是html5新增的一個屬性&#xff0c;極大的減輕了表單提示功能的實現&#xff0c;但是對于IE6-IE9真的是只能靠自己寫啦&#xff01; 但是在自己寫時會掉進了一個坑里&#xff0c;還好用了一會時間還是爬出來啦。 最終的解決方法方法如下&#xff1a; 1 <form nam…

常用數據處理

1、樹形數據轉換 在處理商品分類數據、企業列表數據等情況下&#xff0c;后臺會返回到前臺所有的數據。我們需要根據parentId,數據ID將數據轉換為樹形數據進行渲染。 /*** 樹形數據轉換* param {*} data* param {*} id* param {*} pid*/ export function treeDataTranslate(d…

運行Xcode時出現 Lazy loading NSBundle MobileCoreServices.framework和 Loaded MobileCoreServices.framework

運行Xcode時出現 Lazy loading NSBundle MobileCoreServices.framework和 Loaded MobileCoreServices.framework 解決方案&#xff1a; 1、打開項目的 Product-->Scheme --> Edit Scheme--> Run-->Arguments-->Environment Variables添加Name為OS_ACTIVITY_MO…

less中的for循環

.loop(count) when (counter > 0) { .loop((counter - 1)); // 遞歸調用自身width: (10px * counter); // 每次調用時產生的樣式代碼}轉載于:https://www.cnblogs.com/zhouyideboke/p/11178271.html

詳解 vue-cli 的打包配置文件代碼(轉)

一、前言 對于webpack基礎不好&#xff0c;node指令不通的童鞋。估計對自己搭建Vue、react腳手架是相當頭疼的&#xff0c;有種無從下手的感覺。然而&#xff0c;從頭看這2塊&#xff0c;耗時太長&#xff0c;而且說實話得練才行&#xff0c;不練練手看不明白。那大多數人就采取…

iOS之頁面布局-踩坑的原由

iOS之頁面布局 原文請點擊 在《iOS 7 UI Transition Guide》中有在《iOS 7 UI Transition Guide》的Bar and Bar Buttons一節中有這么一段話 In iOS 7, the status bar is transparent, and other bars—that is, navigation bars, tab bars, toolbars, search bars, and sco…

工作中的javascript代碼收集及整理

有個pub庫放在blog的文件夾里面了,注意查查1.用javascript去除字符串左右空格,包括全角和半角//用javascript去除字符串左右空格,包括全角和半角String.prototype.trim function() { //其中表示為&#xff1a;對象.屬性.方法函數方法var strTrim this.replace(/(^\s*)|(\s*$)/…