Skip to content

Commit eb98cd4

Browse files
committed
chore: fix lint
1 parent fea59fe commit eb98cd4

9 files changed

Lines changed: 20 additions & 12 deletions

File tree

.eslintrc.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
1-
const base = require('@umijs/fabric/dist/eslint');
2-
31
module.exports = {
4-
...base,
2+
extends: [require.resolve('@umijs/fabric/dist/eslint')],
53
rules: {
6-
...base.rules,
74
'default-case': 0,
85
'react/sort-comp': 0,
96
'react/no-array-index-key': 0,

examples/extra.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* eslint-disable jsx-a11y/label-has-for, jsx-a11y/label-has-associated-control */
21
import React from 'react';
32
import Tabs, { TabPane } from '../src';
43
import '../assets/index.less';

examples/mix.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* eslint-disable jsx-a11y/label-has-for, jsx-a11y/label-has-associated-control */
21
import React from 'react';
32
import Tabs, { TabPane } from '../src';
43
import '../assets/index.less';

examples/overflow.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* eslint-disable jsx-a11y/label-has-for, jsx-a11y/label-has-associated-control */
21
import React from 'react';
32
import Tabs, { TabPane } from '../src';
43
import '../assets/index.less';

examples/position.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* eslint-disable jsx-a11y/label-has-for, jsx-a11y/label-has-associated-control */
21
import React from 'react';
32
import Tabs, { TabPane } from '../src';
43
import '../assets/index.less';

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
"@types/jest": "^25.2.3",
4646
"@types/react": "^16.9.35",
4747
"@types/react-dom": "^16.9.8",
48-
"@umijs/fabric": "^2.0.4",
48+
"@umijs/fabric": "^2.3.1",
4949
"coveralls": "^3.0.6",
5050
"cross-env": "^7.0.2",
5151
"enzyme": "^3.7.0",
@@ -68,7 +68,7 @@
6868
"react-sticky": "^6.0.3",
6969
"react-test-renderer": "^16.0.0",
7070
"sortablejs": "^1.7.0",
71-
"typescript": "^3.9.2"
71+
"typescript": "^4.0.0"
7272
},
7373
"dependencies": {
7474
"@babel/runtime": "^7.11.2",

src/TabNavList/OperationNode.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ function OperationNode(
150150

151151
const overlayClassName = classNames({
152152
[`${dropdownPrefix}-rtl`]: rtl
153-
})
153+
});
154154

155155
const moreNode: React.ReactElement = mobile ? null : (
156156
<Dropdown

src/TabNavList/index.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,6 @@ function TabNavList(props: TabNavListProps, ref: React.Ref<HTMLDivElement>) {
421421
pingBottom = -transformTop + wrapperHeight < wrapperScrollHeight;
422422
}
423423

424-
/* eslint-disable jsx-a11y/interactive-supports-focus */
425424
return (
426425
<div
427426
ref={ref}

tsconfig.json

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"compilerOptions": {
3+
"target": "esnext",
4+
"moduleResolution": "node",
5+
"baseUrl": "./",
6+
"jsx": "preserve",
7+
"declaration": true,
8+
"skipLibCheck": true,
9+
"esModuleInterop": true,
10+
"paths": {
11+
"@/*": ["src/*"],
12+
"@@/*": ["src/.umi/*"],
13+
"rc-tabs": ["src/index.tsx"]
14+
}
15+
}
16+
}

0 commit comments

Comments
 (0)