mirror of
https://github.com/home-assistant/frontend.git
synced 2025-04-24 13:27:22 +00:00
Add HomeAssistant object hass to LovelaceCard interface (#1843)
This commit is contained in:
parent
ef0d11c042
commit
fbbbe7d17d
@ -26,7 +26,7 @@ interface Config extends LovelaceConfig {
|
||||
|
||||
class HuiEntityButtonCard extends HassLocalizeLitMixin(LitElement)
|
||||
implements LovelaceCard {
|
||||
protected hass?: HomeAssistant;
|
||||
public hass?: HomeAssistant;
|
||||
protected config?: Config;
|
||||
|
||||
static get properties(): PropertyDeclarations {
|
||||
|
@ -37,7 +37,7 @@ interface Config extends LovelaceConfig {
|
||||
|
||||
export class HuiGlanceCard extends HassLocalizeLitMixin(LitElement)
|
||||
implements LovelaceCard {
|
||||
protected hass?: HomeAssistant;
|
||||
public hass?: HomeAssistant;
|
||||
protected config?: Config;
|
||||
protected configEntities?: EntityConfig[];
|
||||
|
||||
|
@ -1,8 +1,11 @@
|
||||
import { HomeAssistant } from "../../types.js";
|
||||
|
||||
export interface LovelaceConfig {
|
||||
type: string;
|
||||
}
|
||||
|
||||
export interface LovelaceCard {
|
||||
export interface LovelaceCard extends HTMLElement {
|
||||
hass?: HomeAssistant;
|
||||
getCardSize(): number;
|
||||
setConfig(config: LovelaceConfig): void;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user