diff --git a/src/components/ha-selector/ha-selector-object.ts b/src/components/ha-selector/ha-selector-object.ts index 3d2bad4c09..42bc771de7 100644 --- a/src/components/ha-selector/ha-selector-object.ts +++ b/src/components/ha-selector/ha-selector-object.ts @@ -1,9 +1,10 @@ -import { html, LitElement } from "lit"; -import { customElement, property } from "lit/decorators"; +import { html, LitElement, PropertyValues } from "lit"; +import { customElement, property, query } from "lit/decorators"; import { fireEvent } from "../../common/dom/fire_event"; import { HomeAssistant } from "../../types"; import "../ha-yaml-editor"; import "../ha-input-helper-text"; +import type { HaYamlEditor } from "../ha-yaml-editor"; @customElement("ha-selector-object") export class HaObjectSelector extends LitElement { @@ -21,6 +22,10 @@ export class HaObjectSelector extends LitElement { @property({ type: Boolean }) public required = true; + @query("ha-yaml-editor", true) private _yamlEditor!: HaYamlEditor; + + private _valueChangedFromChild = false; + protected render() { return html`