Skip to content

Commit

Permalink
Timers: eliminate more explicit mdi:timer and related icons
Browse files Browse the repository at this point in the history
- add `translation_key: timer` to more number and select entities
  that are timers by another name.
- remove icons from `class: duration` sensors

Explicit timer icons remain for now on number entities that are
configuring some duration that doesn't strictly match with a "Timer".

Issue #1579
  • Loading branch information
make-all committed Mar 1, 2024
1 parent 513a555 commit 56134d3
Show file tree
Hide file tree
Showing 42 changed files with 50 additions and 75 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ secondary_entities:
name: lock
- entity: select
name: Countdown
icon: "mdi:timer"
translation_key: timer
category: config
dps:
- id: 12
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ primary_entity:
secondary_entities:
- entity: number
name: Countdown
icon: "mdi:timer"
translation_key: timer
category: config
dps:
- id: 7
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ secondary_entities:
- entity: number
name: Light timer
category: config
icon: "mdi:timer"
translation_key: timer
dps:
- id: 26
type: integer
Expand Down
15 changes: 7 additions & 8 deletions custom_components/tuya_local/devices/atorch_s1wp.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ secondary_entities:
- entity: number
category: config
name: Countdown
icon: "mdi:timer"
translation_key: timer
dps:
- id: 9
type: integer
Expand Down Expand Up @@ -321,7 +321,6 @@ secondary_entities:
name: Countdown timer
category: diagnostic
class: duration
icon: "mdi:timer-star"
dps:
- id: 124
name: sensor
Expand All @@ -330,7 +329,7 @@ secondary_entities:
- entity: number
category: config
name: Timing off time
icon: "mdi:timer"
translation_key: timer
mode: slider
dps:
- id: 125
Expand All @@ -345,7 +344,7 @@ secondary_entities:
- entity: number
category: config
name: Timing on time
icon: "mdi:timer"
translation_key: timer
mode: slider
dps:
- id: 126
Expand All @@ -360,7 +359,7 @@ secondary_entities:
- entity: number
category: config
name: Timing loop on time
icon: "mdi:timer"
translation_key: timer
mode: slider
dps:
- id: 127
Expand All @@ -375,7 +374,7 @@ secondary_entities:
- entity: number
category: config
name: Timing loop off time
icon: "mdi:timer"
translation_key: timer
mode: slider
dps:
- id: 128
Expand All @@ -390,7 +389,7 @@ secondary_entities:
- entity: number
category: config
name: Timing countdown on time
icon: "mdi:timer"
translation_key: timer
mode: slider
dps:
- id: 129
Expand All @@ -405,7 +404,7 @@ secondary_entities:
- entity: number
category: config
name: Timing countdown off time
icon: "mdi:timer"
translation_key: timer
mode: slider
dps:
- id: 130
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@ secondary_entities:
category: diagnostic
class: duration
name: Remaining time
icon: "mdi:timer"
dps:
- id: 104
type: integer
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tuya_local/devices/ble_water_valve.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ secondary_entities:
- entity: number
name: Irrigation time
category: config
icon: "mdi:timer"
translation_key: timer
dps:
- id: 11
type: integer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ secondary_entities:
name: Time left
category: diagnostic
class: duration
icon: "mdi:timer"
dps:
- id: 20
name: sensor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ secondary_entities:
name: Time left
category: diagnostic
class: duration
icon: "mdi:timer"
dps:
- id: 20
name: sensor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ secondary_entities:
value: 24 hours
- entity: sensor
name: Time remaining
icon: "mdi:timer"
class: duration
category: diagnostic
dps:
- id: 20
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ secondary_entities:
- entity: sensor
name: UV runtime
class: duration
icon: "mdi:timer-outline"
category: diagnostic
dps:
- id: 11
Expand Down
5 changes: 2 additions & 3 deletions custom_components/tuya_local/devices/cecotec_fan_light.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,7 @@ secondary_entities:
# - dps_val: night
# value: night
- entity: select
name: timer
icon: "mdi:timer"
translation_key: timer
dps:
- id: 22
name: option
Expand All @@ -101,7 +100,7 @@ secondary_entities:
- dps_val: "cancel"
value: "cancel"
- dps_val: "1h"
value: "1 hours"
value: "1 hour"
- dps_val: "2h"
value: "2 hours"
- dps_val: "3h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ primary_entity:
secondary_entities:
- entity: number
name: Countdown
icon: mdi:timer-lock
translation_key: timer
category: config
dps:
- id: 2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,6 @@ secondary_entities:
- entity: sensor
name: Time left
category: diagnostic
icon: "mdi:timer-outline"
class: duration
dps:
- id: 18
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tuya_local/devices/es01_powerstrip.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ secondary_entities:
- entity: number
category: config
name: USB timer
icon: "mdi:timer"
translation_key: timer
dps:
- id: 8
name: value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@ secondary_entities:
- entity: sensor
name: Time remaining
class: duration
icon: "mdi:timer"
category: diagnostic
dps:
- id: 5
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tuya_local/devices/evsun_evcharger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ secondary_entities:
- entity: number
name: Delayed charge timer
category: config
icon: "mdi:timer"
translation_key: timer
dps:
- id: 28
type: integer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ secondary_entities:
- entity: number
category: config
name: Countdown
icon: "mdi:timer"
translation_key: timer
dps:
- id: 6
name: value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ secondary_entities:
class: measurement
- entity: sensor
name: Time remaining
icon: "mdi:timer-sand"
class: duration
dps:
- id: 101
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ secondary_entities:
name: switch
- entity: number
name: Outlet timer
icon: "mdi:timer"
translation_key: timer
category: config
dps:
- id: 9
Expand All @@ -30,7 +30,7 @@ secondary_entities:
unit: mi
- entity: number
name: USB timer
icon: "mdi:timer"
translation_key: timer
category: config
dps:
- id: 10
Expand Down
4 changes: 2 additions & 2 deletions custom_components/tuya_local/devices/holman_wx1_taptimer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -92,9 +92,9 @@ secondary_entities:
range:
min: 0
max: 60
- entity: number
- entity: sensor
name: Time left
icon: "mdi:timer"
class: duration
category: diagnostic
dps:
- id: 109
Expand Down
12 changes: 6 additions & 6 deletions custom_components/tuya_local/devices/holman_wx2_taptimer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ secondary_entities:
value: "Rain Delay"
- entity: number
name: Manual timer 1
icon: "mdi:timer"
translation_key: timer
category: config
dps:
- id: 107
Expand All @@ -101,9 +101,9 @@ secondary_entities:
range:
min: 0
max: 60
- entity: number
- entity: sensor
name: Time left 1
icon: "mdi:timer"
class: duration
category: diagnostic
dps:
- id: 109
Expand Down Expand Up @@ -540,7 +540,7 @@ secondary_entities:
value: "Rain Delay"
- entity: number
name: Manual timer 2
icon: "mdi:timer"
translation_key: timer
category: config
dps:
- id: 154
Expand All @@ -550,9 +550,9 @@ secondary_entities:
range:
min: 0
max: 60
- entity: number
- entity: sensor
name: Time left 2 # doesn't seem to get populated with manual watering
icon: "mdi:timer"
class: duration
category: diagnostic
dps:
- id: 156
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,7 @@ secondary_entities:
type: boolean
name: switch
- entity: select
name: timer
icon: "mdi:timer"
translation_key: timer
category: config
dps:
- id: 22
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ secondary_entities:
name: Remaining time
category: diagnostic
class: duration
icon: "mdi:timer"
dps:
- id: 106
type: integer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ secondary_entities:
name: switch
- entity: select
name: Boost
icon: "mdi:timer-outline"
translation_key: timer
dps:
- id: 19
type: string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ secondary_entities:
- entity: sensor
name: Time Remaining
class: duration
icon: "mdi:timer"
category: diagnostic
dps:
- id: 12
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tuya_local/devices/ledkia_fan_light.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ secondary_entities:
- scale: 10
- entity: number
name: Fan timer
icon: "mdi:timer"
translation_key: timer
category: config
dps:
- id: 64
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ secondary_entities:
- entity: number
category: config
name: USB timer
icon: "mdi:timer"
translation_key: timer
dps:
- id: 13
name: value
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tuya_local/devices/loratap_relay.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ primary_entity:
secondary_entities:
- entity: number
name: Countdown
icon: "mdi:timer"
translation_key: timer
category: config
dps:
- id: 9
Expand Down
2 changes: 1 addition & 1 deletion custom_components/tuya_local/devices/m027_curtain.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ secondary_entities:
value: Night
- entity: sensor
name: Time remaining
icon: "mdi:timer"
class: duration
category: diagnostic
dps:
- id: 9
Expand Down
Loading

0 comments on commit 56134d3

Please sign in to comment.