Add more ESLint rules and change the formatting scripts (#626)
* Add curly rule in ESLint for consistency * Fix rules * More rules * REturn * Push * no else return * prefer const * destructing
This commit is contained in:
@ -11,13 +11,17 @@ export function resizeTest(
|
||||
y: number,
|
||||
{ scrollX, scrollY }: SceneScroll,
|
||||
): HandlerRectanglesRet | false {
|
||||
if (!element.isSelected || element.type === "text") return false;
|
||||
if (!element.isSelected || element.type === "text") {
|
||||
return false;
|
||||
}
|
||||
|
||||
const handlers = handlerRectangles(element, { scrollX, scrollY });
|
||||
|
||||
const filter = Object.keys(handlers).filter(key => {
|
||||
const handler = handlers[key as HandlerRectanglesRet]!;
|
||||
if (!handler) return false;
|
||||
if (!handler) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return (
|
||||
x + scrollX >= handler[0] &&
|
||||
|
Reference in New Issue
Block a user