mirror of
https://github.com/adrianjagielak/home-assistant-futurehome.git
synced 2025-09-13 15:47:08 +00:00
Fix using the unit reported by the numerical sensor
This commit is contained in:
parent
850fc7fc57
commit
0d993643fb
@ -5,6 +5,7 @@
|
|||||||
- Added logo.
|
- Added logo.
|
||||||
- Added support for pairing new devices.
|
- Added support for pairing new devices.
|
||||||
- Added support for unpairing devices.
|
- Added support for unpairing devices.
|
||||||
|
- Fixed using the unit reported by the numerical sensor.
|
||||||
|
|
||||||
## 0.1.7 (26.07.2025)
|
## 0.1.7 (26.07.2025)
|
||||||
|
|
||||||
|
@ -74,7 +74,7 @@ export function _sensor_numeric__components(
|
|||||||
|
|
||||||
const device_class = data[0];
|
const device_class = data[0];
|
||||||
const name = data[1];
|
const name = data[1];
|
||||||
let unit = data[2];
|
let unit = svc.props?.sup_units?.[0] ?? data[2];
|
||||||
if (unit === 'C') unit = '°C';
|
if (unit === 'C') unit = '°C';
|
||||||
if (unit === 'F') unit = '°F';
|
if (unit === 'F') unit = '°F';
|
||||||
if (unit === 'kph') unit = 'km/h';
|
if (unit === 'kph') unit = 'km/h';
|
||||||
|
Loading…
x
Reference in New Issue
Block a user