CSS3 learning animation property_html/css_WEB-ITnose
I found the new attribute of animation very interesting, learn it here and organize it!
Browser support :
Internet Explorer 10, Firefox and Opera support the animation attribute;
Safari and Chrome support the alternative -webkit-animation attribute .
Definition and Usage
The animation property is a shorthand property for setting six animation properties:
Syntax
animation: name duration timing-function delay iteration-count direction;
animation-name | Specifies the keyframe that needs to be bound to the selector name. .
Where animation-timing-function uses a mathematical function called the Cubic Bezier function to generate the velocity curve. You can use your own values in this function, or predefined values:
Case: Very practical, an arrow jumps up and down in a loop 50% {transform:translate(0, 0)} 100% {transform:translate(0, 10px)}} @-webkit-keyframes dd{0% {-webkit-transform:translate(0, 10px)} 50% {-webkit-transform:translate(0, 0)}100% {-webkit-transform:translate(0, 10px)} } Note: The animation attribute must be used in conjunction with @keyframes The percentage means the percentage of duration. If duration is not set, it means is infinity. transform:translate(): Meaning - change, displacement; also a new attribute in CSS3.Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
![]() Hot AI Tools![]() Undresser.AI UndressAI-powered app for creating realistic nude photos ![]() AI Clothes RemoverOnline AI tool for removing clothes from photos. ![]() Undress AI ToolUndress images for free ![]() Clothoff.ioAI clothes remover ![]() AI Hentai GeneratorGenerate AI Hentai for free. ![]() Hot Article
R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
3 weeks ago
By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
3 weeks ago
By 尊渡假赌尊渡假赌尊渡假赌
Assassin's Creed Shadows: Seashell Riddle Solution
1 weeks ago
By DDD
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
3 weeks ago
By 尊渡假赌尊渡假赌尊渡假赌
Where to find the Crane Control Keycard in Atomfall
1 weeks ago
By DDD
![]() Hot Tools![]() Notepad++7.3.1Easy-to-use and free code editor ![]() SublimeText3 Chinese versionChinese version, very easy to use ![]() Zend Studio 13.0.1Powerful PHP integrated development environment ![]() Dreamweaver CS6Visual web development tools ![]() SublimeText3 Mac versionGod-level code editing software (SublimeText3) ![]() Hot Topics
CakePHP Tutorial
![]() ![]() ![]() The article discusses the HTML <progress> element, its purpose, styling, and differences from the <meter> element. The main focus is on using <progress> for task completion and <meter> for stati ![]() The article discusses the HTML <datalist> element, which enhances forms by providing autocomplete suggestions, improving user experience and reducing errors.Character count: 159 ![]() The article discusses the HTML <meter> element, used for displaying scalar or fractional values within a range, and its common applications in web development. It differentiates <meter> from <progress> and ex ![]() The article discusses the viewport meta tag, essential for responsive web design on mobile devices. It explains how proper use ensures optimal content scaling and user interaction, while misuse can lead to design and accessibility issues. ![]() This article explains the HTML5 <time> element for semantic date/time representation. It emphasizes the importance of the datetime attribute for machine readability (ISO 8601 format) alongside human-readable text, boosting accessibilit ![]() Article discusses best practices for ensuring HTML5 cross-browser compatibility, focusing on feature detection, progressive enhancement, and testing methods. ![]() The article discusses using HTML5 form validation attributes like required, pattern, min, max, and length limits to validate user input directly in the browser. ![]() The article discusses the <iframe> tag's purpose in embedding external content into webpages, its common uses, security risks, and alternatives like object tags and APIs. ![]() |