From caf85c104f9b1b329ce1bcaf26dfd4c406b48f98 Mon Sep 17 00:00:00 2001 From: muerwre Date: Wed, 7 Aug 2019 14:28:43 +0700 Subject: [PATCH] added upload sagas (failed) --- .eslintrc.js | 8 ++++--- src/containers/dialogs/ScrollDialog/index.tsx | 22 +++++++++---------- 2 files changed, 16 insertions(+), 14 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index 4da03f7e..f02c9765 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -11,9 +11,10 @@ module.exports = { plugins: ['@typescript-eslint', 'react', 'jsx-a11y', 'import', 'react-hooks'], settings: { 'import/resolver': { - node: { - extensions: ['.js', '.jsx', '.ts', '.tsx'], - }, + // node: { + // extensions: ['.js', '.jsx', '.ts', '.tsx'], + // }, + typescript: {}, }, }, rules: { @@ -22,6 +23,7 @@ module.exports = { '@typescript-eslint/indent': ['error', 2], 'comma-dangle': 0, 'no-restricted-syntax': 1, + 'react/prop-types': 0, 'new-cap': 1, 'no-continue': 1, 'no-underscore-dangle': 1, diff --git a/src/containers/dialogs/ScrollDialog/index.tsx b/src/containers/dialogs/ScrollDialog/index.tsx index 48d556bf..a2a72499 100644 --- a/src/containers/dialogs/ScrollDialog/index.tsx +++ b/src/containers/dialogs/ScrollDialog/index.tsx @@ -1,14 +1,14 @@ -import React, { FC, MouseEventHandler, ReactChild, useCallback, useEffect, useState } from "react"; +import React, { FC, MouseEventHandler, ReactChild, useCallback, useEffect, useState } from 'react'; // import { DialogPanel } from '~/components/panels/DialogPanel'; -import { Scroll } from "~/components/containers/Scroll"; -import * as styles from "./styles.scss"; -import classNames from "classnames"; +import classNames from 'classnames'; +import { Scroll } from '~/components/containers/Scroll'; +import * as styles from './styles.scss'; interface IProps { children: React.ReactChild; title?: JSX.Element; buttons?: JSX.Element; - size?: "medium" | "big"; + size?: 'medium' | 'big'; width?: number; error?: string; @@ -39,8 +39,8 @@ const ScrollDialog: FC = ({ const onResize = useCallback(() => setHeight(window.innerHeight - 120), []); useEffect(() => { - window.addEventListener("resize", onResize); - return () => window.removeEventListener("resize", onResize); + window.addEventListener('resize', onResize); + return () => window.removeEventListener('resize', onResize); }, []); const onScroll = useCallback( @@ -71,13 +71,13 @@ const ScrollDialog: FC = ({
{!!title && (
- { onClose &&
} + {onClose &&
}
{title} @@ -92,7 +92,7 @@ const ScrollDialog: FC = ({ {!title && (
- { onClose &&
} + {onClose &&
}
@@ -112,7 +112,7 @@ const ScrollDialog: FC = ({