250x250
Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | |||||
3 | 4 | 5 | 6 | 7 | 8 | 9 |
10 | 11 | 12 | 13 | 14 | 15 | 16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 | 25 | 26 | 27 | 28 | 29 | 30 |
Tags
- 개발자
- 풀스택
- iPhone
- ipad
- css3
- image
- 애니메이션
- iOS 개발자
- hover
- html5
- CSS
- keyframes
- react
- front-end
- php
- MAC
- button
- Animation
- 백엔드
- 자바스크립트
- 비전공 개발자
- 비전공자
- HTML
- IOS
- xcode
- SWIFT
- jQuery
- 프론트엔드
- javascript
- effect
Archives
- Today
- Total
비전공자 개발일기
Broken Effect 본문
728x90
SMALL
https://bennettfeely.com/clippy/
<!DOCTYPE html>
<html lang="ko">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>BROKEN EFFECT</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<div class="box">
<span></span>
<span></span>
<span></span>
<span></span>
</div>
</body>
</html>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
display: flex;
justify-content: center;
align-items: center;
min-height: 100vh;
background-color: #222;
}
.box {
position: relative;
width: 400px;
height: 300px;
background-color: #FFF;
}
.box span {
position: absolute;
inset: 0;
transition: .5s;
background:url('./image2.jpg');
background-size: cover;
}
.box span:nth-child(1) {
clip-path: polygon(0 0, 50% 0%, 50% 50%, 0 50%);
transition-delay: 0;
}
.box span:nth-child(2) {
clip-path: polygon(50% 0, 100% 0, 100% 50%, 50% 50%);
transition-delay: .25s;
}
.box span:nth-child(3) {
clip-path: polygon(0 50%, 50% 50%, 50% 100%, 0 100%);
transition-delay: .5s;
}
.box span:nth-child(4) {
clip-path: polygon(50% 50%, 100% 50%, 100% 100%, 50% 100%);
transition-delay: .75s;
}
.box:hover span:nth-child(1) {
transform: translate(-40px, -60px) rotate(-15deg);
}
.box:hover span:nth-child(2) {
transform: translate(40px, -100px) rotate(25deg);
}
.box:hover span:nth-child(3) {
transform: translate(-40px, 80px) rotate(15deg);
}
.box:hover span:nth-child(4) {
transform: translate(40px, 80px) rotate(-15deg);
}
728x90
LIST
'HTML _CSS' 카테고리의 다른 글
Animated Login Form (0) | 2022.07.20 |
---|---|
Mordern Sidebar Menu (0) | 2022.07.19 |
Progress Bar (0) | 2022.07.16 |
Rainbow Button (0) | 2022.07.15 |
CSS Focus (0) | 2022.07.14 |