mirror of
https://github.com/privacyguides/privacyguides.org.git
synced 2025-07-07 03:52:38 +00:00
docs: Add recommendation for WebP optimization (#2666)
Signed-off-by: Jonah Aragon <jonah@triplebit.net> Signed-off-by: Daniel Gray <dngray@privacyguides.org> Signed-off-by: kimg45 <138676274+kimg45@users.noreply.github.com>
This commit is contained in:
@ -2,11 +2,11 @@
|
|||||||
title: Uploading Images
|
title: Uploading Images
|
||||||
---
|
---
|
||||||
|
|
||||||
Here are a couple of general rules for contributing to Privacy Guides:
|
If you make changes to this website that involve adding new images or replacing existing ones, here are a couple of general recommendations:
|
||||||
|
|
||||||
## Images
|
## Images
|
||||||
|
|
||||||
- We **prefer** SVG images, but if those do not exist we can use PNG images
|
- We **prefer** SVG images, but if those do not exist we can use PNG images. Additionally, for cover images, we prefer that they are obtained from [Unsplash](https://unsplash.com) and are in the WebP format.
|
||||||
|
|
||||||
Company logos have canvas size of:
|
Company logos have canvas size of:
|
||||||
|
|
||||||
@ -17,7 +17,7 @@ Company logos have canvas size of:
|
|||||||
|
|
||||||
### PNG
|
### PNG
|
||||||
|
|
||||||
Use the [OptiPNG](https://sourceforge.net/projects/optipng) to optimize the PNG image:
|
Use the [OptiPNG](https://sourceforge.net/projects/optipng) tool to optimize PNG images:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
optipng -o7 file.png
|
optipng -o7 file.png
|
||||||
@ -87,3 +87,11 @@ scour --set-precision=5 \
|
|||||||
--protect-ids-noninkscape \
|
--protect-ids-noninkscape \
|
||||||
input.svg output.svg
|
input.svg output.svg
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### WebP
|
||||||
|
|
||||||
|
Use the [cwebp](https://developers.google.com/speed/webp/docs/using) command to convert PNG or JPEG image files to WebP format:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cwebp -q 70 -m 6 input_file -o output.webp
|
||||||
|
```
|
||||||
|
Reference in New Issue
Block a user