Lint
This commit is contained in:
parent
5794bddb05
commit
3a663a272b
|
@ -66,7 +66,7 @@
|
|||
"curly": "error",
|
||||
"default-case": "off",
|
||||
"default-param-last": "error",
|
||||
"dot-location": "error",
|
||||
"dot-location": ["error", "property"],
|
||||
"dot-notation": "error",
|
||||
"eol-last": "error",
|
||||
"eqeqeq": "error",
|
||||
|
@ -88,7 +88,11 @@
|
|||
"id-length": "off",
|
||||
"id-match": "error",
|
||||
"implicit-arrow-linebreak": "error",
|
||||
"indent": "off",
|
||||
"indent": [
|
||||
"error", 4, {
|
||||
"SwitchCase": 1
|
||||
}
|
||||
],
|
||||
"indent-legacy": "off",
|
||||
"init-declarations": "off",
|
||||
"jsx-quotes": "error",
|
||||
|
|
17
alert.js
17
alert.js
|
@ -3,11 +3,18 @@
|
|||
(function (global) {
|
||||
"use strict";
|
||||
|
||||
var divAlert, divAlertInput, divAlertConfirm, divAlertButton, alertButtonOK,
|
||||
divAlertCallback, divAlertCallbackYes, divAlertCallbackNo, alertInput,
|
||||
divAlertContent;
|
||||
let divAlert;
|
||||
let divAlertInput;
|
||||
let divAlertConfirm;
|
||||
let divAlertButton;
|
||||
let alertButtonOK;
|
||||
let divAlertCallback;
|
||||
let divAlertCallbackYes;
|
||||
let divAlertCallbackNo;
|
||||
let alertInput;
|
||||
let divAlertContent;
|
||||
|
||||
var _ = (window.libD && libD.l10n) ? libD.l10n() : function (s) {return s;};
|
||||
const _ = (window.libD && libD.l10n) ? libD.l10n() : function (s) {return s;};
|
||||
|
||||
function promptOK() {
|
||||
divAlert.style.display = "none";
|
||||
|
@ -90,7 +97,7 @@
|
|||
alertButtonOK.textContent = _("OK");
|
||||
alertButtonOK.onclick = alertOK;
|
||||
|
||||
var divAlertOuter = document.createElement("div");
|
||||
const divAlertOuter = document.createElement("div");
|
||||
divAlertOuter.className = "alert-outer";
|
||||
divAlertOuter.appendChild(divAlertContent);
|
||||
divAlertOuter.appendChild(divAlertInput);
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
* @source: https://gitlab.com/raphj/trivabble/
|
||||
*/
|
||||
|
||||
/*eslint strict: [2, "global"]*/
|
||||
/*eslint strict: [2, "global"]*/
|
||||
|
||||
"use strict";
|
||||
|
||||
|
|
20
trivabble.js
20
trivabble.js
|
@ -1047,17 +1047,15 @@ let tile;
|
|||
myConfirm(
|
||||
_("Are you sure you want to put all your tiles back in the bag?"),
|
||||
function () {
|
||||
sendCmds(
|
||||
[
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 0, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 1, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 2, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 3, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 4, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 5, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 6, to: "bag", indexTo: -1}
|
||||
]
|
||||
);
|
||||
sendCmds([
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 0, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 1, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 2, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 3, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 4, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 5, to: "bag", indexTo: -1},
|
||||
{cmd: "moveLetter", from: "rack", indexFrom: 6, to: "bag", indexTo: -1}
|
||||
]);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue