akveo / eva-icons

A pack of more than 480 beautifully crafted Open Source icons. SVG, Sketch, Web Font and Animations support.
https://akveo.github.io/eva-icons/
MIT License
8.63k stars 364 forks source link
icon icon-font icon-pack icons

Eva Icons

Eva Icons is a pack of more than 480 beautifully crafted Open Source icons for common actions and items. Additionally, Eva Icons supports 4 animation types: zoom, pulse, shake and flip. Download on desktop to use them in your digital products for Web, iOS and Android. Icons are provided in two visual types: Fill and Outline and in several formats, including PNG, SVG, font, Sketch, etc.

Download

CDN

Load from CDN in your project:

<script src="https://unpkg.com/eva-icons"></script>

After including the script, eva will be available as a global variable.

NPM

const eva = require('eva-icons');
import * as eva from 'eva-icons';

How to use

JavaScript

<i data-eva="github"></i>
<!DOCTYPE html>
<html lang="en">
  <title></title>
  <script src="https://unpkg.com/eva-icons"></script>
  <body>

    <i data-eva="github"></i>

    <script>
      eva.replace()
    </script>
  </body>
</html>

Thanks to Feather Icons for the build process inspiration.

<i data-eva="github" data-eva-fill="#ff0000" data-eva-height="48" data-eva-width="48"></i>

Fonts

Eva Icons are also available as a Web Font.

<link href="https://github.com/akveo/eva-icons/blob/master/path/to/style/eva-icons.css">
<i class="eva eva-github"></i>

We recommend using SVG icons due to better rendering and performance capabilities, more details.

Documentation

eva.replace(options)

Replaces all elements that have a data-eva attribute with SVG markup.

options optional object.

Available 'option' properties:

Name Type Default value Description
fill string none Icon color
width string or number 24px Icon width
height string or number 24px Icon height
class string none Custom css class
animation object none Icon animation

Animation

<i data-eva="github" data-eva-animation="zoom"></i>
<i data-eva="github" data-eva-animation="zoom" data-eva-hover="false" data-eva-infinite="true"></i>

Note: In the above example github icon will be always animated. This type of animation will be applied only to current icons.

eva.replace({
  animation: {
    type: string, // zoom, pulse, shake, flip
    hover: boolean, // default true
    infinite: boolean, // default false
  }
});

Note: The animation will be applied to all replaced elements.

<div class="eva-parent-hover">
  <i data-eva="github" data-eva-animation="zoom"></i>
  Zoom animation
</div>

3rd party implementations

License

MIT license.

More from Akveo

How can I support the developers?

From Developers

Made with :heart: by Akveo team. Follow us on Twitter to get the latest news first! We're always happy to receive your feedback!