fix markdown warnings

This commit is contained in:
mampfes
2022-12-28 17:36:18 +01:00
parent 093c1c63ae
commit f321a47531
3 changed files with 24 additions and 12 deletions

View File

@@ -14,7 +14,6 @@ This is implemented using the following markup:
The empty line after the <p> is intentional and is required for the expand/collapse to function correctly.
-->
<img src="/images/icon.png" alt="Waste Collection Schedule logo" title="Waste Collection Schedule" align="right" height="60" />
# Frequently Asked Questions, or "How Do I ...?"
@@ -38,9 +37,9 @@ date_template: '{{value.date.strftime("%m/%d/%Y")}}'
value_template: '{{value.date.strftime("%a, %m/%d/%Y")}}'
date_template: '{{value.date.strftime("%a, %m/%d/%Y")}}'
```
</p>
</details>
<details>
<summary>How do I show the number of days to the next collection?</summary>
<p>
@@ -50,9 +49,9 @@ Set `value_template` within the sensor configuration:
```yaml
value_template: 'in {{value.daysTo}} days'
```
</p>
</details>
<details>
<summary>How do I show Today / Tomorrow instead of in 0 / 1 days?</summary>
<p>
@@ -65,6 +64,7 @@ Set `value_template` within the sensor configuration:
# returns "in X days" if value.daysTo > 1
value_template: '{% if value.daysTo == 0 %}Today{% elif value.daysTo == 1 %}Tomorrow{% else %}in {{value.daysTo}} days{% endif %}'
```
</p>
</details>
@@ -95,6 +95,7 @@ Set `value_template` within the sensor configuration:
```yaml
value_template: '{{value.daysTo}}'
```
</p>
</details>
@@ -107,6 +108,7 @@ Set `value_template` within the sensor configuration:
```yaml
value_template: '{{value.date.strftime("%m/%d/%Y")}}'
```
</p>
</details>
@@ -119,6 +121,7 @@ Set `value_template` within the sensor configuration:
```yaml
value_template: '{{value.types|join(", ")}}'
```
</p>
</details>
@@ -162,6 +165,7 @@ waste_collection_schedule:
- type: Very long recycle name
alias: Recycle
```
</p>
</details>
@@ -179,6 +183,7 @@ waste_collection_schedule:
- type: Unwanted Waste Type
show: false
```
</p>
</details>
@@ -228,6 +233,7 @@ state:
value: '[[[ return entity.state.split("|")[1] == 1 ]]]'
- value: default
```
</p>
</details>
@@ -266,6 +272,7 @@ sensor:
entity: sensor.garbage
type: 'custom:garbage-collection-card'
```
</p>
</details>
@@ -278,4 +285,3 @@ Prerequisites: You already have dedicated sensors per waste type and want to sho
Add `add_days_to: True` to the configuration of all sensors you want to sort. This will add the attribute `daysTo` which can be used by e.g. [auto-entities](https://github.com/thomasloven/lovelace-auto-entities) to sort entities by day of next collection.
</p>
</details>

View File

@@ -3,12 +3,14 @@
# Installation
## Automated Installation Using HACS
![hacs_badge](https://img.shields.io/badge/HACS-Default-orange)
![hacs installs](https://img.shields.io/endpoint.svg?url=https%3A%2F%2Flauwbier.nl%2Fhacs%2Fwaste_collection_schedule)
The `Waste Collection Schedule` component can be installed via [HACS](https://hacs.xyz/). This allows you to be notified of any updates or new releases of the component.
After installing HACS:
1. Visit the HACS `Integrations` panel in Home Assistant.
2. Click `Explore & Download Repositories`.
3. Search for `Waste Collection Schedule`.
@@ -67,7 +69,6 @@ waste_collection_schedule:
separator: SEPARATOR
```
| Parameter | Type | Requirement | Description |
|-----|-----|-----|-----|
| sources: | | required | Contains information for the service provider being used |
@@ -105,6 +106,7 @@ sensor:
- Waste Type 1
- Waste Type 2
```
| Parameter | Type | Requirement | Description |
|--|--|--|--|
| platform | | required | waste_collection_schedule |
@@ -118,8 +120,10 @@ sensor:
| add_days_to | boolean | optional | Adds a `daysTo` attribute to the source entity state containing the number of days to the next collection |
| types | list of strings | optional | Used to filter waste types. The sensor will only display collections matching these waste types |
## Options for _details_format_ parameter ##
## Options for _details_format_ parameter
Possible choices:
| upcoming | appointment_types | generic |
|--|--|--|
| shows a list of upcoming collections |shows a list of waste types and their next collection date | provides all attributes as generic Python data types. |
@@ -135,15 +139,16 @@ The following variables can be used within `value_template` and `date_template`:
| `value.daysTo` | Days to collection | int | 0 = today, 1 = tomorrow, etc |
| `value.types` | Waste types | list of strings | Use `join` filter to join types |
## HomeAssistant Service to manually update the source
## HomeAssistant Service to manually trigger update
If you want to manually update the source, you can call the service:
If you want to trigger a manual update of the sources, you can call the service:
`waste_collection_schedule.fetch_data`
Normally the configuration parametet 'fetch_time' is used to do this periodically.
Normally the configuration option 'fetch_time' is used to do this periodically.
## Further Help
## Further help ##
For a full example, see [custom_components/waste_collection_schedule/waste_collection_schedule/source/example.py](/custom_components/waste_collection_schedule/waste_collection_schedule/source/example.py).
For other examples on how to configure source(s) and sensor(s), see the [FAQ](/doc/faq.md).

View File

@@ -6,16 +6,17 @@ Github Markdown reference: https://docs.github.com/en/get-started/writing-on-git
<img src="/images/icon.png" alt="Waste Collection Schedule logo" title="Waste Collection Schedule" align="right" height="60" />
<!-- The main page heading -->
# Waste Collection Schedule Online
# Waste Collection Schedule Online
<!-- The page content -->
## Community Forum
![Community Discussion](https://img.shields.io/badge/Home%20Assistant%20Community-Discussion-orange)
The main discussion thread on Home Assistant's Community forum can be found [here](https://community.home-assistant.io/t/waste-collection-schedule-framework/186492).
## YouTube
## YouTube
There are some videos on YouTube:
- [Bunte Mülltonnenerinnerung mit Home Assistant](https://youtu.be/MzQgARDvRww) (German language)