mirror of
https://github.com/ankitects/anki.git
synced 2025-09-19 14:32:22 -04:00
Set .prettierrc printWidth to 88 because the default is too short
This commit is contained in:
parent
683f664d85
commit
51ec5d0fa9
3 changed files with 4 additions and 8 deletions
|
@ -1,5 +1,6 @@
|
||||||
{
|
{
|
||||||
"trailingComma": "es5",
|
"trailingComma": "es5",
|
||||||
|
"printWidth": 88,
|
||||||
"tabWidth": 4,
|
"tabWidth": 4,
|
||||||
"semi": true
|
"semi": true
|
||||||
}
|
}
|
||||||
|
|
|
@ -274,10 +274,7 @@ function enableButtons() {
|
||||||
|
|
||||||
// disable the buttons if a field is not currently focused
|
// disable the buttons if a field is not currently focused
|
||||||
function maybeDisableButtons() {
|
function maybeDisableButtons() {
|
||||||
if (
|
if (!document.activeElement || document.activeElement.className !== "field") {
|
||||||
!document.activeElement ||
|
|
||||||
document.activeElement.className !== "field"
|
|
||||||
) {
|
|
||||||
disableButtons();
|
disableButtons();
|
||||||
} else {
|
} else {
|
||||||
enableButtons();
|
enableButtons();
|
||||||
|
|
|
@ -41,10 +41,8 @@ function _updateQA(html, fadeTime, onupdate, onshown) {
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
qa.html(
|
qa.html(
|
||||||
(
|
(
|
||||||
`Invalid HTML on card: ${String(err).substring(
|
`Invalid HTML on card: ${String(err).substring(0, 2000)}\n` +
|
||||||
0,
|
String(err.stack).substring(0, 2000)
|
||||||
2000
|
|
||||||
)}\n` + String(err.stack).substring(0, 2000)
|
|
||||||
).replace(/\n/g, "<br />")
|
).replace(/\n/g, "<br />")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue