A set of cool hamburger icon deformation animation special effects

黄舟
Release: 2017-01-19 14:24:12
Original
2470 people have browsed it

Brief Tutorial

Hamburgers is a super cool hamburger icon deformation animation special effects CSS3 animation library. This set of hamburger icon animations includes 18 different hamburger deformation animation effects. You can also customize your own hamburger icon deformation animation through Sass files.

A set of cool hamburger icon deformation animation special effects

Installation

You can install Hamburgers hamburger deformation animation through bower or npm.

bower install css-hamburgers npm install hamburgers
Copy after login

How to use

To use the hamburger deformation animation special effects, you need to introduce the hamburgers.css file into the page

Copy after login

HTML structure

The hamburger icon deformation animation The HTML structure of the special effect is as follows:

Copy after login

You can also use

instead of the button element.

Copy after login

Then you can add the corresponding class class to get the corresponding hamburger icon deformation animation.

Copy after login

The following are the classes for all the hamburger deformation animations you can choose.

  • hamburger--arrow

  • hamburger--arrow-r

  • hamburger--arrowalt

  • hamburger--arrowalt-r

  • hamburger--boring

  • hamburger--collapse

  • hamburger--collapse-r

  • ##hamburger--elastic

  • hamburger--elastic -r

  • hamburger--emphatic

  • hamburger--emphatic-r

  • hamburger- -slider

  • hamburger--slider-r

  • hamburger--spin

  • hamburger- -spin-r

  • hamburger--squeeze

  • hamburger--vortex

  • hamburger- -vortex-r

The class with -r represents the reverse effect of the animation without -r class.

Finally, to trigger the hamburger icon deformation animation, you need to add an is-active class.

Copy after login

Tips

When using Hamburger as a menu button, it is recommended to use ARIA attributes.

 
Copy after login

If you are using
elements, they will not receive focus by default. You can add tabindex attributes and ARIA attributes to it.

Copy after login

In addition, you can also add a label to the hamburger icon.

Copy after login
The github address of Hamburgers hamburger icon deformation animation special effects is: https://github.com/jonsuh/hamburgers

The above is a set of cool hamburger icon deformation animation special effects, more For more related content, please pay attention to the PHP Chinese website (m.sbmmt.com)!


Related labels:
source:php.cn
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
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!