Add and fix stylistic eslint rules (#23735)

* Fix stylistic eslint rules

* Fix eslint issues
This commit is contained in:
Wendelin
2025-01-14 21:00:14 +01:00
committed by GitHub
parent 69a93ddb6e
commit e703750136
582 changed files with 12485 additions and 13451 deletions

View File

@@ -1,6 +1,6 @@
import "@material/mwc-button";
import { mdiAlertOctagram, mdiCheckBold } from "@mdi/js";
import type { CSSResultGroup, TemplateResult } from "lit";
import type { TemplateResult } from "lit";
import { css, html, LitElement, nothing } from "lit";
import { customElement, property, state } from "lit/decorators";
import "../ha-circular-progress";
@@ -62,64 +62,62 @@ export class HaProgressButton extends LitElement {
}, 2000);
}
static get styles(): CSSResultGroup {
return css`
:host {
outline: none;
display: inline-block;
position: relative;
pointer-events: none;
}
static styles = css`
:host {
outline: none;
display: inline-block;
position: relative;
pointer-events: none;
}
mwc-button {
transition: all 1s;
pointer-events: initial;
}
mwc-button {
transition: all 1s;
pointer-events: initial;
}
mwc-button.success {
--mdc-theme-primary: white;
background-color: var(--success-color);
transition: none;
border-radius: 4px;
pointer-events: none;
}
mwc-button.success {
--mdc-theme-primary: white;
background-color: var(--success-color);
transition: none;
border-radius: 4px;
pointer-events: none;
}
mwc-button[raised].success {
--mdc-theme-primary: var(--success-color);
--mdc-theme-on-primary: white;
}
mwc-button[raised].success {
--mdc-theme-primary: var(--success-color);
--mdc-theme-on-primary: white;
}
mwc-button.error {
--mdc-theme-primary: white;
background-color: var(--error-color);
transition: none;
border-radius: 4px;
pointer-events: none;
}
mwc-button.error {
--mdc-theme-primary: white;
background-color: var(--error-color);
transition: none;
border-radius: 4px;
pointer-events: none;
}
mwc-button[raised].error {
--mdc-theme-primary: var(--error-color);
--mdc-theme-on-primary: white;
}
mwc-button[raised].error {
--mdc-theme-primary: var(--error-color);
--mdc-theme-on-primary: white;
}
.progress {
bottom: 4px;
position: absolute;
text-align: center;
top: 4px;
width: 100%;
}
.progress {
bottom: 4px;
position: absolute;
text-align: center;
top: 4px;
width: 100%;
}
ha-svg-icon {
color: white;
}
ha-svg-icon {
color: white;
}
mwc-button.success slot,
mwc-button.error slot {
visibility: hidden;
}
`;
}
mwc-button.success slot,
mwc-button.error slot {
visibility: hidden;
}
`;
}
declare global {