mirror of
https://github.com/home-assistant/frontend.git
synced 2025-11-15 05:50:24 +00:00
Add compatibility for Lit 2.0 (#8878)
This commit is contained in:
@@ -4,9 +4,9 @@ import "@polymer/paper-item/paper-item-body";
|
||||
import "@polymer/paper-listbox/paper-listbox";
|
||||
import {
|
||||
css,
|
||||
CSSResult,
|
||||
CSSResultGroup,
|
||||
html,
|
||||
internalProperty,
|
||||
state,
|
||||
LitElement,
|
||||
property,
|
||||
TemplateResult,
|
||||
@@ -33,11 +33,11 @@ export abstract class HaDeviceAutomationPicker<
|
||||
|
||||
@property() public value?: T;
|
||||
|
||||
@internalProperty() private _automations: T[] = [];
|
||||
@state() private _automations: T[] = [];
|
||||
|
||||
// Trigger an empty render so we start with a clean DOM.
|
||||
// paper-listbox does not like changing things around.
|
||||
@internalProperty() private _renderEmpty = false;
|
||||
@state() private _renderEmpty = false;
|
||||
|
||||
protected get NO_AUTOMATION_TEXT() {
|
||||
return this.hass.localize(
|
||||
@@ -188,7 +188,7 @@ export abstract class HaDeviceAutomationPicker<
|
||||
fireEvent(this, "value-changed", { value: automation });
|
||||
}
|
||||
|
||||
static get styles(): CSSResult {
|
||||
static get styles(): CSSResultGroup {
|
||||
return css`
|
||||
ha-paper-dropdown-menu {
|
||||
width: 100%;
|
||||
|
||||
Reference in New Issue
Block a user