You are on page 1of 9

HTML CSS

Head : title,meta
Body: h1->h6,p,img:

,ul li

,style

,table thead tbody


,input,button

,div
<h1 title="day la helloworld">Hello World</h1>

Attribute
Css in html : 3 cách internal(style)

,external(link)

,inline(style=”color : red”;)

*(all),html(inheritted)
Css selector: id (#), class(.)

priority:
Root(biến)

Biến toàn cục

Biến cục bộ
.box :
<div class="box" ></div>

Absolute unit : px
Relative unit : %(phụ thuộc kích thước thẻ chứa nó),rem(theo html),em,vw(1vw
=1% kích thước trình duyệt),vh
Padding,border,margin:

Box-sizing

,background-clip

,
background-image url(),
linear-gradient(0,#333,#ccc)

,rgba(51,51,51,0.5)(0.5 là độ mờ)
,var(--primary-color)
,rgb(),calc()

,
attr()

background-size: contain,cover
background-origin~background-clip: dung origin khi dung background image
background-position:50%,top right, bottom center, left 20px top 20px,30px
50px,center

shorthand:
pseudo class:
hover(kich hoat khi re chuot vao)

Active(kich hoat khi click chuot vao)

first-child,last-child(thao tác với li đầu và li cuối)


Phần tử giả:
Before,after,first-letter,first-line,selection
Thuộc tính position:
Relative

Absolute:

Fixed:
Flex box

You might also like