CSS

[animation] CSS - animation-direction 속성 - 애니방향 (= 움직임방향 = 애니메이션디렉션속성, IE10)

animation-direction 예제

 

<style> 

#hz {

  padding:20px 30px;

  width:200px;

  background: red;

  position: relative;

  -webkit-animation: homzzang 5s 2; /* Safari 4.0 - 8.0 */

  -webkit-animation-direction: alternate; /* Safari 4.0 - 8.0 */

  animation: homzzang 5s 2;

  animation-direction: alternate;

}


/* Safari 4.0 - 8.0 */

@-webkit-keyframes homzzang {

  0%   {background: red; left: 0px; top: 0px;}

  25%  {background: yellow; left: 200px; top: 0px;}

  50%  {background: blue; left: 200px; top: 200px;}

  75%  {background: green; left: 0px; top: 200px;}

  100% {background: red; left: 0px; top: 0px;}

}


@keyframes homzzang {

  0%   {background: red; left: 0px; top: 0px;}

  25%  {background: yellow; left: 200px; top: 0px;}

  50%  {background: blue; left: 200px; top: 200px;}

  75%  {background: green; left: 0px; top: 200px;}

  100% {background: red; left: 0px; top: 0px;}

}

</style>


<div id='hz'>홈짱닷컴 Homzzang.com</div>



결과보기

 

 

animation-direction 정의

 

애니메이션 방향 (= 움직이는 방향)

 



기본값 : normal
속성상속 : X
애니효과 : X
CSS버전: CSS3
JS구문 : object.style.animationDirection="속성값"
브라우저: IE10이상 주요 최신브라우저 (구버전 경우, -webkit- , -moz- , -o- 등 붙여 사용)

 

 

 

animation-direction 구문

 

선택자 {animation-direction: 속성값;}

 


 

[속성값]

 

normal

기본값. 애니메이션 정방향 재생

 

reverse

애니메이션 역방향 재생.

 

alternate

애니메이션 정방향 재생 후 역방향 재생.

 

alternate-reverse

애니메이션 역방향 재생 후 정방향 재생.

 

initial

이 속성의 기본값으로 설정.

 

inherit

부모 요소 속성을 상속.

 



분류 제목
background CSS - background-attachment 속성 - 배경이미지 고정 (= background-atta…
selector CSS - :nth-child(n) 가상선택자 ★ - 그 부모의 n번째 자식요소 (=nth-child선택자 …
background CSS - background 속성 ★ - 배경 일괄 (= background속성 = 백그라운드속성)
animation CSS - animation-direction 속성 - 애니방향 (= 움직임방향 = 애니메이션디렉션속성, I…
responsive CSS - Responsive Image - (반응형 이미지) ★★★
flex CSS - flex-wrap 속성(C) ★ - 아이템 줄바꿈 가능 여부. (= flex-wrap속성 = 플렉…
text CSS - text-indent 속성 ★★ - 단락 첫줄 텍스트 들여쓰기 (= text-indent속성 = …
selector CSS - :active 가상선택자 - 링크클릭순간 (= 액티브선택자, 링크선택자)
box CSS - max-width 속성 - 최대너비 (= 최대가로길이 = max-width속성 = 맥스위드스속성)
list CSS - list-style-type 속성 ★ - 리스트 스타일 타입 (= 리스트 마커 종류 = list-…
responsive CSS - Viewport ★ - 사용자에게 보이는 웹페이지 영역 (= 메타태그 뷰포트 ※ 반응형 필수조건 …
css CSS - cursor 속성 - 커서 모양 (= cursor속성 = 커서속성)
box CSS - min-width 속성 - 최소너비 (=최소가로길이 = min-width속성 = 민위드스속성)
selector CSS - :visited 가상선택자 ★ -이미 방문한 링크 선택 (= 읽은글/방문글/확인글 표시 = 비지티…
border CSS - border-radius 속성 ★ - 테두리둥글기 지정 (= border-radius속성 = 보더…
28/33
목록
 홈  PC버전 로그인 일본어
그누앞단언어
그누뒷단언어
그외코딩언어
그누보드 1
제작의뢰
Q&A
커뮤니티
웹유틸
회원센터
홈짱닷컴 PC버전 로그인