Commit 67b02d6d by zhanghaozhe

storybook

parent b801a42d
...@@ -4,26 +4,25 @@ ...@@ -4,26 +4,25 @@
"private": true, "private": true,
"dependencies": { "dependencies": {
"@babel/core": "7.9.0", "@babel/core": "7.9.0",
"@babel/plugin-proposal-decorators": "^7.4.4", "@babel/plugin-proposal-decorators": "^7.10.5",
"@babel/runtime": "^7.7.7", "@loadable/component": "^5.13.1",
"@loadable/component": "^5.10.1",
"@svgr/webpack": "4.3.3", "@svgr/webpack": "4.3.3",
"@testing-library/jest-dom": "^4.2.4", "@testing-library/jest-dom": "^4.2.4",
"@testing-library/react": "^9.5.0", "@testing-library/react": "^9.5.0",
"@testing-library/user-event": "^7.2.1", "@testing-library/user-event": "^7.2.1",
"@types/classnames": "^2.2.10", "@types/classnames": "^2.2.10",
"@types/jest": "^24.9.1", "@types/jest": "^24.9.1",
"@types/node": "^12.12.53", "@types/node": "^12.12.54",
"@types/qs": "^6.9.4", "@types/qs": "^6.9.4",
"@types/react": "^16.9.43", "@types/react": "^16.9.44",
"@types/react-dom": "^16.9.8", "@types/react-dom": "^16.9.8",
"@types/react-redux": "^7.1.9", "@types/react-redux": "^7.1.9",
"@types/react-router-dom": "^5.1.5", "@types/react-router-dom": "^5.1.5",
"@types/redux-logger": "^3.0.8", "@types/redux-logger": "^3.0.8",
"@typescript-eslint/eslint-plugin": "^2.10.0", "@typescript-eslint/eslint-plugin": "^2.10.0",
"@typescript-eslint/parser": "^2.10.0", "@typescript-eslint/parser": "^2.10.0",
"antd-mobile": "^2.3.1", "antd-mobile": "^2.3.3",
"autoprefixer": "^9.6.0", "autoprefixer": "^9.8.6",
"axios": "^0.19.2", "axios": "^0.19.2",
"babel-core": "7.0.0-bridge.0", "babel-core": "7.0.0-bridge.0",
"babel-eslint": "10.1.0", "babel-eslint": "10.1.0",
...@@ -35,9 +34,9 @@ ...@@ -35,9 +34,9 @@
"callapp-lib": "^2.1.8", "callapp-lib": "^2.1.8",
"camelcase": "^5.3.1", "camelcase": "^5.3.1",
"case-sensitive-paths-webpack-plugin": "2.3.0", "case-sensitive-paths-webpack-plugin": "2.3.0",
"crypto-js": "^3.1.9-1", "crypto-js": "^3.3.0",
"css-loader": "3.4.2", "css-loader": "3.4.2",
"date-fns": "^2.14.0", "date-fns": "^2.15.0",
"dotenv": "8.2.0", "dotenv": "8.2.0",
"dotenv-expand": "5.1.0", "dotenv-expand": "5.1.0",
"eslint": "^6.6.0", "eslint": "^6.6.0",
...@@ -53,17 +52,17 @@ ...@@ -53,17 +52,17 @@
"fs-extra": "^8.1.0", "fs-extra": "^8.1.0",
"html-webpack-plugin": "4.0.0-beta.11", "html-webpack-plugin": "4.0.0-beta.11",
"html2canvas": "^1.0.0-rc.5", "html2canvas": "^1.0.0-rc.5",
"http-proxy-middleware": "^0.19.1", "http-proxy-middleware": "^0.19.2",
"identity-obj-proxy": "3.0.0", "identity-obj-proxy": "3.0.0",
"jest": "24.9.0", "jest": "24.9.0",
"jest-environment-jsdom-fourteen": "1.0.1", "jest-environment-jsdom-fourteen": "1.0.1",
"jest-pnp-resolver": "1.0.2", "jest-pnp-resolver": "1.0.2",
"jest-resolve": "24.9.0", "jest-resolve": "24.9.0",
"jest-watch-typeahead": "0.4.2", "jest-watch-typeahead": "0.4.2",
"js-base64": "^2.5.1", "js-base64": "^2.6.4",
"js-cookie": "^2.2.0", "js-cookie": "^2.2.1",
"json-stringify-safe": "^5.0.1", "json-stringify-safe": "^5.0.1",
"less": "^3.9.0", "less": "^3.12.2",
"less-loader": "^4.1.0", "less-loader": "^4.1.0",
"lodash": "^4.17.19", "lodash": "^4.17.19",
"mini-css-extract-plugin": "0.9.0", "mini-css-extract-plugin": "0.9.0",
...@@ -77,21 +76,21 @@ ...@@ -77,21 +76,21 @@
"postcss-safe-parser": "4.0.1", "postcss-safe-parser": "4.0.1",
"prop-types": "^15.7.2", "prop-types": "^15.7.2",
"qrcode": "^1.4.4", "qrcode": "^1.4.4",
"qs": "^6.7.0", "qs": "^6.9.4",
"react": "^16.13.1", "react": "^16.13.1",
"react-ace": "^8.0.0", "react-ace": "^8.1.0",
"react-app-polyfill": "^1.0.6", "react-app-polyfill": "^1.0.6",
"react-copy-to-clipboard": "^5.0.1", "react-copy-to-clipboard": "^5.0.2",
"react-dev-utils": "^10.2.1", "react-dev-utils": "^10.2.1",
"react-dom": "^16.13.1", "react-dom": "^16.13.1",
"react-infinite-scroller": "^1.2.4", "react-infinite-scroller": "^1.2.4",
"react-lazy-load": "^3.0.13", "react-lazy-load": "^3.1.13",
"react-mobile-swiper": "^1.1.4", "react-mobile-swiper": "^1.1.4",
"react-redux": "^7.0.2", "react-redux": "^7.2.1",
"react-router-dom": "^5.2.0", "react-router-dom": "^5.2.0",
"react-spinners": "^0.5.4", "react-spinners": "^0.5.12",
"react-sticky": "^6.0.3", "react-sticky": "^6.0.3",
"redux": "^4.0.1", "redux": "^4.0.5",
"redux-immutable": "^4.0.0", "redux-immutable": "^4.0.0",
"redux-logger": "^3.0.6", "redux-logger": "^3.0.6",
"redux-thunk": "^2.3.0", "redux-thunk": "^2.3.0",
...@@ -99,7 +98,7 @@ ...@@ -99,7 +98,7 @@
"resolve-url-loader": "3.1.1", "resolve-url-loader": "3.1.1",
"sass-loader": "8.0.2", "sass-loader": "8.0.2",
"semver": "6.3.0", "semver": "6.3.0",
"socket.io": "^2.2.0", "socket.io": "^2.3.0",
"store2": "^2.11.2", "store2": "^2.11.2",
"style-loader": "0.23.1", "style-loader": "0.23.1",
"swiper": "^4.5.1", "swiper": "^4.5.1",
...@@ -107,8 +106,8 @@ ...@@ -107,8 +106,8 @@
"ts-pnp": "1.1.6", "ts-pnp": "1.1.6",
"typescript": "^3.7.5", "typescript": "^3.7.5",
"url-loader": "2.3.0", "url-loader": "2.3.0",
"video.js": "^7.6.5", "video.js": "^7.8.4",
"web-launch-app": "^2.1.9", "web-launch-app": "^2.2.4",
"webpack": "4.42.0", "webpack": "4.42.0",
"webpack-dev-server": "^3.11.0", "webpack-dev-server": "^3.11.0",
"webpack-manifest-plugin": "2.2.0", "webpack-manifest-plugin": "2.2.0",
...@@ -196,20 +195,20 @@ ...@@ -196,20 +195,20 @@
] ]
}, },
"devDependencies": { "devDependencies": {
"@babel/runtime": "^7.7.2", "@babel/runtime": "^7.11.2",
"@storybook/addon-actions": "^5.3.19", "@storybook/addon-actions": "^5.3.19",
"@storybook/addon-knobs": "^5.3.19", "@storybook/addon-knobs": "^5.3.19",
"@storybook/addon-links": "^5.3.19", "@storybook/addon-links": "^5.3.19",
"@storybook/addons": "^5.3.19", "@storybook/addons": "^5.3.19",
"@storybook/preset-typescript": "^3.0.0", "@storybook/preset-typescript": "^3.0.0",
"@storybook/react": "^5.3.19", "@storybook/react": "^5.3.19",
"babel-plugin-import": "^1.11.0", "babel-plugin-import": "^1.13.0",
"browserslist": "^4.6.6", "browserslist": "^4.14.0",
"caniuse-lite": "^1.0.30000989", "caniuse-lite": "^1.0.30001112",
"classnames": "^2.2.6", "classnames": "^2.2.6",
"fork-ts-checker-webpack-plugin": "^5.0.14", "fork-ts-checker-webpack-plugin": "^5.0.14",
"mockjs": "^1.0.1-beta3", "mockjs": "^1.1.0",
"postcss-px-to-viewport": "^1.1.0", "postcss-px-to-viewport": "^1.1.1",
"ts-loader": "^8.0.2" "ts-loader": "^8.0.2"
}, },
"theme": "./src/assets/theme/config.js" "theme": "./src/assets/theme/config.js"
......
...@@ -8,8 +8,8 @@ const re = /(https?|ftp):\/\/[-A-Za-z0-9+&@#/%?=~_|!:,.;]+[-A-Za-z0-9+&@#/%=~_|] ...@@ -8,8 +8,8 @@ const re = /(https?|ftp):\/\/[-A-Za-z0-9+&@#/%?=~_|!:,.;]+[-A-Za-z0-9+&@#/%=~_|]
interface Props { interface Props {
title: string title: string
content: React.ReactNode content: React.ReactNode
closable?: boolean
className?: string className?: string
closable?: boolean
clickMaskClose?: boolean clickMaskClose?: boolean
close?: () => void | Promise<void> close?: () => void | Promise<void>
closeIcon?: string closeIcon?: string
...@@ -31,7 +31,7 @@ function ClosablePopup({ ...@@ -31,7 +31,7 @@ function ClosablePopup({
remove = function () { remove = function () {
} }
}: Props = {title: '标题', content: '内容'}) { }: Props) {
function unmountComponent() { function unmountComponent() {
ReactDOM.unmountComponentAtNode(div) ReactDOM.unmountComponentAtNode(div)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment