1
0
mirror of https://github.com/imgproxy/imgproxy.git synced 2025-03-17 20:17:48 +02:00

Add emojis to notes and warning in docs

This commit is contained in:
DarthSim 2020-02-13 15:54:43 +06:00
parent 4896cc9438
commit 6c6bcd32f8
6 changed files with 20 additions and 18 deletions

View File

@ -51,7 +51,7 @@ imgproxy can process animated images (GIF, WebP), but since this operation is pr
* `IMGPROXY_MAX_ANIMATION_FRAMES`: the maximum of animated image frames to being processed. Default: `1`.
**Note:** imgproxy summarizes all frames resolutions while checking source image resolution.
**📝Note:** imgproxy summarizes all frames resolutions while checking source image resolution.
imgproxy reads some amount of bytes to check if the source image is SVG. By default it reads maximum of 32KB, but you can change this:
@ -69,7 +69,7 @@ You can limit allowed source URLs:
* `IMGPROXY_ALLOWED_SOURCES`: whitelist of source image URLs prefixes divided by comma. When blank, imgproxy allows all source image URLs. Example: `s3://,https://example.com/,local://`. Default: blank.
**Warning:** Be careful when using this config to limit source URL hosts, and always add a trailing slash after the host. Bad: `http://example.com`, good: `http://example.com/`. If you don't add a trailing slash, `http://example.com@baddomain.com` will be an allowed URL but the request will be made to `baddomain.com`.
**⚠️Warning:** Be careful when using this config to limit source URL hosts, and always add a trailing slash after the host. Bad: `http://example.com`, good: `http://example.com/`. If you don't add a trailing slash, `http://example.com@baddomain.com` will be an allowed URL but the request will be made to `baddomain.com`.
When you use imgproxy in a development environment, it can be useful to ignore SSL verification:
@ -102,7 +102,7 @@ Also you may want imgproxy to respond with the same error message that it writes
* `7`: Table from A Visual Detection Model for DCT Coefficient Quantization (1993);
* `8`: Table from An Improved Detection Model for DCT Coefficient Quantization (1993).
**Note:** `IMGPROXY_JPEG_TRELLIS_QUANT`, `IMGPROXY_JPEG_OVERSHOOT_DERINGING`, `IMGPROXY_JPEG_OPTIMIZE_SCANS`, and `IMGPROXY_JPEG_QUANT_TABLE` require libvips to be built with [MozJPEG](https://github.com/mozilla/mozjpeg) since standard libjpeg doesn't support those optimizations.
**📝Note:** `IMGPROXY_JPEG_TRELLIS_QUANT`, `IMGPROXY_JPEG_OVERSHOOT_DERINGING`, `IMGPROXY_JPEG_OPTIMIZE_SCANS`, and `IMGPROXY_JPEG_QUANT_TABLE` require libvips to be built with [MozJPEG](https://github.com/mozilla/mozjpeg) since standard libjpeg doesn't support those optimizations.
### Advanced PNG compression
@ -124,7 +124,7 @@ imgproxy can use the `Accept` HTTP header to detect if the browser supports WebP
When WebP support detection is enabled, please take care to configure your CDN or caching proxy to take the `Accept` HTTP header into account while caching.
**Warning**: Headers cannot be signed. This means that an attacker can bypass your CDN cache by changing the `Accept` HTTP headers. Have this in mind when configuring your production caching setup.
**⚠️Warning:** Headers cannot be signed. This means that an attacker can bypass your CDN cache by changing the `Accept` HTTP headers. Have this in mind when configuring your production caching setup.
## Client Hints support
@ -132,7 +132,7 @@ imgproxy can use the `Width`, `Viewport-Width` or `DPR` HTTP headers to determin
* `IMGPROXY_ENABLE_CLIENT_HINTS`: enables Client Hints support to determine default width and DPR options. Read [here](https://developers.google.com/web/updates/2015/09/automating-resource-selection-with-client-hints) details about Client Hints.
**Warning**: Headers cannot be signed. This means that an attacker can bypass your CDN cache by changing the `Width`, `Viewport-Width` or `DPR` HTTP headers. Have this in mind when configuring your production caching setup.
**⚠️Warning:** Headers cannot be signed. This means that an attacker can bypass your CDN cache by changing the `Width`, `Viewport-Width` or `DPR` HTTP headers. Have this in mind when configuring your production caching setup.
## Watermark
@ -249,11 +249,11 @@ imgproxy can send logs to syslog, but this feature is disabled by default. To en
* `IMGPROXY_SYSLOG_ADDRESS`: address of the syslog service. Not used if `IMGPROXY_SYSLOG_NETWORK` is blank. Default: blank;
* `IMGPROXY_SYSLOG_TAG`: specific syslog tag. Default: `imgproxy`;
**Note:** imgproxy always uses structured log format for syslog.
**📝Note:** imgproxy always uses structured log format for syslog.
## Memory usage tweaks
**Warning:** It's highly recommended to read [Memory usage tweaks](memory_usage_tweaks.md) guide before changing this settings.
**⚠️Warning:** It's highly recommended to read [Memory usage tweaks](memory_usage_tweaks.md) guide before changing this settings.
* `IMGPROXY_DOWNLOAD_BUFFER_SIZE`: the initial size (in bytes) of a single download buffer. When zero, initializes empty download buffers. Default: `0`;
* `IMGPROXY_GZIP_BUFFER_SIZE`: the initial size (in bytes) of a single GZip buffer. When zero, initializes empty GZip buffers. Makes sense only when GZip compression is enabled. Default: `0`;

View File

@ -181,8 +181,9 @@ Removes surrounding background.
* `threshold` - color similarity tolerance.
**Warning:** Trimming requires an image to be fully loaded into memory. This disables scale-on-load and significantly increases memory usage and processing time. Use it carefully with large images.
**Note:** Trimming of animated images is not supported.
**⚠️Warning:** Trimming requires an image to be fully loaded into memory. This disables scale-on-load and significantly increases memory usage and processing time. Use it carefully with large images.
**📝Note:** Trimming of animated images is not supported.
#### Quality
@ -204,8 +205,9 @@ mb:%bytes
When set, imgproxy automatically degrades the quality of the image until the image is under the specified amount of bytes.
**Note:** Applicable only to `jpg`, `webp`, `heic`, and `tiff`.
**Warning**: When `max_bytes` is set, imgproxy saves image multiple times to achieve specified image size.
**📝Note:** Applicable only to `jpg`, `webp`, `heic`, and `tiff`.
**⚠️Warning:** When `max_bytes` is set, imgproxy saves image multiple times to achieve specified image size.
Default: 0
@ -438,7 +440,7 @@ The source URL can be provided as is, prendended by `/plain/` part:
/plain/http://example.com/images/curiosity.jpg
```
**Note:** If the source URL contains query string or `@`, you need to escape it.
**📝Note:** If the source URL contains query string or `@`, you need to escape it.
When using plain source URL, you can specify the [extension](#extension) after `@`:
@ -466,7 +468,7 @@ Extension specifies the format of the resulting image. At the moment, imgproxy s
<img class="pro-badge" src="assets/pro.svg" alt="pro" /> Also you can yse `mp4` extension to convert animated images to MP4.
**Note:** Read more about image formats support [here](image_formats_support.md).
**📝Note:** Read more about image formats support [here](image_formats_support.md).
The extension part can be omitted. In this case, imgproxy will use source image format as resulting one. If source image format is not supported as resulting, imgproxy will use `jpg`. You also can [enable WebP support detection](configuration.md#webp-support-detection) to use it as default resulting format when possible.

View File

@ -63,7 +63,7 @@ The source URL can be provided as is, prepended by `/plain/` part:
/plain/http://example.com/images/curiosity.jpg
```
**Note:** If the sorce URL contains query string or `@`, you need to escape it.
**📝Note:** If the sorce URL contains query string or `@`, you need to escape it.
When using plain source URL, you can specify the [extension](#extension) after `@`:
@ -91,7 +91,7 @@ Extension specifies the format of the resulting image. At the moment, imgproxy s
<img class="pro-badge" src="assets/pro.svg" alt="pro" /> Also you can yse `mp4` extension to convert animated images to MP4.
**Note:** Read more about image formats support [here](image_formats_support.md).
**📝Note:** Read more about image formats support [here](image_formats_support.md).
The extension part can be omitted. In this case, imgproxy will use source image format as resulting one. If source image format is not supported as resulting, imgproxy will use `jpg`. You also can [enable WebP support detection](configuration.md#webp-support-detection) to use it as default resulting format when possible.

View File

@ -49,7 +49,7 @@ Since processing of animated images is pretty heavy, only one frame is processed
* `IMGPROXY_MAX_ANIMATION_FRAMES`: the maximum of animated image frames to being processed. Default: `1`.
**Note:** imgproxy summarizes all frames resolutions while checking source image resolution.
**📝Note:** imgproxy summarizes all frames resolutions while checking source image resolution.
## Converting animated images to MP4 <img class="pro-badge" src="assets/pro.svg" alt="pro" />

View File

@ -2,7 +2,7 @@
There are some imgproxy options that can help you to optimize memory usage and decrease memory fragmentation.
**Warning:** This is an advanced part. Please make sure that you know what you're doing before changing anything.
**⚠️Warning:** This is an advanced part. Please make sure that you know what you're doing before changing anything.
### IMGPROXY_DOWNLOAD_BUFFER_SIZE

View File

@ -15,7 +15,7 @@ There are three ways to specify a watermark image using environment variables:
You can also specify the base opacity of watermark with `IMGPROXY_WATERMARK_OPACITY`.
**Note:** If you're going to use `scale` argument of `watermark`, it's highly recommended to use SVG, WebP or JPEG watermarks since these formats support scale-on-load.
**📝Note:** If you're going to use `scale` argument of `watermark`, it's highly recommended to use SVG, WebP or JPEG watermarks since these formats support scale-on-load.
## Watermarking an image