diff --git a/src/components/ha-card.ts b/src/components/ha-card.ts index c37687190d..97ed27a7d7 100644 --- a/src/components/ha-card.ts +++ b/src/components/ha-card.ts @@ -12,6 +12,8 @@ import { class HaCard extends LitElement { @property() public header?: string; + @property({ type: Boolean, reflect: true }) public outlined = false; + static get styles(): CSSResult { return css` :host { @@ -19,12 +21,12 @@ class HaCard extends LitElement { --ha-card-background, var(--paper-card-background-color, white) ); - border-radius: var(--ha-card-border-radius, 2px); + border-radius: var(--ha-card-border-radius, 4px); box-shadow: var( --ha-card-box-shadow, - 0 2px 2px 0 rgba(0, 0, 0, 0.14), - 0 1px 5px 0 rgba(0, 0, 0, 0.12), - 0 3px 1px -2px rgba(0, 0, 0, 0.2) + 0px 2px 1px -1px rgba(0, 0, 0, 0.2), + 0px 1px 1px 0px rgba(0, 0, 0, 0.14), + 0px 1px 3px 0px rgba(0, 0, 0, 0.12) ); color: var(--primary-text-color); display: block; @@ -32,6 +34,16 @@ class HaCard extends LitElement { position: relative; } + :host([outlined]) { + box-shadow: 0 0 0 0; + border-width: 1px; + border-style: solid; + border-color: var( + --ha-card-border-color, + var(--divider-color, #e0e0e0) + ); + } + .card-header, :host ::slotted(.card-header) { color: var(--ha-card-header-color, --primary-text-color); diff --git a/src/panels/config/integrations/ha-config-integrations.ts b/src/panels/config/integrations/ha-config-integrations.ts index 6838af965c..ee6a60ddf1 100644 --- a/src/panels/config/integrations/ha-config-integrations.ts +++ b/src/panels/config/integrations/ha-config-integrations.ts @@ -299,7 +299,7 @@ class HaConfigIntegrations extends SubscribeMixin(LitElement) { ${this._showIgnored ? ignoredConfigEntries.map( (item: ConfigEntryExtended) => html` - +
${this.hass.localize( "ui.panel.config.integrations.ignore.ignored" @@ -335,7 +335,7 @@ class HaConfigIntegrations extends SubscribeMixin(LitElement) { ${configEntriesInProgress.length ? configEntriesInProgress.map( (flow: DataEntryFlowProgressExtended) => html` - +
${this.hass.localize( "ui.panel.config.integrations.discovered" @@ -396,7 +396,7 @@ class HaConfigIntegrations extends SubscribeMixin(LitElement) { ) : !this._configEntries.length ? html` - +

${this.hass.localize("ui.panel.config.integrations.none")} @@ -613,7 +613,7 @@ class HaConfigIntegrations extends SubscribeMixin(LitElement) { justify-content: space-between; } .discovered { - border: 1px solid var(--primary-color); + --ha-card-border-color: var(--primary-color); } .discovered .header { background: var(--primary-color); @@ -622,7 +622,7 @@ class HaConfigIntegrations extends SubscribeMixin(LitElement) { text-align: center; } .ignored { - border: 1px solid var(--light-theme-disabled-color); + --ha-card-border-color: var(--light-theme-disabled-color); } .ignored img { filter: grayscale(1); diff --git a/src/panels/config/integrations/ha-integration-card.ts b/src/panels/config/integrations/ha-integration-card.ts index 8cb53bace6..a904ebc338 100644 --- a/src/panels/config/integrations/ha-integration-card.ts +++ b/src/panels/config/integrations/ha-integration-card.ts @@ -76,7 +76,7 @@ export class HaIntegrationCard extends LitElement { private _renderGroupedIntegration(): TemplateResult { return html` - +