Migrate base automation config to plurals (#22053)

* Migrate base automation config to plurals

* revert

* Update hat-script-graph.ts

* Make traces work with both new and old config

* Adjust validateConfig
This commit is contained in:
Bram Kragten
2024-09-24 20:03:53 +02:00
committed by GitHub
parent 1bbf45d35e
commit cbce6f633f
15 changed files with 99 additions and 45 deletions

View File

@@ -467,7 +467,7 @@ export class HaScriptEditor extends KeyboardShortcutMixin(LitElement) {
return;
}
const validation = await validateConfig(this.hass, {
action: this._config.sequence,
actions: this._config.sequence,
});
this._validationErrors = (
Object.entries(validation) as Entries<typeof validation>
@@ -475,7 +475,7 @@ export class HaScriptEditor extends KeyboardShortcutMixin(LitElement) {
value.valid
? ""
: html`${this.hass.localize(
`ui.panel.config.automation.editor.${key}s.name`
`ui.panel.config.automation.editor.${key}.name`
)}:
${value.error}<br />`
);