Computer >> 컴퓨터 >  >> 프로그램 작성 >> CSS

Animate CSS가 속성을 떠났습니다.

<시간/>

왼쪽 에 애니메이션을 구현하려면 CSS를 사용하여 속성을 사용하여 다음 코드를 실행할 수 있습니다.

예시

<!DOCTYPE html>
<html>
   <head>
      <style>
         div {
            border: 2px solid black;
            width: 300px;
            height: 100px;
            position: absolute;
            left: 0;
            animation: myanim 5s infinite;
         }
         @keyframes myanim {
            30% {
               left: 200px;
            }
         }
      </style>
   </head>
   <body>
      <div>This is demo text</div>
   </body>
</html>