Search

μ „ν™˜ 속성

μ „ν™˜ 속성

μŠ€νƒ€μΌ μ†μ„±μ˜ λ³€κ²½ μ‹œ λ³€κ²½κ°’μœΌλ‘œ μ „ν™˜λ˜λŠ” μŠ€νƒ€μΌμ„ μ§€μ •ν•˜λŠ” 속성
β€’
λ³€ν™˜ 속성 μ’…λ₯˜
β€’
κΈ°λ³Έ μ˜ˆμ‹œ μ½”λ“œ
β€’
타이밍 속도 생성 μ‚¬μ΄νŠΈ

λ³€ν™˜ 속성 μ’…λ₯˜

속성
μ„€λͺ…
κΈ°λ³Έ μ˜ˆμ‹œ μ½”λ“œ
transition
νŠΉμ • μ†μ„±μ˜ 변경에 λŒ€ν•΄ μ• λ‹ˆλ©”μ΄μ…˜ 효과λ₯Ό μ μš©ν•©λ‹ˆλ‹€.
transition: property duration timing-function delay;
β€’
속성 (property): μ• λ‹ˆλ©”μ΄μ…˜μ„ μ μš©ν•  CSS μ†μ„±μž…λ‹ˆλ‹€.
β€’
지속 μ‹œκ°„ (duration): μ• λ‹ˆλ©”μ΄μ…˜μ˜ 지속 μ‹œκ°„μž…λ‹ˆλ‹€. (예: 0.5s, 300ms)
β€’
타이밍 ν•¨μˆ˜ (timing-function): μ• λ‹ˆλ©”μ΄μ…˜μ˜ 속도 λ³€ν™” κ³‘μ„ μž…λ‹ˆλ‹€. (예: linear, ease-in, ease-out, ease-in-out)
β€’
지연 μ‹œκ°„ (delay): μ• λ‹ˆλ©”μ΄μ…˜μ΄ μ‹œμž‘λ˜κΈ° 전에 μ§€μ—°λ˜λŠ” μ‹œκ°„μž…λ‹ˆλ‹€. (예: 0s, 200ms)

κΈ°λ³Έ μ˜ˆμ‹œ μ½”λ“œ

<!DOCTYPE html> <html lang="ko"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>μ „ν™˜ 속성 μ˜ˆμ‹œ</title> <style> body { margin: 0; font-family: Arial, sans-serif; text-align: center; padding: 50px; background-color: #f0f0f0; } /* κΈ°λ³Έ λ²„νŠΌ μŠ€νƒ€μΌ */ .transition-example { width: 150px; height: 50px; background-color: lightcoral; color: white; border: none; border-radius: 5px; font-size: 16px; cursor: pointer; transition: background-color 0.3s ease, transform 0.3s ease; /* μ „ν™˜ 속성 적용 */ } /* λ²„νŠΌ ν˜Έλ²„ μ‹œ μŠ€νƒ€μΌ λ³€κ²½ */ .transition-example:hover { background-color: lightcoral; transform: scale(1.1); } </style> </head> <body> <button class="transition-example">Hover Me</button> </body> </html>
HTML
볡사

타이밍 속도 생성 μ‚¬μ΄νŠΈ

μŠ€νƒ€μΌ 속성
μŠ€νƒ€μΌ 속성