Compare commits

...

4 Commits

Author SHA1 Message Date
Thomas Lovén
6c59a42dda More lint. Sure hope this gets squashed... 2024-02-08 09:35:43 +01:00
Thomas Lovén
edd9cb769d Lint 2024-02-08 09:31:03 +01:00
Thomas Lovén
c567f20074 Quote 2024-02-08 09:26:42 +01:00
Thomas Lovén
21b171245a Use fixed colors for qr codes 2024-02-08 09:18:41 +01:00

View File

@@ -64,8 +64,6 @@ export class HaQrCode extends LitElement {
changedProperties.has("errorCorrectionLevel") ||
changedProperties.has("centerImage"))
) {
const computedStyles = getComputedStyle(this);
QRCode.toCanvas(canvas, this.data, {
errorCorrectionLevel:
this.errorCorrectionLevel || (this.centerImage ? "Q" : "M"),
@@ -74,8 +72,7 @@ export class HaQrCode extends LitElement {
margin: this.margin,
maskPattern: this.maskPattern,
color: {
light: computedStyles.getPropertyValue("--card-background-color"),
dark: computedStyles.getPropertyValue("--primary-text-color"),
light: "#fff",
},
}).catch((err) => {
this._error = err.message;