From e973b8bbc3da97b822f60e443f5181c98a01077b Mon Sep 17 00:00:00 2001 From: Nerdix <70015952+N3rdix@users.noreply.github.com> Date: Wed, 18 Sep 2024 07:58:43 +0200 Subject: [PATCH 1/5] Add hint for firmware version --- src/devices/sonoff.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/devices/sonoff.ts b/src/devices/sonoff.ts index 440359302e6c1..fe469f108aff9 100644 --- a/src/devices/sonoff.ts +++ b/src/devices/sonoff.ts @@ -1152,7 +1152,9 @@ const definitions: DefinitionWithExtend[] = [ name: 'auto_close_when_water_shortage', cluster: 'customClusterEwelink', attribute: 'lackWaterCloseValveTimeout', - description: 'Automatically shut down the water valve after the water shortage exceeds 30 minutes.', + description: + 'Automatically shut down the water valve after the water shortage exceeds 30 minutes. ' + + 'This feature requires firmware version 1.0.4 or later!', valueOff: ['DISABLE', 0], valueOn: ['ENABLE', 30], }), From b37a94df79af37135bfcb7fb18313ab64e57d399 Mon Sep 17 00:00:00 2001 From: Nerdix <70015952+N3rdix@users.noreply.github.com> Date: Wed, 18 Sep 2024 08:17:44 +0200 Subject: [PATCH 2/5] move hint to the top --- src/devices/sonoff.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/devices/sonoff.ts b/src/devices/sonoff.ts index fe469f108aff9..6629408af7106 100644 --- a/src/devices/sonoff.ts +++ b/src/devices/sonoff.ts @@ -1153,8 +1153,8 @@ const definitions: DefinitionWithExtend[] = [ cluster: 'customClusterEwelink', attribute: 'lackWaterCloseValveTimeout', description: - 'Automatically shut down the water valve after the water shortage exceeds 30 minutes. ' + - 'This feature requires firmware version 1.0.4 or later!', + 'This feature requires firmware version 1.0.4 or later! ' + + 'Automatically shut down the water valve after the water shortage exceeds 30 minutes. ', valueOff: ['DISABLE', 0], valueOn: ['ENABLE', 30], }), From 2244eb02bb7fb0a2aa54969ced6adcc37fd47dcd Mon Sep 17 00:00:00 2001 From: Nerdix <70015952+N3rdix@users.noreply.github.com> Date: Wed, 18 Sep 2024 08:32:03 +0200 Subject: [PATCH 3/5] Aligned with other hints from other devices -> at the end --- src/devices/sonoff.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/devices/sonoff.ts b/src/devices/sonoff.ts index 6629408af7106..24f550501549c 100644 --- a/src/devices/sonoff.ts +++ b/src/devices/sonoff.ts @@ -1152,9 +1152,7 @@ const definitions: DefinitionWithExtend[] = [ name: 'auto_close_when_water_shortage', cluster: 'customClusterEwelink', attribute: 'lackWaterCloseValveTimeout', - description: - 'This feature requires firmware version 1.0.4 or later! ' + - 'Automatically shut down the water valve after the water shortage exceeds 30 minutes. ', + description: 'Automatically shut down the water valve after the water shortage exceeds 30 minutes. Requires firmware version 1.0.4 or later! ', valueOff: ['DISABLE', 0], valueOn: ['ENABLE', 30], }), From 8da9991a7e38e7b3af6f8a569ce32aed22da77ea Mon Sep 17 00:00:00 2001 From: Nerdix <70015952+N3rdix@users.noreply.github.com> Date: Wed, 18 Sep 2024 09:16:25 +0200 Subject: [PATCH 4/5] fix prettier error --- src/devices/sonoff.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/devices/sonoff.ts b/src/devices/sonoff.ts index 24f550501549c..8909191750a75 100644 --- a/src/devices/sonoff.ts +++ b/src/devices/sonoff.ts @@ -1152,7 +1152,8 @@ const definitions: DefinitionWithExtend[] = [ name: 'auto_close_when_water_shortage', cluster: 'customClusterEwelink', attribute: 'lackWaterCloseValveTimeout', - description: 'Automatically shut down the water valve after the water shortage exceeds 30 minutes. Requires firmware version 1.0.4 or later! ', + description: + 'Automatically shut down the water valve after the water shortage exceeds 30 minutes. Requires firmware version 1.0.4 or later!', valueOff: ['DISABLE', 0], valueOn: ['ENABLE', 30], }), From 0d414811d36999c73b3f5c7954a696dd0d06a162 Mon Sep 17 00:00:00 2001 From: Nerdix <70015952+N3rdix@users.noreply.github.com> Date: Wed, 18 Sep 2024 09:53:47 +0200 Subject: [PATCH 5/5] again prettier --- src/devices/sonoff.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/devices/sonoff.ts b/src/devices/sonoff.ts index 8909191750a75..ad6b2ea80146e 100644 --- a/src/devices/sonoff.ts +++ b/src/devices/sonoff.ts @@ -1152,7 +1152,7 @@ const definitions: DefinitionWithExtend[] = [ name: 'auto_close_when_water_shortage', cluster: 'customClusterEwelink', attribute: 'lackWaterCloseValveTimeout', - description: + description: 'Automatically shut down the water valve after the water shortage exceeds 30 minutes. Requires firmware version 1.0.4 or later!', valueOff: ['DISABLE', 0], valueOn: ['ENABLE', 30],