Add documentation for images using URL (#3409)

This commit is contained in:
Jesse Hills 2023-11-24 08:10:39 +13:00
parent 04ff3bd010
commit a1861ff6de
No known key found for this signature in database
GPG Key ID: BEAAE804EFD8E83A
2 changed files with 21 additions and 12 deletions

View File

@ -678,6 +678,13 @@ Use this component to store graphical images on the device, you can then draw th
id: alert
resize: 80x80
.. code-block:: yaml
image:
- file: https://esphome.io/_images/logo.png
id: esphome_logo
resize: 200x162
Configuration variables:
- **file** (**Required**, string):
@ -685,6 +692,7 @@ Configuration variables:
- **Local files**: The path (relative to where the .yaml file is) of the image file.
- **Material Design Icons**: Specify the `Material Design Icon <https://pictogrammers.com/library/mdi/>`_
id in the format ``mdi:icon-name``, and that icon will automatically be downloaded and added to the configuration.
- **Remote files**: The URL of the image file.
- **id** (**Required**, :ref:`config-id`): The ID with which you will be able to reference the image later
in your display code.

View File

@ -395,6 +395,7 @@ def lint_directive_formatting(fname, content):
include=["*.rst"],
exclude=[
"components/web_server.rst",
"components/display/index.rst",
],
)
def lint_esphome_io_link(fname, match):