Skip to content

Commit

Permalink
20240329.1 (#20280)
Browse files Browse the repository at this point in the history
  • Loading branch information
piitaya committed Mar 29, 2024
2 parents d24d29e + 85f80ff commit fd06d43
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "home-assistant-frontend"
version = "20240329.0"
version = "20240329.1"
license = {text = "Apache-2.0"}
description = "The Home Assistant frontend"
readme = "README.md"
Expand Down
11 changes: 7 additions & 4 deletions src/panels/lovelace/cards/hui-stack-card.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ export abstract class HuiStackCard<T extends StackCardConfig = StackCardConfig>

@state() protected _config?: T;

@property({ type: Boolean, reflect: true })
public isPanel = false;

public getCardSize(): number | Promise<number> {
return 1;
}
Expand Down Expand Up @@ -98,10 +101,10 @@ export abstract class HuiStackCard<T extends StackCardConfig = StackCardConfig>
display: block;
padding: 24px 16px 16px;
}
#root {
--ha-card-border-radius: var(--restore-card-border-radius, inherit);
--ha-card-border-width: var(--restore-card-border-width, inherit);
--ha-card-box-shadow: var(--restore-card-border-shadow, inherit);
:host([ispanel]) #root {
--ha-card-border-radius: var(--restore-card-border-radius);
--ha-card-border-width: var(--restore-card-border-width);
--ha-card-box-shadow: var(--restore-card-border-shadow);
}
`;
}
Expand Down
4 changes: 1 addition & 3 deletions src/panels/lovelace/views/hui-panel-view.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ export class PanelView extends LitElement implements LovelaceViewElement {

const card: LovelaceCard = this.cards[0];
card.isPanel = true;
card.toggleAttribute("no-border", true);

if (this.isStrategy || !this.lovelace?.editMode) {
card.editMode = false;
Expand All @@ -117,7 +116,6 @@ export class PanelView extends LitElement implements LovelaceViewElement {
}

const wrapper = document.createElement("hui-card-options");
wrapper.toggleAttribute("no-border", true);
wrapper.hass = this.hass;
wrapper.lovelace = this.lovelace;
wrapper.path = [this.index!, 0];
Expand All @@ -137,7 +135,7 @@ export class PanelView extends LitElement implements LovelaceViewElement {
--restore-card-box-shadow: var(--ha-card-box-shadow, none);
}
[no-border] {
* {
--ha-card-border-radius: 0;
--ha-card-border-width: 0;
--ha-card-box-shadow: none;
Expand Down

0 comments on commit fd06d43

Please sign in to comment.