mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-19 07:16:39 +00:00
Fix disable ha-progress button (#22939)
* Fix disable ha-progress button * Simplify ha-progress disabled fix * Fix ha-progress-button click handler * fix ha-progress-button pointer-events
This commit is contained in:
parent
6b0afe6ebb
commit
43911ef3be
@ -22,7 +22,6 @@ export class HaProgressButton extends LitElement {
|
||||
<mwc-button
|
||||
?raised=${this.raised}
|
||||
.disabled=${this.disabled || this.progress}
|
||||
@click=${this._buttonTapped}
|
||||
class=${this._result || ""}
|
||||
>
|
||||
<slot></slot>
|
||||
@ -63,22 +62,18 @@ export class HaProgressButton extends LitElement {
|
||||
}, 2000);
|
||||
}
|
||||
|
||||
private _buttonTapped(ev: Event): void {
|
||||
if (this.progress) {
|
||||
ev.stopPropagation();
|
||||
}
|
||||
}
|
||||
|
||||
static get styles(): CSSResultGroup {
|
||||
return css`
|
||||
:host {
|
||||
outline: none;
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
mwc-button {
|
||||
transition: all 1s;
|
||||
pointer-events: initial;
|
||||
}
|
||||
|
||||
mwc-button.success {
|
||||
|
Loading…
x
Reference in New Issue
Block a user