mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
Improve category map for air quality and pollen sensors in AccuWeather (#140193)
* Fix typo * Improve category map for air quality and pollen * Update test snapshot
This commit is contained in:
parent
e8069e1c07
commit
8a67e89e91
@ -59,13 +59,14 @@ AIR_QUALITY_CATEGORY_MAP = {
|
||||
1: "good",
|
||||
2: "moderate",
|
||||
3: "unhealthy",
|
||||
4: "hazardous",
|
||||
4: "very_unhealthy",
|
||||
5: "hazardous",
|
||||
}
|
||||
POLLEN_CATEGORY_MAP = {
|
||||
1: "low",
|
||||
2: "moderate",
|
||||
3: "high",
|
||||
4: "very high",
|
||||
4: "very_high",
|
||||
}
|
||||
UPDATE_INTERVAL_OBSERVATION = timedelta(minutes=40)
|
||||
UPDATE_INTERVAL_DAILY_FORECAST = timedelta(hours=6)
|
||||
|
@ -27,7 +27,8 @@
|
||||
"good": "Good",
|
||||
"hazardous": "Hazardous",
|
||||
"moderate": "Moderate",
|
||||
"unhealthy": "Unhealthy"
|
||||
"unhealthy": "Unhealthy",
|
||||
"very_unhealthy": "Very unhealthy"
|
||||
},
|
||||
"state_attributes": {
|
||||
"options": {
|
||||
@ -35,7 +36,8 @@
|
||||
"good": "[%key:component::accuweather::entity::sensor::air_quality::state::good%]",
|
||||
"hazardous": "[%key:component::accuweather::entity::sensor::air_quality::state::hazardous%]",
|
||||
"moderate": "[%key:component::accuweather::entity::sensor::air_quality::state::moderate%]",
|
||||
"unhealthy": "[%key:component::accuweather::entity::sensor::air_quality::state::unhealthy%]"
|
||||
"unhealthy": "[%key:component::accuweather::entity::sensor::air_quality::state::unhealthy%]",
|
||||
"very_unhealthy": "[%key:component::accuweather::entity::sensor::air_quality::state::very_unhealthy%]"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -9,6 +9,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
@ -50,6 +51,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
@ -71,6 +73,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
@ -112,6 +115,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
@ -133,6 +137,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
@ -174,6 +179,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
@ -195,6 +201,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
@ -236,6 +243,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
@ -257,6 +265,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
@ -298,6 +307,7 @@
|
||||
'good',
|
||||
'moderate',
|
||||
'unhealthy',
|
||||
'very_unhealthy',
|
||||
'hazardous',
|
||||
]),
|
||||
}),
|
||||
|
Loading…
x
Reference in New Issue
Block a user