오늘은 CSS3으로 3디텍스트 구현해보렵니다.
풀소스는 https://codepen.io/web-tiki/pen/azeKNy 에서 바로 확인가능합니다.

마우스를 HOVER위에 옮기면 글짜가 각도변환되어 3디이펙트를 보여줍니다.
[code]
HTML
<div id="title">
<h1 data-content="HOVER">HOVER</h1>
</div>
CSS
*{margin:0;padding:0;}
html,body{height:100%;width:100%;overflow:hidden;background:#0099CC;}
#title{
position:absolute;
top:50%; left:50%;
transform:translate(-50%,-50%);
perspective-origin:50% 50%;
perspective:300px;
}
h1{
text-align:center;
font-size:12vmin;
font-family: 'Open Sans', sans-serif;
color:rgba(0,0,0,0.8);
line-height:1em;
transform:rotateY(50deg);
transition:transform 2s;
perspective:150px;
perspective-origin:0% 50%;
}
h1:hover{
transform:rotateY(-20deg);
}
h1:after{
content:attr(data-content);
position:absolute;
left:0;top:0;
transform-origin:50% 100%;
transform:rotateX(-90deg);
color:#0099CC;
}
#title:before{
content:'';
position:absolute;
top:-150%; left:-25%;
width:180%; height:328%;
background:rgba(255,255,255,0.7);
transform-origin: 0 100%;
transform: translatez(-200px) rotate(40deg) skewX(35deg);
border-radius:0 0 100% 0;
animation:light 5s;
}
@keyframes light{
from{opacity:0;}
to{opacity:1;}
}
[/code]
게시글 목록
| 번호 | 제목 |
|---|---|
| 16801 | |
| 16798 | |
| 16796 | |
| 16795 | |
| 16791 | |
| 16790 | |
| 16785 | |
| 16777 | |
| 16776 | |
| 16766 | |
| 16760 | |
| 16759 |
JavaScript
전화번호 및 휴대번호 자동하이픈(-)
2
|
| 16740 | |
| 16737 | |
| 16735 | |
| 16728 | |
| 16713 |
PHP
PHP Router
17
|
| 16700 | |
| 16691 | |
| 16669 | |
| 16668 |
MySQL
특정 row의 index 값 구하기
5
|
| 16660 | |
| 16655 | |
| 16654 | |
| 16647 | |
| 16639 | |
| 16637 | |
| 16634 | |
| 16629 | |
| 16620 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기