Skip to content

Commit

Permalink
Fix visibility
Browse files Browse the repository at this point in the history
  • Loading branch information
piitaya committed Jul 17, 2024
1 parent 7b68cbf commit 8ab9b63
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/panels/lovelace/badges/hui-badge.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ declare global {

@customElement("hui-badge")
export class HuiBadge extends ReactiveElement {
@property({ attribute: false }) public preview = false;
@property({ type: Boolean }) public preview = false;

@property({ attribute: false }) public config?: LovelaceBadgeConfig;

Expand Down
3 changes: 3 additions & 0 deletions src/panels/lovelace/views/hui-view.ts
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,9 @@ export class HUIView extends ReactiveElement {
this._cards.forEach((element) => {
element.preview = this.lovelace.editMode;
});
this._badges.forEach((element) => {
element.preview = this.lovelace.editMode;
});
}
if (changedProperties.has("_cards")) {
this._layoutElement.cards = this._cards;
Expand Down

0 comments on commit 8ab9b63

Please sign in to comment.