반응형

2024/12 13

CSS media query

media query 란?오직 CSS 만을 이용해서 스크린의 사이즈를 알 수 있는 방법이다.   DOCTYPE html>html lang="kr"> head> title>The Nick Timestitle> style> body { display: flex; height: 100vh; align-items: center; justify-content: center; } div { background-color: teal; width: 200px; height: 200px; } @media screen and (max-width: 600px;) { div { background-color: tomato; } } style> head> body> div>div> body>html> 해석: 스크린이 600px..

2. CSS 2024.12.09

CSS Animations (애니메이션) 사용하기

우리는 원하는 만큼 애니메이션을 만들고 재생시킬 수 있다. DOCTYPE html>html lang="kr"> head> title>The Nick Timestitle> style> @keyframes superSexyCoinFlip { from { transform: rotateX(0); } to { transform: rotateY(360deg); } } img { border: 10px solid black; border-radius: 50%; animation: superSexyCoinFlip 5s ease-in-out; } style> head> body> img src="img/pic.jpg" /> body>html>     결과  마우스 오버를 하지 않아도 이미지가 로테이트 된다. (참고) ..

2. CSS 2024.12.09

CSS Transform 3D 회전 (rotateY, rotateX)

기본 코딩DOCTYPE html>html lang="kr"> head> title>The Nick Timestitle> style> img { border: 10px solid black; border-radius: 50%; } style> head> body> img src="img/pic.jpg" /> body>html>여기서 img src는VS code에 이미지가 저장된 경로를 불러온 것   결과  자, 이제 transform 적용해 보기DOCTYPE html>html lang="kr"> head> title>The Nick Timestitle> style> img { border: 10px solid black; border-radius: 50%; transform: rotateY(85deg); ..

2. CSS 2024.12.09
반응형