Compare commits

...

7 Commits

9 changed files with 95 additions and 49 deletions

View File

@@ -1 +1 @@
2026.4.0
2026.4.1

View File

@@ -6602,3 +6602,22 @@
path: github.com/weatheralerts_persistent_notification_original.yaml
input:
sensor: sensor.weatheralerts_defiance_ohz004_ohc039
- id: '1775709997448'
alias: Basement Heat Disallow
description: Turn off the heater when the Heat Allowed toggle is switched off
triggers:
- trigger: state
entity_id:
- input_boolean.basement_studio_heat_allowed
from:
- 'on'
to:
- 'off'
conditions: []
actions:
- action: climate.turn_off
metadata: {}
target:
entity_id: climate.basement_studio_vtherm
data: {}
mode: restart

View File

@@ -162,6 +162,22 @@
}
},
{
'language': 'da',
'plural_form': 'english',
'phrases': {
'year': ['år', 'år', 'år'],
'month': ['mnd', 'måned', 'måneder'],
'week': ['uge', 'uge', 'uger'],
'day': ['dag', 'dag', 'dage'],
'hour': ['t.', 'time', 'timer'],
'minute': ['min.', 'minut', 'minutter'],
'second': ['sek.', 'sekund', 'sekunder'],
'millisecond': ['ms.', 'millisekund', 'millisekunder'],
'combine': 'og',
'error': 'Ugyldig dato',
}
},
{
'language': 'dk',
'plural_form': 'english',
'phrases': {
@@ -170,7 +186,7 @@
'week': ['uge', 'uge', 'uger'],
'day': ['dag', 'dag', 'dage'],
'hour': ['t.', 'time', 'timer'],
'minute': ['min.', 'minut', 'minuter'],
'minute': ['min.', 'minut', 'minutter'],
'second': ['sek.', 'sekund', 'sekunder'],
'millisecond': ['ms.', 'millisekund', 'millisekunder'],
'combine': 'og',
@@ -236,7 +252,7 @@
'hour': ['ч', 'час', 'часа', 'часов'],
'minute': ['м', 'минута', 'минуты', 'минут'],
'second': ['с', 'секунда', 'секунды', 'секунд'],
'millisecond': ['мс', 'миллисекунда', 'миллисекунды', 'миллисекунд'],
'millisecond': ['мс', 'милисекунда', 'милисекунды', 'милисекунд'],
'combine': 'и',
'error': 'Неверная дата',
}
@@ -337,22 +353,6 @@
'error': 'Érvénytelen dátum',
}
},
{
'language': 'tr',
'plural_form': 'english',
'phrases': {
'year': ['yıl', 'yıl', 'yıl'],
'month': ['ay', 'ay', 'ay'],
'week': ['hf', 'hafta', 'hafta'],
'day': ['gün', 'gün', 'gün'],
'hour': ['sa', 'saat', 'saat'],
'minute': ['dk', 'dakika', 'dakika'],
'second': ['sn', 'saniye', 'saniye'],
'millisecond': ['ms', 'milisaniye', 'milisaniye'],
'combine': 've',
'error': 'Geçersiz tarih',
}
},
] -%}
{# macro to convert the abbreviated input for the not_use and always_show lists to the full time part names #}
@@ -374,8 +374,33 @@
macro to split a timedelta in years, months, weeks, days, hours, minutes, seconds and milliseconds
used by the relative time plus macro, set up as a seperate macro so it can be reused
#}
{%- macro time_split(date, parts=8, compare_date=now(), not_use=[], always_show=['all'], time=true, round_mode='floor') -%}
{%- macro time_split(date, parts=8, compare_date=now(), not_use=[], always_show=['all'], time=true, round_mode='floor', duration=false, duration_unit='s') -%}
{#- set defaults for input if not entered #}
{%- if date in states | map(attribute='entity_id') -%}
{%- if date | has_value and is_state_attr(date, 'device_class', 'duration') -%}
{%- set duration = true -%}
{%- set duration_unit = state_attr(date, 'unit_of_measurement') -%}
{%- set date = states(date) -%}
{%- elif date is match('input_datetime') and not state_attr(date, 'has_date') -%}
{%- set date = today_at(states(date)) -%}
{%- else -%}
{%- set date = states(date) -%}
{%- endif -%}
{%- endif -%}
{%- if duration and date | is_number -%}
{%- set conversion_mapper =
{
'd': 3600 * 24,
'h': 3600,
'min': 60,
's': 1,
'ms': 1/1000,
'μs': 1/1000000
}
-%}
{%- set sec = date | float * conversion_mapper[duration_unit] | default(1) -%}
{%- set date = now() + timedelta(seconds=sec) -%}
{%- endif -%}
{%- set date = date if date is datetime else date | as_datetime('invalid') -%}
{%- set compare_date = compare_date if compare_date is datetime else compare_date | as_datetime('invalid') -%}
{%- set time = time | bool(true) -%}
@@ -521,7 +546,7 @@
{%- else -%} {{- dict(error='No time parts left to output') -}}
{%- endif -%} {# 3 #}
{%- endif -%} {# 2 #}
{%- else -%} {{- dict(error='Invalid date input')-}}
{%- else -%} {{- dict(error='Invalid date input') -}}
{%- endif -%} {# 1 #}
{%- endmacro -%}
@@ -557,7 +582,7 @@
{%- endmacro -%}
{# macro to output a timedelta in a readable format #}
{%- macro relative_time_plus(date, parts=1, abbr=false, language='en', compare_date=now(), not_use=['millisecond'], always_show=[], time=true, round_mode='floor') -%}
{%- macro relative_time_plus(date, parts=1, abbr=false, language='en', compare_date=now(), not_use=['millisecond'], always_show=[], time=true, round_mode='floor', duration=false, duration_unit='s') -%}
{#- select correct phrases bases on language input #}
{%- set phrases = _time_period_phrases -%}
{%- set languages = phrases | map(attribute='language') | list -%}
@@ -566,7 +591,7 @@
{%- set plural_form = phrases | selectattr('language', 'eq', language) | map(attribute='plural_form') | list | first -%}
{%- set abbr = abbr | bool(false) -%}
{# split timedelta #}
{%- set time_parts = time_split(date, parts, compare_date, not_use, always_show, time, round_mode) | from_json -%}
{%- set time_parts = time_split(date, parts, compare_date, not_use, always_show, time, round_mode, duration, duration_unit) | from_json -%}
{# check for error #}
{%- if 'error' in time_parts -%}
{{- time_parts['error'] -}}

View File

@@ -61,7 +61,7 @@
{% if is_state(team,'PRE') %}
{% set date = state_attr(team,'date') | as_timestamp | timestamp_custom('%m-%d') %}
{% if date == now().strftime('%m-%d') %}
The {{ state_attr(team,'friendly_name') }} will be playing today against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} at {{ state_attr(team,'venue') }}.
The {{ entity_name(team) }} will be playing today against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} at {{ state_attr(team,'venue') }}.
{{ sports_str(team,'start') }} is at {{ state_attr(team,'date') | as_timestamp | timestamp_custom('%I:%M %p') }}.
{% endif %}
{% endif %}
@@ -82,26 +82,26 @@
{% set yday = (as_timestamp(now()) - (24*3600)) | timestamp_custom('%m-%d') %}
{% if date == now().strftime('%m-%d') %}
{% if state_attr(team,'clock') in ['postponed','Postponed'] %}
The {{ state_attr(team,'friendly_name') }} had their game postponed today, and it will be played at a later date.
The {{ entity_name(team) }} had their game postponed today, and it will be played at a later date.
{% elif (state_attr(team,'team_score') | int) == state_attr(team,'opponent_score') | int %}
The {{ state_attr(team,'friendly_name') }} tied in their game today against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }}.
The {{ entity_name(team) }} tied in their game today against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }}.
{% elif state_attr(team,'team_winner') == true %}
The {{ state_attr(team,'friendly_name') }} won their game today against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }}.
The {{ entity_name(team) }} won their game today against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }}.
{% elif state_attr(team,'opponent_winner') == true %}
The {{ state_attr(team,'friendly_name') }} lost their game today against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'opponent_score') }} to {{ state_attr(team,'team_score') }}.
The {{ entity_name(team) }} lost their game today against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'opponent_score') }} to {{ state_attr(team,'team_score') }}.
{% endif %}
{% if state_attr(team,'clock') not in ['postponed','Postponed'] and state_attr(team,'team_record') != None %}
This brings their record to {{ state_attr(team,'team_record') | replace("-"," and ") }} on the season.
{% endif %}
{% elif yday == date %}
{% if state_attr(team,'clock') in ['postponed','Postponed'] %}
The {{ state_attr(team,'friendly_name') }} had their game postponed yesterday, and it will be played at a later date.
The {{ entity_name(team) }} had their game postponed yesterday, and it will be played at a later date.
{% elif (state_attr(team,'team_score') | int) == state_attr(team,'opponent_score') | int %}
The {{ state_attr(team,'friendly_name') }} tied in their game yesterday against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }}.
The {{ entity_name(team) }} tied in their game yesterday against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }}.
{% elif state_attr(team,'team_winner') == true %}
The {{ state_attr(team,'friendly_name') }} won their game yesterday against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }}.
The {{ entity_name(team) }} won their game yesterday against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }}.
{% elif state_attr(team,'opponent_winner') == true %}
The {{ state_attr(team,'friendly_name') }} lost their game yesterday against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'opponent_score') }} to {{ state_attr(team,'team_score') }}.
The {{ entity_name(team) }} lost their game yesterday against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} by a score of {{ state_attr(team,'opponent_score') }} to {{ state_attr(team,'team_score') }}.
{% endif %}
{% if state_attr(team,'clock') not in ['postponed','Postponed'] %}
This brings their record to {{ state_attr(team,'team_record') | replace("-"," and ") }} on the season.
@@ -109,11 +109,11 @@
{% endif %}
{% elif is_state(team,'IN') %}
{% if (state_attr(team,'team_score') | int) == (state_attr(team,'opponent_score') | int) %}
The {{ state_attr(team,'friendly_name') }} are currently tied in their game against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} with a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }} {{ sports_clock(team) }}.
The {{ entity_name(team) }} are currently tied in their game against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} with a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }} {{ sports_clock(team) }}.
{% elif (state_attr(team,'team_score') | int) > (state_attr(team,'opponent_score') | int) %}
The {{ state_attr(team,'friendly_name') }} are currently winning their game against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} with a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }} {{ sports_clock(team) }}.
The {{ entity_name(team) }} are currently winning their game against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} with a score of {{ state_attr(team,'team_score') }} to {{ state_attr(team,'opponent_score') }} {{ sports_clock(team) }}.
{% else %}
The {{ state_attr(team,'friendly_name') }} are currently losing their game against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} with a score of {{ state_attr(team,'opponent_score') }} to {{ state_attr(team,'team_score') }} {{ sports_clock(team) }}.
The {{ entity_name(team) }} are currently losing their game against {% if state_attr(team,'league') != 'NCAAF'%}the{% endif %} {{ opponent_name }} with a score of {{ state_attr(team,'opponent_score') }} to {{ state_attr(team,'team_score') }} {{ sports_clock(team) }}.
{% endif %}
{% endif %}
{% endmacro %}

View File

@@ -31,15 +31,15 @@ input_datetime:
input_number:
rabbit_feeding_interval:
name: Rabbit Feeding Interval
min: 0
min: 1
max: 24
step: 1
unit_of_measurement: hours
icon: mdi:rabbit
rabbit_hutch_cleaning_interval:
name: Rabbit Hutch Cleaning Interval
min: 0
max: 3
min: 1
max: 14
step: 1
unit_of_measurement: days
icon: mdi:rabbit

View File

@@ -376,7 +376,7 @@ intent_script:
speech:
text: >
{% set location = states(person) %}
{% set name = state_attr(person,'friendly_name') %}
{% set name = entity_name(person) %}
{% if location in ['away','not_home'] %}
{{ name }} is currently away from home
{% elif location in ['unavailable','unknown'] %}

View File

@@ -271,7 +271,7 @@ template:
{% endfor %}
{{ fn.friendly }}
icon: >-
{% if states('sensor.window_faults') | int > 0 %}
{% if this.state | int > 0 %}
mdi:window-open
{% else %}
mdi:window-closed
@@ -335,7 +335,7 @@ template:
{% endfor %}
{{ fn.friendly }}
icon: >-
{% if states('sensor.door_faults') | int > 0 %}
{% if this.state | int > 0 %}
mdi:door-open
{% else %}
mdi:door-closed
@@ -365,7 +365,7 @@ template:
| list %}
{{ window_names }}
icon: >-
{% if states('sensor.windows_open') | int == 0 %}
{% if this.state | int == 0 %}
mdi:window-closed
{% else %}
mdi:window-open
@@ -392,7 +392,7 @@ template:
| list %}
{{ window_names }}
icon: >-
{% if states('sensor.front_windows_open') | int == 0 %}
{% if this.state | int == 0 %}
mdi:window-closed
{% else %}
mdi:window-open
@@ -418,7 +418,7 @@ template:
| list | count %}
{{ windows_open }}
icon: >
{% if states('sensor.living_room_windows_open') | int == 0 %}
{% if this.state | int == 0 %}
mdi:window-closed
{% else %}
mdi:window-open
@@ -442,7 +442,7 @@ template:
| list %}
{{ door_names }}
icon: >-
{% if states('sensor.doors_open') | int == 0 %}
{% if this.state | int == 0 %}
mdi:door-closed
{% else %}
mdi:door-open
@@ -476,7 +476,7 @@ template:
| list %}
{{ interior }}
icon: >-
{% if states('sensor.interior_doors') | int == 0 %}
{% if this.state | int == 0 %}
mdi:door-closed
{% else %}
mdi:door-open
@@ -507,7 +507,7 @@ template:
{% set doors_open = states('sensor.doors_open') | int %}
{{ doors_open + windows_open }}
icon: >-
{% if states('sensor.air_leaks') | int == 0 %}
{% if this.state | int == 0 %}
mdi:leak-off
{% else %}
mdi:leak

View File

@@ -181,7 +181,7 @@ intent_script:
{% set inhibit = "binary_sensor." + team + "_inhibit" %}
{% set sensor = "sensor." + team %}
{% if is_state(inhibit,'on') %}
I do not have any information about the {{ state_attr(team,'friendly_name') }} at this time.
I do not have any information about the {{ entity_name(sensor) }} at this time.
{% elif states(sensor) in ["NOT_FOUND"] %}
They do not appear to have a game scheduled for today.
{% else %}

View File

@@ -58,6 +58,8 @@ ## HACS Components
- [WeatherFlow Forecast](https://github.com/briis/weatherflow_forecast)
- [NWS SPC Outlook](https://github.com/sedward5/nws_spc_outlook)
- [Music Assistant Queue Actions](https://github.com/droans/mass_queue)
- [Bubble Card Tools](https://github.com/Clooos/Bubble-Card-Tools)
- [Home Assistant Global Health Score](https://github.com/D-N91/home-assistant-global-health-score)
</details>
@@ -91,7 +93,7 @@ ## HACS Lovelace Cards
- [Weather Card](https://github.com/bramkragten/weather-card)
- [Template Entity Row](https://github.com/thomasloven/lovelace-template-entity-row)
- [Waze Travel Time](https://github.com/r-renato/ha-card-waze-travel-time)
- [Fold Entity Row](https://github.com/thomasloven/lovelace-fold-entity-row)
- [Lovelace Expander Card](https://github.com/MelleD/lovelace-expander-card)
- [Room Card](https://github.com/marcokreeft87/room-card)
- [Simple Thermostat Card](https://github.com/nervetattoo/simple-thermostat)
- [Clock Weather Card](https://github.com/pkissling/clock-weather-card)