Skip to content

Commit

Permalink
Fix entities sort for hidden/readonly
Browse files Browse the repository at this point in the history
  • Loading branch information
karwosts committed Dec 22, 2023
1 parent 09dcc29 commit 621918e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
10 changes: 8 additions & 2 deletions src/panels/config/entities/ha-config-entities.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export interface EntityRow extends StateEntity {
entity?: HassEntity;
unavailable: boolean;
restored: boolean;
status: string;
status: string | undefined;
area?: string;
localized_platform: string;
}
Expand Down Expand Up @@ -429,7 +429,13 @@ export class HaConfigEntities extends LitElement {
? localize("ui.panel.config.entities.picker.status.unavailable")
: entry.disabled_by
? localize("ui.panel.config.entities.picker.status.disabled")
: localize("ui.panel.config.entities.picker.status.ok"),
: entry.hidden_by
? localize("ui.panel.config.entities.picker.status.hidden")
: entry.readonly
? localize(
"ui.panel.config.entities.picker.status.readonly"
)
: undefined,
});
}

Expand Down
3 changes: 1 addition & 2 deletions src/translations/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -3607,8 +3607,7 @@
"unavailable": "Unavailable",
"disabled": "Disabled",
"readonly": "Read-only",
"hidden": "Hidden",
"ok": "Ok"
"hidden": "Hidden"
},
"headers": {
"state_icon": "State icon",
Expand Down

0 comments on commit 621918e

Please sign in to comment.