mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-28 11:46:42 +00:00
Fix layout of domain toggler dialog (#6771)
This commit is contained in:
parent
8e506f7749
commit
57763ef032
@ -10,8 +10,8 @@ import {
|
|||||||
} from "lit-element";
|
} from "lit-element";
|
||||||
import { fireEvent } from "../../common/dom/fire_event";
|
import { fireEvent } from "../../common/dom/fire_event";
|
||||||
import { createCloseHeading } from "../../components/ha-dialog";
|
import { createCloseHeading } from "../../components/ha-dialog";
|
||||||
import "../../components/ha-switch";
|
|
||||||
import "../../components/ha-formfield";
|
import "../../components/ha-formfield";
|
||||||
|
import "../../components/ha-switch";
|
||||||
import { domainToName } from "../../data/integration";
|
import { domainToName } from "../../data/integration";
|
||||||
import { haStyleDialog } from "../../resources/styles";
|
import { haStyleDialog } from "../../resources/styles";
|
||||||
import { HomeAssistant } from "../../types";
|
import { HomeAssistant } from "../../types";
|
||||||
@ -59,16 +59,18 @@ class DomainTogglerDialog extends LitElement implements HassDialog {
|
|||||||
(domain) =>
|
(domain) =>
|
||||||
html`
|
html`
|
||||||
<ha-formfield .label=${domain[0]}>
|
<ha-formfield .label=${domain[0]}>
|
||||||
<ha-switch
|
<ha-switch
|
||||||
.domain=${domain[1]}
|
.domain=${domain[1]}
|
||||||
.checked=${!this._params!.exposedDomains ||
|
.checked=${!this._params!.exposedDomains ||
|
||||||
this._params!.exposedDomains.includes(domain[1])}
|
this._params!.exposedDomains.includes(domain[1])}
|
||||||
@change=${this._handleSwitch}
|
@change=${this._handleSwitch}
|
||||||
>
|
>
|
||||||
</ha-switch>
|
</ha-switch>
|
||||||
</ha-formfield>
|
</ha-formfield>
|
||||||
<mwc-button .domain=${domain[1]} @click=${this._handleReset}>
|
<mwc-button .domain=${domain[1]} @click=${this._handleReset}>
|
||||||
${this.hass.localize("ui.dialogs.domain_toggler.reset_entities")}
|
${this.hass.localize(
|
||||||
|
"ui.dialogs.domain_toggler.reset_entities"
|
||||||
|
)}
|
||||||
</mwc-button>
|
</mwc-button>
|
||||||
`
|
`
|
||||||
)}
|
)}
|
||||||
@ -96,7 +98,8 @@ class DomainTogglerDialog extends LitElement implements HassDialog {
|
|||||||
}
|
}
|
||||||
div {
|
div {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: auto auto auto;
|
grid-template-columns: auto auto;
|
||||||
|
grid-row-gap: 8px;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
`,
|
`,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user