MMM-WiFiPassword
MMM-WiFiPassword copied to clipboard
Display or not the QR code
Hello, One feature that I would find interesting is the ability to display or not the QR code. I tried so and it works fine:
In MMM-WiFiPassword.js:
- Add the variable: 'showQR: true'
- Modification of the following code:
if (this.config.showQR) {
var qrDiv = document.createElement("div");
qrDiv.id = "qrdiv";
qrDiv.className = "qr-image";
qrDiv.style = "width:" + this.config.qrSize + "px; background-color:" + this.config.colorLight;
if (this.config.layoutVertical) {
qrDiv.className += " layout-vertical";
} else {
qrDiv.className += " layout-horizontal";
}
div.appendChild(qrDiv);
}
So we only keep the text, which is sometimes enough.
FR / EN translation by Google, sorry.
The variable qrDiv is a fundamental piece of this module. It is used in multiple places throughout the code. What you requested is certainly doable, but will require more testing with the rest of the module before implementing.
Have you tried the change you proposed yourself?
Hello,
I made this change in the module on my MagicMirror and everything works impeccably, the QR is not displayed or nothing instead.
But I don't use MMM-MODAL and WIFIPASSWORD_MODAL so I don't know the impact of this change on that.
do have the same problem, have no QR-Code generated and thus not shown up.
Any Idea, I could try?