Add eslint rule padding-line-between-statements (#1593)

Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com>
This commit is contained in:
Panu Horsmalahti authored and GitHub committed 2020-12-02 09:55:52 +02:00
1 parent 7b77f18376
commit dcf253e7d5
401 files changed
+2018 -40

No files matched your search

@@ -92,6 +92,7 @@ export class AceEditor extends React.Component<Props, State> {
componentDidUpdate() {
if (!this.editor) return;
const { value, cursorPos } = this.props;
if (value !== this.getValue()) {
this.editor.setValue(value);
this.editor.clearSelection();
@@ -136,6 +137,7 @@ export class AceEditor extends React.Component<Props, State> {
setCursorPos(pos: Ace.Point) {
if (!pos) return;
const { row, column } = pos;
this.editor.moveCursorToPosition(pos);
requestAnimationFrame(() => {
this.editor.gotoLine(row + 1, column, false);
@@ -145,6 +147,7 @@ export class AceEditor extends React.Component<Props, State> {
@autobind()
onCursorPosChange() {
const { onCursorPosChange } = this.props;
if (onCursorPosChange) {
onCursorPosChange(this.editor.getCursorPosition());
}
@@ -153,6 +156,7 @@ export class AceEditor extends React.Component<Props, State> {
@autobind()
onChange(delta: Ace.Delta) {
const { onChange } = this.props;
if (onChange) {
onChange(this.getValue(), delta);
}
@@ -160,6 +164,7 @@ export class AceEditor extends React.Component<Props, State> {
render() {
const { className, hidden } = this.props;
return (
<div className={cssNames("AceEditor", className, { hidden })}>
<div className="editor" ref={e => this.elem = e}/>