mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-25 18:26:35 +00:00
Improve toggle button for disabled combo boxes (#24843)
This commit is contained in:
parent
4fbc155f8b
commit
8429d114a8
@ -207,6 +207,7 @@ export class HaComboBox extends LitElement {
|
|||||||
aria-expanded=${this.opened ? "true" : "false"}
|
aria-expanded=${this.opened ? "true" : "false"}
|
||||||
class="toggle-button"
|
class="toggle-button"
|
||||||
.path=${this.opened ? mdiMenuUp : mdiMenuDown}
|
.path=${this.opened ? mdiMenuUp : mdiMenuDown}
|
||||||
|
?disabled=${this.disabled}
|
||||||
@click=${this._toggleOpen}
|
@click=${this._toggleOpen}
|
||||||
></ha-svg-icon>
|
></ha-svg-icon>
|
||||||
</vaadin-combo-box-light>
|
</vaadin-combo-box-light>
|
||||||
@ -359,6 +360,10 @@ export class HaComboBox extends LitElement {
|
|||||||
:host([opened]) .toggle-button {
|
:host([opened]) .toggle-button {
|
||||||
color: var(--primary-color);
|
color: var(--primary-color);
|
||||||
}
|
}
|
||||||
|
.toggle-button[disabled] {
|
||||||
|
color: var(--disabled-text-color);
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
.clear-button {
|
.clear-button {
|
||||||
--mdc-icon-size: 20px;
|
--mdc-icon-size: 20px;
|
||||||
top: -7px;
|
top: -7px;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user