Answer the question
In order to leave comments, you need to log in
How to include icon font Material Design Icons locally?
Good evening, colleagues!
There is such an icon font - Material Design Icons ( https://material.io/icons/ ). I downloaded it as a single ttf file.
Added in CSS:
@font-face {
font-family : 'MaterialIcons';
src : url('/fonts/MaterialIcons-Regular.ttf');
src : url('/fonts/MaterialIcons-Regular.ttf')
format('woff'), url('/fonts/MaterialIcons-Regular.ttf') format('truetype');
font-weight : normal;
font-style : normal;
}
.div-button-download:before {
font-family: 'Material Icons';
content: "\f006";
}
"\f006";
Answer the question
In order to leave comments, you need to log in
Not that is loaded, the font consists of not only one *.ttf file.
Or download everything to yourself,
or take the link
Read more google.github.io/material-design-icons/#icon-font-...
To connect locally:
1) Download archive link in github .
2) Extract the "iconfont" folder and put it in the project (684 KB).
3) Connect. For example via HTML:
4) Select and add icon in HTML:
5) Style:
.material-icons {
color: #ffffff;
font-size: 24px;
}
<link href="https://cdn.materialdesignicons.com/3.8.95/css/materialdesignicons.min.css"
rel="stylesheet">
https://materialdesignicons.com/cdn/2.0.46/
here is a complete list of these icons
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question