diff --git a/web/package.json b/web/package.json
index 1ac823cb..c2cfec89 100644
--- a/web/package.json
+++ b/web/package.json
@@ -8,7 +8,9 @@
"@testing-library/user-event": "^7.1.2",
"antd": "^4.7.2",
"react": "^16.14.0",
+ "react-device-detect": "^1.14.0",
"react-dom": "^16.14.0",
+ "react-router-dom": "^5.2.0",
"react-scripts": "3.4.3"
},
"scripts": {
diff --git a/web/public/index.html b/web/public/index.html
index aa069f27..c0d8c7f4 100644
--- a/web/public/index.html
+++ b/web/public/index.html
@@ -24,7 +24,7 @@
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
-
React App
+ Casdoor
You need to enable JavaScript to run this app.
diff --git a/web/src/App.css b/web/src/App.css
index 016ba351..01c3c4ea 100644
--- a/web/src/App.css
+++ b/web/src/App.css
@@ -9,12 +9,6 @@
pointer-events: none;
}
-@media (prefers-reduced-motion: no-preference) {
- .App-logo {
- animation: App-logo-spin infinite 20s linear;
- }
-}
-
.App-header {
background-color: #282c34;
min-height: 100vh;
@@ -30,11 +24,18 @@
color: #61dafb;
}
-@keyframes App-logo-spin {
- from {
- transform: rotate(0deg);
- }
- to {
- transform: rotate(360deg);
- }
+#parent-area {
+ position: relative;
+ min-height: 100vh;
+}
+
+#content-wrap {
+ padding-bottom: 70px; /* Footer height */
+}
+
+#footer {
+ position: absolute;
+ bottom: 0;
+ width: 100%;
+ height: 70px; /* Footer height */
}
diff --git a/web/src/App.js b/web/src/App.js
index 16f62b27..c8018e91 100644
--- a/web/src/App.js
+++ b/web/src/App.js
@@ -1,13 +1,282 @@
-import React from 'react';
-import './App.css';
-import {Button} from "antd";
+// Copyright 2020 The casbin Authors. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
-function App() {
- return (
-
- Button
-
- );
+import React, {Component} from 'react';
+import './App.css';
+import * as Setting from "./Setting";
+import {DownOutlined, LogoutOutlined, SettingOutlined} from '@ant-design/icons';
+import {Avatar, BackTop, Dropdown, Layout, Menu} from 'antd';
+import {Switch, Route, withRouter, Redirect} from 'react-router-dom'
+import * as AccountBackend from "./backend/AccountBackend";
+
+const { Header, Footer } = Layout;
+
+class App extends Component {
+ constructor(props) {
+ super(props);
+ this.state = {
+ classes: props,
+ selectedMenuKey: 0,
+ account: undefined,
+ };
+ }
+
+ componentWillMount() {
+ this.updateMenuKey();
+ this.getAccount();
+ }
+
+ updateMenuKey() {
+ // eslint-disable-next-line no-restricted-globals
+ const uri = location.pathname;
+ if (uri === '/') {
+ this.setState({ selectedMenuKey: 0 });
+ } else {
+ this.setState({ selectedMenuKey: -1 });
+ }
+ }
+
+ onLogined() {
+ this.getAccount();
+ }
+
+ onUpdateAccount(account) {
+ this.setState({
+ account: account
+ });
+ }
+
+ getAccount() {
+ AccountBackend.getAccount()
+ .then((res) => {
+ const account = Setting.parseJson(res.data);
+ if (window.location.pathname === '/' && account === null) {
+ Setting.goToLink("/");
+ }
+ this.setState({
+ account: account,
+ });
+
+ if (account !== undefined && account !== null) {
+ window.mouselogUserId = account.username;
+ }
+ });
+ }
+
+ logout() {
+ this.setState({
+ expired: false,
+ submitted: false,
+ });
+
+ AccountBackend.logout()
+ .then((res) => {
+ if (res.status === 'ok') {
+ this.setState({
+ account: null
+ });
+
+ Setting.showMessage("success", `Successfully logged out, redirected to homepage`);
+
+ Setting.goToLink("/");
+ } else {
+ Setting.showMessage("error", `Logout failed: ${res.msg}`);
+ }
+ });
+ }
+
+ handleRightDropdownClick(e) {
+ if (e.key === '0') {
+ this.props.history.push(`/account`);
+ } else if (e.key === '1') {
+ this.logout();
+ }
+ }
+
+ renderRightDropdown() {
+ const menu = (
+
+
+
+ My Account
+
+
+
+ Logout
+
+
+ );
+
+ return (
+
+
+
+ {Setting.getShortName(this.state.account.name)}
+
+
+
+ {Setting.isMobile() ? null : Setting.getShortName(this.state.account.name)}
+
+
+
+
+
+ )
+ }
+
+ renderAccount() {
+ let res = [];
+
+ if (this.state.account !== null && this.state.account !== undefined) {
+ res.push(this.renderRightDropdown());
+ } else {
+ res.push(
+
+
+ Register
+
+
+ );
+ res.push(
+
+
+ Login
+
+
+ );
+ res.push(
+
+
+ Home
+
+
+ );
+ }
+
+ return res;
+ }
+
+ renderMenu() {
+ let res = [];
+
+ if (this.state.account === null || this.state.account === undefined) {
+ return [];
+ }
+
+ res.push(
+
+
+ Home
+
+
+ );
+ res.push(
+
+
+ Programs
+
+
+ );
+
+ return res;
+ }
+
+ renderHomeIfLogined(component) {
+ if (this.state.account !== null && this.state.account !== undefined) {
+ return
+ } else {
+ return component;
+ }
+ }
+
+ renderLoginIfNotLogined(component) {
+ if (this.state.account === null) {
+ return
+ } else if (this.state.account === undefined) {
+ return null;
+ }
+ else {
+ return component;
+ }
+ }
+
+ isStartPages() {
+ return window.location.pathname.startsWith('/login') ||
+ window.location.pathname.startsWith('/register') ||
+ window.location.pathname === '/';
+ }
+
+ renderContent() {
+ return (
+
+
+ {
+ Setting.isMobile() ? null :
+ }
+
+ {
+ this.renderMenu()
+ }
+ {
+ this.renderAccount()
+ }
+
+
+
+ {/**/}
+
+
+ )
+ }
+
+ renderFooter() {
+ // How to keep your footer where it belongs ?
+ // https://www.freecodecamp.org/neyarnws/how-to-keep-your-footer-where-it-belongs-59c6aa05c59c/
+
+ return (
+
+ )
+ }
+
+ render() {
+ return (
+
+
+
+ {
+ this.renderContent()
+ }
+
+ {
+ this.renderFooter()
+ }
+
+ );
+ }
}
-export default App;
+export default withRouter(App);
diff --git a/web/src/Setting.js b/web/src/Setting.js
new file mode 100644
index 00000000..bfc5fa08
--- /dev/null
+++ b/web/src/Setting.js
@@ -0,0 +1,79 @@
+// Copyright 2020 The casbin Authors. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+import {message} from "antd";
+import React from "react";
+import {isMobile as isMobileDevice} from "react-device-detect";
+
+export let ServerUrl = '';
+
+export function initServerUrl() {
+ const hostname = window.location.hostname;
+ if (hostname === 'localhost') {
+ ServerUrl = `http://${hostname}:10000`;
+ }
+}
+
+export function parseJson(s) {
+ if (s === "") {
+ return null;
+ } else {
+ return JSON.parse(s);
+ }
+}
+
+export function goToLink(link) {
+ window.location.href = link;
+}
+
+export function showMessage(type, text) {
+ if (type === "") {
+ return;
+ } else if (type === "success") {
+ message.success(text);
+ } else if (type === "error") {
+ message.error(text);
+ }
+}
+
+export function isMobile() {
+ // return getIsMobileView();
+ return isMobileDevice;
+}
+
+export function getShortName(s) {
+ return s.split('/').slice(-1)[0];
+}
+
+function getRandomInt(s) {
+ let hash = 0;
+ if (s.length !== 0) {
+ for (let i = 0; i < s.length; i ++) {
+ let char = s.charCodeAt(i);
+ hash = ((hash << 5) - hash) + char;
+ hash = hash & hash;
+ }
+ }
+
+ return hash;
+}
+
+export function getAvatarColor(s) {
+ const colorList = ['#f56a00', '#7265e6', '#ffbf00', '#00a2ae'];
+ let random = getRandomInt(s);
+ if (random < 0) {
+ random = -random;
+ }
+ return colorList[random % 4];
+}
diff --git a/web/src/backend/AccountBackend.js b/web/src/backend/AccountBackend.js
new file mode 100644
index 00000000..7aed19c9
--- /dev/null
+++ b/web/src/backend/AccountBackend.js
@@ -0,0 +1,52 @@
+// Copyright 2020 The casbin Authors. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+import * as Setting from "../Setting";
+
+export function getUser(username) {
+ return fetch(`${Setting.ServerUrl}/api/get-user?username=${username}`, {
+ method: 'GET',
+ credentials: 'include'
+ }).then(res => res.json());
+}
+
+export function getAccount() {
+ return fetch(`${Setting.ServerUrl}/api/get-account`, {
+ method: 'GET',
+ credentials: 'include'
+ }).then(res => res.json());
+}
+
+export function register(values) {
+ return fetch(`${Setting.ServerUrl}/api/register`, {
+ method: 'POST',
+ credentials: "include",
+ body: JSON.stringify(values),
+ }).then(res => res.json());
+}
+
+export function login(values) {
+ return fetch(`${Setting.ServerUrl}/api/login`, {
+ method: 'POST',
+ credentials: "include",
+ body: JSON.stringify(values),
+ }).then(res => res.json());
+}
+
+export function logout() {
+ return fetch(`${Setting.ServerUrl}/api/logout`, {
+ method: 'POST',
+ credentials: "include",
+ }).then(res => res.json());
+}
diff --git a/web/src/index.css b/web/src/index.css
index ec2585e8..9ca806bf 100644
--- a/web/src/index.css
+++ b/web/src/index.css
@@ -11,3 +11,13 @@ code {
font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
monospace;
}
+
+.logo {
+ background: url("logo.png");
+ background-size: 108px, 33px;
+ width: 108px;
+ height: 27px;
+ /*background: rgba(0, 0, 0, 0.2);*/
+ margin: 17px 10px 16px 20px;
+ float: left;
+}
diff --git a/web/src/index.js b/web/src/index.js
index f5185c1e..9a4e9f7a 100644
--- a/web/src/index.js
+++ b/web/src/index.js
@@ -1,13 +1,28 @@
+// Copyright 2020 The casbin Authors. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
import App from './App';
import * as serviceWorker from './serviceWorker';
+import { BrowserRouter } from 'react-router-dom';
ReactDOM.render(
-
+
- ,
+ ,
document.getElementById('root')
);
diff --git a/web/src/logo.png b/web/src/logo.png
new file mode 100644
index 00000000..7e5d1ecf
Binary files /dev/null and b/web/src/logo.png differ
diff --git a/web/src/logo.svg b/web/src/logo.svg
deleted file mode 100644
index 6b60c104..00000000
--- a/web/src/logo.svg
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/web/yarn.lock b/web/yarn.lock
index a2b23a68..7858700f 100644
--- a/web/yarn.lock
+++ b/web/yarn.lock
@@ -1149,7 +1149,7 @@
dependencies:
regenerator-runtime "^0.13.4"
-"@babel/runtime@^7.0.0", "@babel/runtime@^7.10.1", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.3", "@babel/runtime@^7.10.4", "@babel/runtime@^7.11.1", "@babel/runtime@^7.11.2", "@babel/runtime@^7.3.4", "@babel/runtime@^7.4.5", "@babel/runtime@^7.5.1", "@babel/runtime@^7.7.2", "@babel/runtime@^7.8.4":
+"@babel/runtime@^7.0.0", "@babel/runtime@^7.1.2", "@babel/runtime@^7.10.1", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.3", "@babel/runtime@^7.10.4", "@babel/runtime@^7.11.1", "@babel/runtime@^7.11.2", "@babel/runtime@^7.3.4", "@babel/runtime@^7.4.5", "@babel/runtime@^7.5.1", "@babel/runtime@^7.5.5", "@babel/runtime@^7.7.2", "@babel/runtime@^7.8.4":
version "7.12.1"
resolved "https://registry.npm.taobao.org/@babel/runtime/download/@babel/runtime-7.12.1.tgz?cache=0&sync_timestamp=1602801755591&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40babel%2Fruntime%2Fdownload%2F%40babel%2Fruntime-7.12.1.tgz#b4116a6b6711d010b2dad3b7b6e43bf1b9954740"
integrity sha1-tBFqa2cR0BCy2tO3tuQ78bmVR0A=
@@ -5272,6 +5272,18 @@ hex-color-regex@^1.1.0:
resolved "https://registry.npm.taobao.org/hex-color-regex/download/hex-color-regex-1.1.0.tgz#4c06fccb4602fe2602b3c93df82d7e7dbf1a8a8e"
integrity sha1-TAb8y0YC/iYCs8k9+C1+fb8aio4=
+history@^4.9.0:
+ version "4.10.1"
+ resolved "https://registry.npm.taobao.org/history/download/history-4.10.1.tgz?cache=0&sync_timestamp=1591982561040&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fhistory%2Fdownload%2Fhistory-4.10.1.tgz#33371a65e3a83b267434e2b3f3b1b4c58aad4cf3"
+ integrity sha1-MzcaZeOoOyZ0NOKz87G0xYqtTPM=
+ dependencies:
+ "@babel/runtime" "^7.1.2"
+ loose-envify "^1.2.0"
+ resolve-pathname "^3.0.0"
+ tiny-invariant "^1.0.2"
+ tiny-warning "^1.0.0"
+ value-equal "^1.0.1"
+
hmac-drbg@^1.0.0:
version "1.0.1"
resolved "https://registry.npm.taobao.org/hmac-drbg/download/hmac-drbg-1.0.1.tgz#d2745701025a6c775a6c545793ed502fc0c649a1"
@@ -5281,7 +5293,7 @@ hmac-drbg@^1.0.0:
minimalistic-assert "^1.0.0"
minimalistic-crypto-utils "^1.0.1"
-hoist-non-react-statics@^3.3.2:
+hoist-non-react-statics@^3.1.0, hoist-non-react-statics@^3.3.2:
version "3.3.2"
resolved "https://registry.npm.taobao.org/hoist-non-react-statics/download/hoist-non-react-statics-3.3.2.tgz#ece0acaf71d62c2969c2ec59feff42a4b1a85b45"
integrity sha1-7OCsr3HWLClpwuxZ/v9CpLGoW0U=
@@ -5969,6 +5981,11 @@ is-wsl@^2.1.1:
dependencies:
is-docker "^2.0.0"
+isarray@0.0.1:
+ version "0.0.1"
+ resolved "https://registry.npm.taobao.org/isarray/download/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf"
+ integrity sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=
+
isarray@1.0.0, isarray@^1.0.0, isarray@~1.0.0:
version "1.0.0"
resolved "https://registry.npm.taobao.org/isarray/download/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11"
@@ -6826,7 +6843,7 @@ loglevel@^1.6.8:
resolved "https://registry.npm.taobao.org/loglevel/download/loglevel-1.7.0.tgz?cache=0&sync_timestamp=1598447642950&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Floglevel%2Fdownload%2Floglevel-1.7.0.tgz#728166855a740d59d38db01cf46f042caa041bb0"
integrity sha1-coFmhVp0DVnTjbAc9G8ELKoEG7A=
-loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.4.0:
+loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.2.0, loose-envify@^1.3.1, loose-envify@^1.4.0:
version "1.4.0"
resolved "https://registry.npm.taobao.org/loose-envify/download/loose-envify-1.4.0.tgz#71ee51fa7be4caec1a63839f7e682d8132d30caf"
integrity sha1-ce5R+nvkyuwaY4OffmgtgTLTDK8=
@@ -7029,6 +7046,14 @@ min-indent@^1.0.0:
resolved "https://registry.npm.taobao.org/min-indent/download/min-indent-1.0.1.tgz?cache=0&sync_timestamp=1590693908857&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fmin-indent%2Fdownload%2Fmin-indent-1.0.1.tgz#a63f681673b30571fbe8bc25686ae746eefa9869"
integrity sha1-pj9oFnOzBXH76LwlaGrnRu76mGk=
+mini-create-react-context@^0.4.0:
+ version "0.4.0"
+ resolved "https://registry.npm.taobao.org/mini-create-react-context/download/mini-create-react-context-0.4.0.tgz#df60501c83151db69e28eac0ef08b4002efab040"
+ integrity sha1-32BQHIMVHbaeKOrA7wi0AC76sEA=
+ dependencies:
+ "@babel/runtime" "^7.5.5"
+ tiny-warning "^1.0.3"
+
mini-css-extract-plugin@0.9.0:
version "0.9.0"
resolved "https://registry.npm.taobao.org/mini-css-extract-plugin/download/mini-css-extract-plugin-0.9.0.tgz#47f2cf07aa165ab35733b1fc97d4c46c0564339e"
@@ -7794,6 +7819,13 @@ path-to-regexp@0.1.7:
resolved "https://registry.npm.taobao.org/path-to-regexp/download/path-to-regexp-0.1.7.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fpath-to-regexp%2Fdownload%2Fpath-to-regexp-0.1.7.tgz#df604178005f522f15eb4490e7247a1bfaa67f8c"
integrity sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=
+path-to-regexp@^1.7.0:
+ version "1.8.0"
+ resolved "https://registry.npm.taobao.org/path-to-regexp/download/path-to-regexp-1.8.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fpath-to-regexp%2Fdownload%2Fpath-to-regexp-1.8.0.tgz#887b3ba9d84393e87a0a0b9f4cb756198b53548a"
+ integrity sha1-iHs7qdhDk+h6CgufTLdWGYtTVIo=
+ dependencies:
+ isarray "0.0.1"
+
path-type@^2.0.0:
version "2.0.0"
resolved "https://registry.npm.taobao.org/path-type/download/path-type-2.0.0.tgz#f012ccb8415b7096fc2daa1054c3d72389594c73"
@@ -9231,6 +9263,13 @@ react-dev-utils@^10.2.1:
strip-ansi "6.0.0"
text-table "0.2.0"
+react-device-detect@^1.14.0:
+ version "1.14.0"
+ resolved "https://registry.npm.taobao.org/react-device-detect/download/react-device-detect-1.14.0.tgz#ae8bf8cff85055c030f97aa491a0c2b06c472644"
+ integrity sha1-rov4z/hQVcAw+XqkkaDCsGxHJkQ=
+ dependencies:
+ ua-parser-js "^0.7.22"
+
react-dom@^16.14.0:
version "16.14.0"
resolved "https://registry.npm.taobao.org/react-dom/download/react-dom-16.14.0.tgz?cache=0&sync_timestamp=1602707572899&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Freact-dom%2Fdownload%2Freact-dom-16.14.0.tgz#7ad838ec29a777fb3c75c3a190f661cf92ab8b89"
@@ -9246,7 +9285,7 @@ react-error-overlay@^6.0.7:
resolved "https://registry.npm.taobao.org/react-error-overlay/download/react-error-overlay-6.0.7.tgz?cache=0&sync_timestamp=1600296997401&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Freact-error-overlay%2Fdownload%2Freact-error-overlay-6.0.7.tgz#1dcfb459ab671d53f660a991513cb2f0a0553108"
integrity sha1-Hc+0WatnHVP2YKmRUTyy8KBVMQg=
-react-is@^16.12.0, react-is@^16.7.0, react-is@^16.8.1, react-is@^16.8.4:
+react-is@^16.12.0, react-is@^16.6.0, react-is@^16.7.0, react-is@^16.8.1, react-is@^16.8.4:
version "16.13.1"
resolved "https://registry.npm.taobao.org/react-is/download/react-is-16.13.1.tgz?cache=0&sync_timestamp=1602081887213&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Freact-is%2Fdownload%2Freact-is-16.13.1.tgz#789729a4dc36de2999dc156dd6c1d9c18cea56a4"
integrity sha1-eJcppNw23imZ3BVt1sHZwYzqVqQ=
@@ -9256,6 +9295,35 @@ react-lifecycles-compat@^3.0.4:
resolved "https://registry.npm.taobao.org/react-lifecycles-compat/download/react-lifecycles-compat-3.0.4.tgz#4f1a273afdfc8f3488a8c516bfda78f872352362"
integrity sha1-TxonOv38jzSIqMUWv9p4+HI1I2I=
+react-router-dom@^5.2.0:
+ version "5.2.0"
+ resolved "https://registry.npm.taobao.org/react-router-dom/download/react-router-dom-5.2.0.tgz#9e65a4d0c45e13289e66c7b17c7e175d0ea15662"
+ integrity sha1-nmWk0MReEyieZsexfH4XXQ6hVmI=
+ dependencies:
+ "@babel/runtime" "^7.1.2"
+ history "^4.9.0"
+ loose-envify "^1.3.1"
+ prop-types "^15.6.2"
+ react-router "5.2.0"
+ tiny-invariant "^1.0.2"
+ tiny-warning "^1.0.0"
+
+react-router@5.2.0:
+ version "5.2.0"
+ resolved "https://registry.npm.taobao.org/react-router/download/react-router-5.2.0.tgz#424e75641ca8747fbf76e5ecca69781aa37ea293"
+ integrity sha1-Qk51ZByodH+/duXsyml4GqN+opM=
+ dependencies:
+ "@babel/runtime" "^7.1.2"
+ history "^4.9.0"
+ hoist-non-react-statics "^3.1.0"
+ loose-envify "^1.3.1"
+ mini-create-react-context "^0.4.0"
+ path-to-regexp "^1.7.0"
+ prop-types "^15.6.2"
+ react-is "^16.6.0"
+ tiny-invariant "^1.0.2"
+ tiny-warning "^1.0.0"
+
react-scripts@3.4.3:
version "3.4.3"
resolved "https://registry.npm.taobao.org/react-scripts/download/react-scripts-3.4.3.tgz?cache=0&sync_timestamp=1600298780128&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Freact-scripts%2Fdownload%2Freact-scripts-3.4.3.tgz#21de5eb93de41ee92cd0b85b0e1298d0bb2e6c51"
@@ -9613,6 +9681,11 @@ resolve-from@^4.0.0:
resolved "https://registry.npm.taobao.org/resolve-from/download/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6"
integrity sha1-SrzYUq0y3Xuqv+m0DgCjbbXzkuY=
+resolve-pathname@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.npm.taobao.org/resolve-pathname/download/resolve-pathname-3.0.0.tgz#99d02224d3cf263689becbb393bc560313025dcd"
+ integrity sha1-mdAiJNPPJjaJvsuzk7xWAxMCXc0=
+
resolve-url-loader@3.1.1:
version "3.1.1"
resolved "https://registry.npm.taobao.org/resolve-url-loader/download/resolve-url-loader-3.1.1.tgz?cache=0&sync_timestamp=1603188581258&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fresolve-url-loader%2Fdownload%2Fresolve-url-loader-3.1.1.tgz#28931895fa1eab9be0647d3b2958c100ae3c0bf0"
@@ -10640,6 +10713,16 @@ timsort@^0.3.0:
resolved "https://registry.npm.taobao.org/timsort/download/timsort-0.3.0.tgz#405411a8e7e6339fe64db9a234de11dc31e02bd4"
integrity sha1-QFQRqOfmM5/mTbmiNN4R3DHgK9Q=
+tiny-invariant@^1.0.2:
+ version "1.1.0"
+ resolved "https://registry.npm.taobao.org/tiny-invariant/download/tiny-invariant-1.1.0.tgz#634c5f8efdc27714b7f386c35e6760991d230875"
+ integrity sha1-Y0xfjv3CdxS384bDXmdgmR0jCHU=
+
+tiny-warning@^1.0.0, tiny-warning@^1.0.3:
+ version "1.0.3"
+ resolved "https://registry.npm.taobao.org/tiny-warning/download/tiny-warning-1.0.3.tgz#94a30db453df4c643d0fd566060d60a875d84754"
+ integrity sha1-lKMNtFPfTGQ9D9VmBg1gqHXYR1Q=
+
tinycolor2@^1.4.1:
version "1.4.2"
resolved "https://registry.npm.taobao.org/tinycolor2/download/tinycolor2-1.4.2.tgz?cache=0&sync_timestamp=1601056446986&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Ftinycolor2%2Fdownload%2Ftinycolor2-1.4.2.tgz#3f6a4d1071ad07676d7fa472e1fac40a719d8803"
@@ -10803,6 +10886,11 @@ typedarray@^0.0.6:
resolved "https://registry.npm.taobao.org/typedarray/download/typedarray-0.0.6.tgz?cache=0&sync_timestamp=1596697411295&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Ftypedarray%2Fdownload%2Ftypedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=
+ua-parser-js@^0.7.22:
+ version "0.7.22"
+ resolved "https://registry.npm.taobao.org/ua-parser-js/download/ua-parser-js-0.7.22.tgz?cache=0&sync_timestamp=1599900411653&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fua-parser-js%2Fdownload%2Fua-parser-js-0.7.22.tgz#960df60a5f911ea8f1c818f3747b99c6e177eae3"
+ integrity sha1-lg32Cl+RHqjxyBjzdHuZxuF36uM=
+
unicode-canonical-property-names-ecmascript@^1.0.4:
version "1.0.4"
resolved "https://registry.npm.taobao.org/unicode-canonical-property-names-ecmascript/download/unicode-canonical-property-names-ecmascript-1.0.4.tgz#2619800c4c825800efdd8343af7dd9933cbe2818"
@@ -10995,6 +11083,11 @@ validate-npm-package-license@^3.0.1:
spdx-correct "^3.0.0"
spdx-expression-parse "^3.0.0"
+value-equal@^1.0.1:
+ version "1.0.1"
+ resolved "https://registry.npm.taobao.org/value-equal/download/value-equal-1.0.1.tgz#1e0b794c734c5c0cade179c437d356d931a34d6c"
+ integrity sha1-Hgt5THNMXAyt4XnEN9NW2TGjTWw=
+
vary@~1.1.2:
version "1.1.2"
resolved "https://registry.npm.taobao.org/vary/download/vary-1.1.2.tgz#2299f02c6ded30d4a5961b0b9f74524a18f634fc"