From d1d6f916e0e6a5b4b8869c5ad0b53913e545ffc5 Mon Sep 17 00:00:00 2001 From: Tony Stork Date: Fri, 11 Jul 2025 21:23:48 -0400 Subject: [PATCH] Add NWS SPC status chips for the daily severe weather outlooks --- mobile_dashboard.yaml | 86 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) diff --git a/mobile_dashboard.yaml b/mobile_dashboard.yaml index d98664a..97778bc 100644 --- a/mobile_dashboard.yaml +++ b/mobile_dashboard.yaml @@ -3753,6 +3753,92 @@ views: - condition: state entity: input_boolean.school_cancelled state: 'on' + - type: custom:mushroom-template-badge + content: '{{ states(entity) }}' + icon: |- + {% if is_state(entity,'Marginal Risk') %} + mdi:numeric-1-circle + {% elif is_state(entity,'Slight Risk') %} + mdi:numeric-2-circle + {% elif is_state(entity,'Enhanced Risk') %} + mdi:numeric-3-circle + {% elif is_state(entity,'Moderate Risk') %} + mdi:numeric-4-circle + {% elif is_state(entity,'High Risk') %} + mdi:numeric-5-circle + {% elif is_state(entity,'General Thunderstorms Risk') %} + mdi:information + {% else %} + mdi:close + {% endif %} + color: '{{ state_attr(entity,''fill'') }}' + entity: sensor.spc_outlook_day_1 + label: SPC Outlook Day 1 + tap_action: + action: more-info + hold_action: + action: none + double_tap_action: + action: none + visibility: + - condition: and + conditions: + - condition: state + entity: sensor.spc_outlook_day_1 + state_not: unavailable + - condition: state + entity: sensor.spc_outlook_day_1 + state_not: unknown + - condition: state + entity: sensor.spc_outlook_day_1 + state_not: No Risk + - type: custom:mushroom-template-badge + content: '{{ state_attr(entity,''wind_probability'') }}' + icon: mdi:weather-windy + color: '{{ state_attr(entity,''wind_fill'') }}' + entity: sensor.spc_outlook_day_1 + label: SPC Wind Risk + tap_action: &ref_0 + action: more-info + hold_action: &ref_1 + action: none + double_tap_action: &ref_2 + action: none + visibility: &ref_3 + - condition: and + conditions: + - condition: state + entity: sensor.spc_outlook_day_1 + state_not: unavailable + - condition: state + entity: sensor.spc_outlook_day_1 + state_not: unknown + - condition: state + entity: sensor.spc_outlook_day_1 + state_not: No Risk + - condition: state + entity: sensor.spc_outlook_day_1 + state_not: General Thunderstorms Risk + - type: custom:mushroom-template-badge + content: '{{ state_attr(entity,''torn_probability'') }}' + icon: mdi:weather-tornado + color: '{{ state_attr(entity,''torn_fill'') }}' + entity: sensor.spc_outlook_day_1 + label: SPC Tornado Risk + tap_action: *ref_0 + hold_action: *ref_1 + double_tap_action: *ref_2 + visibility: *ref_3 + - type: custom:mushroom-template-badge + content: '{{ state_attr(entity,''hail_probability'') }}' + icon: mdi:weather-hail + color: '{{ state_attr(entity,''hail_fill'') }}' + entity: sensor.spc_outlook_day_1 + label: SPC Hail Risk + tap_action: *ref_0 + hold_action: *ref_1 + double_tap_action: *ref_2 + visibility: *ref_3 - type: custom:mushroom-template-badge content: |- {% if is_state(entity,'on') %}