Add icon translations to GPSd (#108602)
parent
a075accbe3
commit
421e276185
|
@ -0,0 +1,13 @@
|
|||
{
|
||||
"entity": {
|
||||
"sensor": {
|
||||
"mode": {
|
||||
"default": "mdi:crosshairs",
|
||||
"state": {
|
||||
"2d_fix": "mdi:crosshairs-gps",
|
||||
"3d_fix": "mdi:crosshairs-gps"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -144,12 +144,3 @@ class GpsdSensor(SensorEntity):
|
|||
ATTR_CLIMB: self.agps_thread.data_stream.climb,
|
||||
ATTR_MODE: self.agps_thread.data_stream.mode,
|
||||
}
|
||||
|
||||
@property
|
||||
def icon(self) -> str:
|
||||
"""Return the icon of the sensor."""
|
||||
mode = self.agps_thread.data_stream.mode
|
||||
|
||||
if isinstance(mode, int) and mode >= 2:
|
||||
return "mdi:crosshairs-gps"
|
||||
return "mdi:crosshairs"
|
||||
|
|
Loading…
Reference in New Issue