[TOC]
> ### 背景
background-color //背景顏色
background-image //背景圖片
background-repeat //背景重復
background-position //背景圖片位置
background //參數列表:顏色 背景圖片 重復設置 位置
> ### 文本
text-decoration //文本修飾(穿透,下劃線,無...)
text-indent //首行縮進
font-weight //文本加粗(bold)
font-style //文本樣式(斜體 italic)
font-size //文本大小
font-family: //字體樣式(-apple-system,SF UI Text,Arial,PingFang SC,Hiragino Sans GB,Microsoft YaHei,WenQuanYi Micro Hei,sans-serif;)
> ### 鏈接
a:link{} //未訪問
a:visited{} //已被訪問
a:hover{} //鼠標懸停
a:active{} //點擊那一刻
//*若單獨設置幾個鏈接,必須遵守如下規則:
a:hover 必須跟在 a:link 和 a:visited后面
a:active 必須跟在 a:hover后面
> ### 列表
list-style //列表樣式 none |circle | disc |square (無,圓圈,默認,方形)
list-style-image //列表樣式圖片
> ### 表格
table,th,td{
border:1px solid #333;
}
table{
/* 邊框折疊 */
border-collapse: collapse;
width:500px;
line-height: 50px;
text-align: center;
}
標簽:
<table>
<thead>
<tbody>
<tr>
<th>
<td>
- 跨列屬性
colspan
- 跨行屬性
rowspan
跨越行的表格只能寫在tbody中
> ### 繼承
文本和字體相關樣式可以繼承
- 寬繼承
子元素會繼承父元素的寬度
- 高繼承
父元素不設置高,它會獲取子元素的高度
> ### 邊界
margin: -1px;
display: flex|grid;
grid-template-columns: 1fr 1fr 1fr 1fe //自適應寬度
gird-template-rows
justify-content: space-evenly; //justify-content space-between space-evently