mirror of
https://github.com/konpa/devicon.git
synced 2025-04-21 05:11:56 +02:00
Added colored class and change README.md
This commit is contained in:
parent
940fd13c13
commit
318e2df2b7
@ -43,13 +43,11 @@ _2 ways of using devicon:_
|
||||
|
||||
#### Icons font
|
||||
|
||||
- Upload devicon.css and font files to your project
|
||||
- Upload devicon.min.css and font files to your project
|
||||
- Note: the `devicon.css` file is not the same as the `devicon.min.css`. It doesn't contain any colors or aliases.
|
||||
|
||||
```html
|
||||
<link rel="stylesheet" href="devicon.css">
|
||||
|
||||
<!-- if you want colored versions -->
|
||||
<link rel="stylesheet" href="devicon-colors.css">
|
||||
<link rel="stylesheet" href="devicon.min.css">
|
||||
```
|
||||
|
||||
- Add icon using `<i>` tag
|
||||
|
@ -107,7 +107,7 @@ function createColorsCSS(deviconJson) {
|
||||
console.log(`This object doesn't have a font or a color: ${name}`);
|
||||
return "";
|
||||
}
|
||||
let cssClasses = fonts.map(font => `.devicon-${name}-${font}`);
|
||||
let cssClasses = fonts.map(font => `.devicon-${name}-${font}.colored`);
|
||||
return `${cssClasses.join(",")}{color: ${color}}`;
|
||||
}).join(" ");
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user