고요빛물결
CSS

CSS Tutorial for Beginners #36-40

· 2019-02-16 (토) 00:29:45 · 1284

The Box Model

 

203892234_1549992905.6435.png

 

그림에 border가 빠져있네요..

.box {

  margin: 30px;

  padding: 30px;

  border: 1px solid #000;

  width: 400px;

  height: 200px;

}

 

체크하는 방법은 구글 디벨러퍼 버전에서..

 

 

Margins

 

margin: top right bottom left  시계 방향으로 기억

 

margin: top_bottom right_left  2개의 값일 때..

 

margin: top right_left bottom  3개의 값일 때

 

margin: all  1개의 값일 때.

 

값이 auto 일때.. 양쪽 값이 자동으로 들어감.  보통 센터가 됨.

 

 

Padding

 

padding: 마진과 같은 동작

 

 

Padding & Margin Long-hand

 

margin-top, margin-left, margin-right, margin-bottom

padding-top, padding-left, padding-right, padding-bottom

 

 

Borders

 

border-top-width:

border-top-style: dashed, dotted, double, groove, inset, outset, ridge, solid

border-top-color:

 

border: [width] [style] [color]

 

 

 

댓글을 작성하시려면 로그인이 필요합니다.

소모임

23,243건
+
분류 제목 글쓴이 날짜 조회
모형취미 19-02-16 조회 1,233
해외사용자 19-02-16 조회 1,630
자동차 19-02-16 조회 1,672
자동차 19-02-16 조회 1,489
사진 19-02-16 조회 1,644
해외사용자 19-02-16 조회 2,381
CSS 19-02-16 조회 981
CSS 19-02-16 조회 1,273
CSS 19-02-16 조회 1,285
JS프레임워크
[JS프레임워크]
19-02-16 조회 1,199
JS프레임워크
[JS프레임워크]
19-02-16 조회 1,328
JS프레임워크
[JS프레임워크]
19-02-16 조회 1,511
출산육아 19-02-16 조회 1,039
음악/악기 19-02-16 조회 1,548
자동차 19-02-15 조회 1,624
출산육아 19-02-15 조회 1,356
앱개발 19-02-15 조회 1,422
Node.js 19-02-15 조회 2,062
써글모 19-02-15 조회 6,788
써글모 19-02-15 조회 1,221
소지구
[소지구]
19-02-15 조회 1,872
음악/악기
[음악/악기]
19-02-15 조회 1,313
모형취미 19-02-15 조회 826
CSS 19-02-15 조회 1,186
JS프레임워크
[JS프레임워크]
19-02-15 조회 1,681
JS프레임워크 19-02-15 조회 1,465
JS프레임워크 19-02-15 조회 3,197
서버관리자 19-02-14 조회 2,083
오늘뭐먹지? 19-02-14 조회 1,793
서버관리자 19-02-14 조회 3,305