Materialize CSS provides a rich set of material icons of google which can be downloaded from Material Design specs. Icon libraries that are supported by materialize css are Google Material Icons, Font Awesome Icons and Bootstrap Icons. Different icons can be selected from Material Icons.
Library and Usage: To use these icon, the following line is added in the <head> part of the HTML code.
<link href=”https://fonts.googleapis.com/icon?family=Material+Icons” rel=”stylesheet”>
Then to use the icons, name of the icon is provided in the <i> part of HTML element.
<i class="material-icons">add</i>
Material icon sizes: Materialize CSS provides icons in four sizes: tiny, small, medium, large. The sizes for tiny, small, medium and large are 1 rem, 2 rem, 4 rem and 6 rem respectively.
<i class = "material-icons tiny">add</i> <i class = "material-icons small">add</i> <i class = "material-icons">add</i> <i class = "material-icons medium">add</i> <i class = "material-icons large">add</i>
Example:
HTML
<!DOCTYPE html> <html> <head> <!--Import Google Icon Font--> <link href= rel="stylesheet"> <!-- Compiled and minified CSS --> <link rel="stylesheet" href= <script type="text/javascript" src= </script> <!--Let browser know website is optimized for mobile--> <meta name="viewport" content= "width=device-width, initial-scale=1.0" /> </head> <body> <div class="card-panel"> <h3 class="green-text">Icons</h3> <div class="container"> <div class="row"> <div class="col"> <i class="material-icons tiny">account_circle</i> </div> <div class="col"> <i class="material-icons"> account_circle</i> </div> <div class="col"> <i class="material-icons small">account_circle</i> </div> <div class="col"> <i class="material-icons medium">account_circle</i> </div> <div class="col"> <i class="material-icons large">account_circle</i> </div> </div> </div> </div> <!-- Compiled and minified JavaScript --> <script src= </script> </body> </html> |
Output:

Recommended Posts:
- CSS | Icons
- ReactJS | Icons
- How to use font-awesome icons from node-modules?
- How to target all Font Awesome icons and align them center?
- Materialize CSS | Collections
- Materialize CSS | Waves
- Materialize CSS | Typography
- Materialize CSS | Tooltips
- Materialize CSS | Pagination
- Materialize | Collapsible
- Materialize CSS Navbars
- Materialize | Cards
- Materialize CSS | Tables
- Materialize CSS | Helpers
- Materialize CSS | Grids
- Materialize CSS | Preloader
- Materialize CSS | Colors
- Materialize CSS | Buttons
- Materialize CSS | Footer
- Materialize CSS | Badges
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.


