README: Add a section about light and dark modes in SVG. #3
1 changed files with 12 additions and 0 deletions
12
README.md
12
README.md
|
|
@ -50,6 +50,18 @@ The [online](https://svgomg.net/) version can be used.
|
||||||
- Make sure `Prefer viewBox to width/height` is enabled.
|
- Make sure `Prefer viewBox to width/height` is enabled.
|
||||||
- Download the optimized SVG file.
|
- Download the optimized SVG file.
|
||||||
|
|
||||||
|
### Last touch of style
|
||||||
|
|
||||||
|
If desired, a `<style>` node can be added to the `<svg>` root with the following
|
||||||
|
content:
|
||||||
|
|
||||||
|
```css
|
||||||
|
:root{color-scheme:light dark;fill:currentColor;}
|
||||||
|
```
|
||||||
|
|
||||||
|
This will allow the SVG to adapt to light and dark modes, even when used from a
|
||||||
|
`<img>` element.
|
||||||
|
|
||||||
### Git
|
### Git
|
||||||
|
|
||||||
- Push to this Git repository. No need to use [Git LFS](https://git-lfs.com/).
|
- Push to this Git repository. No need to use [Git LFS](https://git-lfs.com/).
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue