mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-25 18:26: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) {
|
||||
return `When triggered by ${condition.id}`;
|
||||
if (condition.condition === "trigger" && condition.id != null) {
|
||||
return hass.localize(
|
||||
`${conditionsTranslationBaseKey}.trigger.description.full`,
|
||||
{
|
||||
id: formatListWithOrs(
|
||||
hass.locale,
|
||||
ensureArray(condition.id).map((id) => id.toString())
|
||||
),
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
return (
|
||||
|
@ -2689,7 +2689,10 @@
|
||||
"trigger": {
|
||||
"label": "Triggered by",
|
||||
"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": {
|
||||
"label": "[%key:ui::panel::config::automation::editor::triggers::type::zone::label%]",
|
||||
|
Loading…
x
Reference in New Issue
Block a user