animation css
CSS
CSS animation properties template:
{
animation-name: anima-name;
animation-duration: 1s;
animation-iteration-count: infinite;
animation-delay: 2s;
animation-direction: reverse | normal | alternate | alternate-reverse ;
animation-timing-function: ease | ease-out | ease-in | ease-in-out | linear | cubic-bezier(x1, y1, x2, y2) (e.g. cubic-bezier(0.5, 0.2, 0.3, 1.0));
animation-fill-mode:forwards | backwards | both | none;
}
@keyframes anima-name {
from {
background-position:right;
}
to {
background-position:left;
}
}
@keyframes anima-name {
0% {
background-color: red;
}
50% {
background-color: green;
}
100% {
background-color: red;
}
}
@-webkit-keyframes pulse {
0% {
background-color: red;
opacity: 1.0;
-webkit-transform: scale(1.0) rotate(0deg);
}
33% {
background-color: blue;
opacity: 0.75;
-webkit-transform: scale(1.1) rotate(-5deg);
}
67% {
background-color: green;
opacity: 0.5;
-webkit-transform: scale(1.1) rotate(5deg);
}
100% {
background-color: red;
opacity: 1.0;
-webkit-transform: scale(1.0) rotate(0deg);
}
}
.pulsedbox {
-webkit-animation-name: pulse;
-webkit-animation-duration: 4s;
-webkit-animation-direction: alternate;
-webkit-animation-timing-function: ease-in-out;
}
<style>
#ball {
width: 100px;
height: 100px;
margin: 50px auto;
position: relative;
border-radius: 50%;
background: linear-gradient(
35deg,
#ccffff,
#ffcccc
);
/*"Call" the animation "function" */
animation-name: bounce;
animation-duration: 1s;
animation-iteration-count: infinite;
animation-delay: 2s;
/* Normal, reverse, alternate(between the fwd and back)
and alternate-reverse */
animation-direction: reverse;
/* Ease is deafault, use cubic-bezier(n,n,n,n) for custom */
animation-timing-function: linear;
/* if you want something to display from hidden
set the opacity to 0 and in the keyframe steps bring
the opacity to 1 gradually to stop it flashing */
}
/* The animation "bounce" */
@keyframes bounce{
/* start */
0% {
top: 0px;
}
/* step (you can add multiple incremental steps from 1-100) */
50% {
top: 249px;
width: 130px;
height: 90px;
}
/* end (you can count down from 100 to 0 too) */
100% {
top: 0px;
}
}
</style>
<div id="ball"></div><!DOCTYPE html>
<html>
<head>
<style>
div {
width: 100px;
height: 100px;
background-color: red;
position: relative;
animation: myfirst 5s linear 2s infinite alternate;
}
@keyframes myfirst {
0% {background-color:red; left:0px; top:0px;}
25% {background-color:yellow; left:200px; top:0px;}
50% {background-color:blue; left:200px; top:200px;}
75% {background-color:green; left:0px; top:200px;}
100% {background-color:red; left:0px; top:0px;}
}
</style>
</head>
<body>
<p><b>Note:</b> This example does not work in Internet Explorer 9 and earlier versions.</p>
<div><p>you can add text in this box or anithing else like a pictrue</p></div>
</body>
</html>animation-name: none;
animation-duration: 0s;
animation-timing-function: ease;
animation-delay: 0s;
animation-iteration-count: 1;
animation-direction: normal;
animation-fill-mode: none;
animation-play-state: running;animation: name time func delay iteration dir fill play;
animation: none 0s ease 0s 1 normal none running;
Also in CSS:
- Title
- link html css
- Category
- CSS
- Title
- css font size
- Category
- CSS
- Title
- css keep background image from scrolling
- Category
- CSS
- Title
- javascript canvas pixel art
- Category
- CSS
- Title
- uibutton image
- Category
- CSS
- Title
- image orientation css
- Category
- CSS
- Title
- choose grid position html
- Category
- CSS
- Title
- put an border around an text in css
- Category
- CSS
- Title
- laavel relation through morph
- Category
- CSS
- Title
- javascript add inline style css var
- Category
- CSS
- Title
- css styling
- Category
- CSS
- Title
- bootstrap 4 mobile media query
- Category
- CSS
- Title
- css to hide scrollbar
- Category
- CSS
- Title
- hwo to use flexbox to make a nav bar
- Category
- CSS
- Title
- material design css
- Category
- CSS
- Title
- css first h element
- Category
- CSS
- Title
- css grid align
- Category
- CSS
- Title
- text vertical align css
- Category
- CSS
- Title
- tzutc
- Category
- CSS
- Title
- text underline hover css
- Category
- CSS
- Title
- css for chrome only
- Category
- CSS
- Title
- nth-child(2n+1)
- Category
- CSS
- Title
- css how to stop screen from left and right
- Category
- CSS
- Title
- add a border to a div css
- Category
- CSS
- Title
- print zend db select query to string
- Category
- CSS
- Title
- equivalent zoom css
- Category
- CSS
- Title
- link css file in html
- Category
- CSS
- Title
- css box shadow
- Category
- CSS
- Title
- how to include one css file in another
- Category
- CSS
- Title
- css remove number input arrows
- Category
- CSS
- Title
- css hiddden
- Category
- CSS
- Title
- css disable user interaction
- Category
- CSS
- Title
- pseudo elements css
- Category
- CSS
- Title
- how to stilize title property css
- Category
- CSS
- Title
- pure css heart
- Category
- CSS
- Title
- css all children of type
- Category
- CSS
- Title
- padding css shorthand
- Category
- CSS
- Title
- how to center a div in css
- Category
- CSS
- Title
- opacity transition in css
- Category
- CSS
- Title
- bem in nested element
- Category
- CSS
- Title
- css hide timeline
- Category
- CSS
- Title
- text shadow css generator
- Category
- CSS
- Title
- css media queries
- Category
- CSS
- Title
- css immediate child
- Category
- CSS
- Title
- css how to add double shadow to text
- Category
- CSS
- Title
- vertical align span tailwindscss
- Category
- CSS
- Title
- for loops in cpp
- Category
- CSS
- Title
- how to remove link blue color from a tag using css
- Category
- CSS
- Title
- width defined by content css
- Category
- CSS
- Title
- how to change font in css
- Category
- CSS
- Title
- css selectors w3schools
- Category
- CSS
- Title
- custom border css
- Category
- CSS
- Title
- css hero image
- Category
- CSS
- Title
- basic css designn elements
- Category
- CSS
- Title
- how to apply bg image in inline css
- Category
- CSS
- Title
- how to cover full image in css
- Category
- CSS
- Title
- adjecent sibling selectors
- Category
- CSS
- Title
- font awesome css
- Category
- CSS
- Title
- simple font-face mixin scss
- Category
- CSS
- Title
- css hover rounded corners
- Category
- CSS
- Title
- git stop merge
- Category
- CSS
- Title
- Can you change the color of a placeholder
- Category
- CSS
- Title
- hide horizontal scrollbar css
- Category
- CSS
- Title
- transparent text css
- Category
- CSS
- Title
- transition prefixes css
- Category
- CSS
- Title
- best css framework 2020
- Category
- CSS
- Title
- center image css
- Category
- CSS
- Title
- what is css
- Category
- CSS
- Title
- css click event jquery
- Category
- CSS
- Title
- col-xs-12 col-sm-4 col-md-4 col-lg-4
- Category
- CSS
- Title
- get data from firestore and save it to state
- Category
- CSS
- Title
- css first element
- Category
- CSS
- Title
- hegith specific css in media query
- Category
- CSS
- Title
- watch scss to css
- Category
- CSS
- Title
- css distance between text and input box
- Category
- CSS
- Title
- vertical align h1 inside div
- Category
- CSS
- Title
- javascript remove css class
- Category
- CSS
- Title
- how to make a relative div not take up space
- Category
- CSS
- Title
- how to center with position fixed
- Category
- CSS
- Title
- js ransform css
- Category
- CSS
- Title
- how to change the background color in css
- Category
- CSS
- Title
- clip path css
- Category
- CSS
- Title
- css change text color
- Category
- CSS
- Title
- how to mirror object through css
- Category
- CSS
- Title
- default position css
- Category
- CSS
- Title
- truncate text css
- Category
- CSS
- Title
- css rotate 90 deg
- Category
- CSS
- Title
- how to give a div placeholder text
- Category
- CSS
- Title
- css change multiple classes
- Category
- CSS
- Title
- css top bottom left right order
- Category
- CSS
- Title
- how to apply a transition to a child element when hovering over parent element
- Category
- CSS
- Title
- css float
- Category
- CSS
- Title
- How do you change the font colour in CSS?
- Category
- CSS
- Title
- font family css
- Category
- CSS
- Title
- css child multiple of 3
- Category
- CSS
- Title
- font family css list
- Category
- CSS
- Title
- css erase text
- Category
- CSS
- Title
- css how to style a
- Category
- CSS
- Title
- aos animate
- Category
- CSS
- Title
- css animation examples
- Category
- CSS