update required libraries.
This commit is contained in:
+15
-15
@@ -4,37 +4,37 @@
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
"@types/async-lock": "^1.1.1",
|
||||
"@types/jest": "24.0.18",
|
||||
"@types/jest": "24.0.22",
|
||||
"@types/lokijs": "^1.5.2",
|
||||
"@types/node": "12.7.2",
|
||||
"@types/react": "16.9.2",
|
||||
"@types/react-dom": "16.9.0",
|
||||
"@types/react-helmet": "^5.0.9",
|
||||
"@types/node": "12.12.6",
|
||||
"@types/react": "16.9.11",
|
||||
"@types/react-dom": "16.9.3",
|
||||
"@types/react-helmet": "^5.0.14",
|
||||
"@types/react-html-parser": "^2.0.1",
|
||||
"@types/react-overlays": "^1.1.3",
|
||||
"@types/react-router-dom": "^4.3.5",
|
||||
"@types/react-router-dom": "^5.1.2",
|
||||
"@types/react-router-hash-link": "^1.2.1",
|
||||
"@types/xregexp": "^3.0.30",
|
||||
"async-lock": "^1.2.2",
|
||||
"axios": "^0.19.0",
|
||||
"lokijs": "^1.5.7",
|
||||
"lokijs": "^1.5.8",
|
||||
"moment": "^2.24.0",
|
||||
"rc-tree": "^3.0.0-alpha.15",
|
||||
"react": "^16.9.0",
|
||||
"react-app-polyfill": "^1.0.2",
|
||||
"rc-tree": "3.0.0-alpha.37",
|
||||
"react": "^16.11.0",
|
||||
"react-app-polyfill": "^1.0.4",
|
||||
"react-cookie": "^4.0.1",
|
||||
"react-dom": "^16.9.0",
|
||||
"react-ga": "^2.6.0",
|
||||
"react-dom": "^16.11.0",
|
||||
"react-ga": "^2.7.0",
|
||||
"react-helmet": "^5.2.1",
|
||||
"react-html-parser": "^2.0.2",
|
||||
"react-image-lightbox": "^5.1.0",
|
||||
"react-overlays": "^1.2.0",
|
||||
"react-router-dom": "^5.0.1",
|
||||
"react-router-dom": "^5.1.2",
|
||||
"react-router-hash-link": "^1.2.2",
|
||||
"react-scripts": "3.1.1",
|
||||
"react-scripts": "3.2.0",
|
||||
"react-spinner-material": "^1.1.3",
|
||||
"react-twitter-widgets": "^1.7.1",
|
||||
"typescript": "3.5.3",
|
||||
"typescript": "3.7.2",
|
||||
"xregexp": "^4.2.4"
|
||||
},
|
||||
"scripts": {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import Tree from 'rc-tree';
|
||||
import { DataNode, NodeInstance } from 'rc-tree/lib/interface';
|
||||
import React, { Component } from 'react';
|
||||
import { DataNode, EventDataNode } from 'rc-tree/lib/interface';
|
||||
import React, { Component, ReactText } from 'react';
|
||||
import { RouteComponentProps, withRouter } from 'react-router';
|
||||
import { MultiLang } from '../../config';
|
||||
import Functions from '../../functions';
|
||||
@@ -67,7 +67,8 @@ class IndexTree extends Component<Props, State> {
|
||||
}
|
||||
|
||||
componentDidUpdate(prevProps: Props, prevState: State) {
|
||||
if (prevProps.lang !== this.props.lang) {
|
||||
const { lang } = this.props;
|
||||
if (prevProps.lang !== lang) {
|
||||
const res = this.load();
|
||||
this.setState({
|
||||
tree: res.elements,
|
||||
@@ -84,8 +85,8 @@ class IndexTree extends Component<Props, State> {
|
||||
this.setState({ expandedKeys: [] })
|
||||
}
|
||||
|
||||
handleExpand(expandedKeys: (string | number)[], info: {
|
||||
node: NodeInstance;
|
||||
handleExpand(expandedKeys: ReactText[], info: {
|
||||
node: EventDataNode;
|
||||
expanded: boolean;
|
||||
nativeEvent: MouseEvent;
|
||||
}): void {
|
||||
@@ -95,10 +96,10 @@ class IndexTree extends Component<Props, State> {
|
||||
this.setState({ expandedKeys: keys });
|
||||
}
|
||||
|
||||
handleSelect(selectedKeys: (string | number)[], info: {
|
||||
handleSelect(selectedKeys: ReactText[], info: {
|
||||
event: 'select';
|
||||
selected: boolean;
|
||||
node: NodeInstance;
|
||||
node: EventDataNode;
|
||||
selectedNodes: DataNode[];
|
||||
nativeEvent: MouseEvent;
|
||||
}): void {
|
||||
|
||||
+2
-2
@@ -4,11 +4,11 @@ import React from 'react';
|
||||
import ReactDOM from 'react-dom';
|
||||
import './index.css';
|
||||
import App from './App';
|
||||
import * as serviceWorker from './serviceWorker';
|
||||
// import * as serviceWorker from './serviceWorker';
|
||||
|
||||
ReactDOM.render(<App />, document.getElementById('root'));
|
||||
|
||||
// If you want your app to work offline and load faster, you can change
|
||||
// unregister() to register() below. Note this comes with some pitfalls.
|
||||
// Learn more about service workers: https://bit.ly/CRA-PWA
|
||||
serviceWorker.unregister();
|
||||
// serviceWorker.unregister();
|
||||
|
||||
Reference in New Issue
Block a user