Unverified Commit e15f82bf authored by alexpott's avatar alexpott
Browse files

Issue #2983365 by ApacheEx, m1r1k, drpal: JS codestyle: operator-linebreak

parent 3fe7057f
......@@ -36,6 +36,7 @@
"requireReturn": false
}],
"brace-style": ["error", "stroustrup"],
"no-unused-vars": ["warn"]
"no-unused-vars": ["warn"],
"operator-linebreak": ["error", "after"]
}
}
......@@ -8,7 +8,6 @@
"max-len": "off",
"default-case": "off",
"prefer-destructuring": "off",
"operator-linebreak": "off",
"react/no-this-in-sfc": "off",
"react/destructuring-assignment": "off",
"import/named": "off"
......
......@@ -1040,9 +1040,9 @@
$newContent[i].nodeName === '#comment' ||
($newContent[i].nodeName === '#text' && /^(\s|\n|\r)*$/.test($newContent[i].textContent))
),
).length > 1
? Drupal.theme('ajaxWrapperMultipleRootElements', $newContent)
: $newContent
).length > 1 ?
Drupal.theme('ajaxWrapperMultipleRootElements', $newContent) :
$newContent
);
/**
......
......@@ -702,8 +702,10 @@
// Stop any current scrolling.
clearInterval(self.scrollInterval);
// Continue scrolling if the mouse has moved in the scroll direction.
if ((scrollAmount > 0 && self.rowObject.direction === 'down')
|| (scrollAmount < 0 && self.rowObject.direction === 'up')) {
if (
(scrollAmount > 0 && self.rowObject.direction === 'down') ||
(scrollAmount < 0 && self.rowObject.direction === 'up')
) {
self.setScroll(scrollAmount);
}
......@@ -1129,8 +1131,10 @@
self.checkScroll(self.currentPointerCoords.y);
const aboveTable = self.scrollY > self.table.topY;
const belowTable = self.scrollY + self.windowHeight < self.table.bottomY;
if ((scrollAmount > 0 && belowTable)
|| (scrollAmount < 0 && aboveTable)) {
if (
(scrollAmount > 0 && belowTable) ||
(scrollAmount < 0 && aboveTable)
) {
window.scrollBy(0, scrollAmount);
}
}, this.scrollSettings.interval);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment