Use UnitOfElectricPotential in integrations (#84044)
This commit is contained in:
parent
d72c28a135
commit
0184aadb09
43 changed files with 141 additions and 143 deletions
|
@ -17,10 +17,10 @@ from homeassistant.components.sensor import (
|
|||
from homeassistant.config_entries import ConfigEntry
|
||||
from homeassistant.const import (
|
||||
ELECTRIC_CURRENT_AMPERE,
|
||||
ELECTRIC_POTENTIAL_VOLT,
|
||||
ENERGY_KILO_WATT_HOUR,
|
||||
PERCENTAGE,
|
||||
TEMP_CELSIUS,
|
||||
UnitOfElectricPotential,
|
||||
UnitOfFrequency,
|
||||
UnitOfPower,
|
||||
)
|
||||
|
@ -58,7 +58,7 @@ SENSOR_DESCRIPTIONS: dict[tuple[Units, bool], SensorEntityDescription] = {
|
|||
(Units.V, False): SensorEntityDescription(
|
||||
key=f"{Units.V}_{False}",
|
||||
device_class=SensorDeviceClass.VOLTAGE,
|
||||
native_unit_of_measurement=ELECTRIC_POTENTIAL_VOLT,
|
||||
native_unit_of_measurement=UnitOfElectricPotential.VOLT,
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
),
|
||||
(Units.A, False): SensorEntityDescription(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue