Fix attribute-prop mapping (#2794)

This commit is contained in:
Paulus Schoutsen 2019-02-19 09:09:07 -08:00 committed by GitHub
parent 32d0e8bf1d
commit 12064a086b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 5 deletions

View File

@ -22,9 +22,10 @@ import { HassEntity } from "home-assistant-js-websocket";
class HaEntitiesPickerLight extends LitElement {
@property() public hass?: HomeAssistant;
@property() public value?: string[];
@property() public domainFilter?: string;
@property() public pickedEntityLabel?: string;
@property() public pickEntityLabel?: string;
@property({ attribute: "domain-filter" }) public domainFilter?: string;
@property({ attribute: "picked-entity-label" })
public pickedEntityLabel?: string;
@property({ attribute: "pick-entity-label" }) public pickEntityLabel?: string;
protected render(): TemplateResult | void {
if (!this.hass) {

View File

@ -55,11 +55,12 @@ const rowRenderer = (
class HaEntityPicker extends LitElement {
@property({ type: Boolean }) public autofocus?: boolean;
@property({ type: Boolean }) public disabled?: boolean;
@property({ type: Boolean }) public allowCustomEntity;
@property({ type: Boolean, attribute: "allow-custom-entity" })
public allowCustomEntity;
@property() public hass?: HomeAssistant;
@property() public label?: string;
@property() public value?: string;
@property() public domainFilter?: string;
@property({ attribute: "domain-filter" }) public domainFilter?: string;
@property() public entityFilter?: HaEntityPickerEntityFilterFunc;
@property({ type: Boolean }) private _opened?: boolean;
@property() private _hass?: HomeAssistant;