├── .babelrc ├── .eslintignore ├── .eslintrc ├── .gitignore ├── README.md ├── README_en.md ├── demo.gif ├── dist ├── Aboutpage-8a75c.chunk.js ├── Contactpage-8a75c.chunk.js ├── FundListContainer-8a75c.chunk.js ├── HomeContainer-8a75c.chunk.js ├── NotFound-8a75c.chunk.js ├── bundle-8a75c.min.css ├── bundle-8a75c.min.js ├── dll │ ├── vendor-manifest.json │ └── vendor.dll.js ├── img │ └── 4c8c0d3b.tusiji.png └── index.html ├── index.html ├── mock └── db.json ├── package.json ├── server.js ├── src ├── app.js ├── favicon.ico ├── index.tpl.html ├── module │ ├── Dialog │ │ ├── close.png │ │ ├── dialog.less │ │ └── index.js │ └── Spin │ │ ├── index.js │ │ └── spin.less ├── reducers │ └── index.js ├── router │ └── index.js ├── store │ └── index.js ├── styles │ ├── animation.less │ ├── button.less │ └── reset.less ├── util │ └── co │ │ └── index.js └── view │ ├── Aboutpage │ ├── index.js │ ├── logo.jpg │ └── style.less │ ├── Contactpage │ ├── index.js │ ├── style.less │ └── tusiji.png │ ├── FundListpage │ ├── component.js │ ├── index.js │ └── style.less │ ├── Homepage │ ├── component.js │ ├── index.js │ └── style.less │ └── NotFound │ ├── index.js │ └── style.less ├── test ├── add.spec.js ├── index.spec.js └── test_helper.js.js ├── webpack.dev.config.js ├── webpack.dll.config.js └── webpack.prod.config.js /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["es2015", "stage-0", "react"] 3 | } 4 | -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | dist 2 | node_modules 3 | dependent 4 | coverage 5 | webpack.*.js 6 | *Server.js 7 | -------------------------------------------------------------------------------- /.eslintrc: -------------------------------------------------------------------------------- 1 | { 2 | "ecmaFeatures": { 3 | "jsx": true, 4 | "es6": true, 5 | "modules": true 6 | }, 7 | "env": { 8 | "browser": true, 9 | "node": true, 10 | "mocha": true 11 | }, 12 | "parser": "babel-eslint", 13 | "rules": { 14 | no-empty: ["error", { "allowEmptyCatch": true }], 15 | "strict": [2, "never"], 16 | "react/jsx-uses-react": "error", 17 | "react/jsx-uses-vars": "error", 18 | "no-console": ["error", { allow: ["warn", "error", "log"] }] 19 | }, 20 | "plugins": [ 21 | "react" 22 | ], 23 | "extends": ["eslint:recommended", "plugin:react/recommended"] 24 | } 25 | 26 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | build/ 3 | npm-debug.log 4 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 这是个主要使用 webpack + react + redux + es6 + cssModule 的 demo,包含 React 技术栈全家桶,可作为开发模板使用。 2 | 3 | 4 | 5 | ##主要功能特征 6 | - 使用热加载,文件改变页面自动刷新 7 | - 文件 Code Spliiting 按需加载 8 | - 使用 DllPlugin 将依赖文件独立打包 9 | - 使用 ESlint 检测 js 10 | - less->css,autoprefixer 11 | - 小于 8k 图片转化为 base64,图片压缩 12 | - 文件压缩、添加 MD5 13 | - 使用 Fetch,抛弃 Ajax 14 | 15 | --------- 16 | 17 | ####页面效果如下: 18 | 19 | ![demo](./demo.gif) 20 | 21 | 22 | --------- 23 | 24 | 25 | 26 | ## Requirements 27 | - [Node.js](https://nodejs.org) 28 | - [npm](https://www.npmjs.com/) 29 | - [webapck](https://webpack.github.io/) 30 | 31 | 32 | ## Usage 33 | ####安装 34 | ``` 35 | git clone https://github.com/rover5056/React-Redux-webpack.git 36 | cd boilerplate-webpack-react-es6-cssModule 37 | npm install 38 | ``` 39 | ####开始开发 40 | ``` 41 | //将 react、react-dom 单独打包 42 | npm run dll 43 | //启动服务器开始开发 44 | npm start 45 | ``` 46 | ####生产打包 47 | ``` 48 | npm run buil-win 49 | ``` 50 | 51 | ####启动接口 52 | 本项目的接口数据通过 `json-server` 配置,需全局安装并启动: 53 | 54 | ``` 55 | npm i -g json-server 56 | npm run mock 57 | ``` 58 | 59 | 接口将会在本地 3003 端口启动 60 | 61 | 62 | ## Linting 63 | 本项目使用 ESlint,项目开发过程中会自动检测 js 64 | 65 | 也可手动检测: 66 | ``` 67 | npm run lint src 68 | ``` 69 | 70 | 检测完毕会在命令行显示所有纠错提示 71 | 72 | 73 | ## Dependencies 74 | - [React](https://github.com/facebook/react) 75 | - [React-router](https://github.com/reactjs/react-router) 76 | - [redux](https://github.com/reactjs/redux) 77 | - [fetch](https://github.com/github/fetch) 78 | - [postcss](https://github.com/postcss/postcss) 79 | - [eslint](https://github.com/eslint/eslint) 80 | - [babel-loader](https://github.com/babel/babel-loader) 81 | - [react-hot-loader](https://github.com/gaearon/react-hot-loader) 82 | 83 | -------------------------------------------------------------------------------- /README_en.md: -------------------------------------------------------------------------------- 1 | 2 | This repo is a boilerplate for webpack-react-es6-cssModule project. You could use it as a base to build your own web app. 3 | 4 | 5 | ### Requirements 6 | First you'll need [Node.js](https://nodejs.org) and the package manager 7 | that comes with it: [npm](https://www.npmjs.com/). 8 | 9 | 10 | Once you've got that working, head to the command line where we'll set 11 | up our project. 12 | 13 | ### Usage 14 | First, clone the repo and install the dependencies. 15 | 16 | ``` 17 | git clone https://github.com/tumars/boilerplate-webpack-react-es6-cssModule 18 | cd boilerplate-webpack-react-es6-cssModule 19 | npm install 20 | npm start 21 | ``` 22 | 23 | Now open up [http://localhost:3000](http://localhost:3000) 24 | 25 | ### Linting 26 | 27 | This boilerplate project includes React-friendly ESLint configuration. 28 | 29 | ``` 30 | npm run lint 31 | ``` 32 | 33 | ### Using `0.0.0.0` as Host 34 | 35 | You may want to change the host in `server.js` and `webpack.config.js` from `localhost` to `0.0.0.0` to allow access from same WiFi network. This is not enabled by default because it is reported to cause problems on Windows. This may also be useful if you're using a VM. 36 | 37 | 38 | ### Dependencies 39 | 40 | * React 41 | * React-router 42 | * Webpack 43 | * [webpack-dev-server](https://github.com/webpack/webpack-dev-server) 44 | * [babel-loader](https://github.com/babel/babel-loader) 45 | * [react-hot-loader](https://github.com/gaearon/react-hot-loader) 46 | 47 | ### Resources 48 | 49 | * [react-hot-loader on Github](https://github.com/gaearon/react-hot-loader) 50 | * [Integrating JSX live reload into your workflow](http://gaearon.github.io/react-hot-loader/getstarted/) 51 | * [Troubleshooting guide](https://github.com/gaearon/react-hot-loader/blob/master/docs/Troubleshooting.md) 52 | * [react-router-tutorial](https://github.com/reactjs/react-router-tutoria) -------------------------------------------------------------------------------- /demo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rover5056/React-Redux-webpack/37a914786fc47f227a743a8fe8021e75a4168300/demo.gif -------------------------------------------------------------------------------- /dist/Aboutpage-8a75c.chunk.js: -------------------------------------------------------------------------------- 1 | webpackJsonp([4],{136:function(A,e,a){"use strict";function t(A){return A&&A.__esModule?A:{default:A}}Object.defineProperty(e,"__esModule",{value:!0});var l=a(4),p=t(l),u=a(23),n=a(156),i=t(n),m=function(){return p.default.createElement("div",{className:i.default.content},p.default.createElement("h1",null,"About"),p.default.createElement("p",null,"This is a boilerplate for webpack-react-es6-cssModule project. You could use it as a base to build your own web app."),p.default.createElement("p",null,"You can get update and more information in this github repo:"),p.default.createElement("p",null,p.default.createElement("a",{href:"https://github.com/tumars/boilerplate-webpack-react-es6-cssModule"},"https://github.com/tumars/boilerplate-webpack-react-es6-cssModule")),p.default.createElement(u.IndexLink,{to:"/",className:"btn-primary"},"Back to Home"),p.default.createElement("div",{className:i.default.logo}))};e.default=m},144:function(A,e,a){e=A.exports=a(17)(),e.push([A.id,".style-content-3jVKl h1{line-height:3;font-size:40px;font-weight:700;text-align:center}.style-content-3jVKl p{width:280px;margin:15px auto;line-height:1.5;color:#333}.style-content-3jVKl p a{color:#49a0ff}.style-content-3jVKl .style-logo-2QWwR{background:url("+a(297)+") no-repeat;background-size:100%;width:60px;height:60px;margin:20px auto}",""]),e.locals={content:"style-content-3jVKl",logo:"style-logo-2QWwR"}},156:function(A,e,a){var t=a(144);"string"==typeof t&&(t=[[A.id,t,""]]),a(19)(t,{}),t.locals&&(A.exports=t.locals)},297:function(A,e){A.exports="data:image/jpeg;base64,/9j/4AAQSkZJR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q0VbVU2Q2ShkthpjHKNNWo1pE6zdPzPro7iyxGz7f50vMmJRisI5RJSTJliwR7ij5J44FcFxJo3b8764ywKfvllO8TrgoxJb1axbxYLepo9bmPeJM9VZDfZxH/UE2sEd/mlg9fmaq/zp8+l9LfVXU5v2J1uDw/sPx0Ol+osUTUbNBYUSOxVccMns8lfwRLZqoxwent28CW3RSPpHzwV0qv4LKuch6SOCdfF9D6dlnGNuWajWqvUJ59iWqrlXmLKtyxqMTJzomuWT6muN5OVbXLJK6HmEsCtXIlL2Lpcn0PphJweUStlL5I3zSxkc23kWpn8ZHJt5PPnjGRybPOljByecitkN5+434J9S+0x+CRxx9v/2Q=="}}); -------------------------------------------------------------------------------- /dist/Contactpage-8a75c.chunk.js: -------------------------------------------------------------------------------- 1 | webpackJsonp([3],{137:function(e,t,l){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var a=l(4),c=n(a),i=l(23),u=l(157),o=n(u),r=function(){return c.default.createElement("div",{className:o.default.content},c.default.createElement("h1",null,"Contact me"),c.default.createElement("ul",null,c.default.createElement("li",null,"Email: ",c.default.createElement("a",{href:"javascript:;"},"menghui9898@gmail.com")),c.default.createElement("li",null,"Blog: ",c.default.createElement("a",{href:"https://www.ferecord.com"},"www.ferecord.com")),c.default.createElement("li",null,"Twitter: ",c.default.createElement("a",{href:"https://twitter.com/Tumars"},"Tumars"))),c.default.createElement(i.IndexLink,{to:"/",className:"btn-primary"},"Back to Home"),c.default.createElement("div",{className:o.default.tusiji}))};t.default=r},145:function(e,t,l){t=e.exports=l(17)(),t.push([e.id,".style-content-OHFC9 h1{line-height:4;font-size:30px;text-align:center}.style-content-OHFC9 ul{display:block;width:300px;margin:0 auto}.style-content-OHFC9 li{line-height:2;color:#333}.style-content-OHFC9 li a{color:#49a0ff}.style-content-OHFC9 .style-tusiji-1Q-s0{background:url("+l(298)+") no-repeat;background-size:100%;width:170.66666667px;height:170.66666667px;margin:20px auto}",""]),t.locals={content:"style-content-OHFC9",tusiji:"style-tusiji-1Q-s0"}},157:function(e,t,l){var n=l(145);"string"==typeof n&&(n=[[e.id,n,""]]),l(19)(n,{}),n.locals&&(e.exports=n.locals)},298:function(e,t,l){e.exports=l.p+"img/4c8c0d3b.tusiji.png"}}); -------------------------------------------------------------------------------- /dist/FundListContainer-8a75c.chunk.js: -------------------------------------------------------------------------------- 1 | webpackJsonp([1],{46:function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;ndiv{position:fixed;top:50%;left:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);box-sizing:border-box}.spin-laballspin-2LrMx{display:block;font-size:0;color:#333}.spin-laballspin-2LrMx.spin-la-dark-1KlJY{color:#333}.spin-laballspin-2LrMx>div{display:inline-block;float:none;background-color:currentColor;border:0 solid currentColor}.spin-laballspin-2LrMx{width:32px;height:32px}.spin-laballspin-2LrMx>div{position:absolute;top:50%;left:50%;width:8px;height:8px;margin-top:-4px;margin-left:-4px;border-radius:100%;-webkit-animation:spin-ball-spin-3cuzS 1s infinite ease-in-out;animation:spin-ball-spin-3cuzS 1s infinite ease-in-out}.spin-laballspin-2LrMx>div:nth-child(1){top:5%;left:50%;-webkit-animation-delay:-1.125s;animation-delay:-1.125s}.spin-laballspin-2LrMx>div:nth-child(2){top:18.18019485%;left:81.81980515%;-webkit-animation-delay:-1.25s;animation-delay:-1.25s}.spin-laballspin-2LrMx>div:nth-child(3){top:50%;left:95%;-webkit-animation-delay:-1.375s;animation-delay:-1.375s}.spin-laballspin-2LrMx>div:nth-child(4){top:81.81980515%;left:81.81980515%;-webkit-animation-delay:-1.5s;animation-delay:-1.5s}.spin-laballspin-2LrMx>div:nth-child(5){top:95%;left:50%;-webkit-animation-delay:-1.625s;animation-delay:-1.625s}.spin-laballspin-2LrMx>div:nth-child(6){top:81.8198047%;left:18.18019492%;-webkit-animation-delay:-1.75s;animation-delay:-1.75s}.spin-laballspin-2LrMx>div:nth-child(7){top:49.99997508%;left:5.00000512%;-webkit-animation-delay:-1.875s;animation-delay:-1.875s}.spin-laballspin-2LrMx>div:nth-child(8){top:18.17946497%;left:18.18037005%;-webkit-animation-delay:-2s;animation-delay:-2s}.spin-laballspin-2LrMx.spin-la-sm-2MZyy{width:16px;height:16px}.spin-laballspin-2LrMx.spin-la-sm-2MZyy>div{width:4px;height:4px;margin-top:-2px;margin-left:-2px}.spin-laballspin-2LrMx.spin-la-2x-1om4p{width:64px;height:64px}.spin-laballspin-2LrMx.spin-la-2x-1om4p>div{width:16px;height:16px;margin-top:-8px;margin-left:-8px}.spin-laballspin-2LrMx.spin-la-3x-320-W{width:96px;height:96px}.spin-laballspin-2LrMx.spin-la-3x-320-W>div{width:24px;height:24px;margin-top:-12px;margin-left:-12px}@-webkit-keyframes spin-ball-spin-3cuzS{0%,to{opacity:1;-webkit-transform:scale(1);transform:scale(1)}20%{opacity:1}80%{opacity:0;-webkit-transform:scale(0);transform:scale(0)}}@keyframes spin-ball-spin-3cuzS{0%,to{opacity:1;-webkit-transform:scale(1);transform:scale(1)}20%{opacity:1}80%{opacity:0;-webkit-transform:scale(0);transform:scale(0)}}",""]),t.locals={dyy:"spin-dyy-oX8Ta",laballspin:"spin-laballspin-2LrMx","la-dark":"spin-la-dark-1KlJY","ball-spin":"spin-ball-spin-3cuzS","la-sm":"spin-la-sm-2MZyy","la-2x":"spin-la-2x-1om4p","la-3x":"spin-la-3x-320-W"}},146:function(e,t,n){t=e.exports=n(17)(),t.push([e.id,".style-content-5Ws7D{display:block;width:100%;height:100%;background:#eee}.style-content-5Ws7D h1{line-height:3;font-size:40px;font-weight:700;text-align:center}.style-content-5Ws7D .style-funditem-3NcNe{display:block;width:100%;box-sizing:border-box;margin:5px auto;padding:0 10px;line-height:3;background-color:#fff}.style-content-5Ws7D .style-funditem-3NcNe i{font-weight:700;margin-right:10px}.style-content-5Ws7D .style-bottom-2uOYB{display:block;width:100%;margin:10px auto}.style-content-5Ws7D .style-bottom-2uOYB div{display:inline-block;width:25%;box-sizing:border-box;padding:5px 10px;border:1px solid #eee;color:#fff;text-align:center;background-color:#49a0ff}.style-content-5Ws7D .style-bottom-2uOYB div:first-child{color:#49a0ff;background-color:#fff}",""]),t.locals={content:"style-content-5Ws7D",funditem:"style-funditem-3NcNe",bottom:"style-bottom-2uOYB"}},152:function(e,t,n){var i=n(143);"string"==typeof i&&(i=[[e.id,i,""]]),n(19)(i,{}),i.locals&&(e.exports=i.locals)},158:function(e,t,n){var i=n(146);"string"==typeof i&&(i=[[e.id,i,""]]),n(19)(i,{}),i.locals&&(e.exports=i.locals)}}); -------------------------------------------------------------------------------- /dist/HomeContainer-8a75c.chunk.js: -------------------------------------------------------------------------------- 1 | webpackJsonp([2],{46:function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function r(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var a=function(){function e(e,t){for(var n=0;n1){for(var h=Array(y),m=0;m1){for(var g=Array(b),E=0;E>"),O={array:u("array"),bool:u("boolean"),func:u("function"),number:u("number"),object:u("object"),string:u("string"),symbol:u("symbol"),any:a(),arrayOf:s,element:c(),instanceOf:l,node:v(),objectOf:p,oneOf:f,oneOfType:d,shape:y};o.prototype=Error.prototype,e.exports=O},{12:12,14:14,19:19,23:23,26:26,9:9}],14:[function(t,e,n){"use strict";var r="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";e.exports=r},{}],15:[function(t,e,n){"use strict";function r(t,e,n){this.props=t,this.context=e,this.refs=s,this.updater=n||a}function o(){}var i=t(27),u=t(6),a=t(11),s=t(24);o.prototype=u.prototype,r.prototype=new o,r.prototype.constructor=r,i(r.prototype,u.prototype),r.prototype.isPureReactComponent=!0,e.exports=r},{11:11,24:24,27:27,6:6}],16:[function(t,e,n){"use strict";var r=t(27),o=t(3),i=r({__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:{ReactCurrentOwner:t(7)}},o);e.exports=i},{27:27,3:3,7:7}],17:[function(t,e,n){"use strict";e.exports="15.4.1"},{}],18:[function(t,e,n){"use strict";var r=!1;e.exports=r},{}],19:[function(t,e,n){"use strict";function r(t){var e=t&&(o&&t[o]||t[i]);if("function"==typeof e)return e}var o="function"==typeof Symbol&&Symbol.iterator,i="@@iterator";e.exports=r},{}],20:[function(t,e,n){"use strict";function r(t){return i.isValidElement(t)?void 0:o("143"),t}var o=t(21),i=t(9);t(25);e.exports=r},{21:21,25:25,9:9}],21:[function(t,e,n){"use strict";function r(t){for(var e=arguments.length-1,n="Minified React error #"+t+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant="+t,r=0;r8&&b<=11),w=32,T=String.fromCharCode(w),k={beforeInput:{phasedRegistrationNames:{bubbled:"onBeforeInput",captured:"onBeforeInputCapture"},dependencies:["topCompositionEnd","topKeyPress","topTextInput","topPaste"]},compositionEnd:{phasedRegistrationNames:{bubbled:"onCompositionEnd",captured:"onCompositionEndCapture"},dependencies:["topBlur","topCompositionEnd","topKeyDown","topKeyPress","topKeyUp","topMouseDown"]},compositionStart:{phasedRegistrationNames:{bubbled:"onCompositionStart",captured:"onCompositionStartCapture"},dependencies:["topBlur","topCompositionStart","topKeyDown","topKeyPress","topKeyUp","topMouseDown"]},compositionUpdate:{phasedRegistrationNames:{bubbled:"onCompositionUpdate",captured:"onCompositionUpdateCapture"},dependencies:["topBlur","topCompositionUpdate","topKeyDown","topKeyPress","topKeyUp","topMouseDown"]}},P=!1,N=null,S={eventTypes:k,extractEvents:function(e,t,n,r){return[l(e,t,n,r),d(e,t,n,r)]}};t.exports=S},{123:123,19:19,20:20,78:78,82:82}],4:[function(e,t,n){"use strict";function r(e,t){return e+t.charAt(0).toUpperCase()+t.substring(1)}var o={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridColumn:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},i=["Webkit","ms","Moz","O"];Object.keys(o).forEach(function(e){i.forEach(function(t){o[r(t,e)]=o[e]})});var a={background:{backgroundAttachment:!0,backgroundColor:!0,backgroundImage:!0,backgroundPositionX:!0,backgroundPositionY:!0,backgroundRepeat:!0},backgroundPosition:{backgroundPositionX:!0,backgroundPositionY:!0},border:{borderWidth:!0,borderStyle:!0,borderColor:!0},borderBottom:{borderBottomWidth:!0,borderBottomStyle:!0,borderBottomColor:!0},borderLeft:{borderLeftWidth:!0,borderLeftStyle:!0,borderLeftColor:!0},borderRight:{borderRightWidth:!0,borderRightStyle:!0,borderRightColor:!0},borderTop:{borderTopWidth:!0,borderTopStyle:!0,borderTopColor:!0},font:{fontStyle:!0,fontVariant:!0,fontWeight:!0,fontSize:!0,lineHeight:!0,fontFamily:!0},outline:{outlineWidth:!0,outlineStyle:!0,outlineColor:!0}},s={isUnitlessNumber:o,shorthandPropertyExpansions:a};t.exports=s},{}],5:[function(e,t,n){"use strict";var r=e(4),o=e(123),i=(e(58),e(125),e(94)),a=e(136),s=e(140),u=(e(142),s(function(e){return a(e)})),l=!1,c="cssFloat";if(o.canUseDOM){var p=document.createElement("div").style;try{p.font=""}catch(e){l=!0}void 0===document.documentElement.style.cssFloat&&(c="styleFloat")}var d={createMarkupForStyles:function(e,t){var n="";for(var r in e)if(e.hasOwnProperty(r)){var o=e[r];null!=o&&(n+=u(r)+":",n+=i(r,o,t)+";")}return n||null},setValueForStyles:function(e,t,n){var o=e.style;for(var a in t)if(t.hasOwnProperty(a)){var s=i(a,t[a],n);if("float"!==a&&"cssFloat"!==a||(a=c),s)o[a]=s;else{var u=l&&r.shorthandPropertyExpansions[a];if(u)for(var p in u)o[p]="";else o[a]=""}}}};t.exports=d},{123:123,125:125,136:136,140:140,142:142,4:4,58:58,94:94}],6:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=e(113),i=e(24),a=(e(137),function(){function e(t){r(this,e),this._callbacks=null,this._contexts=null,this._arg=t}return e.prototype.enqueue=function(e,t){this._callbacks=this._callbacks||[],this._callbacks.push(e),this._contexts=this._contexts||[],this._contexts.push(t)},e.prototype.notifyAll=function(){var e=this._callbacks,t=this._contexts,n=this._arg;if(e&&t){e.length!==t.length?o("24"):void 0,this._callbacks=null,this._contexts=null;for(var r=0;r8));var R=!1;C.canUseDOM&&(R=T("input")&&(!document.documentMode||document.documentMode>11));var A={get:function(){return I.get.call(this)},set:function(e){M=""+e,I.set.call(this,e)}},D={eventTypes:P,extractEvents:function(e,t,n,o){var i,a,s=t?b.getNodeFromInstance(t):window;if(r(s)?O?i=u:a=l:k(s)?R?i=f:(i=m,a=h):v(s)&&(i=g),i){var c=i(e,t);if(c){var p=x.getPooled(P.change,c,n,o);return p.type="change",_.accumulateTwoPhaseDispatches(p),p}}a&&a(e,s,t)}};t.exports=D},{102:102,110:110,111:111,123:123,16:16,19:19,33:33,71:71,80:80}],8:[function(e,t,n){"use strict";function r(e,t){return Array.isArray(t)&&(t=t[1]),t?t.nextSibling:e.firstChild}function o(e,t,n){c.insertTreeBefore(e,t,n)}function i(e,t,n){Array.isArray(t)?s(e,t[0],t[1],n):m(e,t,n)}function a(e,t){if(Array.isArray(t)){var n=t[1];t=t[0],u(e,t,n),e.removeChild(n)}e.removeChild(t)}function s(e,t,n,r){for(var o=t;;){var i=o.nextSibling;if(m(e,o,r),o===n)break;o=i}}function u(e,t,n){for(;;){var r=t.nextSibling;if(r===n)break;e.removeChild(r)}}function l(e,t,n){var r=e.parentNode,o=e.nextSibling;o===t?n&&m(r,document.createTextNode(n),o):n?(h(o,n),u(r,o,t)):u(r,e,t)}var c=e(9),p=e(13),d=(e(33),e(58),e(93)),f=e(115),h=e(116),m=d(function(e,t,n){e.insertBefore(t,n)}),v=p.dangerouslyReplaceNodeWithMarkup,g={dangerouslyReplaceNodeWithMarkup:v,replaceDelimitedText:l,processUpdates:function(e,t){for(var n=0;n-1?void 0:a("96",e),!l.plugins[n]){t.extractEvents?void 0:a("97",e),l.plugins[n]=t;var r=t.eventTypes;for(var i in r)o(r[i],t,i)?void 0:a("98",i,e)}}}function o(e,t,n){l.eventNameDispatchConfigs.hasOwnProperty(n)?a("99",n):void 0,l.eventNameDispatchConfigs[n]=e;var r=e.phasedRegistrationNames;if(r){for(var o in r)if(r.hasOwnProperty(o)){var s=r[o];i(s,t,n)}return!0}return!!e.registrationName&&(i(e.registrationName,t,n),!0)}function i(e,t,n){l.registrationNameModules[e]?a("100",e):void 0,l.registrationNameModules[e]=t,l.registrationNameDependencies[e]=t.eventTypes[n].dependencies}var a=e(113),s=(e(137),null),u={},l={plugins:[],eventNameDispatchConfigs:{},registrationNameModules:{},registrationNameDependencies:{},possibleRegistrationNames:null,injectEventPluginOrder:function(e){s?a("101"):void 0,s=Array.prototype.slice.call(e),r()},injectEventPluginsByName:function(e){var t=!1;for(var n in e)if(e.hasOwnProperty(n)){var o=e[n];u.hasOwnProperty(n)&&u[n]===o||(u[n]?a("102",n):void 0,u[n]=o,t=!0)}t&&r()},getPluginModuleForEvent:function(e){var t=e.dispatchConfig;if(t.registrationName)return l.registrationNameModules[t.registrationName]||null;if(void 0!==t.phasedRegistrationNames){var n=t.phasedRegistrationNames;for(var r in n)if(n.hasOwnProperty(r)){var o=l.registrationNameModules[n[r]];if(o)return o}}return null},_resetEventPlugins:function(){s=null;for(var e in u)u.hasOwnProperty(e)&&delete u[e];l.plugins.length=0;var t=l.eventNameDispatchConfigs;for(var n in t)t.hasOwnProperty(n)&&delete t[n];var r=l.registrationNameModules;for(var o in r)r.hasOwnProperty(o)&&delete r[o]}};t.exports=l},{113:113,137:137}],18:[function(e,t,n){"use strict";function r(e){return"topMouseUp"===e||"topTouchEnd"===e||"topTouchCancel"===e}function o(e){return"topMouseMove"===e||"topTouchMove"===e}function i(e){return"topMouseDown"===e||"topTouchStart"===e}function a(e,t,n,r){var o=e.type||"unknown-event";e.currentTarget=g.getNodeFromInstance(r),t?m.invokeGuardedCallbackWithCatch(o,n,e):m.invokeGuardedCallback(o,n,e),e.currentTarget=null}function s(e,t){var n=e._dispatchListeners,r=e._dispatchInstances;if(Array.isArray(n))for(var o=0;o1?1-t:void 0;return this._fallbackText=o.slice(e,s),this._fallbackText}}),i.addPoolingTo(r),t.exports=r},{107:107,143:143,24:24}],21:[function(e,t,n){"use strict";var r=e(11),o=r.injection.MUST_USE_PROPERTY,i=r.injection.HAS_BOOLEAN_VALUE,a=r.injection.HAS_NUMERIC_VALUE,s=r.injection.HAS_POSITIVE_NUMERIC_VALUE,u=r.injection.HAS_OVERLOADED_BOOLEAN_VALUE,l={isCustomAttribute:RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+r.ATTRIBUTE_NAME_CHAR+"]*$")),Properties:{accept:0,acceptCharset:0,accessKey:0,action:0,allowFullScreen:i,allowTransparency:0,alt:0,as:0,async:i,autoComplete:0,autoPlay:i,capture:i,cellPadding:0,cellSpacing:0,charSet:0,challenge:0,checked:o|i,cite:0,classID:0,className:0,cols:s,colSpan:0,content:0,contentEditable:0,contextMenu:0,controls:i,coords:0,crossOrigin:0,data:0,dateTime:0,default:i,defer:i,dir:0,disabled:i,download:u,draggable:0,encType:0,form:0,formAction:0,formEncType:0,formMethod:0,formNoValidate:i,formTarget:0,frameBorder:0,headers:0,height:0,hidden:i,high:0,href:0,hrefLang:0,htmlFor:0,httpEquiv:0,icon:0,id:0,inputMode:0,integrity:0,is:0,keyParams:0,keyType:0,kind:0,label:0,lang:0,list:0,loop:i,low:0,manifest:0,marginHeight:0,marginWidth:0,max:0,maxLength:0,media:0,mediaGroup:0,method:0,min:0,minLength:0,multiple:o|i,muted:o|i,name:0,nonce:0,noValidate:i,open:i,optimum:0,pattern:0,placeholder:0,playsInline:i,poster:0,preload:0,profile:0,radioGroup:0,readOnly:i,referrerPolicy:0,rel:0,required:i,reversed:i,role:0,rows:s,rowSpan:a,sandbox:0,scope:0,scoped:i,scrolling:0,seamless:i,selected:o|i,shape:0,size:s,sizes:0,span:s,spellCheck:0,src:0,srcDoc:0,srcLang:0,srcSet:0,start:a,step:0,style:0,summary:0,tabIndex:0,target:0,title:0,type:0,useMap:0,value:0,width:0,wmode:0,wrap:0,about:0,datatype:0,inlist:0,prefix:0,property:0,resource:0,typeof:0,vocab:0,autoCapitalize:0,autoCorrect:0,autoSave:0,color:0,itemProp:0,itemScope:i,itemType:0,itemID:0,itemRef:0,results:0,security:0,unselectable:0},DOMAttributeNames:{acceptCharset:"accept-charset",className:"class",htmlFor:"for",httpEquiv:"http-equiv"},DOMPropertyNames:{}};t.exports=l},{11:11}],22:[function(e,t,n){"use strict";function r(e){var t=/[=:]/g,n={"=":"=0",":":"=2"},r=(""+e).replace(t,function(e){return n[e]});return"$"+r}function o(e){var t=/(=0|=2)/g,n={"=0":"=","=2":":"},r="."===e[0]&&"$"===e[1]?e.substring(2):e.substring(1);return(""+r).replace(t,function(e){return n[e]})}var i={escape:r,unescape:o};t.exports=i},{}],23:[function(e,t,n){"use strict";function r(e){null!=e.checkedLink&&null!=e.valueLink?s("87"):void 0}function o(e){r(e),null!=e.value||null!=e.onChange?s("88"):void 0}function i(e){r(e),null!=e.checked||null!=e.onChange?s("89"):void 0}function a(e){if(e){var t=e.getName();if(t)return" Check the render method of `"+t+"`."}return""}var s=e(113),u=e(121),l=e(64),c=(e(137),e(142),{button:!0,checkbox:!0,image:!0,hidden:!0,radio:!0,reset:!0,submit:!0}),p={value:function(e,t,n){return!e[t]||c[e.type]||e.onChange||e.readOnly||e.disabled?null:new Error("You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`.")},checked:function(e,t,n){return!e[t]||e.onChange||e.readOnly||e.disabled?null:new Error("You provided a `checked` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultChecked`. Otherwise, set either `onChange` or `readOnly`.")},onChange:u.PropTypes.func},d={},f={checkPropTypes:function(e,t,n){for(var r in p){if(p.hasOwnProperty(r))var o=p[r](t,r,e,"prop",null,l);o instanceof Error&&!(o.message in d)&&(d[o.message]=!0,a(n))}},getValue:function(e){return e.valueLink?(o(e),e.valueLink.value):e.value},getChecked:function(e){return e.checkedLink?(i(e),e.checkedLink.value):e.checked},executeOnChange:function(e,t){return e.valueLink?(o(e),e.valueLink.requestChange(t.target.value)):e.checkedLink?(i(e),e.checkedLink.requestChange(t.target.checked)):e.onChange?e.onChange.call(void 0,t):void 0}};t.exports=f},{113:113,121:121,137:137,142:142,64:64}],24:[function(e,t,n){"use strict";var r=e(113),o=(e(137),function(e){var t=this;if(t.instancePool.length){var n=t.instancePool.pop();return t.call(n,e),n}return new t(e)}),i=function(e,t){var n=this;if(n.instancePool.length){var r=n.instancePool.pop();return n.call(r,e,t),r}return new n(e,t)},a=function(e,t,n){var r=this;if(r.instancePool.length){var o=r.instancePool.pop();return r.call(o,e,t,n),o}return new r(e,t,n)},s=function(e,t,n,r){var o=this;if(o.instancePool.length){var i=o.instancePool.pop();return o.call(i,e,t,n,r),i}return new o(e,t,n,r)},u=function(e,t,n,r,o){var i=this;if(i.instancePool.length){var a=i.instancePool.pop();return i.call(a,e,t,n,r,o),a}return new i(e,t,n,r,o)},l=function(e){var t=this;e instanceof t?void 0:r("25"),e.destructor(),t.instancePool.length=0||null!=t.is}function h(e){var t=e.type;d(t),this._currentElement=e,this._tag=t.toLowerCase(),this._namespaceURI=null,this._renderedChildren=null,this._previousStyle=null,this._previousStyleCopy=null,this._hostNode=null,this._hostParent=null,this._rootNodeID=0,this._domID=0,this._hostContainerInfo=null,this._wrapperState=null,this._topLevelWrapper=null,this._flags=0}var m=e(113),v=e(143),g=e(2),y=e(5),_=e(9),C=e(10),b=e(11),E=e(12),x=e(16),w=e(17),T=e(25),k=e(32),P=e(33),N=e(38),S=e(39),M=e(40),I=e(43),O=(e(58),e(61)),R=e(68),A=(e(129),e(95)),D=(e(137),e(110),e(141),e(119),e(142),k),L=x.deleteListener,U=P.getNodeFromInstance,F=T.listenTo,B=w.registrationNameModules,V={string:!0,number:!0},j="style",W="__html",H={children:null,dangerouslySetInnerHTML:null,suppressContentEditableWarning:null},q=11,K={topAbort:"abort",topCanPlay:"canplay",topCanPlayThrough:"canplaythrough",topDurationChange:"durationchange",topEmptied:"emptied",topEncrypted:"encrypted",topEnded:"ended",topError:"error",topLoadedData:"loadeddata",topLoadedMetadata:"loadedmetadata",topLoadStart:"loadstart",topPause:"pause",topPlay:"play",topPlaying:"playing",topProgress:"progress",topRateChange:"ratechange",topSeeked:"seeked",topSeeking:"seeking",topStalled:"stalled",topSuspend:"suspend",topTimeUpdate:"timeupdate",topVolumeChange:"volumechange",topWaiting:"waiting"},z={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},Y={listing:!0,pre:!0,textarea:!0},X=v({menuitem:!0},z),Q=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,G={},$={}.hasOwnProperty,Z=1;h.displayName="ReactDOMComponent",h.Mixin={mountComponent:function(e,t,n,r){this._rootNodeID=Z++,this._domID=n._idCounter++,this._hostParent=t,this._hostContainerInfo=n;var i=this._currentElement.props;switch(this._tag){case"audio":case"form":case"iframe":case"img":case"link":case"object":case"source":case"video":this._wrapperState={listeners:null},e.getReactMountReady().enqueue(c,this);break;case"input":N.mountWrapper(this,i,t),i=N.getHostProps(this,i),e.getReactMountReady().enqueue(c,this);break;case"option":S.mountWrapper(this,i,t),i=S.getHostProps(this,i);break;case"select":M.mountWrapper(this,i,t),i=M.getHostProps(this,i),e.getReactMountReady().enqueue(c,this);break;case"textarea":I.mountWrapper(this,i,t),i=I.getHostProps(this,i),e.getReactMountReady().enqueue(c,this)}o(this,i);var a,p;null!=t?(a=t._namespaceURI,p=t._tag):n._tag&&(a=n._namespaceURI,p=n._tag),(null==a||a===C.svg&&"foreignobject"===p)&&(a=C.html),a===C.html&&("svg"===this._tag?a=C.svg:"math"===this._tag&&(a=C.mathml)),this._namespaceURI=a;var d;if(e.useCreateElement){var f,h=n._ownerDocument;if(a===C.html)if("script"===this._tag){var m=h.createElement("div"),v=this._currentElement.type;m.innerHTML="<"+v+">",f=m.removeChild(m.firstChild)}else f=i.is?h.createElement(this._currentElement.type,i.is):h.createElement(this._currentElement.type);else f=h.createElementNS(a,this._currentElement.type);P.precacheNode(this,f),this._flags|=D.hasCachedChildNodes,this._hostParent||E.setAttributeForRoot(f),this._updateDOMProperties(null,i,e);var y=_(f);this._createInitialChildren(e,i,r,y),d=y}else{var b=this._createOpenTagMarkupAndPutListeners(e,i),x=this._createContentMarkup(e,i,r);d=!x&&z[this._tag]?b+"/>":b+">"+x+""}switch(this._tag){case"input":e.getReactMountReady().enqueue(s,this),i.autoFocus&&e.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"textarea":e.getReactMountReady().enqueue(u,this),i.autoFocus&&e.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"select":i.autoFocus&&e.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"button":i.autoFocus&&e.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"option":e.getReactMountReady().enqueue(l,this)}return d},_createOpenTagMarkupAndPutListeners:function(e,t){var n="<"+this._currentElement.type;for(var r in t)if(t.hasOwnProperty(r)){var o=t[r];if(null!=o)if(B.hasOwnProperty(r))o&&i(this,r,o,e);else{r===j&&(o&&(o=this._previousStyleCopy=v({},t.style)),o=y.createMarkupForStyles(o,this));var a=null;null!=this._tag&&f(this._tag,t)?H.hasOwnProperty(r)||(a=E.createMarkupForCustomAttribute(r,o)):a=E.createMarkupForProperty(r,o),a&&(n+=" "+a)}}return e.renderToStaticMarkup?n:(this._hostParent||(n+=" "+E.createMarkupForRoot()),n+=" "+E.createMarkupForID(this._domID))},_createContentMarkup:function(e,t,n){var r="",o=t.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&(r=o.__html);else{var i=V[typeof t.children]?t.children:null,a=null!=i?null:t.children;if(null!=i)r=A(i);else if(null!=a){var s=this.mountChildren(a,e,n);r=s.join("")}}return Y[this._tag]&&"\n"===r.charAt(0)?"\n"+r:r},_createInitialChildren:function(e,t,n,r){var o=t.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&_.queueHTML(r,o.__html);else{var i=V[typeof t.children]?t.children:null,a=null!=i?null:t.children;if(null!=i)_.queueText(r,i);else if(null!=a)for(var s=this.mountChildren(a,e,n),u=0;u"},receiveComponent:function(){},getHostNode:function(){return i.getNodeFromInstance(this)},unmountComponent:function(){i.uncacheNode(this)}}),t.exports=a},{143:143,33:33,9:9}],36:[function(e,t,n){"use strict";var r={useCreateElement:!0,useFiber:!1};t.exports=r},{}],37:[function(e,t,n){"use strict";var r=e(8),o=e(33),i={dangerouslyProcessChildrenUpdates:function(e,t){var n=o.getNodeFromInstance(e);r.processUpdates(n,t)}};t.exports=i},{33:33,8:8}],38:[function(e,t,n){"use strict";function r(){this._rootNodeID&&p.updateWrapper(this)}function o(e){var t=this._currentElement.props,n=u.executeOnChange(t,e);c.asap(r,this);var o=t.name;if("radio"===t.type&&null!=o){for(var a=l.getNodeFromInstance(this),s=a;s.parentNode;)s=s.parentNode;for(var p=s.querySelectorAll("input[name="+JSON.stringify(""+o)+'][type="radio"]'),d=0;dt.end?(n=t.end,r=t.start):(n=t.start,r=t.end),o.moveToElementText(e),o.moveStart("character",n),o.setEndPoint("EndToStart",o),o.moveEnd("character",r-n),o.select()}function s(e,t){if(window.getSelection){var n=window.getSelection(),r=e[c()].length,o=Math.min(t.start,r),i=void 0===t.end?o:Math.min(t.end,r);if(!n.extend&&o>i){var a=i;i=o,o=a}var s=l(e,o),u=l(e,i);if(s&&u){var p=document.createRange();p.setStart(s.node,s.offset),n.removeAllRanges(),o>i?(n.addRange(p),n.extend(u.node,u.offset)):(p.setEnd(u.node,u.offset),n.addRange(p))}}}var u=e(123),l=e(106),c=e(107),p=u.canUseDOM&&"selection"in document&&!("getSelection"in window),d={getOffsets:p?o:i,setOffsets:p?a:s};t.exports=d},{106:106,107:107,123:123}],42:[function(e,t,n){"use strict";var r=e(113),o=e(143),i=e(8),a=e(9),s=e(33),u=e(95),l=(e(137),e(119),function(e){this._currentElement=e,this._stringText=""+e,this._hostNode=null,this._hostParent=null,this._domID=0,this._mountIndex=0,this._closingComment=null,this._commentNodes=null});o(l.prototype,{mountComponent:function(e,t,n,r){var o=n._idCounter++,i=" react-text: "+o+" ",l=" /react-text "; 84 | if(this._domID=o,this._hostParent=t,e.useCreateElement){var c=n._ownerDocument,p=c.createComment(i),d=c.createComment(l),f=a(c.createDocumentFragment());return a.queueChild(f,a(p)),this._stringText&&a.queueChild(f,a(c.createTextNode(this._stringText))),a.queueChild(f,a(d)),s.precacheNode(this,p),this._closingComment=d,f}var h=u(this._stringText);return e.renderToStaticMarkup?h:""+h+""},receiveComponent:function(e,t){if(e!==this._currentElement){this._currentElement=e;var n=""+e;if(n!==this._stringText){this._stringText=n;var r=this.getHostNode();i.replaceDelimitedText(r[0],r[1],n)}}},getHostNode:function(){var e=this._commentNodes;if(e)return e;if(!this._closingComment)for(var t=s.getNodeFromInstance(this),n=t.nextSibling;;){if(null==n?r("67",this._domID):void 0,8===n.nodeType&&" /react-text "===n.nodeValue){this._closingComment=n;break}n=n.nextSibling}return e=[this._hostNode,this._closingComment],this._commentNodes=e,e},unmountComponent:function(){this._closingComment=null,this._commentNodes=null,s.uncacheNode(this)}}),t.exports=l},{113:113,119:119,137:137,143:143,33:33,8:8,9:9,95:95}],43:[function(e,t,n){"use strict";function r(){this._rootNodeID&&c.updateWrapper(this)}function o(e){var t=this._currentElement.props,n=s.executeOnChange(t,e);return l.asap(r,this),n}var i=e(113),a=e(143),s=e(23),u=e(33),l=e(71),c=(e(137),e(142),{getHostProps:function(e,t){null!=t.dangerouslySetInnerHTML?i("91"):void 0;var n=a({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue,onChange:e._wrapperState.onChange});return n},mountWrapper:function(e,t){var n=s.getValue(t),r=n;if(null==n){var a=t.defaultValue,u=t.children;null!=u&&(null!=a?i("92"):void 0,Array.isArray(u)&&(u.length<=1?void 0:i("93"),u=u[0]),a=""+u),null==a&&(a=""),r=a}e._wrapperState={initialValue:""+r,listeners:null,onChange:o.bind(e)}},updateWrapper:function(e){var t=e._currentElement.props,n=u.getNodeFromInstance(e),r=s.getValue(t);if(null!=r){var o=""+r;o!==n.value&&(n.value=o),null==t.defaultValue&&(n.defaultValue=o)}null!=t.defaultValue&&(n.defaultValue=t.defaultValue)},postMountWrapper:function(e){var t=u.getNodeFromInstance(e);t.value=t.textContent}});t.exports=c},{113:113,137:137,142:142,143:143,23:23,33:33,71:71}],44:[function(e,t,n){"use strict";function r(e,t){"_hostNode"in e?void 0:u("33"),"_hostNode"in t?void 0:u("33");for(var n=0,r=e;r;r=r._hostParent)n++;for(var o=0,i=t;i;i=i._hostParent)o++;for(;n-o>0;)e=e._hostParent,n--;for(;o-n>0;)t=t._hostParent,o--;for(var a=n;a--;){if(e===t)return e;e=e._hostParent,t=t._hostParent}return null}function o(e,t){"_hostNode"in e?void 0:u("35"),"_hostNode"in t?void 0:u("35");for(;t;){if(t===e)return!0;t=t._hostParent}return!1}function i(e){return"_hostNode"in e?void 0:u("36"),e._hostParent}function a(e,t,n){for(var r=[];e;)r.push(e),e=e._hostParent;var o;for(o=r.length;o-- >0;)t(r[o],"captured",n);for(o=0;o0;)n(u[l],"captured",i)}var u=e(113);e(137);t.exports={isAncestor:o,getLowestCommonAncestor:r,getParentInstance:i,traverseTwoPhase:a,traverseEnterLeave:s}},{113:113,137:137}],45:[function(e,t,n){"use strict";var r=e(143),o=e(30),i=r({__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:{ReactInstanceMap:e(57)}},o);t.exports=i},{143:143,30:30,57:57}],46:[function(e,t,n){"use strict";function r(){this.reinitializeTransaction()}var o=e(143),i=e(71),a=e(89),s=e(129),u={initialize:s,close:function(){d.isBatchingUpdates=!1}},l={initialize:s,close:i.flushBatchedUpdates.bind(i)},c=[l,u];o(r.prototype,a,{getTransactionWrappers:function(){return c}});var p=new r,d={isBatchingUpdates:!1,batchedUpdates:function(e,t,n,r,o,i){var a=d.isBatchingUpdates;return d.isBatchingUpdates=!0,a?e(t,n,r,o,i):p.perform(e,null,t,n,r,o,i)}};t.exports=d},{129:129,143:143,71:71,89:89}],47:[function(e,t,n){"use strict";function r(){x||(x=!0,y.EventEmitter.injectReactEventListener(g),y.EventPluginHub.injectEventPluginOrder(s),y.EventPluginUtils.injectComponentTree(d),y.EventPluginUtils.injectTreeTraversal(h),y.EventPluginHub.injectEventPluginsByName({SimpleEventPlugin:E,EnterLeaveEventPlugin:u,ChangeEventPlugin:a,SelectEventPlugin:b,BeforeInputEventPlugin:i}),y.HostComponent.injectGenericComponentClass(p),y.HostComponent.injectTextComponentClass(m),y.DOMProperty.injectDOMPropertyConfig(o),y.DOMProperty.injectDOMPropertyConfig(l),y.DOMProperty.injectDOMPropertyConfig(C),y.EmptyComponent.injectEmptyComponentFactory(function(e){return new f(e)}),y.Updates.injectReconcileTransaction(_),y.Updates.injectBatchingStrategy(v),y.Component.injectEnvironment(c))}var o=e(1),i=e(3),a=e(7),s=e(14),u=e(15),l=e(21),c=e(27),p=e(31),d=e(33),f=e(35),h=e(44),m=e(42),v=e(46),g=e(52),y=e(55),_=e(65),C=e(73),b=e(74),E=e(75),x=!1;t.exports={inject:r}},{1:1,14:14,15:15,21:21,27:27,3:3,31:31,33:33,35:35,42:42,44:44,46:46,52:52,55:55,65:65,7:7,73:73,74:74,75:75}],48:[function(e,t,n){"use strict";var r="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103;t.exports=r},{}],49:[function(e,t,n){"use strict";var r,o={injectEmptyComponentFactory:function(e){r=e}},i={create:function(e){return r(e)}};i.injection=o,t.exports=i},{}],50:[function(e,t,n){"use strict";function r(e,t,n){try{t(n)}catch(e){null===o&&(o=e)}}var o=null,i={invokeGuardedCallback:r,invokeGuardedCallbackWithCatch:r,rethrowCaughtError:function(){if(o){var e=o;throw o=null,e}}};t.exports=i},{}],51:[function(e,t,n){"use strict";function r(e){o.enqueueEvents(e),o.processEventQueue(!1)}var o=e(16),i={handleTopLevel:function(e,t,n,i){var a=o.extractEvents(e,t,n,i);r(a)}};t.exports=i},{16:16}],52:[function(e,t,n){"use strict";function r(e){for(;e._hostParent;)e=e._hostParent;var t=p.getNodeFromInstance(e),n=t.parentNode;return p.getClosestInstanceFromNode(n)}function o(e,t){this.topLevelType=e,this.nativeEvent=t,this.ancestors=[]}function i(e){var t=f(e.nativeEvent),n=p.getClosestInstanceFromNode(t),o=n;do e.ancestors.push(o),o=o&&r(o);while(o);for(var i=0;i/,i=/^<\!\-\-/,a={CHECKSUM_ATTR_NAME:"data-react-checksum",addChecksumToMarkup:function(e){var t=r(e);return i.test(e)?e:e.replace(o," "+a.CHECKSUM_ATTR_NAME+'="'+t+'"$&')},canReuseMarkup:function(e,t){var n=t.getAttribute(a.CHECKSUM_ATTR_NAME);n=n&&parseInt(n,10);var o=r(e);return o===n}};t.exports=a},{92:92}],60:[function(e,t,n){"use strict";function r(e,t){for(var n=Math.min(e.length,t.length),r=0;r.":"function"==typeof t?" Instead of passing a class like Foo, pass React.createElement(Foo) or .":null!=t&&void 0!==t.props?" This may be caused by unintentionally loading two independent copies of React.":"");var a,s=v.createElement(F,{child:t});if(e){var u=E.get(e);a=u._processChildContext(u._context)}else a=P;var c=d(n);if(c){var p=c._currentElement,h=p.props.child;if(M(h,t)){var m=c._renderedComponent.getPublicInstance(),g=r&&function(){r.call(m)};return B._updateRootComponent(c,s,a,n,g),m}B.unmountComponentAtNode(n)}var y=o(n),_=y&&!!i(y),C=l(n),b=_&&!c&&!C,x=B._renderNewRootComponent(s,n,b,a)._renderedComponent.getPublicInstance();return r&&r.call(x),x},render:function(e,t,n){return B._renderSubtreeIntoContainer(null,e,t,n)},unmountComponentAtNode:function(e){c(e)?void 0:f("40");var t=d(e);return t?(delete L[t._instance.rootID],k.batchedUpdates(u,t,e,!1),!0):(l(e),1===e.nodeType&&e.hasAttribute(O),!1)},_mountImageIntoNode:function(e,t,n,i,a){if(c(t)?void 0:f("41"),i){var s=o(t);if(x.canReuseMarkup(e,s))return void y.precacheNode(n,s);var u=s.getAttribute(x.CHECKSUM_ATTR_NAME);s.removeAttribute(x.CHECKSUM_ATTR_NAME);var l=s.outerHTML;s.setAttribute(x.CHECKSUM_ATTR_NAME,u);var p=e,d=r(p,l),m=" (client) "+p.substring(d-20,d+20)+"\n (server) "+l.substring(d-20,d+20);t.nodeType===A?f("42",m):void 0}if(t.nodeType===A?f("43"):void 0,a.useCreateElement){for(;t.lastChild;)t.removeChild(t.lastChild);h.insertTreeBefore(t,e,null)}else S(t,e),y.precacheNode(n,t.firstChild)}};t.exports=B},{109:109,11:11,113:113,115:115,117:117,120:120,121:121,130:130,137:137,142:142,25:25,33:33,34:34,36:36,53:53,57:57,58:58,59:59,66:66,70:70,71:71,9:9}],61:[function(e,t,n){"use strict";function r(e,t,n){return{type:"INSERT_MARKUP",content:e,fromIndex:null,fromNode:null,toIndex:n,afterNode:t}}function o(e,t,n){return{type:"MOVE_EXISTING",content:null,fromIndex:e._mountIndex,fromNode:d.getHostNode(e),toIndex:n,afterNode:t}}function i(e,t){return{type:"REMOVE_NODE",content:null,fromIndex:e._mountIndex,fromNode:t,toIndex:null,afterNode:null}}function a(e){return{type:"SET_MARKUP",content:e,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function s(e){return{type:"TEXT_CONTENT",content:e,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function u(e,t){return t&&(e=e||[],e.push(t)),e}function l(e,t){p.processChildrenUpdates(e,t)}var c=e(113),p=e(28),d=(e(57),e(58),e(120),e(66)),f=e(26),h=(e(129),e(97)),m=(e(137),{Mixin:{_reconcilerInstantiateChildren:function(e,t,n){return f.instantiateChildren(e,t,n)},_reconcilerUpdateChildren:function(e,t,n,r,o,i){var a,s=0;return a=h(t,s),f.updateChildren(e,a,n,r,o,this,this._hostContainerInfo,i,s),a},mountChildren:function(e,t,n){var r=this._reconcilerInstantiateChildren(e,t,n);this._renderedChildren=r;var o=[],i=0;for(var a in r)if(r.hasOwnProperty(a)){var s=r[a],u=0,l=d.mountComponent(s,t,this,this._hostContainerInfo,n,u);s._mountIndex=i++,o.push(l)}return o},updateTextContent:function(e){var t=this._renderedChildren;f.unmountChildren(t,!1);for(var n in t)t.hasOwnProperty(n)&&c("118");var r=[s(e)];l(this,r)},updateMarkup:function(e){var t=this._renderedChildren;f.unmountChildren(t,!1);for(var n in t)t.hasOwnProperty(n)&&c("118");var r=[a(e)];l(this,r)},updateChildren:function(e,t,n){this._updateChildren(e,t,n)},_updateChildren:function(e,t,n){var r=this._renderedChildren,o={},i=[],a=this._reconcilerUpdateChildren(r,e,i,o,t,n);if(a||r){var s,c=null,p=0,f=0,h=0,m=null;for(s in a)if(a.hasOwnProperty(s)){var v=r&&r[s],g=a[s];v===g?(c=u(c,this.moveChild(v,m,p,f)),f=Math.max(v._mountIndex,f),v._mountIndex=p):(v&&(f=Math.max(v._mountIndex,f)),c=u(c,this._mountChildAtIndex(g,i[h],m,p,t,n)),h++),p++,m=d.getHostNode(g)}for(s in o)o.hasOwnProperty(s)&&(c=u(c,this._unmountChild(r[s],o[s])));c&&l(this,c),this._renderedChildren=a}},unmountChildren:function(e){var t=this._renderedChildren;f.unmountChildren(t,e),this._renderedChildren=null},moveChild:function(e,t,n,r){if(e._mountIndex0&&r.length<20?n+" (keys: "+r.join(", ")+")":n}function i(e,t){var n=s.get(e);return n?n:null}var a=e(113),s=(e(120),e(57)),u=(e(58),e(71)),l=(e(137),e(142),{isMounted:function(e){var t=s.get(e);return!!t&&!!t._renderedComponent},enqueueCallback:function(e,t,n){l.validateCallback(t,n);var o=i(e);return o?(o._pendingCallbacks?o._pendingCallbacks.push(t):o._pendingCallbacks=[t],void r(o)):null},enqueueCallbackInternal:function(e,t){e._pendingCallbacks?e._pendingCallbacks.push(t):e._pendingCallbacks=[t],r(e)},enqueueForceUpdate:function(e){var t=i(e,"forceUpdate");t&&(t._pendingForceUpdate=!0,r(t))},enqueueReplaceState:function(e,t){var n=i(e,"replaceState");n&&(n._pendingStateQueue=[t],n._pendingReplaceState=!0,r(n))},enqueueSetState:function(e,t){var n=i(e,"setState");if(n){var o=n._pendingStateQueue||(n._pendingStateQueue=[]);o.push(t),r(n)}},enqueueElementInternal:function(e,t,n){e._pendingElement=t,e._context=n,r(e)},validateCallback:function(e,t){e&&"function"!=typeof e?a("122",t,o(e)):void 0}});t.exports=l},{113:113,120:120,137:137,142:142,57:57,58:58,71:71}],71:[function(e,t,n){"use strict";function r(){P.ReactReconcileTransaction&&b?void 0:c("123")}function o(){this.reinitializeTransaction(),this.dirtyComponentsLength=null,this.callbackQueue=d.getPooled(),this.reconcileTransaction=P.ReactReconcileTransaction.getPooled(!0)}function i(e,t,n,o,i,a){return r(),b.batchedUpdates(e,t,n,o,i,a)}function a(e,t){return e._mountOrder-t._mountOrder}function s(e){var t=e.dirtyComponentsLength;t!==g.length?c("124",t,g.length):void 0,g.sort(a),y++;for(var n=0;n]/;t.exports=o},{}],96:[function(e,t,n){"use strict";function r(e){if(null==e)return null;if(1===e.nodeType)return e;var t=a.get(e);return t?(t=s(t),t?i.getNodeFromInstance(t):null):void("function"==typeof e.render?o("44"):o("45",Object.keys(e)))}var o=e(113),i=(e(120),e(33)),a=e(57),s=e(103);e(137),e(142);t.exports=r},{103:103,113:113,120:120,137:137,142:142,33:33,57:57}],97:[function(e,t,n){(function(n){"use strict";function r(e,t,n,r){if(e&&"object"==typeof e){var o=e,i=void 0===o[n];i&&null!=t&&(o[n]=t)}}function o(e,t){if(null==e)return e;var n={};return i(e,r,n),n}var i=(e(22),e(118));e(142);"undefined"!=typeof n&&n.env,t.exports=o}).call(this,void 0)},{118:118,142:142,22:22}],98:[function(e,t,n){"use strict";function r(e,t,n){Array.isArray(e)?e.forEach(t,n):e&&t.call(n,e)}t.exports=r},{}],99:[function(e,t,n){"use strict";function r(e){var t,n=e.keyCode;return"charCode"in e?(t=e.charCode,0===t&&13===n&&(t=13)):t=n,t>=32||13===t?t:0}t.exports=r},{}],100:[function(e,t,n){"use strict";function r(e){if(e.key){var t=i[e.key]||e.key;if("Unidentified"!==t)return t}if("keypress"===e.type){var n=o(e);return 13===n?"Enter":String.fromCharCode(n)}return"keydown"===e.type||"keyup"===e.type?a[e.keyCode]||"Unidentified":""}var o=e(99),i={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},a={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"};t.exports=r},{99:99}],101:[function(e,t,n){"use strict";function r(e){var t=this,n=t.nativeEvent;if(n.getModifierState)return n.getModifierState(e);var r=i[e];return!!r&&!!n[r]}function o(e){return r}var i={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};t.exports=o},{}],102:[function(e,t,n){"use strict";function r(e){var t=e.target||e.srcElement||window;return t.correspondingUseElement&&(t=t.correspondingUseElement),3===t.nodeType?t.parentNode:t}t.exports=r},{}],103:[function(e,t,n){"use strict";function r(e){for(var t;(t=e._renderedNodeType)===o.COMPOSITE;)e=e._renderedComponent;return t===o.HOST?e._renderedComponent:t===o.EMPTY?null:void 0}var o=e(62);t.exports=r},{62:62}],104:[function(e,t,n){"use strict";function r(e){var t=e&&(o&&e[o]||e[i]);if("function"==typeof t)return t}var o="function"==typeof Symbol&&Symbol.iterator,i="@@iterator";t.exports=r},{}],105:[function(e,t,n){"use strict";function r(){return o++}var o=1;t.exports=r},{}],106:[function(e,t,n){"use strict";function r(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function o(e){for(;e;){if(e.nextSibling)return e.nextSibling;e=e.parentNode}}function i(e,t){for(var n=r(e),i=0,a=0;n;){if(3===n.nodeType){if(a=i+n.textContent.length,i<=t&&a>=t)return{node:n,offset:t-i};i=a}n=r(o(n))}}t.exports=i},{}],107:[function(e,t,n){"use strict";function r(){return!i&&o.canUseDOM&&(i="textContent"in document.documentElement?"textContent":"innerText"),i}var o=e(123),i=null;t.exports=r},{123:123}],108:[function(e,t,n){"use strict";function r(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n["ms"+e]="MS"+t,n["O"+e]="o"+t.toLowerCase(),n}function o(e){if(s[e])return s[e];if(!a[e])return e;var t=a[e];for(var n in t)if(t.hasOwnProperty(n)&&n in u)return s[e]=t[n];return""}var i=e(123),a={animationend:r("Animation","AnimationEnd"),animationiteration:r("Animation","AnimationIteration"),animationstart:r("Animation","AnimationStart"),transitionend:r("Transition","TransitionEnd")},s={},u={};i.canUseDOM&&(u=document.createElement("div").style,"AnimationEvent"in window||(delete a.animationend.animation,delete a.animationiteration.animation,delete a.animationstart.animation),"TransitionEvent"in window||delete a.transitionend.transition),t.exports=o},{123:123}],109:[function(e,t,n){"use strict";function r(e){if(e){var t=e.getName();if(t)return" Check the render method of `"+t+"`."}return""}function o(e){return"function"==typeof e&&"undefined"!=typeof e.prototype&&"function"==typeof e.prototype.mountComponent&&"function"==typeof e.prototype.receiveComponent}function i(e,t){var n;if(null===e||e===!1)n=l.create(i);else if("object"==typeof e){var s=e;!s||"function"!=typeof s.type&&"string"!=typeof s.type?a("130",null==s.type?s.type:typeof s.type,r(s._owner)):void 0,"string"==typeof s.type?n=c.createInternalComponent(s):o(s.type)?(n=new s.type(s),n.getHostNode||(n.getHostNode=n.getNativeNode)):n=new p(s)}else"string"==typeof e||"number"==typeof e?n=c.createInstanceForText(e):a("131",typeof e);return n._mountIndex=0,n._mountImage=null,n}var a=e(113),s=e(143),u=e(29),l=e(49),c=e(54),p=(e(105),e(137),e(142),function(e){this.construct(e)});s(p.prototype,u,{_instantiateReactComponent:i}),t.exports=i},{105:105,113:113,137:137,142:142,143:143,29:29,49:49,54:54}],110:[function(e,t,n){"use strict";function r(e,t){if(!i.canUseDOM||t&&!("addEventListener"in document))return!1;var n="on"+e,r=n in document;if(!r){var a=document.createElement("div");a.setAttribute(n,"return;"),r="function"==typeof a[n]}return!r&&o&&"wheel"===e&&(r=document.implementation.hasFeature("Events.wheel","3.0")),r}var o,i=e(123);i.canUseDOM&&(o=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0),t.exports=r},{123:123}],111:[function(e,t,n){"use strict";function r(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!o[e.type]:"textarea"===t}var o={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};t.exports=r},{}],112:[function(e,t,n){"use strict";function r(e){return'"'+o(e)+'"'}var o=e(95);t.exports=r},{95:95}],113:[function(e,t,n){"use strict";function r(e){for(var t=arguments.length-1,n="Minified React error #"+e+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant="+e,r=0;r]/,u=e(93),l=u(function(e,t){if(e.namespaceURI!==i.svg||"innerHTML"in e)e.innerHTML=t;else{r=r||document.createElement("div"),r.innerHTML=""+t+"";for(var n=r.firstChild;n.firstChild;)e.appendChild(n.firstChild)}});if(o.canUseDOM){var c=document.createElement("div");c.innerHTML=" ",""===c.innerHTML&&(l=function(e,t){if(e.parentNode&&e.parentNode.replaceChild(e,e),a.test(t)||"<"===t[0]&&s.test(t)){e.innerHTML=String.fromCharCode(65279)+t;var n=e.firstChild;1===n.data.length?e.removeChild(n):n.deleteData(0,1)}else e.innerHTML=t}),c=null}t.exports=l},{10:10,123:123,93:93}],116:[function(e,t,n){"use strict";var r=e(123),o=e(95),i=e(115),a=function(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t};r.canUseDOM&&("textContent"in document.documentElement||(a=function(e,t){return 3===e.nodeType?void(e.nodeValue=t):void i(e,o(t))})),t.exports=a},{115:115,123:123,95:95}],117:[function(e,t,n){"use strict";function r(e,t){var n=null===e||e===!1,r=null===t||t===!1;if(n||r)return n===r;var o=typeof e,i=typeof t;return"string"===o||"number"===o?"string"===i||"number"===i:"object"===i&&e.type===t.type&&e.key===t.key}t.exports=r},{}],118:[function(e,t,n){"use strict";function r(e,t){return e&&"object"==typeof e&&null!=e.key?l.escape(e.key):t.toString(36)}function o(e,t,n,i){var d=typeof e;if("undefined"!==d&&"boolean"!==d||(e=null),null===e||"string"===d||"number"===d||"object"===d&&e.$$typeof===s)return n(i,e,""===t?c+r(e,0):t),1;var f,h,m=0,v=""===t?c:t+p;if(Array.isArray(e))for(var g=0;g":a.innerHTML="<"+e+">",s[e]=!a.firstChild),s[e]?d[e]:null}var o=e(123),i=e(137),a=o.canUseDOM?document.createElement("div"):null,s={},u=[1,'"],l=[1,"","
"],c=[3,"","
"],p=[1,'',""],d={"*":[1,"?
","
"],area:[1,"",""],col:[2,"","
"],legend:[1,"
","
"],param:[1,"",""],tr:[2,"","
"],optgroup:u,option:u,caption:l,colgroup:l,tbody:l,tfoot:l,thead:l,td:c,th:c},f=["circle","clipPath","defs","ellipse","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","text","tspan"];f.forEach(function(e){d[e]=p,s[e]=!0}),t.exports=r},{123:123,137:137}],134:[function(e,t,n){"use strict";function r(e){return e===window?{x:window.pageXOffset||document.documentElement.scrollLeft,y:window.pageYOffset||document.documentElement.scrollTop}:{x:e.scrollLeft,y:e.scrollTop}}t.exports=r},{}],135:[function(e,t,n){"use strict";function r(e){return e.replace(o,"-$1").toLowerCase()}var o=/([A-Z])/g;t.exports=r},{}],136:[function(e,t,n){"use strict";function r(e){return o(e).replace(i,"-ms-")}var o=e(135),i=/^ms-/;t.exports=r},{135:135}],137:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,a,s){if(!e){var u;if(void 0===t)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,r,o,i,a,s],c=0;u=new Error(t.replace(/%s/g,function(){return l[c++]})),u.name="Invariant Violation"}throw u.framesToPop=1,u}}t.exports=r},{}],138:[function(e,t,n){"use strict";function r(e){return!(!e||!("function"==typeof Node?e instanceof Node:"object"==typeof e&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName))}t.exports=r},{}],139:[function(e,t,n){"use strict";function r(e){return o(e)&&3==e.nodeType}var o=e(138);t.exports=r},{138:138}],140:[function(e,t,n){"use strict";function r(e){var t={};return function(n){return t.hasOwnProperty(n)||(t[n]=e.call(this,n)),t[n]}}t.exports=r},{}],141:[function(e,t,n){"use strict";function r(e,t){return e===t?0!==e||0!==t||1/e===1/t:e!==e&&t!==t}function o(e,t){if(r(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),o=Object.keys(t);if(n.length!==o.length)return!1;for(var a=0;ademo
-------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | react-starter-kit 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 | Sample App 18 | 19 | 20 | 21 | 22 |
23 |
24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /mock/db.json: -------------------------------------------------------------------------------- 1 | { 2 | "page1": { 3 | "inall": 2, 4 | "index": 1, 5 | "data": [ 6 | {"name": "肖申克的救赎"}, 7 | {"name": "这个杀手不太冷"}, 8 | {"name": "霸王别姬"}, 9 | {"name": "阿甘正传"}, 10 | {"name": "美丽人生"} 11 | ] 12 | }, 13 | "page2": { 14 | "inall": 2, 15 | "index": 1, 16 | "data": [ 17 | {"name": "千与千寻"}, 18 | {"name": "辛德勒的名单"}, 19 | {"name": "海上钢琴师"}, 20 | {"name": "机器人总动员"}, 21 | {"name": "盗梦空间"} 22 | ] 23 | } 24 | } -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Rover", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "mock": "json-server mock/db.json --port 3003 &", 8 | "start": "node server.js &", 9 | "test": "mocha --compilers js:babel-register --require ./test/test_helper.js --recursive ./test", 10 | "test:watch": "npm test -- --watch", 11 | "lint": "eslint src", 12 | "dll": "webpack --config ./webpack.dll.config.js", 13 | "build-mac": "rm dist && export NODE_ENV=production && webpack -p --config ./webpack.prod.config.js --progress --profile --colors", 14 | "build-win": "del dist && set NODE_ENV=production && webpack -p --config ./webpack.prod.config.js --progress --profile --colors" 15 | }, 16 | "author": "Rover", 17 | "license": "ISC", 18 | "devDependencies": { 19 | "autoprefixer": "6.3.6", 20 | "babel-core": "^6.8.0", 21 | "babel-eslint": "^6.0.4", 22 | "babel-loader": "^6.2.4", 23 | "babel-preset-es2015": "^6.6.0", 24 | "babel-preset-react": "^6.5.0", 25 | "babel-preset-react-hmre": "^1.1.1", 26 | "babel-preset-stage-0": "^6.5.0", 27 | "css-loader": "^0.23.1", 28 | "eslint": "^2.9.0", 29 | "eslint-loader": "^1.5.0", 30 | "eslint-plugin-react": "^5.0.1", 31 | "eventsource-polyfill": "^0.9.6", 32 | "exports-loader": "^0.6.3", 33 | "express": "^4.14.0", 34 | "extract-text-webpack-plugin": "^1.0.1", 35 | "file-loader": "^0.9.0", 36 | "html-webpack-plugin": "^2.17.0", 37 | "image-webpack-loader": "^3.1.0", 38 | "imports-loader": "^0.7.0", 39 | "less": "^2.6.1", 40 | "less-loader": "^2.2.3", 41 | "postcss-loader": "^0.9.1", 42 | "react-hot-loader": "^1.3.0", 43 | "redux-logger": "^2.6.1", 44 | "resolve-url-loader": "^1.6.1", 45 | "style-loader": "^0.13.1", 46 | "url-loader": "^0.5.7", 47 | "webpack": "^1.13.0", 48 | "webpack-dev-middleware": "^1.6.1", 49 | "webpack-dev-server": "^1.14.1" 50 | }, 51 | "dependencies": { 52 | "es6-promise": "^4.0.5", 53 | "react": "^15.0.2", 54 | "react-addons-css-transition-group": "^15.3.0", 55 | "react-dom": "^15.0.2", 56 | "react-redux": "^4.4.5", 57 | "react-router": "^2.4.1", 58 | "redux": "^3.5.2", 59 | "redux-thunk": "^2.1.0", 60 | "whatwg-fetch": "^2.0.1" 61 | } 62 | } 63 | -------------------------------------------------------------------------------- /server.js: -------------------------------------------------------------------------------- 1 | var webpack = require('webpack'); 2 | var WebpackDevServer = require('webpack-dev-server'); 3 | var config = require('./webpack.dev.config'); 4 | 5 | const isDeveloping = process.env.NODE_ENV !== 'production'; 6 | const port = isDeveloping ? 3000 : process.env.PORT; 7 | 8 | var compiler = webpack(config); 9 | var server = new WebpackDevServer(compiler, { 10 | publicPath: config.output.publicPath, 11 | hot: true, 12 | historyApiFallback: true, 13 | stats: { 14 | colors: true, 15 | hash: false, 16 | timings: true, 17 | chunks: false, 18 | chunkModules: false, 19 | modules: false 20 | } 21 | }); 22 | 23 | server.listen(3000, 'localhost', function(err, result) { 24 | if (err) { 25 | return console.log(err); 26 | } 27 | console.log('Listening at http://localhost:3000/'); 28 | }); -------------------------------------------------------------------------------- /src/app.js: -------------------------------------------------------------------------------- 1 | import ReactDOM from 'react-dom' 2 | import App from './router' 3 | 4 | ReactDOM.render(App, document.getElementById('root')) 5 | -------------------------------------------------------------------------------- /src/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rover5056/React-Redux-webpack/37a914786fc47f227a743a8fe8021e75a4168300/src/favicon.ico -------------------------------------------------------------------------------- /src/index.tpl.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | demo 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /src/module/Dialog/close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rover5056/React-Redux-webpack/37a914786fc47f227a743a8fe8021e75a4168300/src/module/Dialog/close.png -------------------------------------------------------------------------------- /src/module/Dialog/dialog.less: -------------------------------------------------------------------------------- 1 | 2 | .dyy { 3 | position: fixed; 4 | top: 0; 5 | left: 0; 6 | box-sizing: border-box; 7 | width: 100%; 8 | height: 100%; 9 | background: rgba(0, 0, 0, 0.8) 10 | } 11 | 12 | .box { 13 | position: fixed; 14 | top: 50px; 15 | left: 50%; 16 | width: 300px; 17 | box-sizing: border-box; 18 | margin-left: -150px; 19 | padding: 10px 34px; 20 | background-color: #fff; 21 | border-radius: 6px; 22 | } 23 | 24 | .title { 25 | padding: 24px 0 20px; 26 | font-size: 20px; 27 | font-weight: bold; 28 | line-height: 32px; 29 | text-align: left; 30 | } 31 | 32 | p {color: rgba(0, 0, 0, 0.6)} 33 | 34 | .closeicon { 35 | position: absolute; 36 | top: 4px; 37 | right: 4px; 38 | background: url(../Dialog/close.png) no-repeat; 39 | background-size: 100%; 40 | width: 20px; 41 | height: 20px; 42 | } 43 | 44 | .confirmbox { 45 | padding: 20px 0 0 10px; 46 | background: none; 47 | text-align: right; 48 | 49 | a { 50 | color: #49A0FF; 51 | font-size: 16px; 52 | text-decoration: none; 53 | } 54 | } -------------------------------------------------------------------------------- /src/module/Dialog/index.js: -------------------------------------------------------------------------------- 1 | import React, { PropTypes,Component } from 'react'; 2 | import ReactCSSTransitionGroup from 'react-addons-css-transition-group' 3 | import style from './dialog.less'; 4 | 5 | 6 | class Dialog extends Component { 7 | constructor(props) { 8 | super(props); 9 | 10 | this.state = { 11 | isShow: false 12 | }; 13 | } 14 | 15 | componentDidMount() { 16 | if (this.props.visible) { 17 | this.enter(); 18 | } 19 | } 20 | 21 | componentWillReceiveProps(nextProps) { 22 | if (!this.props.visible && nextProps.visible) { 23 | this.enter(); 24 | } else if (this.props.visible && !nextProps.visible) { 25 | this.leave(); 26 | } 27 | } 28 | 29 | enter() { 30 | this.setState({ 31 | isShow: true 32 | }) 33 | } 34 | 35 | leave() { 36 | this.setState({ 37 | isShow: false 38 | }); 39 | } 40 | 41 | render() { 42 | const mask = this.state.isShow ?
: null 43 | const confirmBox = this.props.isConfirm ? ( 44 |
45 |
46 | ok 47 |
48 |
49 | ) : null 50 | const title =

{this.props.title}

51 | const InnerContent = this.state.isShow ? ( 52 |
53 |
54 |
55 | {title} 56 | {this.props.children} 57 | {confirmBox} 58 |
59 |
60 | ) : 61 | null 62 | 63 | return ( 64 |
65 | 66 | {mask} 67 | 68 | 69 | {InnerContent} 70 | 71 |
72 | ); 73 | } 74 | } 75 | 76 | Dialog.propTypes = { 77 | onClose: PropTypes.func.isRequired, 78 | onConfirm: PropTypes.func, 79 | visible: PropTypes.bool, 80 | title:PropTypes.node, 81 | children:PropTypes.node, 82 | isConfirm: PropTypes.bool 83 | }; 84 | 85 | Dialog.defaultProps = { 86 | visible: false, 87 | title: null, 88 | children: null, 89 | isConfirm: false 90 | }; 91 | 92 | export default Dialog; -------------------------------------------------------------------------------- /src/module/Spin/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import style from './spin.less'; 3 | 4 | 5 | const spin = () => ( 6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 | ) 20 | 21 | export default spin 22 | 23 | 24 | -------------------------------------------------------------------------------- /src/module/Spin/spin.less: -------------------------------------------------------------------------------- 1 | .dyy { 2 | position: fixed; 3 | top: 0; 4 | box-sizing: border-box; 5 | width: 100%; 6 | height: 100%; 7 | background: rgba(225, 225, 225, 0.4) 8 | } 9 | 10 | 11 | .laballspin, 12 | .laballspin > div { 13 | position: fixed; 14 | top: 50%; 15 | left: 50%; 16 | transform: translate(-50%, -50%); 17 | -webkit-box-sizing: border-box; 18 | -moz-box-sizing: border-box; 19 | box-sizing: border-box; 20 | } 21 | .laballspin { 22 | display: block; 23 | font-size: 0; 24 | color: #333; 25 | } 26 | .laballspin.la-dark { 27 | color: #333; 28 | } 29 | .laballspin > div { 30 | display: inline-block; 31 | float: none; 32 | background-color: currentColor; 33 | border: 0 solid currentColor; 34 | } 35 | .laballspin { 36 | width: 32px; 37 | height: 32px; 38 | } 39 | .laballspin > div { 40 | position: absolute; 41 | top: 50%; 42 | left: 50%; 43 | width: 8px; 44 | height: 8px; 45 | margin-top: -4px; 46 | margin-left: -4px; 47 | border-radius: 100%; 48 | -webkit-animation: ball-spin 1s infinite ease-in-out; 49 | -moz-animation: ball-spin 1s infinite ease-in-out; 50 | -o-animation: ball-spin 1s infinite ease-in-out; 51 | animation: ball-spin 1s infinite ease-in-out; 52 | } 53 | .laballspin > div:nth-child(1) { 54 | top: 5%; 55 | left: 50%; 56 | -webkit-animation-delay: -1.125s; 57 | -moz-animation-delay: -1.125s; 58 | -o-animation-delay: -1.125s; 59 | animation-delay: -1.125s; 60 | } 61 | .laballspin > div:nth-child(2) { 62 | top: 18.1801948466%; 63 | left: 81.8198051534%; 64 | -webkit-animation-delay: -1.25s; 65 | -moz-animation-delay: -1.25s; 66 | -o-animation-delay: -1.25s; 67 | animation-delay: -1.25s; 68 | } 69 | .laballspin > div:nth-child(3) { 70 | top: 50%; 71 | left: 95%; 72 | -webkit-animation-delay: -1.375s; 73 | -moz-animation-delay: -1.375s; 74 | -o-animation-delay: -1.375s; 75 | animation-delay: -1.375s; 76 | } 77 | .laballspin > div:nth-child(4) { 78 | top: 81.8198051534%; 79 | left: 81.8198051534%; 80 | -webkit-animation-delay: -1.5s; 81 | -moz-animation-delay: -1.5s; 82 | -o-animation-delay: -1.5s; 83 | animation-delay: -1.5s; 84 | } 85 | .laballspin > div:nth-child(5) { 86 | top: 94.9999999966%; 87 | left: 50.0000000005%; 88 | -webkit-animation-delay: -1.625s; 89 | -moz-animation-delay: -1.625s; 90 | -o-animation-delay: -1.625s; 91 | animation-delay: -1.625s; 92 | } 93 | .laballspin > div:nth-child(6) { 94 | top: 81.8198046966%; 95 | left: 18.1801949248%; 96 | -webkit-animation-delay: -1.75s; 97 | -moz-animation-delay: -1.75s; 98 | -o-animation-delay: -1.75s; 99 | animation-delay: -1.75s; 100 | } 101 | .laballspin > div:nth-child(7) { 102 | top: 49.9999750815%; 103 | left: 5.0000051215%; 104 | -webkit-animation-delay: -1.875s; 105 | -moz-animation-delay: -1.875s; 106 | -o-animation-delay: -1.875s; 107 | animation-delay: -1.875s; 108 | } 109 | .laballspin > div:nth-child(8) { 110 | top: 18.179464974%; 111 | left: 18.1803700518%; 112 | -webkit-animation-delay: -2s; 113 | -moz-animation-delay: -2s; 114 | -o-animation-delay: -2s; 115 | animation-delay: -2s; 116 | } 117 | .laballspin.la-sm { 118 | width: 16px; 119 | height: 16px; 120 | } 121 | .laballspin.la-sm > div { 122 | width: 4px; 123 | height: 4px; 124 | margin-top: -2px; 125 | margin-left: -2px; 126 | } 127 | .laballspin.la-2x { 128 | width: 64px; 129 | height: 64px; 130 | } 131 | .laballspin.la-2x > div { 132 | width: 16px; 133 | height: 16px; 134 | margin-top: -8px; 135 | margin-left: -8px; 136 | } 137 | .laballspin.la-3x { 138 | width: 96px; 139 | height: 96px; 140 | } 141 | .laballspin.la-3x > div { 142 | width: 24px; 143 | height: 24px; 144 | margin-top: -12px; 145 | margin-left: -12px; 146 | } 147 | /* 148 | * Animation 149 | */ 150 | @-webkit-keyframes ball-spin { 151 | 0%, 152 | 100% { 153 | opacity: 1; 154 | -webkit-transform: scale(1); 155 | transform: scale(1); 156 | } 157 | 20% { 158 | opacity: 1; 159 | } 160 | 80% { 161 | opacity: 0; 162 | -webkit-transform: scale(0); 163 | transform: scale(0); 164 | } 165 | } 166 | @-moz-keyframes ball-spin { 167 | 0%, 168 | 100% { 169 | opacity: 1; 170 | -moz-transform: scale(1); 171 | transform: scale(1); 172 | } 173 | 20% { 174 | opacity: 1; 175 | } 176 | 80% { 177 | opacity: 0; 178 | -moz-transform: scale(0); 179 | transform: scale(0); 180 | } 181 | } 182 | @-o-keyframes ball-spin { 183 | 0%, 184 | 100% { 185 | opacity: 1; 186 | -o-transform: scale(1); 187 | transform: scale(1); 188 | } 189 | 20% { 190 | opacity: 1; 191 | } 192 | 80% { 193 | opacity: 0; 194 | -o-transform: scale(0); 195 | transform: scale(0); 196 | } 197 | } 198 | @keyframes ball-spin { 199 | 0%, 200 | 100% { 201 | opacity: 1; 202 | -webkit-transform: scale(1); 203 | -moz-transform: scale(1); 204 | -o-transform: scale(1); 205 | transform: scale(1); 206 | } 207 | 20% { 208 | opacity: 1; 209 | } 210 | 80% { 211 | opacity: 0; 212 | -webkit-transform: scale(0); 213 | -moz-transform: scale(0); 214 | -o-transform: scale(0); 215 | transform: scale(0); 216 | } 217 | } 218 | -------------------------------------------------------------------------------- /src/reducers/index.js: -------------------------------------------------------------------------------- 1 | import { combineReducers } from 'redux' 2 | 3 | const initalHelloState = { 4 | HELLO_TEXT: 'Hi, World!' 5 | } 6 | 7 | const changeText = (state = initalHelloState, action) => { 8 | switch (action.type) { 9 | case 'sayHi': 10 | { 11 | if (state.HELLO_TEXT != action.text ) return { HELLO_TEXT: action.text } 12 | return initalHelloState; 13 | } 14 | 15 | default: 16 | return state 17 | } 18 | } 19 | 20 | const initalFundState = { 21 | datas:[], 22 | page:0, 23 | isloading: false, 24 | isShowTip: false 25 | } 26 | 27 | const FundPageInfo = (state = initalFundState, action) => { 28 | switch (action.type) { 29 | case 'INIT_FUND': 30 | { 31 | return Object.assign({}, state, action.item) 32 | } 33 | case 'TURN_PAGE': 34 | { 35 | return Object.assign({}, state, action.item, { 36 | datas: action.item.datas ? state.datas.concat(action.item.datas) : state.datas 37 | }) 38 | } 39 | default: 40 | return state 41 | } 42 | } 43 | 44 | 45 | export default combineReducers({ 46 | changeText, 47 | FundPageInfo 48 | }) -------------------------------------------------------------------------------- /src/router/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { Router, Route, IndexRoute, browserHistory } from 'react-router' 3 | import ReactCSSTransitionGroup from 'react-addons-css-transition-group' 4 | 5 | import { Provider } from 'react-redux' 6 | import store from '../store' 7 | 8 | import '../styles/animation.less' 9 | import '../styles/button.less' 10 | import '../styles/reset.less' 11 | 12 | 13 | 14 | const Layout = ({ children, location }) => ( 15 |
16 | 21 | {React.cloneElement(children, { 22 | key: location.pathname 23 | })} 24 | 25 |
26 | ) 27 | 28 | Layout.propTypes = { 29 | children: React.PropTypes.node, 30 | location: React.PropTypes.object 31 | } 32 | 33 | 34 | const App = ( 35 | 36 | 37 | 38 | { 40 | require.ensure([], function (require) { 41 | callback(null, require('../view/Homepage').default); 42 | }, 'HomeContainer'); 43 | }} 44 | /> 45 | { 48 | require.ensure([], function (require) { 49 | callback(null, require('../view/Aboutpage').default); 50 | }, 'Aboutpage'); 51 | }} 52 | /> 53 | { 56 | require.ensure([], function (require) { 57 | callback(null, require('../view/Contactpage').default); 58 | }, 'Contactpage'); 59 | }} 60 | /> 61 | { 64 | require.ensure([], function (require) { 65 | callback(null, require('../view/FundListpage').default); 66 | }, 'FundListContainer'); 67 | }} 68 | /> 69 | { 72 | require.ensure([], function (require) { 73 | callback(null, require('../view/NotFound/index.js').default); 74 | }, 'NotFound'); 75 | }} 76 | /> 77 | 78 | 79 | 80 | ) 81 | 82 | export default App -------------------------------------------------------------------------------- /src/store/index.js: -------------------------------------------------------------------------------- 1 | import { createStore, applyMiddleware} from 'redux' 2 | 3 | import thunk from 'redux-thunk' 4 | // import createLogger from 'redux-logger' 5 | 6 | import reducers from '../reducers' 7 | 8 | let store = createStore( 9 | reducers, 10 | applyMiddleware( 11 | thunk 12 | // createLogger() //打印action与store,开发时使用 13 | ) 14 | ) 15 | 16 | export default store 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /src/styles/animation.less: -------------------------------------------------------------------------------- 1 | :global{ 2 | .carousel-enter { 3 | opacity: 0; 4 | transform: translateX(100%); 5 | } 6 | .carousel-enter-active { 7 | width: 100%; 8 | opacity: 1; 9 | transform: translateX(0); 10 | transition: transform 500ms ease, opacity 500ms ease; 11 | } 12 | .carousel-leave { 13 | opacity: 1; 14 | transform: 0; 15 | } 16 | .carousel-leave-active { 17 | width: 100%; 18 | opacity: translateX(0); 19 | transform: translateX(-100%); 20 | transition: transform 500ms ease, opacity 500ms ease; 21 | } 22 | 23 | .fade-appear { 24 | opacity: 0.01; 25 | } 26 | .fade-appear-active { 27 | opacity: 1; 28 | transition: opacity 300ms linear; 29 | } 30 | .fade-enter { 31 | opacity: 0.01; 32 | } 33 | .fade-enter-active { 34 | opacity: 1; 35 | transition: opacity 300ms linear; 36 | } 37 | .fade-leave { 38 | opacity: 1; 39 | } 40 | .fade-leave-active { 41 | opacity: 0.01; 42 | transition: opacity 300ms ease-in; 43 | } 44 | 45 | 46 | .slideTop-apper { 47 | opacity: 0.01; 48 | transform: translate(0, -2rem); 49 | } 50 | .slideTop-appear-active { 51 | opacity: 1; 52 | transform: translate(0, 0); 53 | transition: transform 200ms linear, opacity 200ms linear; 54 | } 55 | .slideTop-enter { 56 | opacity: 0.01; 57 | transform: translate(0, -2rem); 58 | } 59 | .slideTop-enter-active { 60 | opacity: 1; 61 | transform: translate(0, 0); 62 | transition: transform 200ms linear, opacity 200ms linear; 63 | } 64 | 65 | .slideTop-leave { 66 | opacity: 1; 67 | transform: translate(0, 0); 68 | } 69 | .slideTop-leave-active { 70 | opacity: 0.01; 71 | transform: translate(0, 2rem); 72 | transition: transform 200ms ease-in, opacity 200ms linear; 73 | } 74 | 75 | } -------------------------------------------------------------------------------- /src/styles/button.less: -------------------------------------------------------------------------------- 1 | :global{ 2 | .opa(@a:0.8){ 3 | opacity: @a; 4 | } 5 | .btn-primary { 6 | display: block; 7 | width: 230px; 8 | line-height: 2; 9 | margin: 20px auto; 10 | color: #fff; 11 | font-size: 18px; 12 | font-weight: bold; 13 | text-align: center; 14 | text-decoration: none; 15 | background-color: #49A0FF; 16 | border-radius: 3px; 17 | box-shadow: rgba(0, 0, 0, 0.117647) 0px 1px 6px, rgba(0, 0, 0, 0.117647) 0px 1px 4px; 18 | cursor: pointer; 19 | } 20 | 21 | .btn-positive { 22 | .btn-primary ; 23 | background-color: green; 24 | } 25 | 26 | .btn-dialog { 27 | .btn-primary ; 28 | background-color: #f40; 29 | } 30 | 31 | .btn-disabled { 32 | .btn-primary ; 33 | .opa(0.5) ; 34 | background-color: #aaa; 35 | } 36 | } -------------------------------------------------------------------------------- /src/styles/reset.less: -------------------------------------------------------------------------------- 1 | :global{ 2 | html, 3 | body, 4 | h1, 5 | h2, 6 | h3, 7 | h4, 8 | h5, 9 | h6, 10 | p, 11 | blockquote, 12 | ul, 13 | ol, 14 | li, 15 | dl, 16 | dt, 17 | dd, 18 | form, 19 | fieldset, 20 | legend, 21 | input, 22 | textarea, 23 | button, 24 | th, 25 | td { 26 | margin: 0; 27 | padding: 0; 28 | border: 0; 29 | vertical-align: baseline; 30 | } 31 | html { 32 | line-height: 1; 33 | } 34 | table { 35 | border-collapse: collapse; 36 | border-spacing: 0; 37 | } 38 | ul, 39 | ol { 40 | list-style: none; 41 | } 42 | img { 43 | border: 0; 44 | } 45 | b, 46 | strong { 47 | font-weight: 700; 48 | } 49 | article, 50 | aside, 51 | details, 52 | figcaption, 53 | figure, 54 | footer, 55 | header, 56 | hgroup, 57 | main, 58 | nav, 59 | section, 60 | summary { 61 | display: block; 62 | } 63 | audio, 64 | canvas, 65 | progress, 66 | video { 67 | display: inline-block; 68 | vertical-align: baseline; 69 | } 70 | 71 | body{ 72 | line-height: 1.5; 73 | font-family: Helvetica, Tahoma, Arial, "Microsoft YaHei", "微软雅黑", Heiti, "黑体", SimSun, "宋体", sans-serif; 74 | background: #fff; 75 | } 76 | } -------------------------------------------------------------------------------- /src/util/co/index.js: -------------------------------------------------------------------------------- 1 | const co = { 2 | fixNum(num) { 3 | return '+' + num 4 | } 5 | } 6 | 7 | export default co 8 | -------------------------------------------------------------------------------- /src/view/Aboutpage/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { IndexLink } from 'react-router'; 3 | 4 | import styles from './style.less'; 5 | 6 | 7 | const Aboutpage = () => ( 8 |
9 |

About

10 |

This is a boilerplate for webpack-react-es6-cssModule project. You could use it as a base to build your own web app.

11 |

You can get update and more information in this github repo:

12 |

https://github.com/tumars/boilerplate-webpack-react-es6-cssModule

13 | Back to Home 14 |
15 |
16 | ) 17 | 18 | export default Aboutpage 19 | -------------------------------------------------------------------------------- /src/view/Aboutpage/logo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rover5056/React-Redux-webpack/37a914786fc47f227a743a8fe8021e75a4168300/src/view/Aboutpage/logo.jpg -------------------------------------------------------------------------------- /src/view/Aboutpage/style.less: -------------------------------------------------------------------------------- 1 | .content { 2 | h1 { 3 | line-height: 3; 4 | font-size: 40px; 5 | font-weight: bold; 6 | text-align: center; 7 | } 8 | 9 | p { 10 | width: 280px; 11 | margin: 15px auto; 12 | line-height: 1.5; 13 | color: #333; 14 | a { 15 | color: #49A0FF; 16 | } 17 | } 18 | .logo { 19 | background: url(../Aboutpage/logo.jpg) no-repeat; 20 | background-size: 100%; 21 | width: 60px; 22 | height: 60px; 23 | margin: 20px auto; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /src/view/Contactpage/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { IndexLink } from 'react-router'; 3 | 4 | import styles from './style.less'; 5 | 6 | 7 | 8 | const Contactpage = () => ( 9 |
10 |

Contact me

11 | 16 | Back to Home 17 |
18 |
19 | ) 20 | 21 | 22 | export default Contactpage -------------------------------------------------------------------------------- /src/view/Contactpage/style.less: -------------------------------------------------------------------------------- 1 | .content { 2 | h1 { 3 | line-height: 4; 4 | font-size: 30px; 5 | text-align: center; 6 | } 7 | 8 | ul { 9 | display: block; 10 | width: 300px; 11 | margin: 0 auto; 12 | } 13 | 14 | li { 15 | line-height: 2; 16 | color: #333; 17 | a { 18 | color: #49A0FF; 19 | } 20 | } 21 | .tusiji { 22 | background: url(../Contactpage/tusiji.png) no-repeat; 23 | background-size: 100%; 24 | width: 512/3px; 25 | height: 512/3px; 26 | margin: 20px auto; 27 | } 28 | 29 | } 30 | -------------------------------------------------------------------------------- /src/view/Contactpage/tusiji.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rover5056/React-Redux-webpack/37a914786fc47f227a743a8fe8021e75a4168300/src/view/Contactpage/tusiji.png -------------------------------------------------------------------------------- /src/view/FundListpage/component.js: -------------------------------------------------------------------------------- 1 | import React, {PropTypes, Component } from 'react'; 2 | import ReactCSSTransitionGroup from 'react-addons-css-transition-group' 3 | import Spin from 'Spin' 4 | import Dialog from 'Dialog' 5 | import styles from './style.less' 6 | 7 | 8 | class FundList extends Component { 9 | constructor(props) { 10 | super(props) 11 | } 12 | 13 | componentDidMount() { 14 | this.props.dataInit() 15 | } 16 | 17 | render() { 18 | const { FundData, dataInit, handleRefresh, backHome, handleCloseDialog } = this.props 19 | let list = ( 20 |
    21 | 22 | {FundData.datas.map((elem, index) => 23 |
  • {index}{elem.name}
  • 24 | )} 25 |
    26 |
27 | ) 28 | let spin = FundData.isloading ? () : null 29 | let dialogTip = ( handleCloseDialog()} 34 | onClose={() => handleCloseDialog()} 35 | > 36 |

{FundData.tipMassge}

37 |
) 38 | 39 | return ( 40 |
41 | {spin} 42 | {dialogTip} 43 |

Fund List

44 | {list} 45 |
46 |
第{FundData.page}页
47 |
handleRefresh(FundData.page)}>加载更多
48 |
dataInit()}>折叠
49 |
backHome()}>返回首页
50 |
51 | 52 |
53 | ) 54 | } 55 | } 56 | 57 | 58 | FundList.propTypes = { 59 | FundData: PropTypes.object.isRequired, 60 | dataInit: PropTypes.func.isRequired, 61 | handleRefresh: PropTypes.func.isRequired, 62 | backHome: PropTypes.func.isRequired, 63 | handleCloseDialog: PropTypes.func.isRequired 64 | } 65 | 66 | FundList.defaultProps = { 67 | FundData: { 68 | datas:[], 69 | page:0, 70 | isloading: true, 71 | isShowTip: false, 72 | tipMassge: null 73 | } 74 | }; 75 | 76 | 77 | export default FundList 78 | -------------------------------------------------------------------------------- /src/view/FundListpage/index.js: -------------------------------------------------------------------------------- 1 | import { connect } from 'react-redux' 2 | import { browserHistory } from 'react-router' 3 | import FundList from './component' 4 | // import fetchJsonp from 'fetch-jsonp' 如果使用 jsonp,使用此依赖,方法查看 https://github.com/camsong/fetch-jsonp 5 | 6 | 7 | const mapDispatchToProps = (dispatch) => { 8 | return{ 9 | dataInit: () => { 10 | const result = fetch('http://localhost:3003/page'+1) 11 | result.then(res => res.json()) 12 | .then(MovieData => { 13 | dispatch({type:'INIT_FUND', item:{datas: MovieData.data, page: 1}}) 14 | }); 15 | }, 16 | handleRefresh(page) { 17 | dispatch({type:'TURN_PAGE', item:{isloading: true}}) 18 | 19 | setTimeout(function () { 20 | const result = fetch('http://localhost:3003/page'+(page+1)) 21 | 22 | result.then(res => { 23 | if (res.ok == true) {return res.json()} 24 | 25 | dispatch({type:'TURN_PAGE', item:{isloading: false}}) 26 | return false; 27 | }) 28 | .then(MovieData => { 29 | if (MovieData) { 30 | dispatch({type:'TURN_PAGE', item:{datas: MovieData.data, page: page+1, isloading: false}}) 31 | } else { 32 | dispatch({type:'TURN_PAGE', item:{isloading: false, isShowTip: true, tipMassge: "已无更多"}}) 33 | } 34 | }); 35 | }, 500); 36 | }, 37 | backHome: () => { 38 | browserHistory.push(/${index}/); 39 | }, 40 | handleCloseDialog: () => { 41 | dispatch({type:'TURN_PAGE', item:{isShowTip: false}}) 42 | } 43 | } 44 | } 45 | 46 | const mapStateToProps = (state) => { 47 | return { 48 | FundData: state.FundPageInfo 49 | } 50 | } 51 | 52 | const FundListContainer = connect( 53 | mapStateToProps, 54 | mapDispatchToProps 55 | )(FundList) 56 | 57 | export default FundListContainer; -------------------------------------------------------------------------------- /src/view/FundListpage/style.less: -------------------------------------------------------------------------------- 1 | .content { 2 | display: block; 3 | width: 100%;height: 100%; 4 | background: #fff; 5 | h1 { 6 | line-height: 3; 7 | font-size: 40px; 8 | font-weight: bold; 9 | text-align: center; 10 | } 11 | .funditem { 12 | display: block; 13 | width: 100%; 14 | box-sizing: border-box; 15 | margin: 5px auto; 16 | padding: 0 10px; 17 | line-height: 3; 18 | background-color: #fff; 19 | 20 | i { 21 | font-weight: bold; 22 | margin-right: 10px; 23 | } 24 | } 25 | .bottom { 26 | display: block; 27 | width: 100%; 28 | margin: 10px auto; 29 | 30 | div{ 31 | display: inline-block; 32 | width: 25%; 33 | box-sizing: border-box; 34 | padding: 5px 10px; 35 | border: solid 1px #eee; 36 | color: #fff; 37 | text-align: center; 38 | background-color: #49A0FF; 39 | 40 | &:first-child { 41 | color: #49A0FF; 42 | background-color: #FFF; 43 | } 44 | } 45 | } 46 | } -------------------------------------------------------------------------------- /src/view/Homepage/component.js: -------------------------------------------------------------------------------- 1 | import React, {PropTypes, Component } from 'react' 2 | import {Link} from 'react-router' 3 | import Dialog from 'Dialog' 4 | 5 | import style from './style.less' 6 | 7 | 8 | class Home extends Component { 9 | 10 | constructor (props) { 11 | super(props); 12 | this.state = { 13 | DialogVisible: false 14 | } 15 | } 16 | componentDidMount() { 17 | this.content.style.height = window.innerHeight + 'px' 18 | } 19 | showDialog () { 20 | this.setState({ 21 | DialogVisible: true 22 | }); 23 | } 24 | 25 | hideDialog () { 26 | this.setState({ DialogVisible: false }); 27 | } 28 | 29 | render() { 30 | return ( 31 |
this.content = node}> 32 | 39 |
40 | here are some tips! 41 |
42 |
43 |

{ this.props.title }

44 |
45 | this demo includes following parts: 46 |
    47 |
  • React
  • 48 |
  • React-Router
  • 49 |
  • Redux
  • 50 |
  • ES6
  • 51 |
  • Webpack
  • 52 |
  • CssModule
  • 53 |
54 |
55 | change title (by redux) 56 | open a dialog 57 | About Page 58 | Contact Page 59 | fundlist Page 60 |
61 | 62 | 63 |
64 |
65 | ); 66 | } 67 | } 68 | 69 | 70 | Home.propTypes = { 71 | onChangeTitle: PropTypes.func.isRequired, 72 | handleSubmit: PropTypes.func.isRequired, 73 | title: PropTypes.string.isRequired 74 | } 75 | 76 | export default Home -------------------------------------------------------------------------------- /src/view/Homepage/index.js: -------------------------------------------------------------------------------- 1 | import { connect } from 'react-redux' 2 | import { browserHistory } from 'react-router'; 3 | 4 | import Home from './component' 5 | 6 | const mapDispatchToProps = (dispatch) => { 7 | return{ 8 | onChangeTitle: (e) => { 9 | e.preventDefault(); 10 | dispatch({type:'sayHi', text: 'Look Here'}); 11 | }, 12 | handleSubmit: (e) => { 13 | e.preventDefault(); 14 | const page = e.target.elements[0].value; 15 | const path = `/${page}/`; 16 | browserHistory.push(path); 17 | } 18 | } 19 | } 20 | 21 | const mapStateToProps = (state) => { 22 | return { 23 | title: state.changeText.HELLO_TEXT 24 | } 25 | } 26 | 27 | 28 | const HomeContainer = connect( 29 | mapStateToProps, 30 | mapDispatchToProps 31 | )(Home) 32 | 33 | export default HomeContainer; -------------------------------------------------------------------------------- /src/view/Homepage/style.less: -------------------------------------------------------------------------------- 1 | .content { 2 | position: absolute; 3 | top: 0;left: 0; 4 | display: block; 5 | width: 100%; 6 | overflow-y: scroll; 7 | overflow-x: hidden; 8 | -webkit-overflow-scrolling: touch; 9 | 10 | h1 { 11 | font-size: 36px; 12 | box-sizing: border-box; 13 | padding-left: 10px; 14 | } 15 | 16 | article { 17 | font-size: 18px; 18 | color: #333; 19 | box-sizing: border-box; 20 | padding: 0 10px; 21 | 22 | } 23 | 24 | li { 25 | list-style-type: disc; 26 | margin-left: 40px; 27 | } 28 | } 29 | 30 | .form { 31 | width: 230px; 32 | margin: 0 auto; 33 | line-height: 2.5; 34 | font-size: 18px; 35 | font-weight: bold; 36 | text-align: center; 37 | 38 | input { 39 | width: 70%; 40 | line-height: inherit; 41 | background-color: #fff; 42 | border-radius: 3px 0 0 3px; 43 | text-align: center; 44 | } 45 | 46 | button { 47 | width: 30%; 48 | line-height: inherit; 49 | color: #fff; 50 | border-radius: 0 3px 3px 0; 51 | background-color: #49A0FF; 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /src/view/NotFound/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { IndexLink } from 'react-router'; 3 | 4 | import styles from './style.less'; 5 | 6 | 7 | 8 | const NotFound = () => ( 9 |
10 |

404

11 |

can not found the page.

12 |

try enter "about" or "contact" page.

13 | Back to Home 14 |
15 | ) 16 | 17 | 18 | export default NotFound 19 | -------------------------------------------------------------------------------- /src/view/NotFound/style.less: -------------------------------------------------------------------------------- 1 | .content { 2 | h1 { 3 | line-height: 3; 4 | font-size: 40px; 5 | font-weight: bold; 6 | text-align: center; 7 | } 8 | 9 | p { 10 | width: 280px; 11 | margin: 15px auto; 12 | line-height: 1.5; 13 | color: #333; 14 | word-wrap: break-word; 15 | word-break: break-all; 16 | } 17 | 18 | } 19 | -------------------------------------------------------------------------------- /test/add.spec.js: -------------------------------------------------------------------------------- 1 | import { expect } from 'chai'; 2 | // import sinon from 'sinon'; 3 | 4 | import add from '../src/add.js' 5 | 6 | describe('加法函数测试', () => { 7 | it('1+1 应该等于 2',function() { 8 | expect(add(1, 1)).to.be.equal(2) 9 | }) 10 | 11 | it('任何数加0应该等于自身',() => { 12 | expect(add(0, 4)).to.be.equal(4) 13 | expect(add(0, 0)).to.be.equal(0) 14 | }) 15 | 16 | it('add 是个函数', () => { 17 | expect(add).to.be.an('function') 18 | }) 19 | }) -------------------------------------------------------------------------------- /test/index.spec.js: -------------------------------------------------------------------------------- 1 | import { expect } from 'chai'; 2 | // import sinon from 'sinon'; 3 | 4 | describe('hello react spec', () => { 5 | it('works!', () => { 6 | expect(true).to.be.true; 7 | }); 8 | }); -------------------------------------------------------------------------------- /test/test_helper.js.js: -------------------------------------------------------------------------------- 1 | import { expect } from 'chai'; 2 | import sinon from 'sinon'; 3 | global.expect = expect; 4 | global.sinon = sinon; -------------------------------------------------------------------------------- /webpack.dev.config.js: -------------------------------------------------------------------------------- 1 | var path = require('path'); 2 | var webpack = require('webpack'); 3 | var autoprefixer = require('autoprefixer'); 4 | 5 | module.exports = { 6 | devtool: 'cheap-module-eval-source-map', 7 | entry: [ 8 | 'webpack-dev-server/client?http://localhost:3000', 9 | 'webpack/hot/only-dev-server', 10 | './src/app' 11 | ], 12 | output: { 13 | path: path.join(__dirname, '/dist/'), 14 | filename: 'bundle.js', 15 | publicPath: '/static/' 16 | }, 17 | plugins: [ 18 | new webpack.optimize.OccurenceOrderPlugin(), 19 | new webpack.HotModuleReplacementPlugin(), 20 | new webpack.NoErrorsPlugin(), 21 | new webpack.ProvidePlugin({ 22 | 'Promise':'es6-promise', 23 | 'fetch': 'imports?this=>global!exports?global.fetch!whatwg-fetch' 24 | }), 25 | new webpack.DllReferencePlugin({ 26 | context: __dirname, 27 | manifest: require('./dist/dll/vendor-manifest.json') 28 | }) 29 | ], 30 | module: { 31 | preLoaders: [ 32 | {test: /\.js$/, loader: "eslint-loader", exclude: /node_modules/} 33 | ], 34 | loaders: [{ 35 | test: /\.js$/, 36 | loaders: ['react-hot', 'babel'], 37 | include: path.join(__dirname, 'src') 38 | }, { 39 | test: /\.less$/, 40 | exclude: [/node_modules/], 41 | loader: 'style!css?modules&importLoaders=1&localIdentName=[name]-[local]-[hash:base64:5]!resolve-url!less' 42 | }, { 43 | test: /\.(jpe?g|png|gif|svg)$/i, 44 | include: path.join(__dirname, 'src'), 45 | loaders: [ 46 | 'url?limit=10000&name=img/[hash:8].[name].[ext]' // 图片小于8k就转化为 base64, 或者单独作为文件 47 | ] 48 | }] 49 | }, 50 | postcss: [ autoprefixer({ browsers: ['last 2 versions'] }) ], 51 | eslint: { failOnWarning: true }, 52 | resolve: { 53 | extensions: ['', '.js', '.jsx', '.json'], 54 | modulesDirectories: ['node_modules', './src/module'], 55 | alias: { 56 | 'co': path.join(__dirname, './src/util/co') 57 | } 58 | } 59 | }; -------------------------------------------------------------------------------- /webpack.dll.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | const webpack = require('webpack'); 3 | var nodeModulesPath = path.join(__dirname, '/node_modules/'); 4 | 5 | module.exports = { 6 | entry: { 7 | vendor: ['react', 'react-dom'] 8 | }, 9 | output: { 10 | path: path.join(__dirname, 'dist/dll'), 11 | filename: '[name].dll.js', 12 | /** 13 | * output.library 14 | * 将会定义为 window.${output.library} 15 | * 在这次的例子中,将会定义为`window.vendor_library` 16 | */ 17 | library: '[name]_library' 18 | }, 19 | plugins: [ 20 | new webpack.DllPlugin({ 21 | /** 22 | * path 23 | * 定义 manifest 文件生成的位置 24 | * [name]的部分由entry的名字替换 25 | */ 26 | path: path.join(__dirname, 'dist/dll', '[name]-manifest.json'), 27 | /** 28 | * name 29 | * dll bundle 输出到那个全局变量上 30 | * 和 output.library 一样即可。 31 | */ 32 | name: '[name]_library' 33 | }) 34 | ], 35 | module: { 36 | noParse: [/react/] 37 | }, 38 | resolve: { 39 | extensions: ['', '.js', '.jsx', '.json'], 40 | alias: { 41 | 'react': path.join(nodeModulesPath,'react/dist/react.min'), 42 | 'react-dom': path.join(nodeModulesPath,'react-dom/dist/react-dom.min'), 43 | } 44 | } 45 | }; -------------------------------------------------------------------------------- /webpack.prod.config.js: -------------------------------------------------------------------------------- 1 | var path = require('path'); 2 | var webpack = require('webpack'); 3 | var autoprefixer = require('autoprefixer'); 4 | var HtmlWebpackPlugin = require('html-webpack-plugin'); 5 | var ExtractTextPlugin = require('extract-text-webpack-plugin'); 6 | var nodeModulesPath = path.join(__dirname, '/node_modules/'); 7 | 8 | module.exports = { 9 | devtool: false, 10 | entry: { 11 | bundle: './src/app.js' 12 | }, 13 | output: { 14 | path: path.join(__dirname, '/dist/'), 15 | filename: '[name]-[hash:5].min.js', 16 | chunkFilename: '[name]-[hash:5].chunk.js', 17 | publicPath: './' 18 | }, 19 | plugins: [ 20 | new webpack.optimize.OccurenceOrderPlugin(true), 21 | new webpack.optimize.DedupePlugin(), 22 | new webpack.optimize.UglifyJsPlugin({ 23 | compress: { 24 | warnings: false 25 | } 26 | }), 27 | new HtmlWebpackPlugin({ 28 | template: 'src/index.tpl.html', 29 | minify: { 30 | removeComments: true, 31 | collapseWhitespace: true, 32 | removeRedundantAttributes: true, 33 | useShortDoctype: true, 34 | removeEmptyAttributes: true, 35 | removeStyleLinkTypeAttributes: true, 36 | keepClosingSlash: true, 37 | minifyJS: true, 38 | minifyCSS: true, 39 | minifyURLs: true, 40 | }, 41 | inject: 'body', 42 | filename: 'index.html' 43 | }), 44 | new ExtractTextPlugin('[name]-[hash:5].min.css'), 45 | new webpack.DefinePlugin({ 46 | "process.env": { 47 | NODE_ENV: JSON.stringify("production") 48 | } 49 | }), 50 | new webpack.DllReferencePlugin({ 51 | context: __dirname, 52 | manifest: require('./dll/vendor-manifest.json') 53 | }) 54 | ], 55 | module: { 56 | loaders: [{ 57 | test: /\.js$/, 58 | loaders: ['babel'], 59 | include: path.join(__dirname, 'src'), 60 | }, { 61 | test: /\.less$/, 62 | exclude: [/node_modules/], 63 | loader: ExtractTextPlugin.extract('style', 'css?modules&importLoaders=1&localIdentName=[name]-[local]-[hash:base64:5]!resolve-url!postcss!less') 64 | }, { 65 | test: /\.(jpe?g|png|gif|svg)$/i, 66 | include: path.join(__dirname, 'src'), 67 | loaders: [ 68 | 'url?limit=10000&name=img/[hash:8].[name].[ext]', // 图片小于8k就转化为 base64, 或者单独作为文件 69 | 'image-webpack' // 图片压缩 70 | ] 71 | }] 72 | }, 73 | resolve: { 74 | extensions: ['', '.js', '.jsx', '.json'], 75 | modulesDirectories: ['node_modules', './src/module'], 76 | alias: { 77 | 'co': path.join(__dirname, './src/util/co') 78 | } 79 | }, 80 | postcss: [ 81 | require('autoprefixer') 82 | ] 83 | }; --------------------------------------------------------------------------------