Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

don't round update entity images #17972

Merged
merged 1 commit into from
Sep 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion src/components/entity/state-badge.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,11 +131,15 @@ export class StateBadge extends LitElement {
if (this.hass) {
imageUrl = this.hass.hassUrl(imageUrl);
}
if (computeDomain(stateObj.entity_id) === "camera") {
const domain = computeDomain(stateObj.entity_id);
if (domain === "camera") {
imageUrl = cameraUrlWithWidthHeight(imageUrl, 80, 80);
}
hostStyle.backgroundImage = `url(${imageUrl})`;
this._showIcon = false;
if (domain === "update") {
hostStyle.borderRadius = "0";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, need to replace this with this.style.borderRadius for #17840

}
} else if (this.color) {
// Externally provided overriding color wins over state color
iconStyle.color = this.color;
Expand Down
5 changes: 4 additions & 1 deletion src/panels/config/dashboard/ha-config-updates.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ class HaConfigUpdates extends SubscribeMixin(LitElement) {
return html`
<ha-list-item
twoline
graphic="avatar"
graphic="medium"
class=${entity.attributes.skipped_version ? "skipped" : ""}
.entity_id=${entity.entity_id}
.hasMeta=${!this.narrow}
Expand Down Expand Up @@ -156,6 +156,9 @@ class HaConfigUpdates extends SubscribeMixin(LitElement) {
.skipped {
background: var(--secondary-background-color);
}
ha-list-item {
--mdc-list-item-graphic-size: 40px;
}
ha-icon-next {
color: var(--secondary-text-color);
height: 24px;
Expand Down
Loading