Merge pull request #5695 from jeradM/map-card

Add map card documentation.
This commit is contained in:
DubhAd 2018-07-08 21:01:32 +01:00 committed by GitHub
commit 62697b314f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 66 additions and 0 deletions

View File

@ -0,0 +1,66 @@
---
layout: page
title: "Map Card"
sidebar_label: Map
description: "A card that allows you to display entities on a map"
date: 2018-07-08 10:28 +00:00
sidebar: true
comments: false
sharing: true
footer: true
---
A card that allows you to display entities on a map
<p class='img'>
<img src='/images/lovelace/lovelace_map_card.png' alt='Screenshot of the map card'>
Screenshot of the map card.
</p>
### {% linkable_title Options %}
{% configuration %}
type:
required: true
description: "`map`"
type: string
entities:
required: true
description: "Entity id's or an `entity` object (see structure below)."
type: list
title:
required: false
description: Card title
type: string
aspect_ratio:
required: false
description: "Map height:width ratio"
type: string
default: 100%
{% endconfiguration %}
`entity` object:
{% configuration %}
entity:
required: true
description: "An entity_id. Example: 'device_tracker.demo_paulus'."
type: string
{% endconfiguration %}
<p class='note'>
Only entities that have latitude and longitude attributes will be displayed on the map
</p>
### {% linkable_title Examples %}
Basic map example:
```yaml
- type: map
aspect_ratio: 100%
entities:
- entity: device_tracker.demo_paulus
- zone.home
```

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB