๋ณธ๋ฌธ ๋ฐ”๋กœ๊ฐ€๊ธฐ

โœ๏ธ/CSS

[CSS] animation

๐Ÿ”— CSS์—์„œ animation์ด๋ž€?

 

 CSS ์Šคํƒ€์ผ์„ ๋‹ค๋ฅธ CSS ์Šคํƒ€์ผ๋กœ ๋ถ€๋“œ๋Ÿฝ๊ฒŒ ์ „ํ™˜์‹œ์ผœ์ฃผ๋Š” CSS ์†์„ฑ์ด๋‹ค. @keyframs๋ฅผ ํ†ตํ•ด ์ค‘๊ฐ„ ์ƒํƒœ๋ฅผ ์ง€์ •ํ•œ๋‹ค.

 


 

animation-name : ์• ๋‹ˆ๋ฉ”์ด์…˜ ์ด๋ฆ„ ์ง€์ •

 

@keyframes name : ์ค‘๊ฐ„ ์ƒํƒœ ์ง€์ •
(
from : ์‹œ์  0% ~ to : ์‹œ์  100%)

animation-duration : animation ์ง€์† ์‹œ๊ฐ„ (๋ช‡ ์ดˆ ๋™์•ˆ)

 

animation-delay : animation ๋”œ๋ ˆ์ด ์‹œ๊ฐ„ (๋ช‡ ์ดˆ ๋’ค์—)

 

animation-timing-fuction : animation ๊ฐ€์†๋„

· linear  default

· ease : ๋น ๋ฆ„ -> ๋Š๋ฆผ (ease-out ๋ณด๋‹ค ๋น ๋ฅธ ์†๋„๋กœ ์‹œ์ž‘)

· ease-in : ๋Š๋ฆผ -> ๋น ๋ฆ„

· ease-out : ๋น ๋ฆ„ -> ๋Š๋ฆผ

· east-in-out : ๋Š๋ฆผ -> ๋น ๋ฆ„ -> ๋Š๋ฆผ

 

animation-iteraction-count : ๋ฐ˜๋ณต

· infinite : ๋ฌดํ•œ ๋ฐ˜๋ณต

 

animation-direction : ๋ฐฉํ–ฅ

· normal  (0-100% - 0/100% -)  default

· alternate : ์™•๋ณต (0-100% - 100/0% -)

· alternate-reverse : ์—ญ๋ฐฉํ–ฅ ์™•๋ณต (100-0% - 0/100% -)

 

animation-play-state : ์žฌ์ƒ

· paused : ์ค‘์ง€

· running : ์žฌ์ƒ


transform => ์•ž๋ถ€ํ„ฐ ์ฐจ๋ก€๋กœ ์ ์šฉ๋จ

· rotate(deg) : ํšŒ์ „

· translate(Xpx, Ypx) : ์ด๋™

· skew(Xdeg, Ydeg) : ๊ธฐ์šธ์ž„

· scale(X, Y) : ํ™•๋Œ€ / ์ถ•์†Œ (1 : 100%, 0.1 : 10%)  default : 1

 

transform-origin: X์ถ•๊ฐ’(left/right) Y์ถ•๊ฐ’(top/bottom); : ๊ธฐ์ค€๊ฐ’ ์„ค์ •


transform-style: preserve-3d; : 3์ฐจ์› (3D)

 

transform

· rotate3d(X, Y, Z, deg) : ํšŒ์ „

· translate3d(Xpx, Ypx, Zpx) : ์ด๋™

· skew3d(Xdeg, Ydeg, Zdeg) : ๊ธฐ์šธ์ž„

· scale3d(X, Y, Z) : ํ™•๋Œ€ / ์ถ•์†Œ (1 : 100%, 0.1 : 10%)  default : 1

 

 


๐Ÿ’ก ๊ฐ™์ด ๋ณด๋ฉด ์ข‹์„ Post

 

[CSS] ์™•์ดˆ๋ณด๋ฅผ ์œ„ํ•œ font / background / border ์†์„ฑ ์ด์ •๋ฆฌ

css์—์„œ ์†์„ฑ์€ '์‹œ๊ณ„ ๋ฐฉํ–ฅ'์œผ๋กœ ์ ์šฉ 4๊ฐœ์ผ ๋•Œ : top right bottom left 2๊ฐœ์ผ ๋•Œ : x์ถ•(top, bottom) y์ถ•(left, right) 1๊ฐœ์ผ ๋•Œ : all ๐Ÿ”— Font color : ํ…์ŠคํŠธ ์ƒ‰์ƒ font-size : ํ…์ŠคํŠธ ์‚ฌ์ด์ฆˆ default : 16px..

devjindev.tistory.com

 

[CSS] transition

๐Ÿ”— CSS์—์„œ transition์ด๋ž€?  ์• ๋‹ˆ๋ฉ”์ด์…˜ ์†๋„๋ฅผ ์กฐ์ ˆํ•˜๋Š” CSS ์†์„ฑ์ด๋‹ค. transition-property : transition ์ ์šฉํ•  ์†์„ฑ๋“ค ๋‚˜์—ด transition-property: width, background-color; => width, background-color๋งŒ t..

devjindev.tistory.com

'โœ๏ธ > CSS' ์นดํ…Œ๊ณ ๋ฆฌ์˜ ๋‹ค๋ฅธ ๊ธ€

[CSS] flex  (0) 2020.12.29
[CSS] transition  (0) 2020.12.13
[CSS] ์„ ํƒ์ž(selector) ์ •๋ฆฌ  (0) 2020.12.13
[CSS] link (hover, active, visited, link)  (0) 2020.12.12
[CSS] display (inline, inline-block, block) / ์ฐจ์ด์   (0) 2020.12.12