webkit css code example
Example 1: webkit animation
@-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;
}
Example 2: WHAT IS CSS
Q: What is CSS?
A: CSS stands for Cascading Style Sheets. It is the most common way to
style an HTML element.
CSS Defines how an HTML element will appear on your web browser, such as making
your text green, or a shadow effect behind your button!
There are three ways to add CSS to your code:
-Inline CSS is directly written into the element you would like styled.
-Scripted CSS is also written in HTML, but using the <style> tag.
-Stylesheet / External CSS is on its own document and does not require any
HTML inside it. To bind it to your webpage, use the <link> element.