mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-25 18:26:35 +00:00
Fix guiMode toggle bugs in element-editor (#17282)
This commit is contained in:
parent
38ea25cf5a
commit
11fa9d1ed8
@ -131,6 +131,7 @@ export abstract class HuiElementEditor<T, C = any> extends LitElement {
|
||||
}
|
||||
}
|
||||
|
||||
this.updateComplete.then(() => {
|
||||
fireEvent(this, "config-changed", {
|
||||
config: this.value! as any,
|
||||
error: this._errors?.join(", "),
|
||||
@ -140,6 +141,7 @@ export abstract class HuiElementEditor<T, C = any> extends LitElement {
|
||||
this._guiSupported === false
|
||||
),
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
public get hasWarning(): boolean {
|
||||
@ -156,6 +158,7 @@ export abstract class HuiElementEditor<T, C = any> extends LitElement {
|
||||
|
||||
public set GUImode(guiMode: boolean) {
|
||||
this._guiMode = guiMode;
|
||||
this.updateComplete.then(() => {
|
||||
fireEvent(this as HTMLElement, "GUImode-changed", {
|
||||
guiMode,
|
||||
guiModeAvailable: !(
|
||||
@ -164,6 +167,7 @@ export abstract class HuiElementEditor<T, C = any> extends LitElement {
|
||||
this._guiSupported === false
|
||||
),
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
public toggleMode() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user