mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-27 11:16:35 +00:00
Localize trigger condition and add list formatting (#18488)
This commit is contained in:
parent
5f2375fe84
commit
cfa522068c
@ -1090,8 +1090,16 @@ const tryDescribeCondition = (
|
|||||||
}`;
|
}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (condition.condition === "trigger" && condition.id) {
|
if (condition.condition === "trigger" && condition.id != null) {
|
||||||
return `When triggered by ${condition.id}`;
|
return hass.localize(
|
||||||
|
`${conditionsTranslationBaseKey}.trigger.description.full`,
|
||||||
|
{
|
||||||
|
id: formatListWithOrs(
|
||||||
|
hass.locale,
|
||||||
|
ensureArray(condition.id).map((id) => id.toString())
|
||||||
|
),
|
||||||
|
}
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -2689,7 +2689,10 @@
|
|||||||
"trigger": {
|
"trigger": {
|
||||||
"label": "Triggered by",
|
"label": "Triggered by",
|
||||||
"no_triggers": "No triggers have an ID set. You can set an ID using the trigger menu button.",
|
"no_triggers": "No triggers have an ID set. You can set an ID using the trigger menu button.",
|
||||||
"id": "Trigger"
|
"id": "Trigger",
|
||||||
|
"description": {
|
||||||
|
"full": "When triggered by {id}"
|
||||||
|
}
|
||||||
},
|
},
|
||||||
"zone": {
|
"zone": {
|
||||||
"label": "[%key:ui::panel::config::automation::editor::triggers::type::zone::label%]",
|
"label": "[%key:ui::panel::config::automation::editor::triggers::type::zone::label%]",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user