From 63096c0ddfe4cdb1ff25161087623bf28ae8af24 Mon Sep 17 00:00:00 2001 From: Julian Steinwachs Date: Thu, 21 Jan 2016 08:57:00 +0100 Subject: [PATCH] better account handling --- build/app-bundle.js | 1340 +++-- build/twister-lib.js | 158 +- jsx/App.js | 87 +- jsx/common/FollowButton.js | 22 +- jsx/common/Post.js | 5 + jsx/home/Home.js | 2 +- jsx/other/Accounts.js | 47 + jsx/other/Settings.js | 3 +- node_modules/react-router/README.md | 14 +- node_modules/react-router/lib/Cancellation.js | 0 node_modules/react-router/lib/History.js | 4 +- node_modules/react-router/lib/Match.js | 42 +- node_modules/react-router/lib/Navigation.js | 0 node_modules/react-router/lib/PathUtils.js | 16 +- node_modules/react-router/lib/PropTypes.js | 4 +- node_modules/react-router/lib/Redirect.js | 0 node_modules/react-router/lib/Route.js | 100 +- .../react-router/lib/ScrollHistory.js | 22 +- node_modules/react-router/lib/State.js | 0 node_modules/react-router/lib/TestUtils.js | 0 node_modules/react-router/lib/Transition.js | 0 .../lib/actions/LocationActions.js | 0 .../lib/behaviors/ImitateBrowserBehavior.js | 0 .../lib/behaviors/ScrollToTopBehavior.js | 0 .../lib/components/ActiveHandler.js | 28 +- .../lib/components/ContextWrapper.js | 26 +- .../lib/components/DefaultRoute.js | 20 +- .../react-router/lib/components/Link.js | 36 +- .../lib/components/NotFoundRoute.js | 20 +- .../react-router/lib/components/Redirect.js | 20 +- .../react-router/lib/components/Route.js | 26 +- .../lib/components/RouteHandler.js | 28 +- node_modules/react-router/lib/createRouter.js | 34 +- .../lib/createRoutesFromReactChildren.js | 22 +- .../lib/getWindowScrollPosition.js | 4 +- node_modules/react-router/lib/index.js | 0 .../react-router/lib/isReactChildren.js | 0 .../lib/locations/HashLocation.js | 6 +- .../lib/locations/HistoryLocation.js | 4 +- .../lib/locations/RefreshLocation.js | 0 .../lib/locations/StaticLocation.js | 14 +- .../lib/locations/TestLocation.js | 12 +- node_modules/react-router/lib/runRouter.js | 0 .../react-router/lib/supportsHistory.js | 0 node_modules/react-router/lib/warning.js | 59 + .../node_modules/can-use-dom/.npmignore | 28 + .../node_modules/can-use-dom/LICENSE | 22 + .../node_modules/can-use-dom/index.js | 7 + .../node_modules/can-use-dom/package.json | 51 + .../node_modules/can-use-dom/test.js | 20 + .../node_modules/invariant/CHANGELOG.md | 33 + .../node_modules/invariant/README.md | 35 + .../node_modules/invariant/browser.js | 51 + .../node_modules/invariant/invariant.js | 53 + .../node_modules/loose-envify/.npmignore | 3 + .../node_modules/loose-envify/README.md | 45 + .../node_modules/loose-envify/custom.js | 2 + .../node_modules/loose-envify/index.js | 1 + .../node_modules/loose-envify/loose-envify.js | 36 + .../node_modules/js-tokens/LICENSE | 21 + .../node_modules/js-tokens/changelog.md | 65 + .../node_modules/js-tokens/index.js | 19 + .../node_modules/js-tokens/package.json | 61 + .../node_modules/js-tokens/readme.md | 204 + .../node_modules/loose-envify/package.json | 60 + .../node_modules/loose-envify/replace.js | 65 + .../node_modules/invariant/package.json | 64 + .../node_modules/object-assign/index.js | 0 .../node_modules/object-assign/license | 21 + .../node_modules/object-assign/package.json | 25 +- .../node_modules/object-assign/readme.md | 0 .../node_modules/qs/.jshintignore | 0 .../react-router/node_modules/qs/.jshintrc | 0 .../react-router/node_modules/qs/.npmignore | 0 .../react-router/node_modules/qs/.travis.yml | 0 .../react-router/node_modules/qs/CHANGELOG.md | 0 .../node_modules/qs/CONTRIBUTING.md | 0 .../react-router/node_modules/qs/Makefile | 0 .../react-router/node_modules/qs/index.js | 0 .../react-router/node_modules/qs/package.json | 5 +- node_modules/react-router/package.json | 24 +- node_modules/react-router/umd/ReactRouter.js | 4950 ++++++++--------- .../react-router/umd/ReactRouter.min.js | 5 +- 83 files changed, 4772 insertions(+), 3429 deletions(-) create mode 100644 jsx/other/Accounts.js mode change 100755 => 100644 node_modules/react-router/README.md mode change 100755 => 100644 node_modules/react-router/lib/Cancellation.js mode change 100755 => 100644 node_modules/react-router/lib/History.js mode change 100755 => 100644 node_modules/react-router/lib/Match.js mode change 100755 => 100644 node_modules/react-router/lib/Navigation.js mode change 100755 => 100644 node_modules/react-router/lib/PathUtils.js mode change 100755 => 100644 node_modules/react-router/lib/PropTypes.js mode change 100755 => 100644 node_modules/react-router/lib/Redirect.js mode change 100755 => 100644 node_modules/react-router/lib/Route.js mode change 100755 => 100644 node_modules/react-router/lib/ScrollHistory.js mode change 100755 => 100644 node_modules/react-router/lib/State.js mode change 100755 => 100644 node_modules/react-router/lib/TestUtils.js mode change 100755 => 100644 node_modules/react-router/lib/Transition.js mode change 100755 => 100644 node_modules/react-router/lib/actions/LocationActions.js mode change 100755 => 100644 node_modules/react-router/lib/behaviors/ImitateBrowserBehavior.js mode change 100755 => 100644 node_modules/react-router/lib/behaviors/ScrollToTopBehavior.js mode change 100755 => 100644 node_modules/react-router/lib/components/ActiveHandler.js mode change 100755 => 100644 node_modules/react-router/lib/components/ContextWrapper.js mode change 100755 => 100644 node_modules/react-router/lib/components/DefaultRoute.js mode change 100755 => 100644 node_modules/react-router/lib/components/Link.js mode change 100755 => 100644 node_modules/react-router/lib/components/NotFoundRoute.js mode change 100755 => 100644 node_modules/react-router/lib/components/Redirect.js mode change 100755 => 100644 node_modules/react-router/lib/components/Route.js mode change 100755 => 100644 node_modules/react-router/lib/components/RouteHandler.js mode change 100755 => 100644 node_modules/react-router/lib/createRouter.js mode change 100755 => 100644 node_modules/react-router/lib/createRoutesFromReactChildren.js mode change 100755 => 100644 node_modules/react-router/lib/getWindowScrollPosition.js mode change 100755 => 100644 node_modules/react-router/lib/index.js mode change 100755 => 100644 node_modules/react-router/lib/isReactChildren.js mode change 100755 => 100644 node_modules/react-router/lib/locations/HashLocation.js mode change 100755 => 100644 node_modules/react-router/lib/locations/HistoryLocation.js mode change 100755 => 100644 node_modules/react-router/lib/locations/RefreshLocation.js mode change 100755 => 100644 node_modules/react-router/lib/locations/StaticLocation.js mode change 100755 => 100644 node_modules/react-router/lib/locations/TestLocation.js mode change 100755 => 100644 node_modules/react-router/lib/runRouter.js mode change 100755 => 100644 node_modules/react-router/lib/supportsHistory.js create mode 100644 node_modules/react-router/lib/warning.js create mode 100644 node_modules/react-router/node_modules/can-use-dom/.npmignore create mode 100644 node_modules/react-router/node_modules/can-use-dom/LICENSE create mode 100644 node_modules/react-router/node_modules/can-use-dom/index.js create mode 100644 node_modules/react-router/node_modules/can-use-dom/package.json create mode 100644 node_modules/react-router/node_modules/can-use-dom/test.js create mode 100644 node_modules/react-router/node_modules/invariant/CHANGELOG.md create mode 100644 node_modules/react-router/node_modules/invariant/README.md create mode 100644 node_modules/react-router/node_modules/invariant/browser.js create mode 100644 node_modules/react-router/node_modules/invariant/invariant.js create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/.npmignore create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/README.md create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/custom.js create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/index.js create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/loose-envify.js create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/LICENSE create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/changelog.md create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/index.js create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/package.json create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/readme.md create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/package.json create mode 100644 node_modules/react-router/node_modules/invariant/node_modules/loose-envify/replace.js create mode 100644 node_modules/react-router/node_modules/invariant/package.json mode change 100755 => 100644 node_modules/react-router/node_modules/object-assign/index.js create mode 100644 node_modules/react-router/node_modules/object-assign/license mode change 100755 => 100644 node_modules/react-router/node_modules/object-assign/package.json mode change 100755 => 100644 node_modules/react-router/node_modules/object-assign/readme.md mode change 100755 => 100644 node_modules/react-router/node_modules/qs/.jshintignore mode change 100755 => 100644 node_modules/react-router/node_modules/qs/.jshintrc mode change 100755 => 100644 node_modules/react-router/node_modules/qs/.npmignore mode change 100755 => 100644 node_modules/react-router/node_modules/qs/.travis.yml mode change 100755 => 100644 node_modules/react-router/node_modules/qs/CHANGELOG.md mode change 100755 => 100644 node_modules/react-router/node_modules/qs/CONTRIBUTING.md mode change 100755 => 100644 node_modules/react-router/node_modules/qs/Makefile mode change 100755 => 100644 node_modules/react-router/node_modules/qs/index.js mode change 100755 => 100644 node_modules/react-router/node_modules/qs/package.json mode change 100755 => 100644 node_modules/react-router/package.json mode change 100755 => 100644 node_modules/react-router/umd/ReactRouter.js mode change 100755 => 100644 node_modules/react-router/umd/ReactRouter.min.js diff --git a/build/app-bundle.js b/build/app-bundle.js index c5098ab..8d79103 100644 --- a/build/app-bundle.js +++ b/build/app-bundle.js @@ -39,6 +39,7 @@ var Mentions = require('./profile/Mentions.js'); var Conversation = require('./other/Conversation.js'); var Hashtag = require('./other/Hashtag.js'); var Settings = require('./other/Settings.js'); +var Accounts = require('./other/Accounts.js'); var AppSettingsMixin = require('./common/AppSettingsMixin.js'); App = React.createClass({displayName: "App", @@ -67,6 +68,33 @@ App = React.createClass({displayName: "App", } else {return "none"} }, + getInitialState: function () { + + var state={}; + + state.activeAccount = localStorage.getItem("twister-react-activeAccount") + + state.accounts = Twister.getAccounts().map(function(acc){ + return { + name: acc.getUsername(), + status: acc.getKeyStatus() + } + }); + + //console.log(state); + + return state; + + }, + + componentDidMount: function () { + + this.setInterval(this.saveCache,300000); + + this.setInterval(this.checkAccounts,60000); + + }, + clearCache: function () { localStorage.setItem("twister-cache", null); }, @@ -77,6 +105,24 @@ App = React.createClass({displayName: "App", localStorage.setItem("twister-cache", JSON.stringify(Twister.serializeCache())) }, + checkAccounts: function() { + + this.state.accounts.map(function(acc){ + + Twister.getAccount(newaccoutname).verifyKey(function(key){ + thisComponent.setState(function(oldstate,props){ + + oldstate.accounts[acc].status = key.getStatus(); + + return oldstate; + + }); + }); + + }) + + }, + switchAccount: function (newaccoutname) { //console.log(newaccoutname); @@ -101,28 +147,14 @@ App = React.createClass({displayName: "App", } - }, - - getInitialState: function () { - - var state={}; - - state.activeAccount = localStorage.getItem("twister-react-activeAccount") - - state.accounts = Twister.getAccounts(); - - if (!state.activeAccount) { state.activeAccount=state.accounts[0]; } - - //console.log(state); - - return state; - - }, - - componentDidMount: function () { + this.setState(function(oldstate,props){ + oldstate.accounts.push({ + name: event.detail.getUsername(), + status: event.detail.getKeyStatus() + }) + return oldstate; + }) - this.setInterval(this.saveCache,300000); - }, render: function() { @@ -135,11 +167,11 @@ App = React.createClass({displayName: "App", for (var i in this.state.accounts) { userbuttons.push( React.createElement(MenuItem, { - key: this.state.accounts[i], - bsStyle: this.state.accounts[i]==this.state.activeAccount ? 'primary' : 'default', - onClick: this.switchAccount.bind(this,this.state.accounts[i]), + key: this.state.accounts[i].name, + bsStyle: this.state.accounts[i].name==this.state.activeAccount ? 'primary' : 'default', + onClick: this.switchAccount.bind(this,this.state.accounts[i].name), href: "javascript:void(0);" - }, this.state.accounts[i]) + }, this.state.accounts[i].name) ); } @@ -167,12 +199,14 @@ App = React.createClass({displayName: "App", }, "Clear Cache"), React.createElement(MenuItem, {href: "#/search"}, "Search"), React.createElement(MenuItem, {href: "#/settings"}, "Settings"), + React.createElement(MenuItem, {href: "#/accounts"}, "Accounts"), React.createElement(MenuItem, {href: "#/howtofollow"}, "How to Follow"), React.createElement(MenuItem, {href: "#/trendinghashtags"}, "Trending Hashtags") ) ), React.createElement("br", null), React.createElement(RouteHandler, { + accounts: this.state.accounts, activeAccount: this.state.activeAccount, key: this.getHandlerKey()} ) @@ -201,6 +235,7 @@ var routes = ( React.createElement(Route, {name: "conversation", path: "/conversation/:username/:postid", handler: Conversation}), React.createElement(Route, {name: "hashtag", path: "/hashtag/:hashtag", handler: Hashtag}), React.createElement(Route, {name: "settings", path: "/settings", handler: Settings}), + React.createElement(Route, {name: "accounts", path: "/accounts", handler: Accounts}), React.createElement(DefaultRoute, {name: "home", handler: Home}) ) ); @@ -229,7 +264,7 @@ if (accounts.length==0) { pollInterval:60, pollIntervalProfile: 3600, ignoredUsers: "nobody", - host: "http://tschaul.com:8080" + host: window.location.protocol+"//"+window.location.host+"/" }; @@ -308,7 +343,7 @@ setInterval(function(){ },1000); -},{"./common/AppSettingsMixin.js":2,"./common/SafeStateChangeMixin.js":13,"./common/SetIntervalMixin.js":14,"./home/Home.js":16,"./other/Conversation.js":18,"./other/Hashtag.js":19,"./other/Settings.js":21,"./profile/Followings.js":24,"./profile/Mentions.js":25,"./profile/Profile.js":26,"./profile/Timeline.js":27,"react":299,"react-bootstrap":79,"react-router":112}],2:[function(require,module,exports){ +},{"./common/AppSettingsMixin.js":2,"./common/SafeStateChangeMixin.js":13,"./common/SetIntervalMixin.js":14,"./home/Home.js":16,"./other/Accounts.js":18,"./other/Conversation.js":19,"./other/Hashtag.js":20,"./other/Settings.js":22,"./profile/Followings.js":25,"./profile/Mentions.js":26,"./profile/Profile.js":27,"./profile/Timeline.js":28,"react":303,"react-bootstrap":80,"react-router":113}],2:[function(require,module,exports){ module.exports = AppSettingsMixin = { getInitialState: function() { @@ -414,15 +449,19 @@ module.exports = FollowButton = React.createClass({displayName: "FollowButton", thisComponent = this; - Twister.getUser(thisComponent.props.activeAccount).doFollowings(function(followings){ - if(followings.map(function(fol){ - return fol.getUsername(); - }).indexOf(thisComponent.props.username)<0){ - thisComponent.setStateSafe({isCurrentlyFollowing: false, hasLoaded: true}); - }else{ - thisComponent.setStateSafe({isCurrentlyFollowing: true, hasLoaded: true}); - } - }) + if(thisComponent.props.activeAccount){ + Twister.getUser(thisComponent.props.activeAccount).doFollowings(function(followings){ + if(followings.map(function(fol){ + return fol.getUsername(); + }).indexOf(thisComponent.props.username)<0){ + thisComponent.setStateSafe({isCurrentlyFollowing: false, hasLoaded: true}); + }else{ + thisComponent.setStateSafe({isCurrentlyFollowing: true, hasLoaded: true}); + } + }) + } + + }, render: function() { @@ -439,7 +478,7 @@ module.exports = FollowButton = React.createClass({displayName: "FollowButton", ); } }); -},{"../common/SafeStateChangeMixin.js":13,"react":299,"react-bootstrap":79}],5:[function(require,module,exports){ +},{"../common/SafeStateChangeMixin.js":13,"react":303,"react-bootstrap":80}],5:[function(require,module,exports){ var ReactBootstrap = require('react-bootstrap') , Grid = ReactBootstrap.Grid @@ -482,7 +521,7 @@ module.exports = MiniProfile = React.createClass({displayName: "MiniProfile", ); } }); -},{"../common/ProfileMixin.js":10,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":299,"react-bootstrap":79}],6:[function(require,module,exports){ +},{"../common/ProfileMixin.js":10,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":303,"react-bootstrap":80}],6:[function(require,module,exports){ var ReactBootstrap = require('react-bootstrap') , Grid = ReactBootstrap.Grid @@ -606,6 +645,11 @@ module.exports = Post = React.createClass({displayName: "Post", render: function() { var post = Twister.getUser(this.props.post.username).getPost(this.props.post.id); + if(!post){ + return ( + React.createElement("span", null) + ) + } var retwist = false; var retwistWithComment = false; var comment = ""; @@ -718,7 +762,7 @@ module.exports = Post = React.createClass({displayName: "Post",
*/ -},{"../common/EventListenerMixin.js":3,"../common/PostContent.js":7,"../common/ReplyModalButton.js":11,"../common/RetwistModalButton.js":12,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":299,"react-bootstrap":79}],7:[function(require,module,exports){ +},{"../common/EventListenerMixin.js":3,"../common/PostContent.js":7,"../common/ReplyModalButton.js":11,"../common/RetwistModalButton.js":12,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":303,"react-bootstrap":80}],7:[function(require,module,exports){ var React = require('react'); @@ -926,7 +970,7 @@ module.exports = Post = React.createClass({displayName: "Post",
*/ -},{"react":299}],8:[function(require,module,exports){ +},{"react":303}],8:[function(require,module,exports){ var ReactBootstrap = require('react-bootstrap') , NavItem = ReactBootstrap.NavItem @@ -973,7 +1017,7 @@ module.exports = Postboard = React.createClass({displayName: "Postboard", ); } }); -},{"../common/Post.js":6,"react-bootstrap":79,"react/addons":127}],9:[function(require,module,exports){ +},{"../common/Post.js":6,"react-bootstrap":80,"react/addons":131}],9:[function(require,module,exports){ var ReactBootstrap = require('react-bootstrap') , NavItem = ReactBootstrap.NavItem @@ -1020,7 +1064,7 @@ module.exports = Postboard = React.createClass({displayName: "Postboard", ); } }); -},{"../common/Post.js":6,"react-bootstrap":79,"react/addons":127}],10:[function(require,module,exports){ +},{"../common/Post.js":6,"react-bootstrap":80,"react/addons":131}],10:[function(require,module,exports){ var AppSettingsMixin = require('../common/AppSettingsMixin.js'); var EventListenerMixin = require('../common/EventListenerMixin.js'); @@ -1209,7 +1253,7 @@ module.exports = ReplyModalButton = React.createClass({displayName: "ReplyModalB } }); -},{"../common/PostContent.js":7,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":299,"react-bootstrap":79}],12:[function(require,module,exports){ +},{"../common/PostContent.js":7,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":303,"react-bootstrap":80}],12:[function(require,module,exports){ var ReactBootstrap = require('react-bootstrap') , OverlayMixin = ReactBootstrap.OverlayMixin @@ -1284,7 +1328,7 @@ module.exports = RetwistModalButton = React.createClass({displayName: "RetwistMo } }); -},{"../common/PostContent.js":7,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":299,"react-bootstrap":79}],13:[function(require,module,exports){ +},{"../common/PostContent.js":7,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":303,"react-bootstrap":80}],13:[function(require,module,exports){ function isValidLifeCycleForReplaceState(instance) { // See function validateLifeCycleOnReplaceState(instance) in // ReactCompositeComponent.js @@ -1561,7 +1605,7 @@ module.exports = Home = React.createClass({displayName: "Home", this.setInterval(this.updatePosts, this.state.appSettings.pollInterval*1000); } else { - window.location.hash="#/settings"; + window.location.hash="#/accounts"; console.log("active account is null") } @@ -1596,7 +1640,7 @@ module.exports = Home = React.createClass({displayName: "Home", ); } }); -},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"../home/NewPostModalButton.js":17,"react":299,"react-bootstrap":79}],17:[function(require,module,exports){ +},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"../home/NewPostModalButton.js":17,"react":303,"react-bootstrap":80}],17:[function(require,module,exports){ var ReactBootstrap = require('react-bootstrap') , OverlayMixin = ReactBootstrap.OverlayMixin @@ -1674,7 +1718,55 @@ module.exports = NewPostModalButton = React.createClass({displayName: "NewPostMo } }); -},{"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":299,"react-bootstrap":79}],18:[function(require,module,exports){ +},{"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":303,"react-bootstrap":80}],18:[function(require,module,exports){ +var React = require('react'); +var SetIntervalMixin = require("../common/SetIntervalMixin.js"); +var SafeStateChangeMixin = require('../common/SafeStateChangeMixin.js'); +var EventListenerMixin = require('../common/EventListenerMixin.js'); +var AppSettingsMixin = require('../common/AppSettingsMixin.js'); + +var ImportAccountModalButton = require('../other/ImportAccountModalButton.js'); + +var ReactBootstrap = require('react-bootstrap') + , NavItem = ReactBootstrap.NavItem + , Nav = ReactBootstrap.Nav + , ListGroup = ReactBootstrap.ListGroup + , ListGroupItem = ReactBootstrap.ListGroupItem + , Panel = ReactBootstrap.Panel + , Glyphicon = ReactBootstrap.Glyphicon + , Button = ReactBootstrap.Button + , Input = ReactBootstrap.Input + +module.exports = Accounts = React.createClass({displayName: "Accounts", + + mixins: [ + SetIntervalMixin, + SafeStateChangeMixin, + AppSettingsMixin + ], + contextTypes: { + router: React.PropTypes.func + }, + render: function() { + return ( + React.createElement(ListGroup, null, + React.createElement(ListGroupItem, null, "Settings"), + React.createElement(ListGroupItem, null, + React.createElement("ul", null, + this.props.accounts.map(function(acc,index) { + //console.log(acc,index) + return ( + React.createElement("li", null, acc.name, " - ", acc.status) + ); + }) + ), + React.createElement(ImportAccountModalButton, null) + ) + ) + ); + } +}); +},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../other/ImportAccountModalButton.js":21,"react":303,"react-bootstrap":80}],19:[function(require,module,exports){ var React = require('react'); var Postboard = require("../common/Postboard.js"); var SetIntervalMixin = require("../common/SetIntervalMixin.js"); @@ -1777,7 +1869,7 @@ module.exports = Conversation = React.createClass({displayName: "Conversation", ); } }); -},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react":299,"react-bootstrap":79}],19:[function(require,module,exports){ +},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react":303,"react-bootstrap":80}],20:[function(require,module,exports){ var React = require('react'); var Postboard = require("../common/Postboard.js"); var SetIntervalMixin = require("../common/SetIntervalMixin.js"); @@ -1858,7 +1950,7 @@ module.exports = Hashtag = React.createClass({displayName: "Hashtag", ); } }); -},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react":299,"react-bootstrap":79}],20:[function(require,module,exports){ +},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react":303,"react-bootstrap":80}],21:[function(require,module,exports){ var ReactBootstrap = require('react-bootstrap') , OverlayMixin = ReactBootstrap.OverlayMixin @@ -1951,7 +2043,7 @@ module.exports = ImportAccountModalButton = React.createClass({displayName: "Imp } }); -},{"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":299,"react-bootstrap":79}],21:[function(require,module,exports){ +},{"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":303,"react-bootstrap":80}],22:[function(require,module,exports){ var React = require('react'); var SetIntervalMixin = require("../common/SetIntervalMixin.js"); var SafeStateChangeMixin = require('../common/SafeStateChangeMixin.js'); @@ -1970,7 +2062,7 @@ var ReactBootstrap = require('react-bootstrap') , Button = ReactBootstrap.Button , Input = ReactBootstrap.Input -module.exports = Home = React.createClass({displayName: "Home", +module.exports = Settings = React.createClass({displayName: "Settings", mixins: [ SetIntervalMixin, @@ -2019,14 +2111,13 @@ module.exports = Home = React.createClass({displayName: "Home", defaultValue: this.state.appSettings.host, labelClassName: "col-xs-4", wrapperClassName: "col-xs-8", className: "settings-host"}), React.createElement(Input, {type: "submit", value: "Save", wrapperClassName: "col-xs-offset-10 col-xs-2"}) - ), - React.createElement(ImportAccountModalButton, null) + ) ) ) ); } }); -},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../other/ImportAccountModalButton.js":20,"react":299,"react-bootstrap":79}],22:[function(require,module,exports){ +},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../other/ImportAccountModalButton.js":21,"react":303,"react-bootstrap":80}],23:[function(require,module,exports){ @@ -2172,7 +2263,7 @@ module.exports = EditAvatarModalButton = React.createClass({displayName: "EditAv } }); -},{"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":299,"react-bootstrap":79}],23:[function(require,module,exports){ +},{"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":303,"react-bootstrap":80}],24:[function(require,module,exports){ var ReactBootstrap = require('react-bootstrap') , OverlayMixin = ReactBootstrap.OverlayMixin @@ -2297,7 +2388,7 @@ module.exports = EditProfileModalButton = React.createClass({displayName: "EditP } }); -},{"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":299,"react-bootstrap":79}],24:[function(require,module,exports){ +},{"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"react":303,"react-bootstrap":80}],25:[function(require,module,exports){ var React = require('react/addons'); @@ -2382,7 +2473,7 @@ module.exports = Followings = React.createClass({displayName: "Followings", } }); -},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/MiniProfile.js":5,"../common/ProfileBoard.js":9,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react-bootstrap":79,"react/addons":127}],25:[function(require,module,exports){ +},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/MiniProfile.js":5,"../common/ProfileBoard.js":9,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react-bootstrap":80,"react/addons":131}],26:[function(require,module,exports){ var React = require('react'); var MiniProfile = require("../common/MiniProfile.js"); var Postboard = require("../common/Postboard.js"); @@ -2438,7 +2529,7 @@ module.exports = Mentions = React.createClass({displayName: "Mentions", ); } }); -},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/MiniProfile.js":5,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react":299}],26:[function(require,module,exports){ +},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/MiniProfile.js":5,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react":303}],27:[function(require,module,exports){ var ReactBootstrap = require('react-bootstrap') , Grid = ReactBootstrap.Grid @@ -2540,7 +2631,7 @@ module.exports = Post = React.createClass({displayName: "Post", ); } }); -},{"../common/FollowButton.js":4,"../common/ProfileMixin.js":10,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../profile/EditAvatarModalButton.js":22,"../profile/EditProfileModalButton.js":23,"react":299,"react-bootstrap":79,"react-router":112}],27:[function(require,module,exports){ +},{"../common/FollowButton.js":4,"../common/ProfileMixin.js":10,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../profile/EditAvatarModalButton.js":23,"../profile/EditProfileModalButton.js":24,"react":303,"react-bootstrap":80,"react-router":113}],28:[function(require,module,exports){ var React = require('react'); var Postboard = require("../common/Postboard.js"); var SetIntervalMixin = require("../common/SetIntervalMixin.js"); @@ -2642,7 +2733,7 @@ module.exports = Timeline = React.createClass({displayName: "Timeline", ); } }); -},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react":299,"react-bootstrap":79}],28:[function(require,module,exports){ +},{"../common/AppSettingsMixin.js":2,"../common/EventListenerMixin.js":3,"../common/Postboard.js":8,"../common/SafeStateChangeMixin.js":13,"../common/SetIntervalMixin.js":14,"../common/StreamMixin.js":15,"react":303,"react-bootstrap":80}],29:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -2666,7 +2757,7 @@ var Accordion = React.createClass({ }); module.exports = Accordion; -},{"./PanelGroup":67,"react":299}],29:[function(require,module,exports){ +},{"./PanelGroup":68,"react":303}],30:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -2704,7 +2795,7 @@ var Affix = React.createClass({ }); module.exports = Affix; -},{"./AffixMixin":30,"./utils/domUtils":86,"classnames":87,"react":299}],30:[function(require,module,exports){ +},{"./AffixMixin":31,"./utils/domUtils":87,"classnames":88,"react":303}],31:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -2840,7 +2931,7 @@ var AffixMixin = { }; module.exports = AffixMixin; -},{"./utils/EventListener":81,"./utils/domUtils":86,"react":299}],31:[function(require,module,exports){ +},{"./utils/EventListener":82,"./utils/domUtils":87,"react":303}],32:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -2908,7 +2999,7 @@ var Alert = React.createClass({ }); module.exports = Alert; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],32:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],33:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -2947,7 +3038,7 @@ var Badge = React.createClass({ }); module.exports = Badge; -},{"./utils/ValidComponentChildren":84,"classnames":87,"react":299}],33:[function(require,module,exports){ +},{"./utils/ValidComponentChildren":85,"classnames":88,"react":303}],34:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -2992,7 +3083,7 @@ var BootstrapMixin = { }; module.exports = BootstrapMixin; -},{"./constants":78,"react":299}],34:[function(require,module,exports){ +},{"./constants":79,"react":303}],35:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -3087,7 +3178,7 @@ var Button = React.createClass({ }); module.exports = Button; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],35:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],36:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -3132,7 +3223,7 @@ var ButtonGroup = React.createClass({ }); module.exports = ButtonGroup; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],36:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],37:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -3170,7 +3261,7 @@ var ButtonToolbar = React.createClass({ }); module.exports = ButtonToolbar; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],37:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],38:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -3455,7 +3546,7 @@ var Carousel = React.createClass({ }); module.exports = Carousel; -},{"./BootstrapMixin":33,"./utils/ValidComponentChildren":84,"classnames":87,"react":299}],38:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./utils/ValidComponentChildren":85,"classnames":88,"react":303}],39:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -3557,7 +3648,7 @@ var CarouselItem = React.createClass({ }); module.exports = CarouselItem; -},{"./utils/TransitionEvents":83,"classnames":87,"react":299}],39:[function(require,module,exports){ +},{"./utils/TransitionEvents":84,"classnames":88,"react":303}],40:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -3640,7 +3731,7 @@ var Col = React.createClass({ }); module.exports = Col; -},{"./constants":78,"classnames":87,"react":299}],40:[function(require,module,exports){ +},{"./constants":79,"classnames":88,"react":303}],41:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -3811,7 +3902,7 @@ var CollapsableMixin = { }; module.exports = CollapsableMixin; -},{"react":299,"react/lib/ReactTransitionEvents":223}],41:[function(require,module,exports){ +},{"react":303,"react/lib/ReactTransitionEvents":227}],42:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -3932,7 +4023,7 @@ var CollapsableNav = React.createClass({ }); module.exports = CollapsableNav; -},{"./BootstrapMixin":33,"./CollapsableMixin":40,"./utils/ValidComponentChildren":84,"./utils/createChainedFunction":85,"./utils/domUtils":86,"classnames":87,"react":299}],42:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./CollapsableMixin":41,"./utils/ValidComponentChildren":85,"./utils/createChainedFunction":86,"./utils/domUtils":87,"classnames":88,"react":303}],43:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4066,7 +4157,7 @@ var DropdownButton = React.createClass({ }); module.exports = DropdownButton; -},{"./BootstrapMixin":33,"./Button":34,"./ButtonGroup":35,"./DropdownMenu":43,"./DropdownStateMixin":44,"./utils/ValidComponentChildren":84,"./utils/createChainedFunction":85,"classnames":87,"react":299}],43:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./Button":35,"./ButtonGroup":36,"./DropdownMenu":44,"./DropdownStateMixin":45,"./utils/ValidComponentChildren":85,"./utils/createChainedFunction":86,"classnames":88,"react":303}],44:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4120,7 +4211,7 @@ var DropdownMenu = React.createClass({ }); module.exports = DropdownMenu; -},{"./utils/ValidComponentChildren":84,"./utils/createChainedFunction":85,"classnames":87,"react":299}],44:[function(require,module,exports){ +},{"./utils/ValidComponentChildren":85,"./utils/createChainedFunction":86,"classnames":88,"react":303}],45:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4208,7 +4299,7 @@ var DropdownStateMixin = { }; module.exports = DropdownStateMixin; -},{"./utils/EventListener":81,"./utils/domUtils":86,"react":299}],45:[function(require,module,exports){ +},{"./utils/EventListener":82,"./utils/domUtils":87,"react":303}],46:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4287,7 +4378,7 @@ module.exports = { } } }; -},{"./utils/domUtils":86,"react":299}],46:[function(require,module,exports){ +},{"./utils/domUtils":87,"react":303}],47:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4348,7 +4439,7 @@ FormGroup.propTypes = { }; module.exports = FormGroup; -},{"classnames":87,"react":299}],47:[function(require,module,exports){ +},{"classnames":88,"react":303}],48:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4392,7 +4483,7 @@ var Glyphicon = React.createClass({ }); module.exports = Glyphicon; -},{"./BootstrapMixin":33,"./constants":78,"classnames":87,"react":299}],48:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./constants":79,"classnames":88,"react":303}],49:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4431,7 +4522,7 @@ var Grid = React.createClass({ }); module.exports = Grid; -},{"classnames":87,"react":299}],49:[function(require,module,exports){ +},{"classnames":88,"react":303}],50:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4674,7 +4765,7 @@ var Input = React.createClass({ }); module.exports = Input; -},{"./Button":34,"./FormGroup":46,"classnames":87,"react":299}],50:[function(require,module,exports){ +},{"./Button":35,"./FormGroup":47,"classnames":88,"react":303}],51:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4761,7 +4852,7 @@ var Interpolate = React.createClass({ }); module.exports = Interpolate; -},{"./utils/Object.assign":82,"./utils/ValidComponentChildren":84,"react":299}],51:[function(require,module,exports){ +},{"./utils/Object.assign":83,"./utils/ValidComponentChildren":85,"react":303}],52:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4785,7 +4876,7 @@ var Jumbotron = React.createClass({ }); module.exports = Jumbotron; -},{"classnames":87,"react":299}],52:[function(require,module,exports){ +},{"classnames":88,"react":303}],53:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4822,7 +4913,7 @@ var Label = React.createClass({ }); module.exports = Label; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],53:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],54:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4878,7 +4969,7 @@ ListGroup.propTypes = { }; module.exports = ListGroup; -},{"./utils/ValidComponentChildren":84,"classnames":87,"react":299}],54:[function(require,module,exports){ +},{"./utils/ValidComponentChildren":85,"classnames":88,"react":303}],55:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -4974,7 +5065,7 @@ var ListGroupItem = React.createClass({ }); module.exports = ListGroupItem; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],55:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],56:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -5042,7 +5133,7 @@ var MenuItem = React.createClass({ }); module.exports = MenuItem; -},{"classnames":87,"react":299}],56:[function(require,module,exports){ +},{"classnames":88,"react":303}],57:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -5227,7 +5318,7 @@ var Modal = React.createClass({ }); module.exports = Modal; -},{"./BootstrapMixin":33,"./FadeMixin":45,"./utils/EventListener":81,"./utils/domUtils":86,"classnames":87,"react":299}],57:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./FadeMixin":46,"./utils/EventListener":82,"./utils/domUtils":87,"classnames":88,"react":303}],58:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -5294,7 +5385,7 @@ var ModalTrigger = React.createClass({ }); module.exports = ModalTrigger; -},{"./OverlayMixin":61,"./utils/createChainedFunction":85,"react":299}],58:[function(require,module,exports){ +},{"./OverlayMixin":62,"./utils/createChainedFunction":86,"react":303}],59:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -5420,7 +5511,7 @@ var Nav = React.createClass({ }); module.exports = Nav; -},{"./BootstrapMixin":33,"./CollapsableMixin":40,"./utils/ValidComponentChildren":84,"./utils/createChainedFunction":85,"./utils/domUtils":86,"classnames":87,"react":299}],59:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./CollapsableMixin":41,"./utils/ValidComponentChildren":85,"./utils/createChainedFunction":86,"./utils/domUtils":87,"classnames":88,"react":303}],60:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -5506,7 +5597,7 @@ var NavItem = React.createClass({ }); module.exports = NavItem; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],60:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],61:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -5665,7 +5756,7 @@ var Navbar = React.createClass({ }); module.exports = Navbar; -},{"./BootstrapMixin":33,"./utils/ValidComponentChildren":84,"./utils/createChainedFunction":85,"classnames":87,"react":299}],61:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./utils/ValidComponentChildren":85,"./utils/createChainedFunction":86,"classnames":88,"react":303}],62:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -5739,7 +5830,7 @@ module.exports = { return React.findDOMNode(this.props.container) || domUtils.ownerDocument(this).body; } }; -},{"./utils/CustomPropTypes":80,"./utils/domUtils":86,"react":299}],62:[function(require,module,exports){ +},{"./utils/CustomPropTypes":81,"./utils/domUtils":87,"react":303}],63:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -5971,7 +6062,7 @@ var OverlayTrigger = React.createClass({ }); module.exports = OverlayTrigger; -},{"./OverlayMixin":61,"./utils/Object.assign":82,"./utils/createChainedFunction":85,"./utils/domUtils":86,"react":299}],63:[function(require,module,exports){ +},{"./OverlayMixin":62,"./utils/Object.assign":83,"./utils/createChainedFunction":86,"./utils/domUtils":87,"react":303}],64:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -5999,7 +6090,7 @@ var PageHeader = React.createClass({ }); module.exports = PageHeader; -},{"classnames":87,"react":299}],64:[function(require,module,exports){ +},{"classnames":88,"react":303}],65:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -6066,7 +6157,7 @@ var PageItem = React.createClass({ }); module.exports = PageItem; -},{"classnames":87,"react":299}],65:[function(require,module,exports){ +},{"classnames":88,"react":303}],66:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -6110,7 +6201,7 @@ var Pager = React.createClass({ }); module.exports = Pager; -},{"./utils/ValidComponentChildren":84,"./utils/createChainedFunction":85,"classnames":87,"react":299}],66:[function(require,module,exports){ +},{"./utils/ValidComponentChildren":85,"./utils/createChainedFunction":86,"classnames":88,"react":303}],67:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -6332,7 +6423,7 @@ var Panel = React.createClass({ }); module.exports = Panel; -},{"./BootstrapMixin":33,"./CollapsableMixin":40,"classnames":87,"react":299}],67:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./CollapsableMixin":41,"classnames":88,"react":303}],68:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -6433,7 +6524,7 @@ var PanelGroup = React.createClass({ }); module.exports = PanelGroup; -},{"./BootstrapMixin":33,"./utils/ValidComponentChildren":84,"classnames":87,"react":299}],68:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./utils/ValidComponentChildren":85,"classnames":88,"react":303}],69:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -6516,7 +6607,7 @@ var Popover = React.createClass({ }); module.exports = Popover; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],69:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],70:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -6655,7 +6746,7 @@ var ProgressBar = React.createClass({ }); module.exports = ProgressBar; -},{"./BootstrapMixin":33,"./Interpolate":50,"./utils/ValidComponentChildren":84,"classnames":87,"react":299}],70:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./Interpolate":51,"./utils/ValidComponentChildren":85,"classnames":88,"react":303}],71:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -6691,7 +6782,7 @@ var Row = React.createClass({ }); module.exports = Row; -},{"classnames":87,"react":299}],71:[function(require,module,exports){ +},{"classnames":88,"react":303}],72:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -6824,7 +6915,7 @@ var SplitButton = React.createClass({ }); module.exports = SplitButton; -},{"./BootstrapMixin":33,"./Button":34,"./ButtonGroup":35,"./DropdownMenu":43,"./DropdownStateMixin":44,"classnames":87,"react":299}],72:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./Button":35,"./ButtonGroup":36,"./DropdownMenu":44,"./DropdownStateMixin":45,"classnames":88,"react":303}],73:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -6976,7 +7067,7 @@ var SubNav = React.createClass({ }); module.exports = SubNav; -},{"./BootstrapMixin":33,"./utils/ValidComponentChildren":84,"./utils/createChainedFunction":85,"classnames":87,"react":299}],73:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./utils/ValidComponentChildren":85,"./utils/createChainedFunction":86,"classnames":88,"react":303}],74:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -7071,7 +7162,7 @@ var TabPane = React.createClass({ }); module.exports = TabPane; -},{"./utils/TransitionEvents":83,"classnames":87,"react":299}],74:[function(require,module,exports){ +},{"./utils/TransitionEvents":84,"classnames":88,"react":303}],75:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -7222,7 +7313,7 @@ var TabbedArea = React.createClass({ }); module.exports = TabbedArea; -},{"./BootstrapMixin":33,"./Nav":58,"./NavItem":59,"./utils/ValidComponentChildren":84,"react":299}],75:[function(require,module,exports){ +},{"./BootstrapMixin":34,"./Nav":59,"./NavItem":60,"./utils/ValidComponentChildren":85,"react":303}],76:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -7267,7 +7358,7 @@ var Table = React.createClass({ }); module.exports = Table; -},{"classnames":87,"react":299}],76:[function(require,module,exports){ +},{"classnames":88,"react":303}],77:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -7339,7 +7430,7 @@ var Tooltip = React.createClass({ }); module.exports = Tooltip; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],77:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],78:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -7375,7 +7466,7 @@ var Well = React.createClass({ }); module.exports = Well; -},{"./BootstrapMixin":33,"classnames":87,"react":299}],78:[function(require,module,exports){ +},{"./BootstrapMixin":34,"classnames":88,"react":303}],79:[function(require,module,exports){ "use strict"; module.exports = { @@ -7419,7 +7510,7 @@ module.exports = { }, GLYPHS: ["asterisk", "plus", "euro", "eur", "minus", "cloud", "envelope", "pencil", "glass", "music", "search", "heart", "star", "star-empty", "user", "film", "th-large", "th", "th-list", "ok", "remove", "zoom-in", "zoom-out", "off", "signal", "cog", "trash", "home", "file", "time", "road", "download-alt", "download", "upload", "inbox", "play-circle", "repeat", "refresh", "list-alt", "lock", "flag", "headphones", "volume-off", "volume-down", "volume-up", "qrcode", "barcode", "tag", "tags", "book", "bookmark", "print", "camera", "font", "bold", "italic", "text-height", "text-width", "align-left", "align-center", "align-right", "align-justify", "list", "indent-left", "indent-right", "facetime-video", "picture", "map-marker", "adjust", "tint", "edit", "share", "check", "move", "step-backward", "fast-backward", "backward", "play", "pause", "stop", "forward", "fast-forward", "step-forward", "eject", "chevron-left", "chevron-right", "plus-sign", "minus-sign", "remove-sign", "ok-sign", "question-sign", "info-sign", "screenshot", "remove-circle", "ok-circle", "ban-circle", "arrow-left", "arrow-right", "arrow-up", "arrow-down", "share-alt", "resize-full", "resize-small", "exclamation-sign", "gift", "leaf", "fire", "eye-open", "eye-close", "warning-sign", "plane", "calendar", "random", "comment", "magnet", "chevron-up", "chevron-down", "retweet", "shopping-cart", "folder-close", "folder-open", "resize-vertical", "resize-horizontal", "hdd", "bullhorn", "bell", "certificate", "thumbs-up", "thumbs-down", "hand-right", "hand-left", "hand-up", "hand-down", "circle-arrow-right", "circle-arrow-left", "circle-arrow-up", "circle-arrow-down", "globe", "wrench", "tasks", "filter", "briefcase", "fullscreen", "dashboard", "paperclip", "heart-empty", "link", "phone", "pushpin", "usd", "gbp", "sort", "sort-by-alphabet", "sort-by-alphabet-alt", "sort-by-order", "sort-by-order-alt", "sort-by-attributes", "sort-by-attributes-alt", "unchecked", "expand", "collapse-down", "collapse-up", "log-in", "flash", "log-out", "new-window", "record", "save", "open", "saved", "import", "export", "send", "floppy-disk", "floppy-saved", "floppy-remove", "floppy-save", "floppy-open", "credit-card", "transfer", "cutlery", "header", "compressed", "earphone", "phone-alt", "tower", "stats", "sd-video", "hd-video", "subtitles", "sound-stereo", "sound-dolby", "sound-5-1", "sound-6-1", "sound-7-1", "copyright-mark", "registration-mark", "cloud-download", "cloud-upload", "tree-conifer", "tree-deciduous", "cd", "save-file", "open-file", "level-up", "copy", "paste", "alert", "equalizer", "king", "queen", "pawn", "bishop", "knight", "baby-formula", "tent", "blackboard", "bed", "apple", "erase", "hourglass", "lamp", "duplicate", "piggy-bank", "scissors", "bitcoin", "yen", "ruble", "scale", "ice-lolly", "ice-lolly-tasted", "education", "option-horizontal", "option-vertical", "menu-hamburger", "modal-window", "oil", "grain", "sunglasses", "text-size", "text-color", "text-background", "object-align-top", "object-align-bottom", "object-align-horizontal", "object-align-left", "object-align-vertical", "object-align-right", "triangle-right", "triangle-left", "triangle-bottom", "triangle-top", "console", "superscript", "subscript", "menu-left", "menu-right", "menu-down", "menu-up"] }; -},{}],79:[function(require,module,exports){ +},{}],80:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -7576,7 +7667,7 @@ module.exports = { Well: Well, constants: constants }; -},{"./Accordion":28,"./Affix":29,"./AffixMixin":30,"./Alert":31,"./Badge":32,"./BootstrapMixin":33,"./Button":34,"./ButtonGroup":35,"./ButtonToolbar":36,"./Carousel":37,"./CarouselItem":38,"./Col":39,"./CollapsableMixin":40,"./CollapsableNav":41,"./DropdownButton":42,"./DropdownMenu":43,"./DropdownStateMixin":44,"./FadeMixin":45,"./Glyphicon":47,"./Grid":48,"./Input":49,"./Interpolate":50,"./Jumbotron":51,"./Label":52,"./ListGroup":53,"./ListGroupItem":54,"./MenuItem":55,"./Modal":56,"./ModalTrigger":57,"./Nav":58,"./NavItem":59,"./Navbar":60,"./OverlayMixin":61,"./OverlayTrigger":62,"./PageHeader":63,"./PageItem":64,"./Pager":65,"./Panel":66,"./PanelGroup":67,"./Popover":68,"./ProgressBar":69,"./Row":70,"./SplitButton":71,"./SubNav":72,"./TabPane":73,"./TabbedArea":74,"./Table":75,"./Tooltip":76,"./Well":77,"./constants":78}],80:[function(require,module,exports){ +},{"./Accordion":29,"./Affix":30,"./AffixMixin":31,"./Alert":32,"./Badge":33,"./BootstrapMixin":34,"./Button":35,"./ButtonGroup":36,"./ButtonToolbar":37,"./Carousel":38,"./CarouselItem":39,"./Col":40,"./CollapsableMixin":41,"./CollapsableNav":42,"./DropdownButton":43,"./DropdownMenu":44,"./DropdownStateMixin":45,"./FadeMixin":46,"./Glyphicon":48,"./Grid":49,"./Input":50,"./Interpolate":51,"./Jumbotron":52,"./Label":53,"./ListGroup":54,"./ListGroupItem":55,"./MenuItem":56,"./Modal":57,"./ModalTrigger":58,"./Nav":59,"./NavItem":60,"./Navbar":61,"./OverlayMixin":62,"./OverlayTrigger":63,"./PageHeader":64,"./PageItem":65,"./Pager":66,"./Panel":67,"./PanelGroup":68,"./Popover":69,"./ProgressBar":70,"./Row":71,"./SplitButton":72,"./SubNav":73,"./TabPane":74,"./TabbedArea":75,"./Table":76,"./Tooltip":77,"./Well":78,"./constants":79}],81:[function(require,module,exports){ "use strict"; var ANONYMOUS = "<>"; @@ -7632,7 +7723,7 @@ function createMountableChecker() { } module.exports = CustomPropTypes; -},{}],81:[function(require,module,exports){ +},{}],82:[function(require,module,exports){ /** * Copyright 2013-2014 Facebook, Inc. * @@ -7689,7 +7780,7 @@ var EventListener = { }; module.exports = EventListener; -},{}],82:[function(require,module,exports){ +},{}],83:[function(require,module,exports){ /** * Copyright 2014, Facebook, Inc. * All rights reserved. @@ -7739,7 +7830,7 @@ function assign(target, sources) { } module.exports = assign; -},{}],83:[function(require,module,exports){ +},{}],84:[function(require,module,exports){ /** * Copyright 2013-2014, Facebook, Inc. * All rights reserved. @@ -7851,7 +7942,7 @@ var ReactTransitionEvents = { }; module.exports = ReactTransitionEvents; -},{}],84:[function(require,module,exports){ +},{}],85:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -7948,7 +8039,7 @@ module.exports = { numberOf: numberOfValidComponents, hasValidComponent: hasValidComponent }; -},{"react":299}],85:[function(require,module,exports){ +},{"react":303}],86:[function(require,module,exports){ /** * Safe chained function * @@ -7982,7 +8073,7 @@ function createChainedFunction(one, two) { } module.exports = createChainedFunction; -},{}],86:[function(require,module,exports){ +},{}],87:[function(require,module,exports){ "use strict"; var _interopRequire = function (obj) { return obj && obj.__esModule ? obj["default"] : obj; }; @@ -8107,7 +8198,7 @@ module.exports = { getPosition: getPosition, offsetParent: offsetParentFunc }; -},{"react":299}],87:[function(require,module,exports){ +},{"react":303}],88:[function(require,module,exports){ function classNames() { var classes = ''; var arg; @@ -8139,7 +8230,7 @@ if (typeof module !== 'undefined' && module.exports) { module.exports = classNames; } -},{}],88:[function(require,module,exports){ +},{}],89:[function(require,module,exports){ /** * Represents a cancellation caused by navigating away * before the previous transition has fully resolved. @@ -8149,11 +8240,11 @@ if (typeof module !== 'undefined' && module.exports) { function Cancellation() {} module.exports = Cancellation; -},{}],89:[function(require,module,exports){ +},{}],90:[function(require,module,exports){ 'use strict'; -var invariant = require('react/lib/invariant'); -var canUseDOM = require('react/lib/ExecutionEnvironment').canUseDOM; +var invariant = require('invariant'); +var canUseDOM = require('can-use-dom'); var History = { @@ -8180,14 +8271,14 @@ var History = { }; module.exports = History; -},{"react/lib/ExecutionEnvironment":148,"react/lib/invariant":277}],90:[function(require,module,exports){ +},{"can-use-dom":123,"invariant":124}],91:[function(require,module,exports){ +/* jshint -W084 */ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -/* jshint -W084 */ +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + var PathUtils = require('./PathUtils'); function deepSearch(route, pathname, query) { @@ -8210,29 +8301,20 @@ function deepSearch(route, pathname, query) { // No child routes matched; try the default route. var defaultRoute = route.defaultRoute; - if (defaultRoute && (params = PathUtils.extractParams(defaultRoute.path, pathname))) { - return new Match(pathname, params, query, [route, defaultRoute]); - } // Does the "not found" route match? + if (defaultRoute && (params = PathUtils.extractParams(defaultRoute.path, pathname))) return new Match(pathname, params, query, [route, defaultRoute]); + + // Does the "not found" route match? var notFoundRoute = route.notFoundRoute; - if (notFoundRoute && (params = PathUtils.extractParams(notFoundRoute.path, pathname))) { - return new Match(pathname, params, query, [route, notFoundRoute]); - } // Last attempt: check this route. + if (notFoundRoute && (params = PathUtils.extractParams(notFoundRoute.path, pathname))) return new Match(pathname, params, query, [route, notFoundRoute]); + + // Last attempt: check this route. var params = PathUtils.extractParams(route.path, pathname); - if (params) { - return new Match(pathname, params, query, [route]); - }return null; + if (params) return new Match(pathname, params, query, [route]); + + return null; } var Match = (function () { - function Match(pathname, params, query, routes) { - _classCallCheck(this, Match); - - this.pathname = pathname; - this.params = params; - this.query = query; - this.routes = routes; - } - _createClass(Match, null, [{ key: 'findMatch', @@ -8252,11 +8334,20 @@ var Match = (function () { } }]); + function Match(pathname, params, query, routes) { + _classCallCheck(this, Match); + + this.pathname = pathname; + this.params = params; + this.query = query; + this.routes = routes; + } + return Match; })(); module.exports = Match; -},{"./PathUtils":92}],91:[function(require,module,exports){ +},{"./PathUtils":93}],92:[function(require,module,exports){ 'use strict'; var PropTypes = require('./PropTypes'); @@ -8327,16 +8418,16 @@ var Navigation = { }; module.exports = Navigation; -},{"./PropTypes":93}],92:[function(require,module,exports){ +},{"./PropTypes":94}],93:[function(require,module,exports){ 'use strict'; -var invariant = require('react/lib/invariant'); +var invariant = require('invariant'); var assign = require('object-assign'); var qs = require('qs'); var paramCompileMatcher = /:([a-zA-Z_$][a-zA-Z0-9_$]*)|[*.()\[\]\\+|{}^$]/g; var paramInjectMatcher = /:([a-zA-Z_$][a-zA-Z0-9_$?]*[?]?)|[*]/g; -var paramInjectTrailingSlashMatcher = /\/\/\?|\/\?\/|\/\?/g; +var paramInjectTrailingSlashMatcher = /\/\/\?|\/\?\/|\/\?(?![^\/=]+=.*$)/g; var queryMatcher = /\?(.*)$/; var _compiledPatterns = {}; @@ -8401,9 +8492,9 @@ var PathUtils = { var match = path.match(matcher); - if (!match) { - return null; - }var params = {}; + if (!match) return null; + + var params = {}; paramNames.forEach(function (paramName, index) { params[paramName] = match[index + 1]; @@ -8473,15 +8564,15 @@ var PathUtils = { var queryString = qs.stringify(query, { arrayFormat: 'brackets' }); - if (queryString) { - return PathUtils.withoutQuery(path) + '?' + queryString; - }return PathUtils.withoutQuery(path); + if (queryString) return PathUtils.withoutQuery(path) + '?' + queryString; + + return PathUtils.withoutQuery(path); } }; module.exports = PathUtils; -},{"object-assign":121,"qs":122,"react/lib/invariant":277}],93:[function(require,module,exports){ +},{"invariant":124,"object-assign":125,"qs":126}],94:[function(require,module,exports){ 'use strict'; var assign = require('react/lib/Object.assign'); @@ -8494,9 +8585,7 @@ var PropTypes = assign({}, ReactPropTypes, { * Indicates that a prop should be falsy. */ falsy: function falsy(props, propName, componentName) { - if (props[propName]) { - return new Error('<' + componentName + '> should not have a "' + propName + '" prop'); - } + if (props[propName]) return new Error('<' + componentName + '> should not have a "' + propName + '" prop'); }, /** @@ -8513,7 +8602,7 @@ var PropTypes = assign({}, ReactPropTypes, { }); module.exports = PropTypes; -},{"./Route":95,"react":299,"react/lib/Object.assign":155}],94:[function(require,module,exports){ +},{"./Route":96,"react":303,"react/lib/Object.assign":159}],95:[function(require,module,exports){ /** * Encapsulates a redirect to the given route. */ @@ -8526,60 +8615,22 @@ function Redirect(to, params, query) { } module.exports = Redirect; -},{}],95:[function(require,module,exports){ +},{}],96:[function(require,module,exports){ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + var assign = require('react/lib/Object.assign'); -var invariant = require('react/lib/invariant'); -var warning = require('react/lib/warning'); +var invariant = require('invariant'); +var warning = require('./warning'); var PathUtils = require('./PathUtils'); var _currentRoute; var Route = (function () { - function Route(name, path, ignoreScrollBehavior, isDefault, isNotFound, onEnter, onLeave, handler) { - _classCallCheck(this, Route); - - this.name = name; - this.path = path; - this.paramNames = PathUtils.extractParamNames(this.path); - this.ignoreScrollBehavior = !!ignoreScrollBehavior; - this.isDefault = !!isDefault; - this.isNotFound = !!isNotFound; - this.onEnter = onEnter; - this.onLeave = onLeave; - this.handler = handler; - } - - _createClass(Route, [{ - key: 'appendChild', - - /** - * Appends the given route to this route's child routes. - */ - value: function appendChild(route) { - invariant(route instanceof Route, 'route.appendChild must use a valid Route'); - - if (!this.childRoutes) this.childRoutes = []; - - this.childRoutes.push(route); - } - }, { - key: 'toString', - value: function toString() { - var string = ''; - - return string; - } - }], [{ + _createClass(Route, null, [{ key: 'createRoute', /** @@ -8678,28 +8729,26 @@ var Route = (function () { return route; } - }, { - key: 'createDefaultRoute', /** * Creates and returns a route that is rendered when its parent matches * the current URL. */ + }, { + key: 'createDefaultRoute', value: function createDefaultRoute(options) { return Route.createRoute(assign({}, options, { isDefault: true })); } - }, { - key: 'createNotFoundRoute', /** * Creates and returns a route that is rendered when its parent matches * the current URL but none of its siblings do. */ + }, { + key: 'createNotFoundRoute', value: function createNotFoundRoute(options) { return Route.createRoute(assign({}, options, { isNotFound: true })); } - }, { - key: 'createRedirect', /** * Creates and returns a route that automatically redirects the transition @@ -8713,6 +8762,8 @@ var Route = (function () { * - query The query to use in the redirect URL. Defaults * to using the current query */ + }, { + key: 'createRedirect', value: function createRedirect(options) { return Route.createRoute(assign({}, options, { path: options.path || options.from || '*', @@ -8723,24 +8774,64 @@ var Route = (function () { } }]); + function Route(name, path, ignoreScrollBehavior, isDefault, isNotFound, onEnter, onLeave, handler) { + _classCallCheck(this, Route); + + this.name = name; + this.path = path; + this.paramNames = PathUtils.extractParamNames(this.path); + this.ignoreScrollBehavior = !!ignoreScrollBehavior; + this.isDefault = !!isDefault; + this.isNotFound = !!isNotFound; + this.onEnter = onEnter; + this.onLeave = onLeave; + this.handler = handler; + } + + /** + * Appends the given route to this route's child routes. + */ + + _createClass(Route, [{ + key: 'appendChild', + value: function appendChild(route) { + invariant(route instanceof Route, 'route.appendChild must use a valid Route'); + + if (!this.childRoutes) this.childRoutes = []; + + this.childRoutes.push(route); + } + }, { + key: 'toString', + value: function toString() { + var string = ''; + + return string; + } + }]); + return Route; })(); module.exports = Route; -},{"./PathUtils":92,"react/lib/Object.assign":155,"react/lib/invariant":277,"react/lib/warning":298}],96:[function(require,module,exports){ +},{"./PathUtils":93,"./warning":122,"invariant":124,"react/lib/Object.assign":159}],97:[function(require,module,exports){ 'use strict'; -var invariant = require('react/lib/invariant'); -var canUseDOM = require('react/lib/ExecutionEnvironment').canUseDOM; +var invariant = require('invariant'); +var canUseDOM = require('can-use-dom'); var getWindowScrollPosition = require('./getWindowScrollPosition'); function shouldUpdateScroll(state, prevState) { - if (!prevState) { - return true; - } // Don't update scroll position when only the query has changed. - if (state.pathname === prevState.pathname) { - return false; - }var routes = state.routes; + if (!prevState) return true; + + // Don't update scroll position when only the query has changed. + if (state.pathname === prevState.pathname) return false; + + var routes = state.routes; var prevRoutes = prevState.routes; var sharedAncestorRoutes = routes.filter(function (route) { @@ -8793,9 +8884,9 @@ var ScrollHistory = { }, _updateScroll: function _updateScroll(prevState) { - if (!shouldUpdateScroll(this.state, prevState)) { - return; - }var scrollBehavior = this.constructor.getScrollBehavior(); + if (!shouldUpdateScroll(this.state, prevState)) return; + + var scrollBehavior = this.constructor.getScrollBehavior(); if (scrollBehavior) scrollBehavior.updateScrollPosition(this.constructor.getScrollPosition(this.state.path), this.state.action); } @@ -8803,7 +8894,7 @@ var ScrollHistory = { }; module.exports = ScrollHistory; -},{"./getWindowScrollPosition":111,"react/lib/ExecutionEnvironment":148,"react/lib/invariant":277}],97:[function(require,module,exports){ +},{"./getWindowScrollPosition":112,"can-use-dom":123,"invariant":124}],98:[function(require,module,exports){ 'use strict'; var PropTypes = require('./PropTypes'); @@ -8878,7 +8969,7 @@ var State = { }; module.exports = State; -},{"./PropTypes":93}],98:[function(require,module,exports){ +},{"./PropTypes":94}],99:[function(require,module,exports){ /* jshint -W058 */ 'use strict'; @@ -8954,7 +9045,7 @@ Transition.to = function (transition, routes, params, query, callback) { }; module.exports = Transition; -},{"./Cancellation":88,"./Redirect":94}],99:[function(require,module,exports){ +},{"./Cancellation":89,"./Redirect":95}],100:[function(require,module,exports){ /** * Actions that modify the URL. */ @@ -8980,7 +9071,7 @@ var LocationActions = { }; module.exports = LocationActions; -},{}],100:[function(require,module,exports){ +},{}],101:[function(require,module,exports){ 'use strict'; var LocationActions = require('../actions/LocationActions'); @@ -9010,7 +9101,7 @@ var ImitateBrowserBehavior = { }; module.exports = ImitateBrowserBehavior; -},{"../actions/LocationActions":99}],101:[function(require,module,exports){ +},{"../actions/LocationActions":100}],102:[function(require,module,exports){ /** * A scroll behavior that always scrolls to the top of the page * after a transition. @@ -9026,34 +9117,34 @@ var ScrollToTopBehavior = { }; module.exports = ScrollToTopBehavior; -},{}],102:[function(require,module,exports){ -'use strict'; - -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); - -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; - +},{}],103:[function(require,module,exports){ /** * This component is necessary to get around a context warning * present in React 0.13.0. It sovles this by providing a separation * between the "owner" and "parent" contexts. */ +'use strict'; + +var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); + +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + var React = require('react'); var ContextWrapper = (function (_React$Component) { + _inherits(ContextWrapper, _React$Component); + function ContextWrapper() { _classCallCheck(this, ContextWrapper); - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } + _get(Object.getPrototypeOf(ContextWrapper.prototype), 'constructor', this).apply(this, arguments); } - _inherits(ContextWrapper, _React$Component); - _createClass(ContextWrapper, [{ key: 'render', value: function render() { @@ -9065,12 +9156,14 @@ var ContextWrapper = (function (_React$Component) { })(React.Component); module.exports = ContextWrapper; -},{"react":299}],103:[function(require,module,exports){ +},{"react":303}],104:[function(require,module,exports){ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var PropTypes = require('../PropTypes'); var RouteHandler = require('./RouteHandler'); @@ -9084,23 +9177,21 @@ var Route = require('./Route'); */ var DefaultRoute = (function (_Route) { + _inherits(DefaultRoute, _Route); + function DefaultRoute() { _classCallCheck(this, DefaultRoute); - if (_Route != null) { - _Route.apply(this, arguments); - } + _get(Object.getPrototypeOf(DefaultRoute.prototype), 'constructor', this).apply(this, arguments); } - _inherits(DefaultRoute, _Route); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 return DefaultRoute; })(Route); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - DefaultRoute.propTypes = { name: PropTypes.string, path: PropTypes.falsy, @@ -9113,14 +9204,16 @@ DefaultRoute.defaultProps = { }; module.exports = DefaultRoute; -},{"../PropTypes":93,"./Route":107,"./RouteHandler":108}],104:[function(require,module,exports){ +},{"../PropTypes":94,"./Route":108,"./RouteHandler":109}],105:[function(require,module,exports){ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var React = require('react'); var assign = require('react/lib/Object.assign'); @@ -9154,15 +9247,17 @@ function isModifiedEvent(event) { */ var Link = (function (_React$Component) { + _inherits(Link, _React$Component); + function Link() { _classCallCheck(this, Link); - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } + _get(Object.getPrototypeOf(Link.prototype), 'constructor', this).apply(this, arguments); } - _inherits(Link, _React$Component); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 _createClass(Link, [{ key: 'handleClick', @@ -9172,30 +9267,30 @@ var Link = (function (_React$Component) { if (this.props.onClick) clickResult = this.props.onClick(event); - if (isModifiedEvent(event) || !isLeftClickEvent(event)) { - return; - }if (clickResult === false || event.defaultPrevented === true) allowTransition = false; + if (isModifiedEvent(event) || !isLeftClickEvent(event)) return; + + if (clickResult === false || event.defaultPrevented === true) allowTransition = false; event.preventDefault(); if (allowTransition) this.context.router.transitionTo(this.props.to, this.props.params, this.props.query); } - }, { - key: 'getHref', /** * Returns the value of the "href" attribute to use on the DOM element. */ + }, { + key: 'getHref', value: function getHref() { return this.context.router.makeHref(this.props.to, this.props.params, this.props.query); } - }, { - key: 'getClassName', /** * Returns the value of the "class" attribute to use on the DOM element, which contains * the value of the activeClassName property when this is active. */ + }, { + key: 'getClassName', value: function getClassName() { var className = this.props.className; @@ -9226,10 +9321,6 @@ var Link = (function (_React$Component) { return Link; })(React.Component); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - Link.contextTypes = { router: PropTypes.router.isRequired }; @@ -9249,12 +9340,14 @@ Link.defaultProps = { }; module.exports = Link; -},{"../PropTypes":93,"react":299,"react/lib/Object.assign":155}],105:[function(require,module,exports){ +},{"../PropTypes":94,"react":303,"react/lib/Object.assign":159}],106:[function(require,module,exports){ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var PropTypes = require('../PropTypes'); var RouteHandler = require('./RouteHandler'); @@ -9269,23 +9362,21 @@ var Route = require('./Route'); */ var NotFoundRoute = (function (_Route) { + _inherits(NotFoundRoute, _Route); + function NotFoundRoute() { _classCallCheck(this, NotFoundRoute); - if (_Route != null) { - _Route.apply(this, arguments); - } + _get(Object.getPrototypeOf(NotFoundRoute.prototype), 'constructor', this).apply(this, arguments); } - _inherits(NotFoundRoute, _Route); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 return NotFoundRoute; })(Route); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - NotFoundRoute.propTypes = { name: PropTypes.string, path: PropTypes.falsy, @@ -9298,12 +9389,14 @@ NotFoundRoute.defaultProps = { }; module.exports = NotFoundRoute; -},{"../PropTypes":93,"./Route":107,"./RouteHandler":108}],106:[function(require,module,exports){ +},{"../PropTypes":94,"./Route":108,"./RouteHandler":109}],107:[function(require,module,exports){ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var PropTypes = require('../PropTypes'); var Route = require('./Route'); @@ -9314,23 +9407,21 @@ var Route = require('./Route'); */ var Redirect = (function (_Route) { + _inherits(Redirect, _Route); + function Redirect() { _classCallCheck(this, Redirect); - if (_Route != null) { - _Route.apply(this, arguments); - } + _get(Object.getPrototypeOf(Redirect.prototype), 'constructor', this).apply(this, arguments); } - _inherits(Redirect, _Route); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 return Redirect; })(Route); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - Redirect.propTypes = { path: PropTypes.string, from: PropTypes.string, // Alias for path. @@ -9342,17 +9433,19 @@ Redirect.propTypes = { Redirect.defaultProps = {}; module.exports = Redirect; -},{"../PropTypes":93,"./Route":107}],107:[function(require,module,exports){ +},{"../PropTypes":94,"./Route":108}],108:[function(require,module,exports){ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var React = require('react'); -var invariant = require('react/lib/invariant'); +var invariant = require('invariant'); var PropTypes = require('../PropTypes'); var RouteHandler = require('./RouteHandler'); @@ -9387,7 +9480,7 @@ var RouteHandler = require('./RouteHandler'); * var App = React.createClass({ * render: function () { * return ( - *
+ *
* *
* ); @@ -9398,15 +9491,17 @@ var RouteHandler = require('./RouteHandler'); */ var Route = (function (_React$Component) { + _inherits(Route, _React$Component); + function Route() { _classCallCheck(this, Route); - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } + _get(Object.getPrototypeOf(Route.prototype), 'constructor', this).apply(this, arguments); } - _inherits(Route, _React$Component); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 _createClass(Route, [{ key: 'render', @@ -9418,10 +9513,6 @@ var Route = (function (_React$Component) { return Route; })(React.Component); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - Route.propTypes = { name: PropTypes.string, path: PropTypes.string, @@ -9434,14 +9525,16 @@ Route.defaultProps = { }; module.exports = Route; -},{"../PropTypes":93,"./RouteHandler":108,"react":299,"react/lib/invariant":277}],108:[function(require,module,exports){ +},{"../PropTypes":94,"./RouteHandler":109,"invariant":124,"react":303}],109:[function(require,module,exports){ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var React = require('react'); var ContextWrapper = require('./ContextWrapper'); @@ -9456,15 +9549,17 @@ var REF_NAME = '__routeHandler__'; */ var RouteHandler = (function (_React$Component) { + _inherits(RouteHandler, _React$Component); + function RouteHandler() { _classCallCheck(this, RouteHandler); - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } + _get(Object.getPrototypeOf(RouteHandler.prototype), 'constructor', this).apply(this, arguments); } - _inherits(RouteHandler, _React$Component); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 _createClass(RouteHandler, [{ key: 'getChildContext', @@ -9503,9 +9598,9 @@ var RouteHandler = (function (_React$Component) { value: function createChildRouteHandler(props) { var route = this.context.router.getRouteAtDepth(this.getRouteDepth()); - if (route == null) { - return null; - }var childProps = assign({}, props || this.props, { + if (route == null) return null; + + var childProps = assign({}, props || this.props, { ref: REF_NAME, params: this.context.router.getCurrentParams(), query: this.context.router.getCurrentQuery() @@ -9529,10 +9624,6 @@ var RouteHandler = (function (_React$Component) { return RouteHandler; })(React.Component); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - RouteHandler.contextTypes = { routeDepth: PropTypes.number.isRequired, router: PropTypes.router.isRequired @@ -9543,15 +9634,15 @@ RouteHandler.childContextTypes = { }; module.exports = RouteHandler; -},{"../PropTypes":93,"./ContextWrapper":102,"react":299,"react/lib/Object.assign":155}],109:[function(require,module,exports){ +},{"../PropTypes":94,"./ContextWrapper":103,"react":303,"react/lib/Object.assign":159}],110:[function(require,module,exports){ (function (process){ /* jshint -W058 */ 'use strict'; var React = require('react'); -var warning = require('react/lib/warning'); -var invariant = require('react/lib/invariant'); -var canUseDOM = require('react/lib/ExecutionEnvironment').canUseDOM; +var warning = require('./warning'); +var invariant = require('invariant'); +var canUseDOM = require('can-use-dom'); var LocationActions = require('./actions/LocationActions'); var ImitateBrowserBehavior = require('./behaviors/ImitateBrowserBehavior'); var HashLocation = require('./locations/HashLocation'); @@ -9582,9 +9673,9 @@ var DEFAULT_LOCATION = canUseDOM ? HashLocation : '/'; var DEFAULT_SCROLL_BEHAVIOR = canUseDOM ? ImitateBrowserBehavior : null; function hasProperties(object, properties) { - for (var propertyName in properties) if (properties.hasOwnProperty(propertyName) && object[propertyName] !== properties[propertyName]) { - return false; - }return true; + for (var propertyName in properties) if (properties.hasOwnProperty(propertyName) && object[propertyName] !== properties[propertyName]) return false; + + return true; } function hasMatch(routes, route, prevParams, nextParams, prevQuery, nextQuery) { @@ -9628,15 +9719,15 @@ function routeIsActive(activeRoutes, routeName) { } function paramsAreActive(activeParams, params) { - for (var property in params) if (String(activeParams[property]) !== String(params[property])) { - return false; - }return true; + for (var property in params) if (String(activeParams[property]) !== String(params[property])) return false; + + return true; } function queryIsActive(activeQuery, query) { - for (var property in query) if (String(activeQuery[property]) !== String(query[property])) { - return false; - }return true; + for (var property in query) if (String(activeQuery[property]) !== String(query[property])) return false; + + return true; } /** @@ -9848,9 +9939,7 @@ function createRouter(options) { var prevPath = state.path; var isRefreshing = action == null; - if (prevPath === path && !isRefreshing) { - return; - } // Nothing to do! + if (prevPath === path && !isRefreshing) return; // Nothing to do! // Record the scroll position as early as possible to // get it before browsers try update it automatically. @@ -10007,9 +10096,9 @@ function createRouter(options) { * Returns true if the given route, params, and query are active. */ isActive: function isActive(to, params, query) { - if (PathUtils.isAbsolute(to)) { - return to === state.path; - }return routeIsActive(state.routes, to) && paramsAreActive(state.params, params) && (query == null || queryIsActive(state.query, query)); + if (PathUtils.isAbsolute(to)) return to === state.path; + + return routeIsActive(state.routes, to) && paramsAreActive(state.params, params) && (query == null || queryIsActive(state.query, query)); } }, @@ -10060,13 +10149,13 @@ function createRouter(options) { module.exports = createRouter; }).call(this,require('_process')) -},{"./Cancellation":88,"./History":89,"./Match":90,"./PathUtils":92,"./PropTypes":93,"./Redirect":94,"./Route":95,"./ScrollHistory":96,"./Transition":98,"./actions/LocationActions":99,"./behaviors/ImitateBrowserBehavior":100,"./createRoutesFromReactChildren":110,"./isReactChildren":113,"./locations/HashLocation":114,"./locations/HistoryLocation":115,"./locations/RefreshLocation":116,"./locations/StaticLocation":117,"./supportsHistory":120,"_process":300,"react":299,"react/lib/ExecutionEnvironment":148,"react/lib/invariant":277,"react/lib/warning":298}],110:[function(require,module,exports){ +},{"./Cancellation":89,"./History":90,"./Match":91,"./PathUtils":93,"./PropTypes":94,"./Redirect":95,"./Route":96,"./ScrollHistory":97,"./Transition":99,"./actions/LocationActions":100,"./behaviors/ImitateBrowserBehavior":101,"./createRoutesFromReactChildren":111,"./isReactChildren":114,"./locations/HashLocation":115,"./locations/HistoryLocation":116,"./locations/RefreshLocation":117,"./locations/StaticLocation":118,"./supportsHistory":121,"./warning":122,"_process":304,"can-use-dom":123,"invariant":124,"react":303}],111:[function(require,module,exports){ /* jshint -W084 */ 'use strict'; var React = require('react'); var assign = require('react/lib/Object.assign'); -var warning = require('react/lib/warning'); +var warning = require('./warning'); var DefaultRoute = require('./components/DefaultRoute'); var NotFoundRoute = require('./components/NotFoundRoute'); var Redirect = require('./components/Redirect'); @@ -10097,20 +10186,20 @@ function createRouteOptions(props) { } function createRouteFromReactElement(element) { - if (!React.isValidElement(element)) { - return; - }var type = element.type; + if (!React.isValidElement(element)) return; + + var type = element.type; var props = assign({}, type.defaultProps, element.props); if (type.propTypes) checkPropTypes(type.displayName, type.propTypes, props); - if (type === DefaultRoute) { - return Route.createDefaultRoute(createRouteOptions(props)); - }if (type === NotFoundRoute) { - return Route.createNotFoundRoute(createRouteOptions(props)); - }if (type === Redirect) { - return Route.createRedirect(createRouteOptions(props)); - }return Route.createRoute(createRouteOptions(props), function () { + if (type === DefaultRoute) return Route.createDefaultRoute(createRouteOptions(props)); + + if (type === NotFoundRoute) return Route.createNotFoundRoute(createRouteOptions(props)); + + if (type === Redirect) return Route.createRedirect(createRouteOptions(props)); + + return Route.createRoute(createRouteOptions(props), function () { if (props.children) createRoutesFromReactChildren(props.children); }); } @@ -10142,11 +10231,11 @@ function createRoutesFromReactChildren(children) { } module.exports = createRoutesFromReactChildren; -},{"./Route":95,"./components/DefaultRoute":103,"./components/NotFoundRoute":105,"./components/Redirect":106,"react":299,"react/lib/Object.assign":155,"react/lib/warning":298}],111:[function(require,module,exports){ +},{"./Route":96,"./components/DefaultRoute":104,"./components/NotFoundRoute":106,"./components/Redirect":107,"./warning":122,"react":303,"react/lib/Object.assign":159}],112:[function(require,module,exports){ 'use strict'; -var invariant = require('react/lib/invariant'); -var canUseDOM = require('react/lib/ExecutionEnvironment').canUseDOM; +var invariant = require('invariant'); +var canUseDOM = require('can-use-dom'); /** * Returns the current scroll position of the window as { x, y }. @@ -10161,7 +10250,7 @@ function getWindowScrollPosition() { } module.exports = getWindowScrollPosition; -},{"react/lib/ExecutionEnvironment":148,"react/lib/invariant":277}],112:[function(require,module,exports){ +},{"can-use-dom":123,"invariant":124}],113:[function(require,module,exports){ 'use strict'; exports.DefaultRoute = require('./components/DefaultRoute'); @@ -10193,7 +10282,7 @@ exports.createRoutesFromReactChildren = require('./createRoutesFromReactChildren exports.create = require('./createRouter'); exports.run = require('./runRouter'); -},{"./History":89,"./Navigation":91,"./Route":95,"./State":97,"./behaviors/ImitateBrowserBehavior":100,"./behaviors/ScrollToTopBehavior":101,"./components/DefaultRoute":103,"./components/Link":104,"./components/NotFoundRoute":105,"./components/Redirect":106,"./components/Route":107,"./components/RouteHandler":108,"./createRouter":109,"./createRoutesFromReactChildren":110,"./locations/HashLocation":114,"./locations/HistoryLocation":115,"./locations/RefreshLocation":116,"./locations/StaticLocation":117,"./locations/TestLocation":118,"./runRouter":119}],113:[function(require,module,exports){ +},{"./History":90,"./Navigation":92,"./Route":96,"./State":98,"./behaviors/ImitateBrowserBehavior":101,"./behaviors/ScrollToTopBehavior":102,"./components/DefaultRoute":104,"./components/Link":105,"./components/NotFoundRoute":106,"./components/Redirect":107,"./components/Route":108,"./components/RouteHandler":109,"./createRouter":110,"./createRoutesFromReactChildren":111,"./locations/HashLocation":115,"./locations/HistoryLocation":116,"./locations/RefreshLocation":117,"./locations/StaticLocation":118,"./locations/TestLocation":119,"./runRouter":120}],114:[function(require,module,exports){ 'use strict'; var React = require('react'); @@ -10207,7 +10296,7 @@ function isReactChildren(object) { } module.exports = isReactChildren; -},{"react":299}],114:[function(require,module,exports){ +},{"react":303}],115:[function(require,module,exports){ 'use strict'; var LocationActions = require('../actions/LocationActions'); @@ -10233,9 +10322,9 @@ function notifyChange(type) { function ensureSlash() { var path = HashLocation.getCurrentPath(); - if (path.charAt(0) === '/') { - return true; - }HashLocation.replace('/' + path); + if (path.charAt(0) === '/') return true; + + HashLocation.replace('/' + path); return false; } @@ -10319,7 +10408,7 @@ var HashLocation = { }; module.exports = HashLocation; -},{"../History":89,"../actions/LocationActions":99}],115:[function(require,module,exports){ +},{"../History":90,"../actions/LocationActions":100}],116:[function(require,module,exports){ 'use strict'; var LocationActions = require('../actions/LocationActions'); @@ -10340,9 +10429,7 @@ function notifyChange(type) { } function onPopState(event) { - if (event.state === undefined) { - return; - } // Ignore extraneous popstate events in WebKit. + if (event.state === undefined) return; // Ignore extraneous popstate events in WebKit. notifyChange(LocationActions.POP); } @@ -10406,7 +10493,7 @@ var HistoryLocation = { }; module.exports = HistoryLocation; -},{"../History":89,"../actions/LocationActions":99}],116:[function(require,module,exports){ +},{"../History":90,"../actions/LocationActions":100}],117:[function(require,module,exports){ 'use strict'; var HistoryLocation = require('./HistoryLocation'); @@ -10438,14 +10525,14 @@ var RefreshLocation = { }; module.exports = RefreshLocation; -},{"../History":89,"./HistoryLocation":115}],117:[function(require,module,exports){ +},{"../History":90,"./HistoryLocation":116}],118:[function(require,module,exports){ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var invariant = require('react/lib/invariant'); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +var invariant = require('invariant'); function throwCannotModify() { invariant(false, 'You cannot modify a static location'); @@ -10464,6 +10551,10 @@ var StaticLocation = (function () { this.path = path; } + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 + _createClass(StaticLocation, [{ key: 'getCurrentPath', value: function getCurrentPath() { @@ -10479,23 +10570,19 @@ var StaticLocation = (function () { return StaticLocation; })(); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - StaticLocation.prototype.push = throwCannotModify; StaticLocation.prototype.replace = throwCannotModify; StaticLocation.prototype.pop = throwCannotModify; module.exports = StaticLocation; -},{"react/lib/invariant":277}],118:[function(require,module,exports){ +},{"invariant":124}],119:[function(require,module,exports){ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var invariant = require('react/lib/invariant'); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +var invariant = require('invariant'); var LocationActions = require('../actions/LocationActions'); var History = require('../History'); @@ -10509,15 +10596,11 @@ var TestLocation = (function () { this.history = history || []; this.listeners = []; + this.needsDOM = false; this._updateHistoryLength(); } _createClass(TestLocation, [{ - key: 'needsDOM', - get: function () { - return false; - } - }, { key: '_updateHistoryLength', value: function _updateHistoryLength() { History.length = this.history.length; @@ -10583,7 +10666,7 @@ var TestLocation = (function () { })(); module.exports = TestLocation; -},{"../History":89,"../actions/LocationActions":99,"react/lib/invariant":277}],119:[function(require,module,exports){ +},{"../History":90,"../actions/LocationActions":100,"invariant":124}],120:[function(require,module,exports){ 'use strict'; var createRouter = require('./createRouter'); @@ -10634,7 +10717,7 @@ function runRouter(routes, location, callback) { } module.exports = runRouter; -},{"./createRouter":109}],120:[function(require,module,exports){ +},{"./createRouter":110}],121:[function(require,module,exports){ 'use strict'; function supportsHistory() { @@ -10651,7 +10734,132 @@ function supportsHistory() { } module.exports = supportsHistory; -},{}],121:[function(require,module,exports){ +},{}],122:[function(require,module,exports){ +(function (process){ +/** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of https://github.com/facebook/react/tree/0.13-stable. + * An additional grant of patent rights can be found in the PATENTS file in the same directory. + * + * @providesModule warning + */ + +"use strict"; + +/** + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ + +var __DEV__ = process.env.NODE_ENV !== 'production'; + +var warning = function warning() {}; + +if (__DEV__) { + warning = function (condition, format) { + for (var _len = arguments.length, args = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) { + args[_key - 2] = arguments[_key]; + } + + if (format === undefined) { + throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); + } + + if (format.length < 10 || /^[s\W]*$/.test(format)) { + throw new Error('The warning format should be able to uniquely identify this ' + 'warning. Please, use a more descriptive format than: ' + format); + } + + if (format.indexOf('Failed Composite propType: ') === 0) { + return; // Ignore CompositeComponent proptype check. + } + + if (!condition) { + var argIndex = 0; + var message = 'Warning: ' + format.replace(/%s/g, function () { + return args[argIndex++]; + }); + console.warn(message); + try { + // --- Welcome to debugging React --- + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch (x) {} + } + }; +} + +module.exports = warning; +}).call(this,require('_process')) +},{"_process":304}],123:[function(require,module,exports){ +var canUseDOM = !!( + typeof window !== 'undefined' && + window.document && + window.document.createElement +); + +module.exports = canUseDOM; +},{}],124:[function(require,module,exports){ +(function (process){ +/** + * Copyright 2013-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + +'use strict'; + +/** + * Use invariant() to assert state which your program assumes to be true. + * + * Provide sprintf-style format (only %s is supported) and arguments + * to provide information about what broke and what you were + * expecting. + * + * The invariant message will be stripped in production, but the invariant + * will remain to ensure logic does not differ in production. + */ + +var invariant = function(condition, format, a, b, c, d, e, f) { + if (process.env.NODE_ENV !== 'production') { + if (format === undefined) { + throw new Error('invariant requires an error message argument'); + } + } + + if (!condition) { + var error; + if (format === undefined) { + error = new Error( + 'Minified exception occurred; use the non-minified dev environment ' + + 'for the full error message and additional helpful warnings.' + ); + } else { + var args = [a, b, c, d, e, f]; + var argIndex = 0; + error = new Error( + format.replace(/%s/g, function() { return args[argIndex++]; }) + ); + error.name = 'Invariant Violation'; + } + + error.framesToPop = 1; // we don't care about invariant's own frame + throw error; + } +}; + +module.exports = invariant; + +}).call(this,require('_process')) +},{"_process":304}],125:[function(require,module,exports){ 'use strict'; function ToObject(val) { @@ -10679,10 +10887,10 @@ module.exports = Object.assign || function (target, source) { return to; }; -},{}],122:[function(require,module,exports){ +},{}],126:[function(require,module,exports){ module.exports = require('./lib/'); -},{"./lib/":123}],123:[function(require,module,exports){ +},{"./lib/":127}],127:[function(require,module,exports){ // Load modules var Stringify = require('./stringify'); @@ -10699,7 +10907,7 @@ module.exports = { parse: Parse }; -},{"./parse":124,"./stringify":125}],124:[function(require,module,exports){ +},{"./parse":128,"./stringify":129}],128:[function(require,module,exports){ // Load modules var Utils = require('./utils'); @@ -10862,7 +11070,7 @@ module.exports = function (str, options) { return Utils.compact(obj); }; -},{"./utils":126}],125:[function(require,module,exports){ +},{"./utils":130}],129:[function(require,module,exports){ // Load modules var Utils = require('./utils'); @@ -10961,7 +11169,7 @@ module.exports = function (obj, options) { return keys.join(delimiter); }; -},{"./utils":126}],126:[function(require,module,exports){ +},{"./utils":130}],130:[function(require,module,exports){ // Load modules @@ -11095,10 +11303,10 @@ exports.isBuffer = function (obj) { obj.constructor.isBuffer(obj)); }; -},{}],127:[function(require,module,exports){ +},{}],131:[function(require,module,exports){ module.exports = require('./lib/ReactWithAddons'); -},{"./lib/ReactWithAddons":227}],128:[function(require,module,exports){ +},{"./lib/ReactWithAddons":231}],132:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -11125,7 +11333,7 @@ var AutoFocusMixin = { module.exports = AutoFocusMixin; -},{"./focusNode":261}],129:[function(require,module,exports){ +},{"./focusNode":265}],133:[function(require,module,exports){ /** * Copyright 2013-2015 Facebook, Inc. * All rights reserved. @@ -11620,7 +11828,7 @@ var BeforeInputEventPlugin = { module.exports = BeforeInputEventPlugin; -},{"./EventConstants":142,"./EventPropagators":147,"./ExecutionEnvironment":148,"./FallbackCompositionState":149,"./SyntheticCompositionEvent":233,"./SyntheticInputEvent":237,"./keyOf":284}],130:[function(require,module,exports){ +},{"./EventConstants":146,"./EventPropagators":151,"./ExecutionEnvironment":152,"./FallbackCompositionState":153,"./SyntheticCompositionEvent":237,"./SyntheticInputEvent":241,"./keyOf":288}],134:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -11732,7 +11940,7 @@ var CSSCore = { module.exports = CSSCore; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],131:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],135:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -11857,7 +12065,7 @@ var CSSProperty = { module.exports = CSSProperty; -},{}],132:[function(require,module,exports){ +},{}],136:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -12039,7 +12247,7 @@ var CSSPropertyOperations = { module.exports = CSSPropertyOperations; }).call(this,require('_process')) -},{"./CSSProperty":131,"./ExecutionEnvironment":148,"./camelizeStyleName":248,"./dangerousStyleValue":255,"./hyphenateStyleName":275,"./memoizeStringOnly":286,"./warning":298,"_process":300}],133:[function(require,module,exports){ +},{"./CSSProperty":135,"./ExecutionEnvironment":152,"./camelizeStyleName":252,"./dangerousStyleValue":259,"./hyphenateStyleName":279,"./memoizeStringOnly":290,"./warning":302,"_process":304}],137:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -12139,7 +12347,7 @@ PooledClass.addPoolingTo(CallbackQueue); module.exports = CallbackQueue; }).call(this,require('_process')) -},{"./Object.assign":155,"./PooledClass":156,"./invariant":277,"_process":300}],134:[function(require,module,exports){ +},{"./Object.assign":159,"./PooledClass":160,"./invariant":281,"_process":304}],138:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -12521,7 +12729,7 @@ var ChangeEventPlugin = { module.exports = ChangeEventPlugin; -},{"./EventConstants":142,"./EventPluginHub":144,"./EventPropagators":147,"./ExecutionEnvironment":148,"./ReactUpdates":226,"./SyntheticEvent":235,"./isEventSupported":278,"./isTextInputElement":280,"./keyOf":284}],135:[function(require,module,exports){ +},{"./EventConstants":146,"./EventPluginHub":148,"./EventPropagators":151,"./ExecutionEnvironment":152,"./ReactUpdates":230,"./SyntheticEvent":239,"./isEventSupported":282,"./isTextInputElement":284,"./keyOf":288}],139:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -12546,7 +12754,7 @@ var ClientReactRootIndex = { module.exports = ClientReactRootIndex; -},{}],136:[function(require,module,exports){ +},{}],140:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -12684,7 +12892,7 @@ var DOMChildrenOperations = { module.exports = DOMChildrenOperations; }).call(this,require('_process')) -},{"./Danger":139,"./ReactMultiChildUpdateTypes":205,"./invariant":277,"./setTextContent":292,"_process":300}],137:[function(require,module,exports){ +},{"./Danger":143,"./ReactMultiChildUpdateTypes":209,"./invariant":281,"./setTextContent":296,"_process":304}],141:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -12983,7 +13191,7 @@ var DOMProperty = { module.exports = DOMProperty; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],138:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],142:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -13175,7 +13383,7 @@ var DOMPropertyOperations = { module.exports = DOMPropertyOperations; }).call(this,require('_process')) -},{"./DOMProperty":137,"./quoteAttributeValueForBrowser":290,"./warning":298,"_process":300}],139:[function(require,module,exports){ +},{"./DOMProperty":141,"./quoteAttributeValueForBrowser":294,"./warning":302,"_process":304}],143:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -13362,7 +13570,7 @@ var Danger = { module.exports = Danger; }).call(this,require('_process')) -},{"./ExecutionEnvironment":148,"./createNodesFromMarkup":253,"./emptyFunction":256,"./getMarkupWrap":269,"./invariant":277,"_process":300}],140:[function(require,module,exports){ +},{"./ExecutionEnvironment":152,"./createNodesFromMarkup":257,"./emptyFunction":260,"./getMarkupWrap":273,"./invariant":281,"_process":304}],144:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -13401,7 +13609,7 @@ var DefaultEventPluginOrder = [ module.exports = DefaultEventPluginOrder; -},{"./keyOf":284}],141:[function(require,module,exports){ +},{"./keyOf":288}],145:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -13541,7 +13749,7 @@ var EnterLeaveEventPlugin = { module.exports = EnterLeaveEventPlugin; -},{"./EventConstants":142,"./EventPropagators":147,"./ReactMount":203,"./SyntheticMouseEvent":239,"./keyOf":284}],142:[function(require,module,exports){ +},{"./EventConstants":146,"./EventPropagators":151,"./ReactMount":207,"./SyntheticMouseEvent":243,"./keyOf":288}],146:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -13613,7 +13821,7 @@ var EventConstants = { module.exports = EventConstants; -},{"./keyMirror":283}],143:[function(require,module,exports){ +},{"./keyMirror":287}],147:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -13703,7 +13911,7 @@ var EventListener = { module.exports = EventListener; }).call(this,require('_process')) -},{"./emptyFunction":256,"_process":300}],144:[function(require,module,exports){ +},{"./emptyFunction":260,"_process":304}],148:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -13981,7 +14189,7 @@ var EventPluginHub = { module.exports = EventPluginHub; }).call(this,require('_process')) -},{"./EventPluginRegistry":145,"./EventPluginUtils":146,"./accumulateInto":245,"./forEachAccumulated":262,"./invariant":277,"_process":300}],145:[function(require,module,exports){ +},{"./EventPluginRegistry":149,"./EventPluginUtils":150,"./accumulateInto":249,"./forEachAccumulated":266,"./invariant":281,"_process":304}],149:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -14261,7 +14469,7 @@ var EventPluginRegistry = { module.exports = EventPluginRegistry; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],146:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],150:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -14482,7 +14690,7 @@ var EventPluginUtils = { module.exports = EventPluginUtils; }).call(this,require('_process')) -},{"./EventConstants":142,"./invariant":277,"_process":300}],147:[function(require,module,exports){ +},{"./EventConstants":146,"./invariant":281,"_process":304}],151:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -14624,7 +14832,7 @@ var EventPropagators = { module.exports = EventPropagators; }).call(this,require('_process')) -},{"./EventConstants":142,"./EventPluginHub":144,"./accumulateInto":245,"./forEachAccumulated":262,"_process":300}],148:[function(require,module,exports){ +},{"./EventConstants":146,"./EventPluginHub":148,"./accumulateInto":249,"./forEachAccumulated":266,"_process":304}],152:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -14668,7 +14876,7 @@ var ExecutionEnvironment = { module.exports = ExecutionEnvironment; -},{}],149:[function(require,module,exports){ +},{}],153:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -14759,7 +14967,7 @@ PooledClass.addPoolingTo(FallbackCompositionState); module.exports = FallbackCompositionState; -},{"./Object.assign":155,"./PooledClass":156,"./getTextContentAccessor":272}],150:[function(require,module,exports){ +},{"./Object.assign":159,"./PooledClass":160,"./getTextContentAccessor":276}],154:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -14970,7 +15178,7 @@ var HTMLDOMPropertyConfig = { module.exports = HTMLDOMPropertyConfig; -},{"./DOMProperty":137,"./ExecutionEnvironment":148}],151:[function(require,module,exports){ +},{"./DOMProperty":141,"./ExecutionEnvironment":152}],155:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -15011,7 +15219,7 @@ var LinkedStateMixin = { module.exports = LinkedStateMixin; -},{"./ReactLink":201,"./ReactStateSetters":220}],152:[function(require,module,exports){ +},{"./ReactLink":205,"./ReactStateSetters":224}],156:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -15167,7 +15375,7 @@ var LinkedValueUtils = { module.exports = LinkedValueUtils; }).call(this,require('_process')) -},{"./ReactPropTypes":212,"./invariant":277,"_process":300}],153:[function(require,module,exports){ +},{"./ReactPropTypes":216,"./invariant":281,"_process":304}],157:[function(require,module,exports){ (function (process){ /** * Copyright 2014-2015, Facebook, Inc. @@ -15224,7 +15432,7 @@ var LocalEventTrapMixin = { module.exports = LocalEventTrapMixin; }).call(this,require('_process')) -},{"./ReactBrowserEventEmitter":159,"./accumulateInto":245,"./forEachAccumulated":262,"./invariant":277,"_process":300}],154:[function(require,module,exports){ +},{"./ReactBrowserEventEmitter":163,"./accumulateInto":249,"./forEachAccumulated":266,"./invariant":281,"_process":304}],158:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -15282,7 +15490,7 @@ var MobileSafariClickEventPlugin = { module.exports = MobileSafariClickEventPlugin; -},{"./EventConstants":142,"./emptyFunction":256}],155:[function(require,module,exports){ +},{"./EventConstants":146,"./emptyFunction":260}],159:[function(require,module,exports){ /** * Copyright 2014-2015, Facebook, Inc. * All rights reserved. @@ -15331,7 +15539,7 @@ function assign(target, sources) { module.exports = assign; -},{}],156:[function(require,module,exports){ +},{}],160:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -15447,7 +15655,7 @@ var PooledClass = { module.exports = PooledClass; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],157:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],161:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -15599,7 +15807,7 @@ React.version = '0.13.2'; module.exports = React; }).call(this,require('_process')) -},{"./EventPluginUtils":146,"./ExecutionEnvironment":148,"./Object.assign":155,"./ReactChildren":163,"./ReactClass":164,"./ReactComponent":165,"./ReactContext":170,"./ReactCurrentOwner":171,"./ReactDOM":172,"./ReactDOMTextComponent":183,"./ReactDefaultInjection":186,"./ReactElement":189,"./ReactElementValidator":190,"./ReactInstanceHandles":198,"./ReactMount":203,"./ReactPerf":208,"./ReactPropTypes":212,"./ReactReconciler":215,"./ReactServerRendering":218,"./findDOMNode":259,"./onlyChild":287,"_process":300}],158:[function(require,module,exports){ +},{"./EventPluginUtils":150,"./ExecutionEnvironment":152,"./Object.assign":159,"./ReactChildren":167,"./ReactClass":168,"./ReactComponent":169,"./ReactContext":174,"./ReactCurrentOwner":175,"./ReactDOM":176,"./ReactDOMTextComponent":187,"./ReactDefaultInjection":190,"./ReactElement":193,"./ReactElementValidator":194,"./ReactInstanceHandles":202,"./ReactMount":207,"./ReactPerf":212,"./ReactPropTypes":216,"./ReactReconciler":219,"./ReactServerRendering":222,"./findDOMNode":263,"./onlyChild":291,"_process":304}],162:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -15630,7 +15838,7 @@ var ReactBrowserComponentMixin = { module.exports = ReactBrowserComponentMixin; -},{"./findDOMNode":259}],159:[function(require,module,exports){ +},{"./findDOMNode":263}],163:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -15983,7 +16191,7 @@ var ReactBrowserEventEmitter = assign({}, ReactEventEmitterMixin, { module.exports = ReactBrowserEventEmitter; -},{"./EventConstants":142,"./EventPluginHub":144,"./EventPluginRegistry":145,"./Object.assign":155,"./ReactEventEmitterMixin":193,"./ViewportMetrics":244,"./isEventSupported":278}],160:[function(require,module,exports){ +},{"./EventConstants":146,"./EventPluginHub":148,"./EventPluginRegistry":149,"./Object.assign":159,"./ReactEventEmitterMixin":197,"./ViewportMetrics":248,"./isEventSupported":282}],164:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -16053,7 +16261,7 @@ var ReactCSSTransitionGroup = React.createClass({ module.exports = ReactCSSTransitionGroup; -},{"./Object.assign":155,"./React":157,"./ReactCSSTransitionGroupChild":161,"./ReactTransitionGroup":224}],161:[function(require,module,exports){ +},{"./Object.assign":159,"./React":161,"./ReactCSSTransitionGroupChild":165,"./ReactTransitionGroup":228}],165:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -16201,7 +16409,7 @@ var ReactCSSTransitionGroupChild = React.createClass({ module.exports = ReactCSSTransitionGroupChild; }).call(this,require('_process')) -},{"./CSSCore":130,"./React":157,"./ReactTransitionEvents":223,"./onlyChild":287,"./warning":298,"_process":300}],162:[function(require,module,exports){ +},{"./CSSCore":134,"./React":161,"./ReactTransitionEvents":227,"./onlyChild":291,"./warning":302,"_process":304}],166:[function(require,module,exports){ /** * Copyright 2014-2015, Facebook, Inc. * All rights reserved. @@ -16328,7 +16536,7 @@ var ReactChildReconciler = { module.exports = ReactChildReconciler; -},{"./ReactReconciler":215,"./flattenChildren":260,"./instantiateReactComponent":276,"./shouldUpdateReactComponent":294}],163:[function(require,module,exports){ +},{"./ReactReconciler":219,"./flattenChildren":264,"./instantiateReactComponent":280,"./shouldUpdateReactComponent":298}],167:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -16481,7 +16689,7 @@ var ReactChildren = { module.exports = ReactChildren; }).call(this,require('_process')) -},{"./PooledClass":156,"./ReactFragment":195,"./traverseAllChildren":296,"./warning":298,"_process":300}],164:[function(require,module,exports){ +},{"./PooledClass":160,"./ReactFragment":199,"./traverseAllChildren":300,"./warning":302,"_process":304}],168:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -17427,7 +17635,7 @@ var ReactClass = { module.exports = ReactClass; }).call(this,require('_process')) -},{"./Object.assign":155,"./ReactComponent":165,"./ReactCurrentOwner":171,"./ReactElement":189,"./ReactErrorUtils":192,"./ReactInstanceMap":199,"./ReactLifeCycle":200,"./ReactPropTypeLocationNames":210,"./ReactPropTypeLocations":211,"./ReactUpdateQueue":225,"./invariant":277,"./keyMirror":283,"./keyOf":284,"./warning":298,"_process":300}],165:[function(require,module,exports){ +},{"./Object.assign":159,"./ReactComponent":169,"./ReactCurrentOwner":175,"./ReactElement":193,"./ReactErrorUtils":196,"./ReactInstanceMap":203,"./ReactLifeCycle":204,"./ReactPropTypeLocationNames":214,"./ReactPropTypeLocations":215,"./ReactUpdateQueue":229,"./invariant":281,"./keyMirror":287,"./keyOf":288,"./warning":302,"_process":304}],169:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -17563,7 +17771,7 @@ if ("production" !== process.env.NODE_ENV) { module.exports = ReactComponent; }).call(this,require('_process')) -},{"./ReactUpdateQueue":225,"./invariant":277,"./warning":298,"_process":300}],166:[function(require,module,exports){ +},{"./ReactUpdateQueue":229,"./invariant":281,"./warning":302,"_process":304}],170:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -17610,7 +17818,7 @@ var ReactComponentBrowserEnvironment = { module.exports = ReactComponentBrowserEnvironment; -},{"./ReactDOMIDOperations":176,"./ReactMount":203}],167:[function(require,module,exports){ +},{"./ReactDOMIDOperations":180,"./ReactMount":207}],171:[function(require,module,exports){ (function (process){ /** * Copyright 2014-2015, Facebook, Inc. @@ -17671,7 +17879,7 @@ var ReactComponentEnvironment = { module.exports = ReactComponentEnvironment; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],168:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],172:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -17720,7 +17928,7 @@ var ReactComponentWithPureRenderMixin = { module.exports = ReactComponentWithPureRenderMixin; -},{"./shallowEqual":293}],169:[function(require,module,exports){ +},{"./shallowEqual":297}],173:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -18618,7 +18826,7 @@ var ReactCompositeComponent = { module.exports = ReactCompositeComponent; }).call(this,require('_process')) -},{"./Object.assign":155,"./ReactComponentEnvironment":167,"./ReactContext":170,"./ReactCurrentOwner":171,"./ReactElement":189,"./ReactElementValidator":190,"./ReactInstanceMap":199,"./ReactLifeCycle":200,"./ReactNativeComponent":206,"./ReactPerf":208,"./ReactPropTypeLocationNames":210,"./ReactPropTypeLocations":211,"./ReactReconciler":215,"./ReactUpdates":226,"./emptyObject":257,"./invariant":277,"./shouldUpdateReactComponent":294,"./warning":298,"_process":300}],170:[function(require,module,exports){ +},{"./Object.assign":159,"./ReactComponentEnvironment":171,"./ReactContext":174,"./ReactCurrentOwner":175,"./ReactElement":193,"./ReactElementValidator":194,"./ReactInstanceMap":203,"./ReactLifeCycle":204,"./ReactNativeComponent":210,"./ReactPerf":212,"./ReactPropTypeLocationNames":214,"./ReactPropTypeLocations":215,"./ReactReconciler":219,"./ReactUpdates":230,"./emptyObject":261,"./invariant":281,"./shouldUpdateReactComponent":298,"./warning":302,"_process":304}],174:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -18696,7 +18904,7 @@ var ReactContext = { module.exports = ReactContext; }).call(this,require('_process')) -},{"./Object.assign":155,"./emptyObject":257,"./warning":298,"_process":300}],171:[function(require,module,exports){ +},{"./Object.assign":159,"./emptyObject":261,"./warning":302,"_process":304}],175:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -18730,7 +18938,7 @@ var ReactCurrentOwner = { module.exports = ReactCurrentOwner; -},{}],172:[function(require,module,exports){ +},{}],176:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -18908,7 +19116,7 @@ var ReactDOM = mapObject({ module.exports = ReactDOM; }).call(this,require('_process')) -},{"./ReactElement":189,"./ReactElementValidator":190,"./mapObject":285,"_process":300}],173:[function(require,module,exports){ +},{"./ReactElement":193,"./ReactElementValidator":194,"./mapObject":289,"_process":304}],177:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -18972,7 +19180,7 @@ var ReactDOMButton = ReactClass.createClass({ module.exports = ReactDOMButton; -},{"./AutoFocusMixin":128,"./ReactBrowserComponentMixin":158,"./ReactClass":164,"./ReactElement":189,"./keyMirror":283}],174:[function(require,module,exports){ +},{"./AutoFocusMixin":132,"./ReactBrowserComponentMixin":162,"./ReactClass":168,"./ReactElement":193,"./keyMirror":287}],178:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -19480,7 +19688,7 @@ ReactDOMComponent.injection = { module.exports = ReactDOMComponent; }).call(this,require('_process')) -},{"./CSSPropertyOperations":132,"./DOMProperty":137,"./DOMPropertyOperations":138,"./Object.assign":155,"./ReactBrowserEventEmitter":159,"./ReactComponentBrowserEnvironment":166,"./ReactMount":203,"./ReactMultiChild":204,"./ReactPerf":208,"./escapeTextContentForBrowser":258,"./invariant":277,"./isEventSupported":278,"./keyOf":284,"./warning":298,"_process":300}],175:[function(require,module,exports){ +},{"./CSSPropertyOperations":136,"./DOMProperty":141,"./DOMPropertyOperations":142,"./Object.assign":159,"./ReactBrowserEventEmitter":163,"./ReactComponentBrowserEnvironment":170,"./ReactMount":207,"./ReactMultiChild":208,"./ReactPerf":212,"./escapeTextContentForBrowser":262,"./invariant":281,"./isEventSupported":282,"./keyOf":288,"./warning":302,"_process":304}],179:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -19529,7 +19737,7 @@ var ReactDOMForm = ReactClass.createClass({ module.exports = ReactDOMForm; -},{"./EventConstants":142,"./LocalEventTrapMixin":153,"./ReactBrowserComponentMixin":158,"./ReactClass":164,"./ReactElement":189}],176:[function(require,module,exports){ +},{"./EventConstants":146,"./LocalEventTrapMixin":157,"./ReactBrowserComponentMixin":162,"./ReactClass":168,"./ReactElement":193}],180:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -19697,7 +19905,7 @@ ReactPerf.measureMethods(ReactDOMIDOperations, 'ReactDOMIDOperations', { module.exports = ReactDOMIDOperations; }).call(this,require('_process')) -},{"./CSSPropertyOperations":132,"./DOMChildrenOperations":136,"./DOMPropertyOperations":138,"./ReactMount":203,"./ReactPerf":208,"./invariant":277,"./setInnerHTML":291,"_process":300}],177:[function(require,module,exports){ +},{"./CSSPropertyOperations":136,"./DOMChildrenOperations":140,"./DOMPropertyOperations":142,"./ReactMount":207,"./ReactPerf":212,"./invariant":281,"./setInnerHTML":295,"_process":304}],181:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -19742,7 +19950,7 @@ var ReactDOMIframe = ReactClass.createClass({ module.exports = ReactDOMIframe; -},{"./EventConstants":142,"./LocalEventTrapMixin":153,"./ReactBrowserComponentMixin":158,"./ReactClass":164,"./ReactElement":189}],178:[function(require,module,exports){ +},{"./EventConstants":146,"./LocalEventTrapMixin":157,"./ReactBrowserComponentMixin":162,"./ReactClass":168,"./ReactElement":193}],182:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -19788,7 +19996,7 @@ var ReactDOMImg = ReactClass.createClass({ module.exports = ReactDOMImg; -},{"./EventConstants":142,"./LocalEventTrapMixin":153,"./ReactBrowserComponentMixin":158,"./ReactClass":164,"./ReactElement":189}],179:[function(require,module,exports){ +},{"./EventConstants":146,"./LocalEventTrapMixin":157,"./ReactBrowserComponentMixin":162,"./ReactClass":168,"./ReactElement":193}],183:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -19965,7 +20173,7 @@ var ReactDOMInput = ReactClass.createClass({ module.exports = ReactDOMInput; }).call(this,require('_process')) -},{"./AutoFocusMixin":128,"./DOMPropertyOperations":138,"./LinkedValueUtils":152,"./Object.assign":155,"./ReactBrowserComponentMixin":158,"./ReactClass":164,"./ReactElement":189,"./ReactMount":203,"./ReactUpdates":226,"./invariant":277,"_process":300}],180:[function(require,module,exports){ +},{"./AutoFocusMixin":132,"./DOMPropertyOperations":142,"./LinkedValueUtils":156,"./Object.assign":159,"./ReactBrowserComponentMixin":162,"./ReactClass":168,"./ReactElement":193,"./ReactMount":207,"./ReactUpdates":230,"./invariant":281,"_process":304}],184:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -20017,7 +20225,7 @@ var ReactDOMOption = ReactClass.createClass({ module.exports = ReactDOMOption; }).call(this,require('_process')) -},{"./ReactBrowserComponentMixin":158,"./ReactClass":164,"./ReactElement":189,"./warning":298,"_process":300}],181:[function(require,module,exports){ +},{"./ReactBrowserComponentMixin":162,"./ReactClass":168,"./ReactElement":193,"./warning":302,"_process":304}],185:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -20195,7 +20403,7 @@ var ReactDOMSelect = ReactClass.createClass({ module.exports = ReactDOMSelect; -},{"./AutoFocusMixin":128,"./LinkedValueUtils":152,"./Object.assign":155,"./ReactBrowserComponentMixin":158,"./ReactClass":164,"./ReactElement":189,"./ReactUpdates":226}],182:[function(require,module,exports){ +},{"./AutoFocusMixin":132,"./LinkedValueUtils":156,"./Object.assign":159,"./ReactBrowserComponentMixin":162,"./ReactClass":168,"./ReactElement":193,"./ReactUpdates":230}],186:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -20408,7 +20616,7 @@ var ReactDOMSelection = { module.exports = ReactDOMSelection; -},{"./ExecutionEnvironment":148,"./getNodeForCharacterOffset":270,"./getTextContentAccessor":272}],183:[function(require,module,exports){ +},{"./ExecutionEnvironment":152,"./getNodeForCharacterOffset":274,"./getTextContentAccessor":276}],187:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -20525,7 +20733,7 @@ assign(ReactDOMTextComponent.prototype, { module.exports = ReactDOMTextComponent; -},{"./DOMPropertyOperations":138,"./Object.assign":155,"./ReactComponentBrowserEnvironment":166,"./ReactDOMComponent":174,"./escapeTextContentForBrowser":258}],184:[function(require,module,exports){ +},{"./DOMPropertyOperations":142,"./Object.assign":159,"./ReactComponentBrowserEnvironment":170,"./ReactDOMComponent":178,"./escapeTextContentForBrowser":262}],188:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -20665,7 +20873,7 @@ var ReactDOMTextarea = ReactClass.createClass({ module.exports = ReactDOMTextarea; }).call(this,require('_process')) -},{"./AutoFocusMixin":128,"./DOMPropertyOperations":138,"./LinkedValueUtils":152,"./Object.assign":155,"./ReactBrowserComponentMixin":158,"./ReactClass":164,"./ReactElement":189,"./ReactUpdates":226,"./invariant":277,"./warning":298,"_process":300}],185:[function(require,module,exports){ +},{"./AutoFocusMixin":132,"./DOMPropertyOperations":142,"./LinkedValueUtils":156,"./Object.assign":159,"./ReactBrowserComponentMixin":162,"./ReactClass":168,"./ReactElement":193,"./ReactUpdates":230,"./invariant":281,"./warning":302,"_process":304}],189:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -20738,7 +20946,7 @@ var ReactDefaultBatchingStrategy = { module.exports = ReactDefaultBatchingStrategy; -},{"./Object.assign":155,"./ReactUpdates":226,"./Transaction":243,"./emptyFunction":256}],186:[function(require,module,exports){ +},{"./Object.assign":159,"./ReactUpdates":230,"./Transaction":247,"./emptyFunction":260}],190:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -20897,7 +21105,7 @@ module.exports = { }; }).call(this,require('_process')) -},{"./BeforeInputEventPlugin":129,"./ChangeEventPlugin":134,"./ClientReactRootIndex":135,"./DefaultEventPluginOrder":140,"./EnterLeaveEventPlugin":141,"./ExecutionEnvironment":148,"./HTMLDOMPropertyConfig":150,"./MobileSafariClickEventPlugin":154,"./ReactBrowserComponentMixin":158,"./ReactClass":164,"./ReactComponentBrowserEnvironment":166,"./ReactDOMButton":173,"./ReactDOMComponent":174,"./ReactDOMForm":175,"./ReactDOMIDOperations":176,"./ReactDOMIframe":177,"./ReactDOMImg":178,"./ReactDOMInput":179,"./ReactDOMOption":180,"./ReactDOMSelect":181,"./ReactDOMTextComponent":183,"./ReactDOMTextarea":184,"./ReactDefaultBatchingStrategy":185,"./ReactDefaultPerf":187,"./ReactElement":189,"./ReactEventListener":194,"./ReactInjection":196,"./ReactInstanceHandles":198,"./ReactMount":203,"./ReactReconcileTransaction":214,"./SVGDOMPropertyConfig":228,"./SelectEventPlugin":229,"./ServerReactRootIndex":230,"./SimpleEventPlugin":231,"./createFullPageComponent":252,"_process":300}],187:[function(require,module,exports){ +},{"./BeforeInputEventPlugin":133,"./ChangeEventPlugin":138,"./ClientReactRootIndex":139,"./DefaultEventPluginOrder":144,"./EnterLeaveEventPlugin":145,"./ExecutionEnvironment":152,"./HTMLDOMPropertyConfig":154,"./MobileSafariClickEventPlugin":158,"./ReactBrowserComponentMixin":162,"./ReactClass":168,"./ReactComponentBrowserEnvironment":170,"./ReactDOMButton":177,"./ReactDOMComponent":178,"./ReactDOMForm":179,"./ReactDOMIDOperations":180,"./ReactDOMIframe":181,"./ReactDOMImg":182,"./ReactDOMInput":183,"./ReactDOMOption":184,"./ReactDOMSelect":185,"./ReactDOMTextComponent":187,"./ReactDOMTextarea":188,"./ReactDefaultBatchingStrategy":189,"./ReactDefaultPerf":191,"./ReactElement":193,"./ReactEventListener":198,"./ReactInjection":200,"./ReactInstanceHandles":202,"./ReactMount":207,"./ReactReconcileTransaction":218,"./SVGDOMPropertyConfig":232,"./SelectEventPlugin":233,"./ServerReactRootIndex":234,"./SimpleEventPlugin":235,"./createFullPageComponent":256,"_process":304}],191:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -21163,7 +21371,7 @@ var ReactDefaultPerf = { module.exports = ReactDefaultPerf; -},{"./DOMProperty":137,"./ReactDefaultPerfAnalysis":188,"./ReactMount":203,"./ReactPerf":208,"./performanceNow":289}],188:[function(require,module,exports){ +},{"./DOMProperty":141,"./ReactDefaultPerfAnalysis":192,"./ReactMount":207,"./ReactPerf":212,"./performanceNow":293}],192:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -21369,7 +21577,7 @@ var ReactDefaultPerfAnalysis = { module.exports = ReactDefaultPerfAnalysis; -},{"./Object.assign":155}],189:[function(require,module,exports){ +},{"./Object.assign":159}],193:[function(require,module,exports){ (function (process){ /** * Copyright 2014-2015, Facebook, Inc. @@ -21677,7 +21885,7 @@ ReactElement.isValidElement = function(object) { module.exports = ReactElement; }).call(this,require('_process')) -},{"./Object.assign":155,"./ReactContext":170,"./ReactCurrentOwner":171,"./warning":298,"_process":300}],190:[function(require,module,exports){ +},{"./Object.assign":159,"./ReactContext":174,"./ReactCurrentOwner":175,"./warning":302,"_process":304}],194:[function(require,module,exports){ (function (process){ /** * Copyright 2014-2015, Facebook, Inc. @@ -22142,7 +22350,7 @@ var ReactElementValidator = { module.exports = ReactElementValidator; }).call(this,require('_process')) -},{"./ReactCurrentOwner":171,"./ReactElement":189,"./ReactFragment":195,"./ReactNativeComponent":206,"./ReactPropTypeLocationNames":210,"./ReactPropTypeLocations":211,"./getIteratorFn":268,"./invariant":277,"./warning":298,"_process":300}],191:[function(require,module,exports){ +},{"./ReactCurrentOwner":175,"./ReactElement":193,"./ReactFragment":199,"./ReactNativeComponent":210,"./ReactPropTypeLocationNames":214,"./ReactPropTypeLocations":215,"./getIteratorFn":272,"./invariant":281,"./warning":302,"_process":304}],195:[function(require,module,exports){ (function (process){ /** * Copyright 2014-2015, Facebook, Inc. @@ -22237,7 +22445,7 @@ var ReactEmptyComponent = { module.exports = ReactEmptyComponent; }).call(this,require('_process')) -},{"./ReactElement":189,"./ReactInstanceMap":199,"./invariant":277,"_process":300}],192:[function(require,module,exports){ +},{"./ReactElement":193,"./ReactInstanceMap":203,"./invariant":281,"_process":304}],196:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -22269,7 +22477,7 @@ var ReactErrorUtils = { module.exports = ReactErrorUtils; -},{}],193:[function(require,module,exports){ +},{}],197:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -22319,7 +22527,7 @@ var ReactEventEmitterMixin = { module.exports = ReactEventEmitterMixin; -},{"./EventPluginHub":144}],194:[function(require,module,exports){ +},{"./EventPluginHub":148}],198:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -22502,7 +22710,7 @@ var ReactEventListener = { module.exports = ReactEventListener; -},{"./EventListener":143,"./ExecutionEnvironment":148,"./Object.assign":155,"./PooledClass":156,"./ReactInstanceHandles":198,"./ReactMount":203,"./ReactUpdates":226,"./getEventTarget":267,"./getUnboundedScrollPosition":273}],195:[function(require,module,exports){ +},{"./EventListener":147,"./ExecutionEnvironment":152,"./Object.assign":159,"./PooledClass":160,"./ReactInstanceHandles":202,"./ReactMount":207,"./ReactUpdates":230,"./getEventTarget":271,"./getUnboundedScrollPosition":277}],199:[function(require,module,exports){ (function (process){ /** * Copyright 2015, Facebook, Inc. @@ -22687,7 +22895,7 @@ var ReactFragment = { module.exports = ReactFragment; }).call(this,require('_process')) -},{"./ReactElement":189,"./warning":298,"_process":300}],196:[function(require,module,exports){ +},{"./ReactElement":193,"./warning":302,"_process":304}],200:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -22729,7 +22937,7 @@ var ReactInjection = { module.exports = ReactInjection; -},{"./DOMProperty":137,"./EventPluginHub":144,"./ReactBrowserEventEmitter":159,"./ReactClass":164,"./ReactComponentEnvironment":167,"./ReactDOMComponent":174,"./ReactEmptyComponent":191,"./ReactNativeComponent":206,"./ReactPerf":208,"./ReactRootIndex":217,"./ReactUpdates":226}],197:[function(require,module,exports){ +},{"./DOMProperty":141,"./EventPluginHub":148,"./ReactBrowserEventEmitter":163,"./ReactClass":168,"./ReactComponentEnvironment":171,"./ReactDOMComponent":178,"./ReactEmptyComponent":195,"./ReactNativeComponent":210,"./ReactPerf":212,"./ReactRootIndex":221,"./ReactUpdates":230}],201:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -22864,7 +23072,7 @@ var ReactInputSelection = { module.exports = ReactInputSelection; -},{"./ReactDOMSelection":182,"./containsNode":250,"./focusNode":261,"./getActiveElement":263}],198:[function(require,module,exports){ +},{"./ReactDOMSelection":186,"./containsNode":254,"./focusNode":265,"./getActiveElement":267}],202:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -23200,7 +23408,7 @@ var ReactInstanceHandles = { module.exports = ReactInstanceHandles; }).call(this,require('_process')) -},{"./ReactRootIndex":217,"./invariant":277,"_process":300}],199:[function(require,module,exports){ +},{"./ReactRootIndex":221,"./invariant":281,"_process":304}],203:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -23249,7 +23457,7 @@ var ReactInstanceMap = { module.exports = ReactInstanceMap; -},{}],200:[function(require,module,exports){ +},{}],204:[function(require,module,exports){ /** * Copyright 2015, Facebook, Inc. * All rights reserved. @@ -23286,7 +23494,7 @@ var ReactLifeCycle = { module.exports = ReactLifeCycle; -},{}],201:[function(require,module,exports){ +},{}],205:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -23359,7 +23567,7 @@ ReactLink.PropTypes = { module.exports = ReactLink; -},{"./React":157}],202:[function(require,module,exports){ +},{"./React":161}],206:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -23407,7 +23615,7 @@ var ReactMarkupChecksum = { module.exports = ReactMarkupChecksum; -},{"./adler32":246}],203:[function(require,module,exports){ +},{"./adler32":250}],207:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -24298,7 +24506,7 @@ ReactPerf.measureMethods(ReactMount, 'ReactMount', { module.exports = ReactMount; }).call(this,require('_process')) -},{"./DOMProperty":137,"./ReactBrowserEventEmitter":159,"./ReactCurrentOwner":171,"./ReactElement":189,"./ReactElementValidator":190,"./ReactEmptyComponent":191,"./ReactInstanceHandles":198,"./ReactInstanceMap":199,"./ReactMarkupChecksum":202,"./ReactPerf":208,"./ReactReconciler":215,"./ReactUpdateQueue":225,"./ReactUpdates":226,"./containsNode":250,"./emptyObject":257,"./getReactRootElementInContainer":271,"./instantiateReactComponent":276,"./invariant":277,"./setInnerHTML":291,"./shouldUpdateReactComponent":294,"./warning":298,"_process":300}],204:[function(require,module,exports){ +},{"./DOMProperty":141,"./ReactBrowserEventEmitter":163,"./ReactCurrentOwner":175,"./ReactElement":193,"./ReactElementValidator":194,"./ReactEmptyComponent":195,"./ReactInstanceHandles":202,"./ReactInstanceMap":203,"./ReactMarkupChecksum":206,"./ReactPerf":212,"./ReactReconciler":219,"./ReactUpdateQueue":229,"./ReactUpdates":230,"./containsNode":254,"./emptyObject":261,"./getReactRootElementInContainer":275,"./instantiateReactComponent":280,"./invariant":281,"./setInnerHTML":295,"./shouldUpdateReactComponent":298,"./warning":302,"_process":304}],208:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -24728,7 +24936,7 @@ var ReactMultiChild = { module.exports = ReactMultiChild; -},{"./ReactChildReconciler":162,"./ReactComponentEnvironment":167,"./ReactMultiChildUpdateTypes":205,"./ReactReconciler":215}],205:[function(require,module,exports){ +},{"./ReactChildReconciler":166,"./ReactComponentEnvironment":171,"./ReactMultiChildUpdateTypes":209,"./ReactReconciler":219}],209:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -24761,7 +24969,7 @@ var ReactMultiChildUpdateTypes = keyMirror({ module.exports = ReactMultiChildUpdateTypes; -},{"./keyMirror":283}],206:[function(require,module,exports){ +},{"./keyMirror":287}],210:[function(require,module,exports){ (function (process){ /** * Copyright 2014-2015, Facebook, Inc. @@ -24868,7 +25076,7 @@ var ReactNativeComponent = { module.exports = ReactNativeComponent; }).call(this,require('_process')) -},{"./Object.assign":155,"./invariant":277,"_process":300}],207:[function(require,module,exports){ +},{"./Object.assign":159,"./invariant":281,"_process":304}],211:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -24980,7 +25188,7 @@ var ReactOwner = { module.exports = ReactOwner; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],208:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],212:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -25084,7 +25292,7 @@ function _noMeasure(objName, fnName, func) { module.exports = ReactPerf; }).call(this,require('_process')) -},{"_process":300}],209:[function(require,module,exports){ +},{"_process":304}],213:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -25194,7 +25402,7 @@ var ReactPropTransferer = { module.exports = ReactPropTransferer; -},{"./Object.assign":155,"./emptyFunction":256,"./joinClasses":282}],210:[function(require,module,exports){ +},{"./Object.assign":159,"./emptyFunction":260,"./joinClasses":286}],214:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -25222,7 +25430,7 @@ if ("production" !== process.env.NODE_ENV) { module.exports = ReactPropTypeLocationNames; }).call(this,require('_process')) -},{"_process":300}],211:[function(require,module,exports){ +},{"_process":304}],215:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -25246,7 +25454,7 @@ var ReactPropTypeLocations = keyMirror({ module.exports = ReactPropTypeLocations; -},{"./keyMirror":283}],212:[function(require,module,exports){ +},{"./keyMirror":287}],216:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -25595,7 +25803,7 @@ function getPreciseType(propValue) { module.exports = ReactPropTypes; -},{"./ReactElement":189,"./ReactFragment":195,"./ReactPropTypeLocationNames":210,"./emptyFunction":256}],213:[function(require,module,exports){ +},{"./ReactElement":193,"./ReactFragment":199,"./ReactPropTypeLocationNames":214,"./emptyFunction":260}],217:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -25651,7 +25859,7 @@ PooledClass.addPoolingTo(ReactPutListenerQueue); module.exports = ReactPutListenerQueue; -},{"./Object.assign":155,"./PooledClass":156,"./ReactBrowserEventEmitter":159}],214:[function(require,module,exports){ +},{"./Object.assign":159,"./PooledClass":160,"./ReactBrowserEventEmitter":163}],218:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -25827,7 +26035,7 @@ PooledClass.addPoolingTo(ReactReconcileTransaction); module.exports = ReactReconcileTransaction; -},{"./CallbackQueue":133,"./Object.assign":155,"./PooledClass":156,"./ReactBrowserEventEmitter":159,"./ReactInputSelection":197,"./ReactPutListenerQueue":213,"./Transaction":243}],215:[function(require,module,exports){ +},{"./CallbackQueue":137,"./Object.assign":159,"./PooledClass":160,"./ReactBrowserEventEmitter":163,"./ReactInputSelection":201,"./ReactPutListenerQueue":217,"./Transaction":247}],219:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -25951,7 +26159,7 @@ var ReactReconciler = { module.exports = ReactReconciler; }).call(this,require('_process')) -},{"./ReactElementValidator":190,"./ReactRef":216,"_process":300}],216:[function(require,module,exports){ +},{"./ReactElementValidator":194,"./ReactRef":220,"_process":304}],220:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -26022,7 +26230,7 @@ ReactRef.detachRefs = function(instance, element) { module.exports = ReactRef; -},{"./ReactOwner":207}],217:[function(require,module,exports){ +},{"./ReactOwner":211}],221:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -26053,7 +26261,7 @@ var ReactRootIndex = { module.exports = ReactRootIndex; -},{}],218:[function(require,module,exports){ +},{}],222:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -26135,7 +26343,7 @@ module.exports = { }; }).call(this,require('_process')) -},{"./ReactElement":189,"./ReactInstanceHandles":198,"./ReactMarkupChecksum":202,"./ReactServerRenderingTransaction":219,"./emptyObject":257,"./instantiateReactComponent":276,"./invariant":277,"_process":300}],219:[function(require,module,exports){ +},{"./ReactElement":193,"./ReactInstanceHandles":202,"./ReactMarkupChecksum":206,"./ReactServerRenderingTransaction":223,"./emptyObject":261,"./instantiateReactComponent":280,"./invariant":281,"_process":304}],223:[function(require,module,exports){ /** * Copyright 2014-2015, Facebook, Inc. * All rights reserved. @@ -26248,7 +26456,7 @@ PooledClass.addPoolingTo(ReactServerRenderingTransaction); module.exports = ReactServerRenderingTransaction; -},{"./CallbackQueue":133,"./Object.assign":155,"./PooledClass":156,"./ReactPutListenerQueue":213,"./Transaction":243,"./emptyFunction":256}],220:[function(require,module,exports){ +},{"./CallbackQueue":137,"./Object.assign":159,"./PooledClass":160,"./ReactPutListenerQueue":217,"./Transaction":247,"./emptyFunction":260}],224:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -26354,7 +26562,7 @@ ReactStateSetters.Mixin = { module.exports = ReactStateSetters; -},{}],221:[function(require,module,exports){ +},{}],225:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -26864,7 +27072,7 @@ for (eventType in topLevelTypes) { module.exports = ReactTestUtils; -},{"./EventConstants":142,"./EventPluginHub":144,"./EventPropagators":147,"./Object.assign":155,"./React":157,"./ReactBrowserEventEmitter":159,"./ReactCompositeComponent":169,"./ReactElement":189,"./ReactEmptyComponent":191,"./ReactInstanceHandles":198,"./ReactInstanceMap":199,"./ReactMount":203,"./ReactUpdates":226,"./SyntheticEvent":235}],222:[function(require,module,exports){ +},{"./EventConstants":146,"./EventPluginHub":148,"./EventPropagators":151,"./Object.assign":159,"./React":161,"./ReactBrowserEventEmitter":163,"./ReactCompositeComponent":173,"./ReactElement":193,"./ReactEmptyComponent":195,"./ReactInstanceHandles":202,"./ReactInstanceMap":203,"./ReactMount":207,"./ReactUpdates":230,"./SyntheticEvent":239}],226:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -26969,7 +27177,7 @@ var ReactTransitionChildMapping = { module.exports = ReactTransitionChildMapping; -},{"./ReactChildren":163,"./ReactFragment":195}],223:[function(require,module,exports){ +},{"./ReactChildren":167,"./ReactFragment":199}],227:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -27080,7 +27288,7 @@ var ReactTransitionEvents = { module.exports = ReactTransitionEvents; -},{"./ExecutionEnvironment":148}],224:[function(require,module,exports){ +},{"./ExecutionEnvironment":152}],228:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -27310,7 +27518,7 @@ var ReactTransitionGroup = React.createClass({ module.exports = ReactTransitionGroup; -},{"./Object.assign":155,"./React":157,"./ReactTransitionChildMapping":222,"./cloneWithProps":249,"./emptyFunction":256}],225:[function(require,module,exports){ +},{"./Object.assign":159,"./React":161,"./ReactTransitionChildMapping":226,"./cloneWithProps":253,"./emptyFunction":260}],229:[function(require,module,exports){ (function (process){ /** * Copyright 2015, Facebook, Inc. @@ -27609,7 +27817,7 @@ var ReactUpdateQueue = { module.exports = ReactUpdateQueue; }).call(this,require('_process')) -},{"./Object.assign":155,"./ReactCurrentOwner":171,"./ReactElement":189,"./ReactInstanceMap":199,"./ReactLifeCycle":200,"./ReactUpdates":226,"./invariant":277,"./warning":298,"_process":300}],226:[function(require,module,exports){ +},{"./Object.assign":159,"./ReactCurrentOwner":175,"./ReactElement":193,"./ReactInstanceMap":203,"./ReactLifeCycle":204,"./ReactUpdates":230,"./invariant":281,"./warning":302,"_process":304}],230:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -27891,7 +28099,7 @@ var ReactUpdates = { module.exports = ReactUpdates; }).call(this,require('_process')) -},{"./CallbackQueue":133,"./Object.assign":155,"./PooledClass":156,"./ReactCurrentOwner":171,"./ReactPerf":208,"./ReactReconciler":215,"./Transaction":243,"./invariant":277,"./warning":298,"_process":300}],227:[function(require,module,exports){ +},{"./CallbackQueue":137,"./Object.assign":159,"./PooledClass":160,"./ReactCurrentOwner":175,"./ReactPerf":212,"./ReactReconciler":219,"./Transaction":247,"./invariant":281,"./warning":302,"_process":304}],231:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -27947,7 +28155,7 @@ if ("production" !== process.env.NODE_ENV) { module.exports = React; }).call(this,require('_process')) -},{"./LinkedStateMixin":151,"./React":157,"./ReactCSSTransitionGroup":160,"./ReactComponentWithPureRenderMixin":168,"./ReactDefaultPerf":187,"./ReactFragment":195,"./ReactTestUtils":221,"./ReactTransitionGroup":224,"./ReactUpdates":226,"./cloneWithProps":249,"./cx":254,"./update":297,"_process":300}],228:[function(require,module,exports){ +},{"./LinkedStateMixin":155,"./React":161,"./ReactCSSTransitionGroup":164,"./ReactComponentWithPureRenderMixin":172,"./ReactDefaultPerf":191,"./ReactFragment":199,"./ReactTestUtils":225,"./ReactTransitionGroup":228,"./ReactUpdates":230,"./cloneWithProps":253,"./cx":258,"./update":301,"_process":304}],232:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -28039,7 +28247,7 @@ var SVGDOMPropertyConfig = { module.exports = SVGDOMPropertyConfig; -},{"./DOMProperty":137}],229:[function(require,module,exports){ +},{"./DOMProperty":141}],233:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -28234,7 +28442,7 @@ var SelectEventPlugin = { module.exports = SelectEventPlugin; -},{"./EventConstants":142,"./EventPropagators":147,"./ReactInputSelection":197,"./SyntheticEvent":235,"./getActiveElement":263,"./isTextInputElement":280,"./keyOf":284,"./shallowEqual":293}],230:[function(require,module,exports){ +},{"./EventConstants":146,"./EventPropagators":151,"./ReactInputSelection":201,"./SyntheticEvent":239,"./getActiveElement":267,"./isTextInputElement":284,"./keyOf":288,"./shallowEqual":297}],234:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -28265,7 +28473,7 @@ var ServerReactRootIndex = { module.exports = ServerReactRootIndex; -},{}],231:[function(require,module,exports){ +},{}],235:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -28693,7 +28901,7 @@ var SimpleEventPlugin = { module.exports = SimpleEventPlugin; }).call(this,require('_process')) -},{"./EventConstants":142,"./EventPluginUtils":146,"./EventPropagators":147,"./SyntheticClipboardEvent":232,"./SyntheticDragEvent":234,"./SyntheticEvent":235,"./SyntheticFocusEvent":236,"./SyntheticKeyboardEvent":238,"./SyntheticMouseEvent":239,"./SyntheticTouchEvent":240,"./SyntheticUIEvent":241,"./SyntheticWheelEvent":242,"./getEventCharCode":264,"./invariant":277,"./keyOf":284,"./warning":298,"_process":300}],232:[function(require,module,exports){ +},{"./EventConstants":146,"./EventPluginUtils":150,"./EventPropagators":151,"./SyntheticClipboardEvent":236,"./SyntheticDragEvent":238,"./SyntheticEvent":239,"./SyntheticFocusEvent":240,"./SyntheticKeyboardEvent":242,"./SyntheticMouseEvent":243,"./SyntheticTouchEvent":244,"./SyntheticUIEvent":245,"./SyntheticWheelEvent":246,"./getEventCharCode":268,"./invariant":281,"./keyOf":288,"./warning":302,"_process":304}],236:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -28738,7 +28946,7 @@ SyntheticEvent.augmentClass(SyntheticClipboardEvent, ClipboardEventInterface); module.exports = SyntheticClipboardEvent; -},{"./SyntheticEvent":235}],233:[function(require,module,exports){ +},{"./SyntheticEvent":239}],237:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -28783,7 +28991,7 @@ SyntheticEvent.augmentClass( module.exports = SyntheticCompositionEvent; -},{"./SyntheticEvent":235}],234:[function(require,module,exports){ +},{"./SyntheticEvent":239}],238:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -28822,7 +29030,7 @@ SyntheticMouseEvent.augmentClass(SyntheticDragEvent, DragEventInterface); module.exports = SyntheticDragEvent; -},{"./SyntheticMouseEvent":239}],235:[function(require,module,exports){ +},{"./SyntheticMouseEvent":243}],239:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -28988,7 +29196,7 @@ PooledClass.addPoolingTo(SyntheticEvent, PooledClass.threeArgumentPooler); module.exports = SyntheticEvent; -},{"./Object.assign":155,"./PooledClass":156,"./emptyFunction":256,"./getEventTarget":267}],236:[function(require,module,exports){ +},{"./Object.assign":159,"./PooledClass":160,"./emptyFunction":260,"./getEventTarget":271}],240:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29027,7 +29235,7 @@ SyntheticUIEvent.augmentClass(SyntheticFocusEvent, FocusEventInterface); module.exports = SyntheticFocusEvent; -},{"./SyntheticUIEvent":241}],237:[function(require,module,exports){ +},{"./SyntheticUIEvent":245}],241:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29073,7 +29281,7 @@ SyntheticEvent.augmentClass( module.exports = SyntheticInputEvent; -},{"./SyntheticEvent":235}],238:[function(require,module,exports){ +},{"./SyntheticEvent":239}],242:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29160,7 +29368,7 @@ SyntheticUIEvent.augmentClass(SyntheticKeyboardEvent, KeyboardEventInterface); module.exports = SyntheticKeyboardEvent; -},{"./SyntheticUIEvent":241,"./getEventCharCode":264,"./getEventKey":265,"./getEventModifierState":266}],239:[function(require,module,exports){ +},{"./SyntheticUIEvent":245,"./getEventCharCode":268,"./getEventKey":269,"./getEventModifierState":270}],243:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29241,7 +29449,7 @@ SyntheticUIEvent.augmentClass(SyntheticMouseEvent, MouseEventInterface); module.exports = SyntheticMouseEvent; -},{"./SyntheticUIEvent":241,"./ViewportMetrics":244,"./getEventModifierState":266}],240:[function(require,module,exports){ +},{"./SyntheticUIEvent":245,"./ViewportMetrics":248,"./getEventModifierState":270}],244:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29289,7 +29497,7 @@ SyntheticUIEvent.augmentClass(SyntheticTouchEvent, TouchEventInterface); module.exports = SyntheticTouchEvent; -},{"./SyntheticUIEvent":241,"./getEventModifierState":266}],241:[function(require,module,exports){ +},{"./SyntheticUIEvent":245,"./getEventModifierState":270}],245:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29351,7 +29559,7 @@ SyntheticEvent.augmentClass(SyntheticUIEvent, UIEventInterface); module.exports = SyntheticUIEvent; -},{"./SyntheticEvent":235,"./getEventTarget":267}],242:[function(require,module,exports){ +},{"./SyntheticEvent":239,"./getEventTarget":271}],246:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29412,7 +29620,7 @@ SyntheticMouseEvent.augmentClass(SyntheticWheelEvent, WheelEventInterface); module.exports = SyntheticWheelEvent; -},{"./SyntheticMouseEvent":239}],243:[function(require,module,exports){ +},{"./SyntheticMouseEvent":243}],247:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -29653,7 +29861,7 @@ var Transaction = { module.exports = Transaction; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],244:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],248:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29682,7 +29890,7 @@ var ViewportMetrics = { module.exports = ViewportMetrics; -},{}],245:[function(require,module,exports){ +},{}],249:[function(require,module,exports){ (function (process){ /** * Copyright 2014-2015, Facebook, Inc. @@ -29748,7 +29956,7 @@ function accumulateInto(current, next) { module.exports = accumulateInto; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],246:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],250:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29782,7 +29990,7 @@ function adler32(data) { module.exports = adler32; -},{}],247:[function(require,module,exports){ +},{}],251:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29814,7 +30022,7 @@ function camelize(string) { module.exports = camelize; -},{}],248:[function(require,module,exports){ +},{}],252:[function(require,module,exports){ /** * Copyright 2014-2015, Facebook, Inc. * All rights reserved. @@ -29856,7 +30064,7 @@ function camelizeStyleName(string) { module.exports = camelizeStyleName; -},{"./camelize":247}],249:[function(require,module,exports){ +},{"./camelize":251}],253:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -29915,7 +30123,7 @@ function cloneWithProps(child, props) { module.exports = cloneWithProps; }).call(this,require('_process')) -},{"./ReactElement":189,"./ReactPropTransferer":209,"./keyOf":284,"./warning":298,"_process":300}],250:[function(require,module,exports){ +},{"./ReactElement":193,"./ReactPropTransferer":213,"./keyOf":288,"./warning":302,"_process":304}],254:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -29959,7 +30167,7 @@ function containsNode(outerNode, innerNode) { module.exports = containsNode; -},{"./isTextNode":281}],251:[function(require,module,exports){ +},{"./isTextNode":285}],255:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30045,7 +30253,7 @@ function createArrayFromMixed(obj) { module.exports = createArrayFromMixed; -},{"./toArray":295}],252:[function(require,module,exports){ +},{"./toArray":299}],256:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -30107,7 +30315,7 @@ function createFullPageComponent(tag) { module.exports = createFullPageComponent; }).call(this,require('_process')) -},{"./ReactClass":164,"./ReactElement":189,"./invariant":277,"_process":300}],253:[function(require,module,exports){ +},{"./ReactClass":168,"./ReactElement":193,"./invariant":281,"_process":304}],257:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -30197,7 +30405,7 @@ function createNodesFromMarkup(markup, handleScript) { module.exports = createNodesFromMarkup; }).call(this,require('_process')) -},{"./ExecutionEnvironment":148,"./createArrayFromMixed":251,"./getMarkupWrap":269,"./invariant":277,"_process":300}],254:[function(require,module,exports){ +},{"./ExecutionEnvironment":152,"./createArrayFromMixed":255,"./getMarkupWrap":273,"./invariant":281,"_process":304}],258:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -30253,7 +30461,7 @@ function cx(classNames) { module.exports = cx; }).call(this,require('_process')) -},{"./warning":298,"_process":300}],255:[function(require,module,exports){ +},{"./warning":302,"_process":304}],259:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30311,7 +30519,7 @@ function dangerousStyleValue(name, value) { module.exports = dangerousStyleValue; -},{"./CSSProperty":131}],256:[function(require,module,exports){ +},{"./CSSProperty":135}],260:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30345,7 +30553,7 @@ emptyFunction.thatReturnsArgument = function(arg) { return arg; }; module.exports = emptyFunction; -},{}],257:[function(require,module,exports){ +},{}],261:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -30369,7 +30577,7 @@ if ("production" !== process.env.NODE_ENV) { module.exports = emptyObject; }).call(this,require('_process')) -},{"_process":300}],258:[function(require,module,exports){ +},{"_process":304}],262:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30409,7 +30617,7 @@ function escapeTextContentForBrowser(text) { module.exports = escapeTextContentForBrowser; -},{}],259:[function(require,module,exports){ +},{}],263:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -30482,7 +30690,7 @@ function findDOMNode(componentOrElement) { module.exports = findDOMNode; }).call(this,require('_process')) -},{"./ReactCurrentOwner":171,"./ReactInstanceMap":199,"./ReactMount":203,"./invariant":277,"./isNode":279,"./warning":298,"_process":300}],260:[function(require,module,exports){ +},{"./ReactCurrentOwner":175,"./ReactInstanceMap":203,"./ReactMount":207,"./invariant":281,"./isNode":283,"./warning":302,"_process":304}],264:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -30540,7 +30748,7 @@ function flattenChildren(children) { module.exports = flattenChildren; }).call(this,require('_process')) -},{"./traverseAllChildren":296,"./warning":298,"_process":300}],261:[function(require,module,exports){ +},{"./traverseAllChildren":300,"./warning":302,"_process":304}],265:[function(require,module,exports){ /** * Copyright 2014-2015, Facebook, Inc. * All rights reserved. @@ -30569,7 +30777,7 @@ function focusNode(node) { module.exports = focusNode; -},{}],262:[function(require,module,exports){ +},{}],266:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30600,7 +30808,7 @@ var forEachAccumulated = function(arr, cb, scope) { module.exports = forEachAccumulated; -},{}],263:[function(require,module,exports){ +},{}],267:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30629,7 +30837,7 @@ function getActiveElement() /*?DOMElement*/ { module.exports = getActiveElement; -},{}],264:[function(require,module,exports){ +},{}],268:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30681,7 +30889,7 @@ function getEventCharCode(nativeEvent) { module.exports = getEventCharCode; -},{}],265:[function(require,module,exports){ +},{}],269:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30786,7 +30994,7 @@ function getEventKey(nativeEvent) { module.exports = getEventKey; -},{"./getEventCharCode":264}],266:[function(require,module,exports){ +},{"./getEventCharCode":268}],270:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30833,7 +31041,7 @@ function getEventModifierState(nativeEvent) { module.exports = getEventModifierState; -},{}],267:[function(require,module,exports){ +},{}],271:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30864,7 +31072,7 @@ function getEventTarget(nativeEvent) { module.exports = getEventTarget; -},{}],268:[function(require,module,exports){ +},{}],272:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -30908,7 +31116,7 @@ function getIteratorFn(maybeIterable) { module.exports = getIteratorFn; -},{}],269:[function(require,module,exports){ +},{}],273:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -31025,7 +31233,7 @@ function getMarkupWrap(nodeName) { module.exports = getMarkupWrap; }).call(this,require('_process')) -},{"./ExecutionEnvironment":148,"./invariant":277,"_process":300}],270:[function(require,module,exports){ +},{"./ExecutionEnvironment":152,"./invariant":281,"_process":304}],274:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31100,7 +31308,7 @@ function getNodeForCharacterOffset(root, offset) { module.exports = getNodeForCharacterOffset; -},{}],271:[function(require,module,exports){ +},{}],275:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31135,7 +31343,7 @@ function getReactRootElementInContainer(container) { module.exports = getReactRootElementInContainer; -},{}],272:[function(require,module,exports){ +},{}],276:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31172,7 +31380,7 @@ function getTextContentAccessor() { module.exports = getTextContentAccessor; -},{"./ExecutionEnvironment":148}],273:[function(require,module,exports){ +},{"./ExecutionEnvironment":152}],277:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31212,7 +31420,7 @@ function getUnboundedScrollPosition(scrollable) { module.exports = getUnboundedScrollPosition; -},{}],274:[function(require,module,exports){ +},{}],278:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31245,7 +31453,7 @@ function hyphenate(string) { module.exports = hyphenate; -},{}],275:[function(require,module,exports){ +},{}],279:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31286,7 +31494,7 @@ function hyphenateStyleName(string) { module.exports = hyphenateStyleName; -},{"./hyphenate":274}],276:[function(require,module,exports){ +},{"./hyphenate":278}],280:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -31424,7 +31632,7 @@ function instantiateReactComponent(node, parentCompositeType) { module.exports = instantiateReactComponent; }).call(this,require('_process')) -},{"./Object.assign":155,"./ReactCompositeComponent":169,"./ReactEmptyComponent":191,"./ReactNativeComponent":206,"./invariant":277,"./warning":298,"_process":300}],277:[function(require,module,exports){ +},{"./Object.assign":159,"./ReactCompositeComponent":173,"./ReactEmptyComponent":195,"./ReactNativeComponent":210,"./invariant":281,"./warning":302,"_process":304}],281:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -31481,7 +31689,7 @@ var invariant = function(condition, format, a, b, c, d, e, f) { module.exports = invariant; }).call(this,require('_process')) -},{"_process":300}],278:[function(require,module,exports){ +},{"_process":304}],282:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31546,7 +31754,7 @@ function isEventSupported(eventNameSuffix, capture) { module.exports = isEventSupported; -},{"./ExecutionEnvironment":148}],279:[function(require,module,exports){ +},{"./ExecutionEnvironment":152}],283:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31573,7 +31781,7 @@ function isNode(object) { module.exports = isNode; -},{}],280:[function(require,module,exports){ +},{}],284:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31616,7 +31824,7 @@ function isTextInputElement(elem) { module.exports = isTextInputElement; -},{}],281:[function(require,module,exports){ +},{}],285:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31641,7 +31849,7 @@ function isTextNode(object) { module.exports = isTextNode; -},{"./isNode":279}],282:[function(require,module,exports){ +},{"./isNode":283}],286:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31682,7 +31890,7 @@ function joinClasses(className/*, ... */) { module.exports = joinClasses; -},{}],283:[function(require,module,exports){ +},{}],287:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -31737,7 +31945,7 @@ var keyMirror = function(obj) { module.exports = keyMirror; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],284:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],288:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31773,7 +31981,7 @@ var keyOf = function(oneKeyObj) { module.exports = keyOf; -},{}],285:[function(require,module,exports){ +},{}],289:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31826,7 +32034,7 @@ function mapObject(object, callback, context) { module.exports = mapObject; -},{}],286:[function(require,module,exports){ +},{}],290:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31859,7 +32067,7 @@ function memoizeStringOnly(callback) { module.exports = memoizeStringOnly; -},{}],287:[function(require,module,exports){ +},{}],291:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -31899,7 +32107,7 @@ function onlyChild(children) { module.exports = onlyChild; }).call(this,require('_process')) -},{"./ReactElement":189,"./invariant":277,"_process":300}],288:[function(require,module,exports){ +},{"./ReactElement":193,"./invariant":281,"_process":304}],292:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31927,7 +32135,7 @@ if (ExecutionEnvironment.canUseDOM) { module.exports = performance || {}; -},{"./ExecutionEnvironment":148}],289:[function(require,module,exports){ +},{"./ExecutionEnvironment":152}],293:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31955,7 +32163,7 @@ var performanceNow = performance.now.bind(performance); module.exports = performanceNow; -},{"./performance":288}],290:[function(require,module,exports){ +},{"./performance":292}],294:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -31983,7 +32191,7 @@ function quoteAttributeValueForBrowser(value) { module.exports = quoteAttributeValueForBrowser; -},{"./escapeTextContentForBrowser":258}],291:[function(require,module,exports){ +},{"./escapeTextContentForBrowser":262}],295:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -32072,7 +32280,7 @@ if (ExecutionEnvironment.canUseDOM) { module.exports = setInnerHTML; -},{"./ExecutionEnvironment":148}],292:[function(require,module,exports){ +},{"./ExecutionEnvironment":152}],296:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -32114,7 +32322,7 @@ if (ExecutionEnvironment.canUseDOM) { module.exports = setTextContent; -},{"./ExecutionEnvironment":148,"./escapeTextContentForBrowser":258,"./setInnerHTML":291}],293:[function(require,module,exports){ +},{"./ExecutionEnvironment":152,"./escapeTextContentForBrowser":262,"./setInnerHTML":295}],297:[function(require,module,exports){ /** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. @@ -32158,7 +32366,7 @@ function shallowEqual(objA, objB) { module.exports = shallowEqual; -},{}],294:[function(require,module,exports){ +},{}],298:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -32262,7 +32470,7 @@ function shouldUpdateReactComponent(prevElement, nextElement) { module.exports = shouldUpdateReactComponent; }).call(this,require('_process')) -},{"./warning":298,"_process":300}],295:[function(require,module,exports){ +},{"./warning":302,"_process":304}],299:[function(require,module,exports){ (function (process){ /** * Copyright 2014-2015, Facebook, Inc. @@ -32334,7 +32542,7 @@ function toArray(obj) { module.exports = toArray; }).call(this,require('_process')) -},{"./invariant":277,"_process":300}],296:[function(require,module,exports){ +},{"./invariant":281,"_process":304}],300:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -32587,7 +32795,7 @@ function traverseAllChildren(children, callback, traverseContext) { module.exports = traverseAllChildren; }).call(this,require('_process')) -},{"./ReactElement":189,"./ReactFragment":195,"./ReactInstanceHandles":198,"./getIteratorFn":268,"./invariant":277,"./warning":298,"_process":300}],297:[function(require,module,exports){ +},{"./ReactElement":193,"./ReactFragment":199,"./ReactInstanceHandles":202,"./getIteratorFn":272,"./invariant":281,"./warning":302,"_process":304}],301:[function(require,module,exports){ (function (process){ /** * Copyright 2013-2015, Facebook, Inc. @@ -32758,7 +32966,7 @@ function update(value, spec) { module.exports = update; }).call(this,require('_process')) -},{"./Object.assign":155,"./invariant":277,"./keyOf":284,"_process":300}],298:[function(require,module,exports){ +},{"./Object.assign":159,"./invariant":281,"./keyOf":288,"_process":304}],302:[function(require,module,exports){ (function (process){ /** * Copyright 2014-2015, Facebook, Inc. @@ -32821,10 +33029,10 @@ if ("production" !== process.env.NODE_ENV) { module.exports = warning; }).call(this,require('_process')) -},{"./emptyFunction":256,"_process":300}],299:[function(require,module,exports){ +},{"./emptyFunction":260,"_process":304}],303:[function(require,module,exports){ module.exports = require('./lib/React'); -},{"./lib/React":157}],300:[function(require,module,exports){ +},{"./lib/React":161}],304:[function(require,module,exports){ // shim for using process in browser var process = module.exports = {}; diff --git a/build/twister-lib.js b/build/twister-lib.js index 4886a25..4303e70 100755 --- a/build/twister-lib.js +++ b/build/twister-lib.js @@ -29652,6 +29652,18 @@ TwisterAccount.prototype.trim = function (timestamp) { TwisterAccount.prototype.getUsername = function () {return this._name} +TwisterAccount.prototype.verifyKey = function (cbfunc,querySettings) { + + this._privkey.verifyKey(cbfunc,querySettings); + +} + +TwisterAccount.prototype.getKeyStatus = function () { + + this._privkey.getStatus(); + +} + TwisterAccount.prototype.activateTorrents = function (cbfunc,querySettings) { var Twister = this._scope; @@ -30749,7 +30761,6 @@ var twister_network = Bitcoin.networks.bitcoin; twister_network.messagePrefix= '\x18twister Signed Message:\n'; - /** * Describes the public key of a user. * @class @@ -30764,18 +30775,33 @@ var TwisterPrivKey = function (name,scope) { this._verified = true; - + this._status = "unchecked"; + + this._createdAt = Date.now()/1000; + } inherits(TwisterPrivKey,TwisterResource); module.exports = TwisterPrivKey; +TwisterPrivKey.prototype.flatten = function () { + + var flatData = TwisterResource.prototype.flatten.call(this); + + flatData.status = this._status; + flatData.createdAt = this._createdAt; + + return flatData; + +} + TwisterPrivKey.prototype.inflate = function (flatData) { TwisterResource.prototype.inflate.call(this,flatData); - console.log("inflating privkey",flatData); + this._status = flatData.status; + this._createdAt = flatData.createdAt; if (this._data) { @@ -30789,6 +30815,18 @@ TwisterPrivKey.prototype.trim = function (timestamp) { } +TwisterPrivKey.prototype.getStatus = function () { + + return this._status || "unchecked"; + +} + +TwisterPrivKey.prototype.getCreatedAt = function () { + + return this._createdAt; + +} + TwisterPrivKey.prototype.getKey = function () { return this._data; @@ -30807,30 +30845,43 @@ TwisterPrivKey.prototype.setKey = function (key) { } -TwisterPrivKey.prototype.verifyKey = function (cbfunc) { +TwisterPrivKey.prototype.makeRandomKey = function (key) { + + this._btcKey = Bitcoin.ECPair.makeRandom(twister_network); + + this._data = this._btcKey.toWIF(); + +} + +TwisterPrivKey.prototype.verifyKey = function (cbfunc,querySettings) { var Twister = this._scope; var thisResource = this; - Twister.getUser(this._name)._doPubKey(function(pubkey){ - - if(pubkey._data!=thisResource.getPubKey()){ + Twister.getUser(this._name)._doPubKey(function(pubkey,querySettings){ + + if(pubkey._data){ - this._data = null; - this._btcKey = null; + if(pubkey._data==thisResource.getPubKey()){ + + thisResource._status = "confirmed"; + + }else{ + + thisResource._status = "conflicting"; + + } - thisResource._handleError({ - message: "Private key is in conflict with public key.", - code: 32064 - }) }else{ - if(cbfunc){ - cbfunc(thisResource); - } + + thisResource._status = "unconfirmed"; + } + if(cbfunc) cbfunc(thisResource); + }) } @@ -32344,6 +32395,7 @@ TwisterTorrent.prototype.fillPostsCache = function (id,cbfunc) { } },{"../TwisterResource.js":157,"inherits":52}],147:[function(require,module,exports){ +(function (Buffer){ 'use strict'; /** @@ -32496,7 +32548,7 @@ Twister.getAccounts = function () { var res = []; for (var acc in Twister._wallet) { - res.push(acc); + res.push(Twister._wallet[acc]); } return res; @@ -32543,11 +32595,9 @@ Twister.loadServerAccounts = function (cbfunc) { } - - /** @function - * @name loadAccounts - * @description loads available account into the wallet. + * @name importClientSideAccount + * @description imports an account into client side wallet. The private key is not send to any server. */ Twister.importClientSideAccount = function (name,key,cbfunc) { @@ -32556,9 +32606,68 @@ Twister.importClientSideAccount = function (name,key,cbfunc) { Twister._wallet[name] = new TwisterAccount(name,Twister); Twister._wallet[name]._privkey.setKey(key) - Twister._wallet[name]._privkey.verifyKey(function(){ + Twister._wallet[name]._privkey.verifyKey(function(key){ + + if(key.getStatus()=="confirmed"){ + + if(cbfunc) cbfunc(Twister._wallet[name]) + + }else{ + + Twister._handleError({ + message: "Private key is in conflict with public key.", + code: 32064 + }) + + } + + + }) + +} - if(cbfunc) cbfunc(Twister._wallet[name]) +/** @function + * @name generateClientSideAccount + * @description generate an account in the client side wallet. The private key is not send to any server. + */ +Twister.generateClientSideAccount = function (name,cbfunc) { + + var TwisterAccount = require('./ClientWallet/TwisterAccount.js'); + + Twister._wallet[name] = new TwisterAccount(name,Twister); + + var newAccount = Twister._wallet[name]; + + newAccount._privkey.makeRandomKey() + newAccount._privkey.verifyKey(function(){ + + var pubkey = newAccount._privkey.getPubKey(); + + Twister.RPC("createrawtransaction",[name,pubkey],function(raw){ + + console.log("raw transaction: ",raw); + + Twister.RPC("sendrawtransaction",raw,function(res){ + + console.log("sent transaction",res); + + var twisterPubKey = Twister.getUser(username)._pubkey + + twisterPubKey._lastUpdate = Date.now()/1000; + + twisterPubKey._data = res; + + twisterPubKey._btcKey = Bitcoin.ECPair.fromPublicKeyBuffer(new Buffer(res,"hex"),twister_network); + + if(cbfunc) cbfunc(newAccount) + + },function(err){ + console.log("error",err); + }) + },function(err){ + console.log("error",err); + }) + }) @@ -32726,7 +32835,8 @@ Twister.onQueryComplete = function (id, cbfunc){ module.exports = Twister; -},{"./ClientWallet/TwisterAccount.js":139,"./ServerWallet/TwisterAccount.js":144,"./TwisterHashtag.js":150,"./TwisterPromotedPosts.js":154,"./TwisterResource.js":157,"./TwisterUser.js":160}],148:[function(require,module,exports){ +}).call(this,require("buffer").Buffer) +},{"./ClientWallet/TwisterAccount.js":139,"./ServerWallet/TwisterAccount.js":144,"./TwisterHashtag.js":150,"./TwisterPromotedPosts.js":154,"./TwisterResource.js":157,"./TwisterUser.js":160,"buffer":177}],148:[function(require,module,exports){ var inherits = require('inherits'); var TwisterResource = require('./TwisterResource.js'); diff --git a/jsx/App.js b/jsx/App.js index 460ee18..4d7122d 100755 --- a/jsx/App.js +++ b/jsx/App.js @@ -38,6 +38,7 @@ var Mentions = require('./profile/Mentions.js'); var Conversation = require('./other/Conversation.js'); var Hashtag = require('./other/Hashtag.js'); var Settings = require('./other/Settings.js'); +var Accounts = require('./other/Accounts.js'); var AppSettingsMixin = require('./common/AppSettingsMixin.js'); App = React.createClass({ @@ -66,6 +67,33 @@ App = React.createClass({ } else {return "none"} }, + getInitialState: function () { + + var state={}; + + state.activeAccount = localStorage.getItem("twister-react-activeAccount") + + state.accounts = Twister.getAccounts().map(function(acc){ + return { + name: acc.getUsername(), + status: acc.getKeyStatus() + } + }); + + //console.log(state); + + return state; + + }, + + componentDidMount: function () { + + this.setInterval(this.saveCache,300000); + + this.setInterval(this.checkAccounts,60000); + + }, + clearCache: function () { localStorage.setItem("twister-cache", null); }, @@ -76,6 +104,24 @@ App = React.createClass({ localStorage.setItem("twister-cache", JSON.stringify(Twister.serializeCache())) }, + checkAccounts: function() { + + this.state.accounts.map(function(acc){ + + Twister.getAccount(newaccoutname).verifyKey(function(key){ + thisComponent.setState(function(oldstate,props){ + + oldstate.accounts[acc].status = key.getStatus(); + + return oldstate; + + }); + }); + + }) + + }, + switchAccount: function (newaccoutname) { //console.log(newaccoutname); @@ -100,28 +146,14 @@ App = React.createClass({ } - }, - - getInitialState: function () { - - var state={}; - - state.activeAccount = localStorage.getItem("twister-react-activeAccount") - - state.accounts = Twister.getAccounts(); + this.setState(function(oldstate,props){ + oldstate.accounts.push({ + name: event.detail.getUsername(), + status: event.detail.getKeyStatus() + }) + return oldstate; + }) - if (!state.activeAccount) { state.activeAccount=state.accounts[0]; } - - //console.log(state); - - return state; - - }, - - componentDidMount: function () { - - this.setInterval(this.saveCache,300000); - }, render: function() { @@ -134,11 +166,11 @@ App = React.createClass({ for (var i in this.state.accounts) { userbuttons.push( {this.state.accounts[i]} + >{this.state.accounts[i].name} ); } @@ -166,12 +198,14 @@ App = React.createClass({ >Clear Cache Search Settings + Accounts How to Follow Trending Hashtags
@@ -200,6 +234,7 @@ var routes = ( + ); @@ -228,7 +263,7 @@ if (accounts.length==0) { pollInterval:60, pollIntervalProfile: 3600, ignoredUsers: "nobody", - host: "http://tschaul.com:8080" + host: window.location.protocol+"//"+window.location.host+"/" }; diff --git a/jsx/common/FollowButton.js b/jsx/common/FollowButton.js index cbb3714..1ccfa91 100644 --- a/jsx/common/FollowButton.js +++ b/jsx/common/FollowButton.js @@ -49,15 +49,19 @@ module.exports = FollowButton = React.createClass({ thisComponent = this; - Twister.getUser(thisComponent.props.activeAccount).doFollowings(function(followings){ - if(followings.map(function(fol){ - return fol.getUsername(); - }).indexOf(thisComponent.props.username)<0){ - thisComponent.setStateSafe({isCurrentlyFollowing: false, hasLoaded: true}); - }else{ - thisComponent.setStateSafe({isCurrentlyFollowing: true, hasLoaded: true}); - } - }) + if(thisComponent.props.activeAccount){ + Twister.getUser(thisComponent.props.activeAccount).doFollowings(function(followings){ + if(followings.map(function(fol){ + return fol.getUsername(); + }).indexOf(thisComponent.props.username)<0){ + thisComponent.setStateSafe({isCurrentlyFollowing: false, hasLoaded: true}); + }else{ + thisComponent.setStateSafe({isCurrentlyFollowing: true, hasLoaded: true}); + } + }) + } + + }, render: function() { diff --git a/jsx/common/Post.js b/jsx/common/Post.js index 72a09bf..ac81323 100755 --- a/jsx/common/Post.js +++ b/jsx/common/Post.js @@ -121,6 +121,11 @@ module.exports = Post = React.createClass({ render: function() { var post = Twister.getUser(this.props.post.username).getPost(this.props.post.id); + if(!post){ + return ( + + ) + } var retwist = false; var retwistWithComment = false; var comment = ""; diff --git a/jsx/home/Home.js b/jsx/home/Home.js index a50bdd6..72a0eb4 100755 --- a/jsx/home/Home.js +++ b/jsx/home/Home.js @@ -152,7 +152,7 @@ module.exports = Home = React.createClass({ this.setInterval(this.updatePosts, this.state.appSettings.pollInterval*1000); } else { - window.location.hash="#/settings"; + window.location.hash="#/accounts"; console.log("active account is null") } diff --git a/jsx/other/Accounts.js b/jsx/other/Accounts.js new file mode 100644 index 0000000..927ff95 --- /dev/null +++ b/jsx/other/Accounts.js @@ -0,0 +1,47 @@ +var React = require('react'); +var SetIntervalMixin = require("../common/SetIntervalMixin.js"); +var SafeStateChangeMixin = require('../common/SafeStateChangeMixin.js'); +var EventListenerMixin = require('../common/EventListenerMixin.js'); +var AppSettingsMixin = require('../common/AppSettingsMixin.js'); + +var ImportAccountModalButton = require('../other/ImportAccountModalButton.js'); + +var ReactBootstrap = require('react-bootstrap') + , NavItem = ReactBootstrap.NavItem + , Nav = ReactBootstrap.Nav + , ListGroup = ReactBootstrap.ListGroup + , ListGroupItem = ReactBootstrap.ListGroupItem + , Panel = ReactBootstrap.Panel + , Glyphicon = ReactBootstrap.Glyphicon + , Button = ReactBootstrap.Button + , Input = ReactBootstrap.Input + +module.exports = Accounts = React.createClass({ + + mixins: [ + SetIntervalMixin, + SafeStateChangeMixin, + AppSettingsMixin + ], + contextTypes: { + router: React.PropTypes.func + }, + render: function() { + return ( + + Settings + +
    + {this.props.accounts.map(function(acc,index) { + //console.log(acc,index) + return ( +
  • {acc.name} - {acc.status}
  • + ); + })} +
+ +
+
+ ); + } +}); \ No newline at end of file diff --git a/jsx/other/Settings.js b/jsx/other/Settings.js index 9f4bc38..561e874 100755 --- a/jsx/other/Settings.js +++ b/jsx/other/Settings.js @@ -16,7 +16,7 @@ var ReactBootstrap = require('react-bootstrap') , Button = ReactBootstrap.Button , Input = ReactBootstrap.Input -module.exports = Home = React.createClass({ +module.exports = Settings = React.createClass({ mixins: [ SetIntervalMixin, @@ -66,7 +66,6 @@ module.exports = Home = React.createClass({ wrapperClassName='col-xs-8' className="settings-host"/> - ); diff --git a/node_modules/react-router/README.md b/node_modules/react-router/README.md old mode 100755 new mode 100644 index 985c291..246ebb1 --- a/node_modules/react-router/README.md +++ b/node_modules/react-router/README.md @@ -1,18 +1,14 @@ +[![build status](https://img.shields.io/travis/rackt/react-router/0.13.x.svg?style=flat-square)](https://travis-ci.org/rackt/react-router) [![npm package](https://img.shields.io/npm/v/react-router.svg?style=flat-square)](https://www.npmjs.org/package/react-router) -[![build status](https://img.shields.io/travis/rackt/react-router/master.svg?style=flat-square)](https://travis-ci.org/rackt/react-router) -[![dependency status](https://img.shields.io/david/rackt/react-router.svg?style=flat-square)](https://david-dm.org/rackt/react-router) -[![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/rackt/react-router?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge) +[![react-router channel on slack](https://img.shields.io/badge/slack-react--router@reactiflux-61DAFB.svg?style=flat-square)](http://www.reactiflux.com) React Router ============ A complete routing library for React. -Docs ----- - -- [Guide: Overview](/docs/guides/overview.md) -- [API](/docs/api/) +* [Guides](/docs/guides) +* [Docs](/doc) Important Notes --------------- @@ -124,7 +120,7 @@ Related Modules - [rnr-constrained-route](https://github.com/bjyoungblood/rnr-constrained-route) - validate paths and parameters on route handlers. -- [react-router-bootstrap](https://github.com/mtscout6/react-router-bootstrap) - Integration with [react-bootstrap](https://github.com/react-bootstrap/react-bootstrap) components. +- [react-router-bootstrap](https://github.com/react-bootstrap/react-router-bootstrap) - Integration with [react-bootstrap](https://github.com/react-bootstrap/react-bootstrap) components. - [react-router-proxy-loader](https://github.com/odysseyscience/react-router-proxy-loader) - A Webpack loader to dynamically load react-router components on-demand Contributing diff --git a/node_modules/react-router/lib/Cancellation.js b/node_modules/react-router/lib/Cancellation.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/History.js b/node_modules/react-router/lib/History.js old mode 100755 new mode 100644 index f6194ad..eb14e2d --- a/node_modules/react-router/lib/History.js +++ b/node_modules/react-router/lib/History.js @@ -1,7 +1,7 @@ 'use strict'; -var invariant = require('react/lib/invariant'); -var canUseDOM = require('react/lib/ExecutionEnvironment').canUseDOM; +var invariant = require('invariant'); +var canUseDOM = require('can-use-dom'); var History = { diff --git a/node_modules/react-router/lib/Match.js b/node_modules/react-router/lib/Match.js old mode 100755 new mode 100644 index ec5f8bc..e113e1b --- a/node_modules/react-router/lib/Match.js +++ b/node_modules/react-router/lib/Match.js @@ -1,10 +1,10 @@ +/* jshint -W084 */ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -/* jshint -W084 */ +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + var PathUtils = require('./PathUtils'); function deepSearch(route, pathname, query) { @@ -27,29 +27,20 @@ function deepSearch(route, pathname, query) { // No child routes matched; try the default route. var defaultRoute = route.defaultRoute; - if (defaultRoute && (params = PathUtils.extractParams(defaultRoute.path, pathname))) { - return new Match(pathname, params, query, [route, defaultRoute]); - } // Does the "not found" route match? + if (defaultRoute && (params = PathUtils.extractParams(defaultRoute.path, pathname))) return new Match(pathname, params, query, [route, defaultRoute]); + + // Does the "not found" route match? var notFoundRoute = route.notFoundRoute; - if (notFoundRoute && (params = PathUtils.extractParams(notFoundRoute.path, pathname))) { - return new Match(pathname, params, query, [route, notFoundRoute]); - } // Last attempt: check this route. + if (notFoundRoute && (params = PathUtils.extractParams(notFoundRoute.path, pathname))) return new Match(pathname, params, query, [route, notFoundRoute]); + + // Last attempt: check this route. var params = PathUtils.extractParams(route.path, pathname); - if (params) { - return new Match(pathname, params, query, [route]); - }return null; + if (params) return new Match(pathname, params, query, [route]); + + return null; } var Match = (function () { - function Match(pathname, params, query, routes) { - _classCallCheck(this, Match); - - this.pathname = pathname; - this.params = params; - this.query = query; - this.routes = routes; - } - _createClass(Match, null, [{ key: 'findMatch', @@ -69,6 +60,15 @@ var Match = (function () { } }]); + function Match(pathname, params, query, routes) { + _classCallCheck(this, Match); + + this.pathname = pathname; + this.params = params; + this.query = query; + this.routes = routes; + } + return Match; })(); diff --git a/node_modules/react-router/lib/Navigation.js b/node_modules/react-router/lib/Navigation.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/PathUtils.js b/node_modules/react-router/lib/PathUtils.js old mode 100755 new mode 100644 index c39d210..f190579 --- a/node_modules/react-router/lib/PathUtils.js +++ b/node_modules/react-router/lib/PathUtils.js @@ -1,12 +1,12 @@ 'use strict'; -var invariant = require('react/lib/invariant'); +var invariant = require('invariant'); var assign = require('object-assign'); var qs = require('qs'); var paramCompileMatcher = /:([a-zA-Z_$][a-zA-Z0-9_$]*)|[*.()\[\]\\+|{}^$]/g; var paramInjectMatcher = /:([a-zA-Z_$][a-zA-Z0-9_$?]*[?]?)|[*]/g; -var paramInjectTrailingSlashMatcher = /\/\/\?|\/\?\/|\/\?/g; +var paramInjectTrailingSlashMatcher = /\/\/\?|\/\?\/|\/\?(?![^\/=]+=.*$)/g; var queryMatcher = /\?(.*)$/; var _compiledPatterns = {}; @@ -71,9 +71,9 @@ var PathUtils = { var match = path.match(matcher); - if (!match) { - return null; - }var params = {}; + if (!match) return null; + + var params = {}; paramNames.forEach(function (paramName, index) { params[paramName] = match[index + 1]; @@ -143,9 +143,9 @@ var PathUtils = { var queryString = qs.stringify(query, { arrayFormat: 'brackets' }); - if (queryString) { - return PathUtils.withoutQuery(path) + '?' + queryString; - }return PathUtils.withoutQuery(path); + if (queryString) return PathUtils.withoutQuery(path) + '?' + queryString; + + return PathUtils.withoutQuery(path); } }; diff --git a/node_modules/react-router/lib/PropTypes.js b/node_modules/react-router/lib/PropTypes.js old mode 100755 new mode 100644 index fdee9be..08d1270 --- a/node_modules/react-router/lib/PropTypes.js +++ b/node_modules/react-router/lib/PropTypes.js @@ -10,9 +10,7 @@ var PropTypes = assign({}, ReactPropTypes, { * Indicates that a prop should be falsy. */ falsy: function falsy(props, propName, componentName) { - if (props[propName]) { - return new Error('<' + componentName + '> should not have a "' + propName + '" prop'); - } + if (props[propName]) return new Error('<' + componentName + '> should not have a "' + propName + '" prop'); }, /** diff --git a/node_modules/react-router/lib/Redirect.js b/node_modules/react-router/lib/Redirect.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/Route.js b/node_modules/react-router/lib/Route.js old mode 100755 new mode 100644 index b2d4ac1..50407bc --- a/node_modules/react-router/lib/Route.js +++ b/node_modules/react-router/lib/Route.js @@ -1,56 +1,18 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + var assign = require('react/lib/Object.assign'); -var invariant = require('react/lib/invariant'); -var warning = require('react/lib/warning'); +var invariant = require('invariant'); +var warning = require('./warning'); var PathUtils = require('./PathUtils'); var _currentRoute; var Route = (function () { - function Route(name, path, ignoreScrollBehavior, isDefault, isNotFound, onEnter, onLeave, handler) { - _classCallCheck(this, Route); - - this.name = name; - this.path = path; - this.paramNames = PathUtils.extractParamNames(this.path); - this.ignoreScrollBehavior = !!ignoreScrollBehavior; - this.isDefault = !!isDefault; - this.isNotFound = !!isNotFound; - this.onEnter = onEnter; - this.onLeave = onLeave; - this.handler = handler; - } - - _createClass(Route, [{ - key: 'appendChild', - - /** - * Appends the given route to this route's child routes. - */ - value: function appendChild(route) { - invariant(route instanceof Route, 'route.appendChild must use a valid Route'); - - if (!this.childRoutes) this.childRoutes = []; - - this.childRoutes.push(route); - } - }, { - key: 'toString', - value: function toString() { - var string = ''; - - return string; - } - }], [{ + _createClass(Route, null, [{ key: 'createRoute', /** @@ -149,28 +111,26 @@ var Route = (function () { return route; } - }, { - key: 'createDefaultRoute', /** * Creates and returns a route that is rendered when its parent matches * the current URL. */ + }, { + key: 'createDefaultRoute', value: function createDefaultRoute(options) { return Route.createRoute(assign({}, options, { isDefault: true })); } - }, { - key: 'createNotFoundRoute', /** * Creates and returns a route that is rendered when its parent matches * the current URL but none of its siblings do. */ + }, { + key: 'createNotFoundRoute', value: function createNotFoundRoute(options) { return Route.createRoute(assign({}, options, { isNotFound: true })); } - }, { - key: 'createRedirect', /** * Creates and returns a route that automatically redirects the transition @@ -184,6 +144,8 @@ var Route = (function () { * - query The query to use in the redirect URL. Defaults * to using the current query */ + }, { + key: 'createRedirect', value: function createRedirect(options) { return Route.createRoute(assign({}, options, { path: options.path || options.from || '*', @@ -194,6 +156,46 @@ var Route = (function () { } }]); + function Route(name, path, ignoreScrollBehavior, isDefault, isNotFound, onEnter, onLeave, handler) { + _classCallCheck(this, Route); + + this.name = name; + this.path = path; + this.paramNames = PathUtils.extractParamNames(this.path); + this.ignoreScrollBehavior = !!ignoreScrollBehavior; + this.isDefault = !!isDefault; + this.isNotFound = !!isNotFound; + this.onEnter = onEnter; + this.onLeave = onLeave; + this.handler = handler; + } + + /** + * Appends the given route to this route's child routes. + */ + + _createClass(Route, [{ + key: 'appendChild', + value: function appendChild(route) { + invariant(route instanceof Route, 'route.appendChild must use a valid Route'); + + if (!this.childRoutes) this.childRoutes = []; + + this.childRoutes.push(route); + } + }, { + key: 'toString', + value: function toString() { + var string = ''; + + return string; + } + }]); + return Route; })(); diff --git a/node_modules/react-router/lib/ScrollHistory.js b/node_modules/react-router/lib/ScrollHistory.js old mode 100755 new mode 100644 index 52a585f..8fbd377 --- a/node_modules/react-router/lib/ScrollHistory.js +++ b/node_modules/react-router/lib/ScrollHistory.js @@ -1,16 +1,16 @@ 'use strict'; -var invariant = require('react/lib/invariant'); -var canUseDOM = require('react/lib/ExecutionEnvironment').canUseDOM; +var invariant = require('invariant'); +var canUseDOM = require('can-use-dom'); var getWindowScrollPosition = require('./getWindowScrollPosition'); function shouldUpdateScroll(state, prevState) { - if (!prevState) { - return true; - } // Don't update scroll position when only the query has changed. - if (state.pathname === prevState.pathname) { - return false; - }var routes = state.routes; + if (!prevState) return true; + + // Don't update scroll position when only the query has changed. + if (state.pathname === prevState.pathname) return false; + + var routes = state.routes; var prevRoutes = prevState.routes; var sharedAncestorRoutes = routes.filter(function (route) { @@ -63,9 +63,9 @@ var ScrollHistory = { }, _updateScroll: function _updateScroll(prevState) { - if (!shouldUpdateScroll(this.state, prevState)) { - return; - }var scrollBehavior = this.constructor.getScrollBehavior(); + if (!shouldUpdateScroll(this.state, prevState)) return; + + var scrollBehavior = this.constructor.getScrollBehavior(); if (scrollBehavior) scrollBehavior.updateScrollPosition(this.constructor.getScrollPosition(this.state.path), this.state.action); } diff --git a/node_modules/react-router/lib/State.js b/node_modules/react-router/lib/State.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/TestUtils.js b/node_modules/react-router/lib/TestUtils.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/Transition.js b/node_modules/react-router/lib/Transition.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/actions/LocationActions.js b/node_modules/react-router/lib/actions/LocationActions.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/behaviors/ImitateBrowserBehavior.js b/node_modules/react-router/lib/behaviors/ImitateBrowserBehavior.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/behaviors/ScrollToTopBehavior.js b/node_modules/react-router/lib/behaviors/ScrollToTopBehavior.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/components/ActiveHandler.js b/node_modules/react-router/lib/components/ActiveHandler.js old mode 100755 new mode 100644 index 13844be..b2ec962 --- a/node_modules/react-router/lib/components/ActiveHandler.js +++ b/node_modules/react-router/lib/components/ActiveHandler.js @@ -1,10 +1,12 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var React = require('react'); var ContextWrapper = require('./ContextWrapper'); @@ -19,15 +21,17 @@ var REF_NAME = '__routeHandler__'; */ var RouteHandler = (function (_React$Component) { + _inherits(RouteHandler, _React$Component); + function RouteHandler() { _classCallCheck(this, RouteHandler); - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } + _get(Object.getPrototypeOf(RouteHandler.prototype), 'constructor', this).apply(this, arguments); } - _inherits(RouteHandler, _React$Component); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 _createClass(RouteHandler, [{ key: 'getChildContext', @@ -66,9 +70,9 @@ var RouteHandler = (function (_React$Component) { value: function createChildRouteHandler(props) { var route = this.context.router.getRouteAtDepth(this.getRouteDepth()); - if (route == null) { - return null; - }var childProps = assign({}, props || this.props, { + if (route == null) return null; + + var childProps = assign({}, props || this.props, { ref: REF_NAME, params: this.context.router.getCurrentParams(), query: this.context.router.getCurrentQuery() @@ -92,10 +96,6 @@ var RouteHandler = (function (_React$Component) { return RouteHandler; })(React.Component); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - RouteHandler.contextTypes = { routeDepth: PropTypes.number.isRequired, router: PropTypes.router.isRequired diff --git a/node_modules/react-router/lib/components/ContextWrapper.js b/node_modules/react-router/lib/components/ContextWrapper.js old mode 100755 new mode 100644 index e92a81a..ad59ddf --- a/node_modules/react-router/lib/components/ContextWrapper.js +++ b/node_modules/react-router/lib/components/ContextWrapper.js @@ -1,30 +1,30 @@ -'use strict'; - -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); - -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; - /** * This component is necessary to get around a context warning * present in React 0.13.0. It sovles this by providing a separation * between the "owner" and "parent" contexts. */ +'use strict'; + +var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); + +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + var React = require('react'); var ContextWrapper = (function (_React$Component) { + _inherits(ContextWrapper, _React$Component); + function ContextWrapper() { _classCallCheck(this, ContextWrapper); - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } + _get(Object.getPrototypeOf(ContextWrapper.prototype), 'constructor', this).apply(this, arguments); } - _inherits(ContextWrapper, _React$Component); - _createClass(ContextWrapper, [{ key: 'render', value: function render() { diff --git a/node_modules/react-router/lib/components/DefaultRoute.js b/node_modules/react-router/lib/components/DefaultRoute.js old mode 100755 new mode 100644 index 016a2f8..31ca7d3 --- a/node_modules/react-router/lib/components/DefaultRoute.js +++ b/node_modules/react-router/lib/components/DefaultRoute.js @@ -1,8 +1,10 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var PropTypes = require('../PropTypes'); var RouteHandler = require('./RouteHandler'); @@ -16,23 +18,21 @@ var Route = require('./Route'); */ var DefaultRoute = (function (_Route) { + _inherits(DefaultRoute, _Route); + function DefaultRoute() { _classCallCheck(this, DefaultRoute); - if (_Route != null) { - _Route.apply(this, arguments); - } + _get(Object.getPrototypeOf(DefaultRoute.prototype), 'constructor', this).apply(this, arguments); } - _inherits(DefaultRoute, _Route); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 return DefaultRoute; })(Route); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - DefaultRoute.propTypes = { name: PropTypes.string, path: PropTypes.falsy, diff --git a/node_modules/react-router/lib/components/Link.js b/node_modules/react-router/lib/components/Link.js old mode 100755 new mode 100644 index fdda8f6..49d58d8 --- a/node_modules/react-router/lib/components/Link.js +++ b/node_modules/react-router/lib/components/Link.js @@ -1,10 +1,12 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var React = require('react'); var assign = require('react/lib/Object.assign'); @@ -38,15 +40,17 @@ function isModifiedEvent(event) { */ var Link = (function (_React$Component) { + _inherits(Link, _React$Component); + function Link() { _classCallCheck(this, Link); - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } + _get(Object.getPrototypeOf(Link.prototype), 'constructor', this).apply(this, arguments); } - _inherits(Link, _React$Component); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 _createClass(Link, [{ key: 'handleClick', @@ -56,30 +60,30 @@ var Link = (function (_React$Component) { if (this.props.onClick) clickResult = this.props.onClick(event); - if (isModifiedEvent(event) || !isLeftClickEvent(event)) { - return; - }if (clickResult === false || event.defaultPrevented === true) allowTransition = false; + if (isModifiedEvent(event) || !isLeftClickEvent(event)) return; + + if (clickResult === false || event.defaultPrevented === true) allowTransition = false; event.preventDefault(); if (allowTransition) this.context.router.transitionTo(this.props.to, this.props.params, this.props.query); } - }, { - key: 'getHref', /** * Returns the value of the "href" attribute to use on the DOM element. */ + }, { + key: 'getHref', value: function getHref() { return this.context.router.makeHref(this.props.to, this.props.params, this.props.query); } - }, { - key: 'getClassName', /** * Returns the value of the "class" attribute to use on the DOM element, which contains * the value of the activeClassName property when this is active. */ + }, { + key: 'getClassName', value: function getClassName() { var className = this.props.className; @@ -110,10 +114,6 @@ var Link = (function (_React$Component) { return Link; })(React.Component); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - Link.contextTypes = { router: PropTypes.router.isRequired }; diff --git a/node_modules/react-router/lib/components/NotFoundRoute.js b/node_modules/react-router/lib/components/NotFoundRoute.js old mode 100755 new mode 100644 index a0d00f3..22a7518 --- a/node_modules/react-router/lib/components/NotFoundRoute.js +++ b/node_modules/react-router/lib/components/NotFoundRoute.js @@ -1,8 +1,10 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var PropTypes = require('../PropTypes'); var RouteHandler = require('./RouteHandler'); @@ -17,23 +19,21 @@ var Route = require('./Route'); */ var NotFoundRoute = (function (_Route) { + _inherits(NotFoundRoute, _Route); + function NotFoundRoute() { _classCallCheck(this, NotFoundRoute); - if (_Route != null) { - _Route.apply(this, arguments); - } + _get(Object.getPrototypeOf(NotFoundRoute.prototype), 'constructor', this).apply(this, arguments); } - _inherits(NotFoundRoute, _Route); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 return NotFoundRoute; })(Route); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - NotFoundRoute.propTypes = { name: PropTypes.string, path: PropTypes.falsy, diff --git a/node_modules/react-router/lib/components/Redirect.js b/node_modules/react-router/lib/components/Redirect.js old mode 100755 new mode 100644 index 0e7cebb..0451a86 --- a/node_modules/react-router/lib/components/Redirect.js +++ b/node_modules/react-router/lib/components/Redirect.js @@ -1,8 +1,10 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var PropTypes = require('../PropTypes'); var Route = require('./Route'); @@ -13,23 +15,21 @@ var Route = require('./Route'); */ var Redirect = (function (_Route) { + _inherits(Redirect, _Route); + function Redirect() { _classCallCheck(this, Redirect); - if (_Route != null) { - _Route.apply(this, arguments); - } + _get(Object.getPrototypeOf(Redirect.prototype), 'constructor', this).apply(this, arguments); } - _inherits(Redirect, _Route); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 return Redirect; })(Route); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - Redirect.propTypes = { path: PropTypes.string, from: PropTypes.string, // Alias for path. diff --git a/node_modules/react-router/lib/components/Route.js b/node_modules/react-router/lib/components/Route.js old mode 100755 new mode 100644 index 19664f1..dc0b373 --- a/node_modules/react-router/lib/components/Route.js +++ b/node_modules/react-router/lib/components/Route.js @@ -1,13 +1,15 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var React = require('react'); -var invariant = require('react/lib/invariant'); +var invariant = require('invariant'); var PropTypes = require('../PropTypes'); var RouteHandler = require('./RouteHandler'); @@ -42,7 +44,7 @@ var RouteHandler = require('./RouteHandler'); * var App = React.createClass({ * render: function () { * return ( - *
+ *
* *
* ); @@ -53,15 +55,17 @@ var RouteHandler = require('./RouteHandler'); */ var Route = (function (_React$Component) { + _inherits(Route, _React$Component); + function Route() { _classCallCheck(this, Route); - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } + _get(Object.getPrototypeOf(Route.prototype), 'constructor', this).apply(this, arguments); } - _inherits(Route, _React$Component); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 _createClass(Route, [{ key: 'render', @@ -73,10 +77,6 @@ var Route = (function (_React$Component) { return Route; })(React.Component); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - Route.propTypes = { name: PropTypes.string, path: PropTypes.string, diff --git a/node_modules/react-router/lib/components/RouteHandler.js b/node_modules/react-router/lib/components/RouteHandler.js old mode 100755 new mode 100644 index 13844be..b2ec962 --- a/node_modules/react-router/lib/components/RouteHandler.js +++ b/node_modules/react-router/lib/components/RouteHandler.js @@ -1,10 +1,12 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; +var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } var React = require('react'); var ContextWrapper = require('./ContextWrapper'); @@ -19,15 +21,17 @@ var REF_NAME = '__routeHandler__'; */ var RouteHandler = (function (_React$Component) { + _inherits(RouteHandler, _React$Component); + function RouteHandler() { _classCallCheck(this, RouteHandler); - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } + _get(Object.getPrototypeOf(RouteHandler.prototype), 'constructor', this).apply(this, arguments); } - _inherits(RouteHandler, _React$Component); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 _createClass(RouteHandler, [{ key: 'getChildContext', @@ -66,9 +70,9 @@ var RouteHandler = (function (_React$Component) { value: function createChildRouteHandler(props) { var route = this.context.router.getRouteAtDepth(this.getRouteDepth()); - if (route == null) { - return null; - }var childProps = assign({}, props || this.props, { + if (route == null) return null; + + var childProps = assign({}, props || this.props, { ref: REF_NAME, params: this.context.router.getCurrentParams(), query: this.context.router.getCurrentQuery() @@ -92,10 +96,6 @@ var RouteHandler = (function (_React$Component) { return RouteHandler; })(React.Component); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - RouteHandler.contextTypes = { routeDepth: PropTypes.number.isRequired, router: PropTypes.router.isRequired diff --git a/node_modules/react-router/lib/createRouter.js b/node_modules/react-router/lib/createRouter.js old mode 100755 new mode 100644 index 83216a7..83731f3 --- a/node_modules/react-router/lib/createRouter.js +++ b/node_modules/react-router/lib/createRouter.js @@ -2,9 +2,9 @@ 'use strict'; var React = require('react'); -var warning = require('react/lib/warning'); -var invariant = require('react/lib/invariant'); -var canUseDOM = require('react/lib/ExecutionEnvironment').canUseDOM; +var warning = require('./warning'); +var invariant = require('invariant'); +var canUseDOM = require('can-use-dom'); var LocationActions = require('./actions/LocationActions'); var ImitateBrowserBehavior = require('./behaviors/ImitateBrowserBehavior'); var HashLocation = require('./locations/HashLocation'); @@ -35,9 +35,9 @@ var DEFAULT_LOCATION = canUseDOM ? HashLocation : '/'; var DEFAULT_SCROLL_BEHAVIOR = canUseDOM ? ImitateBrowserBehavior : null; function hasProperties(object, properties) { - for (var propertyName in properties) if (properties.hasOwnProperty(propertyName) && object[propertyName] !== properties[propertyName]) { - return false; - }return true; + for (var propertyName in properties) if (properties.hasOwnProperty(propertyName) && object[propertyName] !== properties[propertyName]) return false; + + return true; } function hasMatch(routes, route, prevParams, nextParams, prevQuery, nextQuery) { @@ -81,15 +81,15 @@ function routeIsActive(activeRoutes, routeName) { } function paramsAreActive(activeParams, params) { - for (var property in params) if (String(activeParams[property]) !== String(params[property])) { - return false; - }return true; + for (var property in params) if (String(activeParams[property]) !== String(params[property])) return false; + + return true; } function queryIsActive(activeQuery, query) { - for (var property in query) if (String(activeQuery[property]) !== String(query[property])) { - return false; - }return true; + for (var property in query) if (String(activeQuery[property]) !== String(query[property])) return false; + + return true; } /** @@ -301,9 +301,7 @@ function createRouter(options) { var prevPath = state.path; var isRefreshing = action == null; - if (prevPath === path && !isRefreshing) { - return; - } // Nothing to do! + if (prevPath === path && !isRefreshing) return; // Nothing to do! // Record the scroll position as early as possible to // get it before browsers try update it automatically. @@ -460,9 +458,9 @@ function createRouter(options) { * Returns true if the given route, params, and query are active. */ isActive: function isActive(to, params, query) { - if (PathUtils.isAbsolute(to)) { - return to === state.path; - }return routeIsActive(state.routes, to) && paramsAreActive(state.params, params) && (query == null || queryIsActive(state.query, query)); + if (PathUtils.isAbsolute(to)) return to === state.path; + + return routeIsActive(state.routes, to) && paramsAreActive(state.params, params) && (query == null || queryIsActive(state.query, query)); } }, diff --git a/node_modules/react-router/lib/createRoutesFromReactChildren.js b/node_modules/react-router/lib/createRoutesFromReactChildren.js old mode 100755 new mode 100644 index 8abf8d3..067f4e5 --- a/node_modules/react-router/lib/createRoutesFromReactChildren.js +++ b/node_modules/react-router/lib/createRoutesFromReactChildren.js @@ -3,7 +3,7 @@ var React = require('react'); var assign = require('react/lib/Object.assign'); -var warning = require('react/lib/warning'); +var warning = require('./warning'); var DefaultRoute = require('./components/DefaultRoute'); var NotFoundRoute = require('./components/NotFoundRoute'); var Redirect = require('./components/Redirect'); @@ -34,20 +34,20 @@ function createRouteOptions(props) { } function createRouteFromReactElement(element) { - if (!React.isValidElement(element)) { - return; - }var type = element.type; + if (!React.isValidElement(element)) return; + + var type = element.type; var props = assign({}, type.defaultProps, element.props); if (type.propTypes) checkPropTypes(type.displayName, type.propTypes, props); - if (type === DefaultRoute) { - return Route.createDefaultRoute(createRouteOptions(props)); - }if (type === NotFoundRoute) { - return Route.createNotFoundRoute(createRouteOptions(props)); - }if (type === Redirect) { - return Route.createRedirect(createRouteOptions(props)); - }return Route.createRoute(createRouteOptions(props), function () { + if (type === DefaultRoute) return Route.createDefaultRoute(createRouteOptions(props)); + + if (type === NotFoundRoute) return Route.createNotFoundRoute(createRouteOptions(props)); + + if (type === Redirect) return Route.createRedirect(createRouteOptions(props)); + + return Route.createRoute(createRouteOptions(props), function () { if (props.children) createRoutesFromReactChildren(props.children); }); } diff --git a/node_modules/react-router/lib/getWindowScrollPosition.js b/node_modules/react-router/lib/getWindowScrollPosition.js old mode 100755 new mode 100644 index 10b0705..b0e025e --- a/node_modules/react-router/lib/getWindowScrollPosition.js +++ b/node_modules/react-router/lib/getWindowScrollPosition.js @@ -1,7 +1,7 @@ 'use strict'; -var invariant = require('react/lib/invariant'); -var canUseDOM = require('react/lib/ExecutionEnvironment').canUseDOM; +var invariant = require('invariant'); +var canUseDOM = require('can-use-dom'); /** * Returns the current scroll position of the window as { x, y }. diff --git a/node_modules/react-router/lib/index.js b/node_modules/react-router/lib/index.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/isReactChildren.js b/node_modules/react-router/lib/isReactChildren.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/locations/HashLocation.js b/node_modules/react-router/lib/locations/HashLocation.js old mode 100755 new mode 100644 index 26067da..9cbf68b --- a/node_modules/react-router/lib/locations/HashLocation.js +++ b/node_modules/react-router/lib/locations/HashLocation.js @@ -23,9 +23,9 @@ function notifyChange(type) { function ensureSlash() { var path = HashLocation.getCurrentPath(); - if (path.charAt(0) === '/') { - return true; - }HashLocation.replace('/' + path); + if (path.charAt(0) === '/') return true; + + HashLocation.replace('/' + path); return false; } diff --git a/node_modules/react-router/lib/locations/HistoryLocation.js b/node_modules/react-router/lib/locations/HistoryLocation.js old mode 100755 new mode 100644 index 5054461..73f3648 --- a/node_modules/react-router/lib/locations/HistoryLocation.js +++ b/node_modules/react-router/lib/locations/HistoryLocation.js @@ -18,9 +18,7 @@ function notifyChange(type) { } function onPopState(event) { - if (event.state === undefined) { - return; - } // Ignore extraneous popstate events in WebKit. + if (event.state === undefined) return; // Ignore extraneous popstate events in WebKit. notifyChange(LocationActions.POP); } diff --git a/node_modules/react-router/lib/locations/RefreshLocation.js b/node_modules/react-router/lib/locations/RefreshLocation.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/locations/StaticLocation.js b/node_modules/react-router/lib/locations/StaticLocation.js old mode 100755 new mode 100644 index e2e14dc..c018d51 --- a/node_modules/react-router/lib/locations/StaticLocation.js +++ b/node_modules/react-router/lib/locations/StaticLocation.js @@ -1,10 +1,10 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var invariant = require('react/lib/invariant'); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +var invariant = require('invariant'); function throwCannotModify() { invariant(false, 'You cannot modify a static location'); @@ -23,6 +23,10 @@ var StaticLocation = (function () { this.path = path; } + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 + _createClass(StaticLocation, [{ key: 'getCurrentPath', value: function getCurrentPath() { @@ -38,10 +42,6 @@ var StaticLocation = (function () { return StaticLocation; })(); -// TODO: Include these in the above class definition -// once we can use ES7 property initializers. -// https://github.com/babel/babel/issues/619 - StaticLocation.prototype.push = throwCannotModify; StaticLocation.prototype.replace = throwCannotModify; StaticLocation.prototype.pop = throwCannotModify; diff --git a/node_modules/react-router/lib/locations/TestLocation.js b/node_modules/react-router/lib/locations/TestLocation.js old mode 100755 new mode 100644 index bb02b18..8a76a43 --- a/node_modules/react-router/lib/locations/TestLocation.js +++ b/node_modules/react-router/lib/locations/TestLocation.js @@ -1,10 +1,10 @@ 'use strict'; -var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var invariant = require('react/lib/invariant'); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +var invariant = require('invariant'); var LocationActions = require('../actions/LocationActions'); var History = require('../History'); @@ -18,15 +18,11 @@ var TestLocation = (function () { this.history = history || []; this.listeners = []; + this.needsDOM = false; this._updateHistoryLength(); } _createClass(TestLocation, [{ - key: 'needsDOM', - get: function () { - return false; - } - }, { key: '_updateHistoryLength', value: function _updateHistoryLength() { History.length = this.history.length; diff --git a/node_modules/react-router/lib/runRouter.js b/node_modules/react-router/lib/runRouter.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/supportsHistory.js b/node_modules/react-router/lib/supportsHistory.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/lib/warning.js b/node_modules/react-router/lib/warning.js new file mode 100644 index 0000000..ffda22c --- /dev/null +++ b/node_modules/react-router/lib/warning.js @@ -0,0 +1,59 @@ +/** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of https://github.com/facebook/react/tree/0.13-stable. + * An additional grant of patent rights can be found in the PATENTS file in the same directory. + * + * @providesModule warning + */ + +"use strict"; + +/** + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ + +var __DEV__ = process.env.NODE_ENV !== 'production'; + +var warning = function warning() {}; + +if (__DEV__) { + warning = function (condition, format) { + for (var _len = arguments.length, args = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) { + args[_key - 2] = arguments[_key]; + } + + if (format === undefined) { + throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); + } + + if (format.length < 10 || /^[s\W]*$/.test(format)) { + throw new Error('The warning format should be able to uniquely identify this ' + 'warning. Please, use a more descriptive format than: ' + format); + } + + if (format.indexOf('Failed Composite propType: ') === 0) { + return; // Ignore CompositeComponent proptype check. + } + + if (!condition) { + var argIndex = 0; + var message = 'Warning: ' + format.replace(/%s/g, function () { + return args[argIndex++]; + }); + console.warn(message); + try { + // --- Welcome to debugging React --- + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch (x) {} + } + }; +} + +module.exports = warning; \ No newline at end of file diff --git a/node_modules/react-router/node_modules/can-use-dom/.npmignore b/node_modules/react-router/node_modules/can-use-dom/.npmignore new file mode 100644 index 0000000..59d842b --- /dev/null +++ b/node_modules/react-router/node_modules/can-use-dom/.npmignore @@ -0,0 +1,28 @@ +# Logs +logs +*.log + +# Runtime data +pids +*.pid +*.seed + +# Directory for instrumented libs generated by jscoverage/JSCover +lib-cov + +# Coverage directory used by tools like istanbul +coverage + +# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) +.grunt + +# Compiled binary addons (http://nodejs.org/api/addons.html) +build/Release + +# Dependency directory +# Commenting this out is preferred by some people, see +# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git- +node_modules + +# Users Environment Variables +.lock-wscript diff --git a/node_modules/react-router/node_modules/can-use-dom/LICENSE b/node_modules/react-router/node_modules/can-use-dom/LICENSE new file mode 100644 index 0000000..1d4da86 --- /dev/null +++ b/node_modules/react-router/node_modules/can-use-dom/LICENSE @@ -0,0 +1,22 @@ +The MIT License (MIT) + +Copyright (c) 2015 Kiran Abburi + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + diff --git a/node_modules/react-router/node_modules/can-use-dom/index.js b/node_modules/react-router/node_modules/can-use-dom/index.js new file mode 100644 index 0000000..d9ef82c --- /dev/null +++ b/node_modules/react-router/node_modules/can-use-dom/index.js @@ -0,0 +1,7 @@ +var canUseDOM = !!( + typeof window !== 'undefined' && + window.document && + window.document.createElement +); + +module.exports = canUseDOM; \ No newline at end of file diff --git a/node_modules/react-router/node_modules/can-use-dom/package.json b/node_modules/react-router/node_modules/can-use-dom/package.json new file mode 100644 index 0000000..920031d --- /dev/null +++ b/node_modules/react-router/node_modules/can-use-dom/package.json @@ -0,0 +1,51 @@ +{ + "name": "can-use-dom", + "version": "0.1.0", + "description": "Test if you can use dom in the current environment", + "main": "index.js", + "scripts": { + "test": "mocha test.js" + }, + "repository": { + "type": "git", + "url": "https://github.com/akiran/can-use-dom.git" + }, + "keywords": [ + "isomorphic" + ], + "author": { + "name": "Kiran Abburi" + }, + "license": "MIT", + "bugs": { + "url": "https://github.com/akiran/can-use-dom/issues" + }, + "homepage": "https://github.com/akiran/can-use-dom", + "devDependencies": { + "jsdom": "^3.1.0", + "mocha": "^2.1.0", + "should": "^4.6.3" + }, + "gitHead": "0d49ab2adaacdd6c0160c6aafd474be4904a2e52", + "_id": "can-use-dom@0.1.0", + "_shasum": "22cc4a34a0abc43950f42c6411024a3f6366b45a", + "_from": "can-use-dom@0.1.0", + "_npmVersion": "2.1.3", + "_nodeVersion": "0.10.26", + "_npmUser": { + "name": "akiran", + "email": "kiran.coder0@gmail.com" + }, + "maintainers": [ + { + "name": "akiran", + "email": "kiran.coder0@gmail.com" + } + ], + "dist": { + "shasum": "22cc4a34a0abc43950f42c6411024a3f6366b45a", + "tarball": "http://registry.npmjs.org/can-use-dom/-/can-use-dom-0.1.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/can-use-dom/-/can-use-dom-0.1.0.tgz" +} diff --git a/node_modules/react-router/node_modules/can-use-dom/test.js b/node_modules/react-router/node_modules/can-use-dom/test.js new file mode 100644 index 0000000..70a3c8d --- /dev/null +++ b/node_modules/react-router/node_modules/can-use-dom/test.js @@ -0,0 +1,20 @@ +var should = require('should'); +// var jsdom = require('jsdom'); + +describe('canUseDOM', function () { + it('should return false in nodejs environment', function (done) { + var canUseDOM = require('./index'); + canUseDOM.should.be.false; + done(); + }); + + // it('should return true in browser', function (done) { + // jsdom.env('
', function (err, window) { + // global.document = jsdom.jsdom(''); + // global.window = document.defaultView; + // var canUseDOM = require('./index'); + // canUseDOM.should.be.true; + // done(); + // }); + // }); +}); \ No newline at end of file diff --git a/node_modules/react-router/node_modules/invariant/CHANGELOG.md b/node_modules/react-router/node_modules/invariant/CHANGELOG.md new file mode 100644 index 0000000..5326f1a --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/CHANGELOG.md @@ -0,0 +1,33 @@ +2.1.1 / 2015-09-20 +================== + + * Use correct SPDX license. + * Test "browser.js" using browserify. + * Switch from "envify" to "loose-envify". + +2.1.0 / 2015-06-03 +================== + + * Add "envify" as a dependency. + * Fixed license field in "package.json". + +2.0.0 / 2015-02-21 +================== + + * Switch to using the "browser" field. There are now browser and server versions that respect the "format" in production. + +1.0.2 / 2014-09-24 +================== + + * Added tests, npmignore and gitignore. + * Clarifications in README. + +1.0.1 / 2014-09-24 +================== + + * Actually include 'invariant.js'. + +1.0.0 / 2014-09-24 +================== + + * Initial release. diff --git a/node_modules/react-router/node_modules/invariant/README.md b/node_modules/react-router/node_modules/invariant/README.md new file mode 100644 index 0000000..813ee26 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/README.md @@ -0,0 +1,35 @@ +# invariant + +[![Build Status](https://travis-ci.org/zertosh/invariant.svg?branch=master)](https://travis-ci.org/zertosh/invariant) + +A mirror of Facebook's `invariant` (e.g. [React](https://github.com/facebook/react/blob/v0.13.3/src/vendor/core/invariant.js), [flux](https://github.com/facebook/flux/blob/2.0.2/src/invariant.js)). + +## Install + +With [npm](http://npmjs.org) do: + +```sh +npm install invariant +``` + +## `invariant(condition, message)` + +```js +var invariant = require('invariant'); + +invariant(someTruthyVal, 'This will not throw'); +// No errors + +invariant(someFalseyVal, 'This will throw an error with this message'); +// Error: Invariant Violation: This will throw an error with this message +``` + +**Note:** When `process.env.NODE_ENV` is not `production`, the message is required. If omitted, `invariant` will throw regardless of the truthiness of the condition. When `process.env.NODE_ENV` is `production`, the message is optional – so they can be minified away. + +### Browser + +When used with [browserify](https://github.com/substack/node-browserify), it'll use `browser.js` (instead of `invariant.js`) and the [envify](https://github.com/hughsk/envify) transform will inline the value of `process.env.NODE_ENV`. + +### Node + +The node version is optimized around the performance implications of accessing `process.env`. The value of `process.env.NODE_ENV` is cached, and repeatedly used instead of reading `proces.env`. See [Server rendering is slower with npm react #812](https://github.com/facebook/react/issues/812) diff --git a/node_modules/react-router/node_modules/invariant/browser.js b/node_modules/react-router/node_modules/invariant/browser.js new file mode 100644 index 0000000..29ead50 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/browser.js @@ -0,0 +1,51 @@ +/** + * Copyright 2013-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + +'use strict'; + +/** + * Use invariant() to assert state which your program assumes to be true. + * + * Provide sprintf-style format (only %s is supported) and arguments + * to provide information about what broke and what you were + * expecting. + * + * The invariant message will be stripped in production, but the invariant + * will remain to ensure logic does not differ in production. + */ + +var invariant = function(condition, format, a, b, c, d, e, f) { + if (process.env.NODE_ENV !== 'production') { + if (format === undefined) { + throw new Error('invariant requires an error message argument'); + } + } + + if (!condition) { + var error; + if (format === undefined) { + error = new Error( + 'Minified exception occurred; use the non-minified dev environment ' + + 'for the full error message and additional helpful warnings.' + ); + } else { + var args = [a, b, c, d, e, f]; + var argIndex = 0; + error = new Error( + format.replace(/%s/g, function() { return args[argIndex++]; }) + ); + error.name = 'Invariant Violation'; + } + + error.framesToPop = 1; // we don't care about invariant's own frame + throw error; + } +}; + +module.exports = invariant; diff --git a/node_modules/react-router/node_modules/invariant/invariant.js b/node_modules/react-router/node_modules/invariant/invariant.js new file mode 100644 index 0000000..fce2a95 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/invariant.js @@ -0,0 +1,53 @@ +/** + * Copyright 2013-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + +'use strict'; + +/** + * Use invariant() to assert state which your program assumes to be true. + * + * Provide sprintf-style format (only %s is supported) and arguments + * to provide information about what broke and what you were + * expecting. + * + * The invariant message will be stripped in production, but the invariant + * will remain to ensure logic does not differ in production. + */ + +var __DEV__ = process.env.NODE_ENV !== 'production'; + +var invariant = function(condition, format, a, b, c, d, e, f) { + if (__DEV__) { + if (format === undefined) { + throw new Error('invariant requires an error message argument'); + } + } + + if (!condition) { + var error; + if (format === undefined) { + error = new Error( + 'Minified exception occurred; use the non-minified dev environment ' + + 'for the full error message and additional helpful warnings.' + ); + } else { + var args = [a, b, c, d, e, f]; + var argIndex = 0; + error = new Error( + format.replace(/%s/g, function() { return args[argIndex++]; }) + ); + error.name = 'Invariant Violation'; + } + + error.framesToPop = 1; // we don't care about invariant's own frame + throw error; + } +}; + +module.exports = invariant; diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/.npmignore b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/.npmignore new file mode 100644 index 0000000..cbc25da --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/.npmignore @@ -0,0 +1,3 @@ +bench/ +test/ +.travis.yml diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/README.md b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/README.md new file mode 100644 index 0000000..5f038f1 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/README.md @@ -0,0 +1,45 @@ +# loose-envify + +[![Build Status](https://travis-ci.org/zertosh/loose-envify.svg?branch=master)](https://travis-ci.org/zertosh/loose-envify) + +Fast (and loose) selective `process.env` replacer using [js-tokens](https://github.com/lydell/js-tokens) instead of an AST. Works just like [envify](https://github.com/hughsk/envify) but much faster. + +## Gotchas + +* Doesn't handle broken syntax. +* Doesn't look inside embedded expressions in template strings. + - **this won't work:** + ```js + console.log(`the current env is ${process.env.NODE_ENV}`); + ``` +* Doesn't replace oddly-spaced or oddly-commented expressions. + - **this won't work:** + ```js + console.log(process./*won't*/env./*work*/NODE_ENV); + ``` + +## Usage/Options + +loose-envify has the exact same interface as [envify](https://github.com/hughsk/envify). + +## Benchmark + +``` +envify: + + $ for i in {1..5}; do node bench/bench.js 'envify'; done + 708ms + 727ms + 791ms + 719ms + 720ms + +loose-envify: + + $ for i in {1..5}; do node bench/bench.js '../'; done + 51ms + 52ms + 52ms + 52ms + 52ms +``` diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/custom.js b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/custom.js new file mode 100644 index 0000000..3a87148 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/custom.js @@ -0,0 +1,2 @@ +// envify compatibility +module.exports = require('./loose-envify'); diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/index.js b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/index.js new file mode 100644 index 0000000..23a3279 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/index.js @@ -0,0 +1 @@ +module.exports = require('./loose-envify')(process.env); diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/loose-envify.js b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/loose-envify.js new file mode 100644 index 0000000..b5a5be2 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/loose-envify.js @@ -0,0 +1,36 @@ +'use strict'; + +var stream = require('stream'); +var util = require('util'); +var replace = require('./replace'); + +var jsonExtRe = /\.json$/; + +module.exports = function(rootEnv) { + rootEnv = rootEnv || process.env; + return function (file, trOpts) { + if (jsonExtRe.test(file)) { + return stream.PassThrough(); + } + var envs = trOpts ? [rootEnv, trOpts] : [rootEnv]; + return new LooseEnvify(envs); + }; +}; + +function LooseEnvify(envs) { + stream.Transform.call(this); + this._data = ''; + this._envs = envs; +} +util.inherits(LooseEnvify, stream.Transform); + +LooseEnvify.prototype._transform = function(buf, enc, cb) { + this._data += buf; + cb(); +}; + +LooseEnvify.prototype._flush = function(cb) { + var replaced = replace(this._data, this._envs); + this.push(replaced); + cb(); +}; diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/LICENSE b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/LICENSE new file mode 100644 index 0000000..f2500e9 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014, 2015 Simon Lydell + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/changelog.md b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/changelog.md new file mode 100644 index 0000000..7a92a50 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/changelog.md @@ -0,0 +1,65 @@ +### Version 1.0.2 (2015-10-18) ### + +- Improved: Limited npm package contents for a smaller download. Thanks to + @zertosh! + + +### Version 1.0.1 (2015-06-20) ### + +- Fixed: Declared an undeclared variable. + + +### Version 1.0.0 (2015-02-26) ### + +- Changed: Merged the 'operator' and 'punctuation' types into 'punctuator'. That + type is now equivalent to the Punctuator token in the ECMAScript + specification. (Backwards-incompatible change.) +- Fixed: A `-` followed by a number is now correctly matched as a punctuator + followed by a number. It used to be matched as just a number, but there is no + such thing as negative number literals. (Possibly backwards-incompatible + change.) + + +### Version 0.4.1 (2015-02-21) ### + +- Added: Support for the regex `u` flag. + + +### Version 0.4.0 (2015-02-21) ### + +- Improved: `jsTokens.matchToToken` performance. +- Added: Support for octal and binary number literals. +- Added: Support for template strings. + + +### Version 0.3.1 (2015-01-06) ### + +- Fixed: Support for unicode spaces. They used to be allowed in names (which is + very confusing), and some unicode newlines were wrongly allowed in strings and + regexes. + + +### Version 0.3.0 (2014-12-19) ### + +- Changed: The `jsTokens.names` array has been replaced with the + `jsTokens.matchToToken` function. The capturing groups of `jsTokens` are no + longer part of the public API; instead use said function. See this [gist] for + an example. (Backwards-incompatible change.) +- Changed: The empty string is now considered an “invalid” token, instead an + “empty” token (its own group). (Backwards-incompatible change.) +- Removed: component support. (Backwards-incompatible change.) + +[gist]: https://gist.github.com/lydell/be49dbf80c382c473004 + + +### Version 0.2.0 (2014-06-19) ### + +- Changed: Match ES6 function arrows (`=>`) as an operator, instead of its own + category (“functionArrow”), for simplicity. (Backwards-incompatible change.) +- Added: ES6 splats (`...`) are now matched as an operator (instead of three + punctuations). (Backwards-incompatible change.) + + +### Version 0.1.0 (2014-03-08) ### + +- Initial release. diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/index.js b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/index.js new file mode 100644 index 0000000..f3969e9 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/index.js @@ -0,0 +1,19 @@ +// Copyright 2014, 2015 Simon Lydell +// X11 (“MIT”) Licensed. (See LICENSE.) + +// This regex comes from regex.coffee, and is inserted here by generate-index.js +// (run `npm run build`). +module.exports = /((['"])(?:(?!\2|\\).|\\(?:\r\n|[\s\S]))*(\2)?|`(?:[^`\\$]|\\[\s\S]|\$(?!\{)|\$\{(?:[^{}]|\{[^}]*\}?)*\}?)*(`)?)|(\/\/.*)|(\/\*(?:[^*]|\*(?!\/))*(\*\/)?)|(\/(?!\*)(?:\[(?:(?![\]\\]).|\\.)*\]|(?![\/\]\\]).|\\.)+\/(?:(?!\s*(?:\b|[\u0080-\uFFFF$\\'"~({]|[+\-!](?!=)|\.?\d))|[gmiyu]{1,5}\b(?![\u0080-\uFFFF$\\]|\s*(?:[+\-*%&|^<>!=?({]|\/(?![\/*])))))|((?:0[xX][\da-fA-F]+|0[oO][0-7]+|0[bB][01]+|(?:\d*\.\d+|\d+\.?)(?:[eE][+-]?\d+)?))|((?!\d)(?:(?!\s)[$\w\u0080-\uFFFF]|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]{1,6}\})+)|(--|\+\+|&&|\|\||=>|\.{3}|(?:[+\-*\/%&|^]|<{1,2}|>{1,3}|!=?|={1,2})=?|[?:~]|[;,.[\](){}])|(\s+)|(^$|[\s\S])/g + +module.exports.matchToToken = function(match) { + var token = {type: "invalid", value: match[0]} + if (match[ 1]) token.type = "string" , token.closed = !!(match[3] || match[4]) + else if (match[ 5]) token.type = "comment" + else if (match[ 6]) token.type = "comment", token.closed = !!match[7] + else if (match[ 8]) token.type = "regex" + else if (match[ 9]) token.type = "number" + else if (match[10]) token.type = "name" + else if (match[11]) token.type = "punctuator" + else if (match[12]) token.type = "whitespace" + return token +} diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/package.json b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/package.json new file mode 100644 index 0000000..80c2064 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/package.json @@ -0,0 +1,61 @@ +{ + "name": "js-tokens", + "version": "1.0.2", + "author": { + "name": "Simon Lydell" + }, + "license": "MIT", + "description": "A regex that tokenizes JavaScript.", + "keywords": [ + "JavaScript", + "js", + "token", + "tokenize", + "regex" + ], + "files": [ + "index.js" + ], + "repository": { + "type": "git", + "url": "git+https://github.com/lydell/js-tokens.git" + }, + "scripts": { + "test": "mocha --ui tdd", + "esprima-compare": "node esprima-compare ./index.js everything.js/es5.js", + "build": "node generate-index.js", + "dev": "npm run build && npm test" + }, + "devDependencies": { + "coffee-script": "~1.9.3", + "esprima": "^2.3.0", + "everything.js": "^1.0.3", + "mocha": "^2.2.5" + }, + "gitHead": "90f0f0a217984625180414763234c923aeee4af5", + "bugs": { + "url": "https://github.com/lydell/js-tokens/issues" + }, + "homepage": "https://github.com/lydell/js-tokens#readme", + "_id": "js-tokens@1.0.2", + "_shasum": "8647f7e13f64ac15d9357a59a346c804d53b3efe", + "_from": "js-tokens@^1.0.1", + "_npmVersion": "2.14.7", + "_nodeVersion": "4.2.1", + "_npmUser": { + "name": "lydell", + "email": "simon.lydell@gmail.com" + }, + "dist": { + "shasum": "8647f7e13f64ac15d9357a59a346c804d53b3efe", + "tarball": "http://registry.npmjs.org/js-tokens/-/js-tokens-1.0.2.tgz" + }, + "maintainers": [ + { + "name": "lydell", + "email": "simon.lydell@gmail.com" + } + ], + "directories": {}, + "_resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-1.0.2.tgz" +} diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/readme.md b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/readme.md new file mode 100644 index 0000000..d53b466 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/node_modules/js-tokens/readme.md @@ -0,0 +1,204 @@ +Overview [![Build Status](https://travis-ci.org/lydell/js-tokens.png?branch=master)](https://travis-ci.org/lydell/js-tokens) +======== + +A regex that tokenizes JavaScript. + +```js +var jsTokens = require("js-tokens") + +var jsString = "var foo=opts.foo;\n..." + +jsString.match(jsTokens) +// ["var", " ", "foo", "=", "opts", ".", "foo", ";", "\n", ...] +``` + + +Installation +============ + +- `npm install js-tokens` + +```js +var jsTokens = require("js-tokens") +``` + + +Usage +===== + +### `jsTokens` ### + +A regex with the `g` flag that matches JavaScript tokens. + +The regex _always_ matches, even invalid JavaScript and the empty string. + +The next match is always directly after the previous. + +### `var token = jsTokens.matchToToken(match)` ### + +Takes a `match` returned by `jsTokens.exec(string)`, and returns a `{type: +String, value: String}` object. The following types are available: + +- string +- comment +- regex +- number +- name +- punctuator +- whitespace +- invalid + +Multi-line comments and strings also have a `closed` property indicating if the +token was closed or not (see below). + +Comments and strings both come in several flavors. To distinguish them, check if +the token starts with `//`, `/*`, `'`, `"` or `` ` ``. + +Names are ECMAScript IdentifierNames, that is, including both identifiers and +keywords. You may use [is-keyword-js] to tell them apart. + +Whitespace includes both line terminators and other whitespace. + +For example usage, please see this [gist]. + +[is-keyword-js]: https://github.com/crissdev/is-keyword-js +[gist]: https://gist.github.com/lydell/be49dbf80c382c473004 + + +Invalid code handling +===================== + +Unterminated strings are still matched as strings. JavaScript strings cannot +contain (unescaped) newlines, so unterminated strings simply end at the end of +the line. Unterminated template strings can contain unescaped newlines, though, +so they go on to the end of input. + +Unterminated multi-line comments are also still matched as comments. They +simply go on to the end of the input. + +Unterminated regex literals are likely matched as division and whatever is +inside the regex. + +Invalid ASCII characters have their own capturing group. + +Invalid non-ASCII characters are treated as names, to simplify the matching of +names (except unicode spaces which are treated as whitespace). + +Regex literals may contain invalid regex syntax. They are still matched as +regex literals. They may also contain repeated regex flags, to keep the regex +simple. + +Strings may contain invalid escape sequences. + + +Limitations +=========== + +Tokenizing JavaScript using regexes—in fact, _one single regex_—won’t be +perfect. But that’s not the point either. + +You may compare jsTokens with [esprima] by using `esprima-compare.js`. +See `npm run esprima-compare`! + +[esprima]: http://esprima.org/ + +### Template string interpolation ### + +Template strings are matched as single tokens, from the starting `` ` `` to the +ending `` ` ``, including interpolations (whose tokens are not matched +individually). + +Matching template string interpolations requires recursive balancing of `{` and +`}`—something that JavaScript regexes cannot do. Only one level of nesting is +supported. + +### Division and regex literals collision ### + +Consider this example: + +```js +var g = 9.82 +var number = bar / 2/g + +var regex = / 2/g +``` + +A human can easily understand that in the `number` line we’re dealing with +division, and in the `regex` line we’re dealing with a regex literal. How come? +Because humans can look at the whole code to put the `/` characters in context. +A JavaScript regex cannot. It only sees forwards. + +When the `jsTokens` regex scans throught the above, it will see the following +at the end of both the `number` and `regex` rows: + +```js +/ 2/g +``` + +It is then impossible to know if that is a regex literal, or part of an +expression dealing with division. + +Here is a similar case: + +```js +foo /= 2/g +foo(/= 2/g) +``` + +The first line divides the `foo` variable with `2/g`. The second line calls the +`foo` function with the regex literal `/= 2/g`. Again, since `jsTokens` only +sees forwards, it cannot tell the two cases apart. + +There are some cases where we _can_ tell division and regex literals apart, +though. + +First off, we have the simple cases where there’s only one slash in the line: + +```js +var foo = 2/g +foo /= 2 +``` + +Regex literals cannot contain newlines, so the above cases are correctly +identified as division. Things are only problematic when there are more than +one non-comment slash in a single line. + +Secondly, not every character is a valid regex flag. + +```js +var number = bar / 2/e +``` + +The above example is also correctly identified as division, because `e` is not a +valid regex flag. I initially wanted to future-proof by allowing `[a-zA-Z]*` +(any letter) as flags, but it is not worth it since it increases the amount of +ambigous cases. So only the standard `g`, `m`, `i`, `y` and `u` flags are +allowed. This means that the above example will be identified as division as +long as you don’t rename the `e` variable to some permutation of `gmiyu` 1 to 5 +characters long. + +Lastly, we can look _forward_ for information. + +- If the token following what looks like a regex literal is not valid after a + regex literal, but is valid in a division expression, then the regex literal + is treated as division instead. For example, a flagless regex cannot be + followed by a string, number or name, but all of those three can be the + denominator of a division. +- Generally, if what looks like a regex literal is followed by an operator, the + regex literal is treated as division instead. This is because regexes are + seldomly used with operators (such as `+`, `*`, `&&` and `==`), but division + could likely be part of such an expression. + +Please consult the regex source and the test cases for precise information on +when regex or division is matched (should you need to know). In short, you +could sum it up as: + +If the end of a statement looks like a regex literal (even if it isn’t), it +will be treated as one. Otherwise it should work as expected (if you write sane +code). + + +License +======= + +[The X11 (“MIT”) License](LICENSE). diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/package.json b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/package.json new file mode 100644 index 0000000..b6fa2c9 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/package.json @@ -0,0 +1,60 @@ +{ + "name": "loose-envify", + "version": "1.1.0", + "description": "Fast (and loose) selective `process.env` replacer using js-tokens instead of an AST", + "keywords": [ + "environment", + "variables", + "browserify", + "browserify-transform", + "transform", + "source", + "configuration" + ], + "homepage": "https://github.com/zertosh/loose-envify", + "license": "MIT", + "author": { + "name": "Andres Suarez", + "email": "zertosh@gmail.com" + }, + "repository": { + "type": "git", + "url": "git://github.com/zertosh/loose-envify.git" + }, + "scripts": { + "test": "tap test/*.js" + }, + "dependencies": { + "js-tokens": "^1.0.1" + }, + "devDependencies": { + "browserify": "^11.0.1", + "envify": "^3.4.0", + "tap": "^1.4.0" + }, + "gitHead": "f536f4fdbde317d77827ac8655c6c8473928b9e1", + "bugs": { + "url": "https://github.com/zertosh/loose-envify/issues" + }, + "_id": "loose-envify@1.1.0", + "_shasum": "527582d62cff4e04da3f9976c7110d3392ec7e0c", + "_from": "loose-envify@^1.0.0", + "_npmVersion": "2.14.4", + "_nodeVersion": "4.1.2", + "_npmUser": { + "name": "zertosh", + "email": "zertosh@gmail.com" + }, + "maintainers": [ + { + "name": "zertosh", + "email": "zertosh@gmail.com" + } + ], + "dist": { + "shasum": "527582d62cff4e04da3f9976c7110d3392ec7e0c", + "tarball": "http://registry.npmjs.org/loose-envify/-/loose-envify-1.1.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.1.0.tgz" +} diff --git a/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/replace.js b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/replace.js new file mode 100644 index 0000000..a5ccbe3 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/node_modules/loose-envify/replace.js @@ -0,0 +1,65 @@ +'use strict'; + +var jsTokens = require('js-tokens'); + +var processEnvRe = /\bprocess\.env\.[_$a-zA-Z][$\w]+\b/; +var spaceOrCommentRe = /^(?:\s|\/[/*])/; + +function replace(src, envs) { + if (!processEnvRe.test(src)) { + return src; + } + + var out = ''; + var purge = envs.some(function(env) { + return env._ && env._.indexOf('purge') !== -1; + }); + + jsTokens.lastIndex = 0 + var parts = src.match(jsTokens); + + for (var i = 0; i < parts.length; i++) { + if (parts[i ] === 'process' && + parts[i + 1] === '.' && + parts[i + 2] === 'env' && + parts[i + 3] === '.') { + var prevCodeToken = getAdjacentCodeToken(-1, parts, i); + var nextCodeToken = getAdjacentCodeToken(1, parts, i + 4); + var replacement = getReplacementString(envs, parts[i + 4], purge); + if (prevCodeToken !== '.' && + nextCodeToken !== '.' && + nextCodeToken !== '=' && + typeof replacement === 'string') { + out += replacement; + i += 4; + continue; + } + } + out += parts[i]; + } + + return out; +} + +function getAdjacentCodeToken(dir, parts, i) { + while (true) { + var part = parts[i += dir]; + if (!spaceOrCommentRe.test(part)) { + return part; + } + } +} + +function getReplacementString(envs, name, purge) { + for (var j = 0; j < envs.length; j++) { + var env = envs[j]; + if (typeof env[name] !== 'undefined') { + return JSON.stringify(env[name]); + } + } + if (purge) { + return 'undefined'; + } +} + +module.exports = replace; diff --git a/node_modules/react-router/node_modules/invariant/package.json b/node_modules/react-router/node_modules/invariant/package.json new file mode 100644 index 0000000..30cf562 --- /dev/null +++ b/node_modules/react-router/node_modules/invariant/package.json @@ -0,0 +1,64 @@ +{ + "name": "invariant", + "version": "2.2.0", + "description": "invariant", + "keywords": [ + "test" + ], + "license": "BSD-3-Clause", + "author": { + "name": "Andres Suarez", + "email": "zertosh@gmail.com" + }, + "files": [ + "invariant.js", + "browser.js" + ], + "repository": { + "type": "git", + "url": "git+https://github.com/zertosh/invariant.git" + }, + "scripts": { + "test": "NODE_ENV=production tap test/*.js && NODE_ENV=development tap test/*.js" + }, + "dependencies": { + "loose-envify": "^1.0.0" + }, + "devDependencies": { + "browserify": "^11.0.1", + "tap": "^1.4.0" + }, + "main": "invariant.js", + "browser": "browser.js", + "browserify": { + "transform": [ + "loose-envify" + ] + }, + "gitHead": "1660eab9f183183e71ef57a7765bb1121680fff9", + "bugs": { + "url": "https://github.com/zertosh/invariant/issues" + }, + "homepage": "https://github.com/zertosh/invariant#readme", + "_id": "invariant@2.2.0", + "_shasum": "c8d7e847366a49cc18b622f058a689d481e895f2", + "_from": "invariant@^2.0.0", + "_npmVersion": "2.14.7", + "_nodeVersion": "4.2.2", + "_npmUser": { + "name": "zertosh", + "email": "zertosh@gmail.com" + }, + "maintainers": [ + { + "name": "zertosh", + "email": "zertosh@gmail.com" + } + ], + "dist": { + "shasum": "c8d7e847366a49cc18b622f058a689d481e895f2", + "tarball": "http://registry.npmjs.org/invariant/-/invariant-2.2.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.0.tgz" +} diff --git a/node_modules/react-router/node_modules/object-assign/index.js b/node_modules/react-router/node_modules/object-assign/index.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/object-assign/license b/node_modules/react-router/node_modules/object-assign/license new file mode 100644 index 0000000..654d0bf --- /dev/null +++ b/node_modules/react-router/node_modules/object-assign/license @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) Sindre Sorhus (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/react-router/node_modules/object-assign/package.json b/node_modules/react-router/node_modules/object-assign/package.json old mode 100755 new mode 100644 index b03ee5a..235a003 --- a/node_modules/react-router/node_modules/object-assign/package.json +++ b/node_modules/react-router/node_modules/object-assign/package.json @@ -1,11 +1,11 @@ { "name": "object-assign", - "version": "2.0.0", + "version": "2.1.1", "description": "ES6 Object.assign() ponyfill", "license": "MIT", "repository": { "type": "git", - "url": "git+https://github.com/sindresorhus/object-assign.git" + "url": "https://github.com/sindresorhus/object-assign" }, "author": { "name": "Sindre Sorhus", @@ -43,26 +43,25 @@ "url": "https://github.com/sindresorhus/object-assign/issues" }, "homepage": "https://github.com/sindresorhus/object-assign", - "_id": "object-assign@2.0.0", - "_shasum": "f8309b09083b01261ece3ef7373f2b57b8dd7042", - "_from": "object-assign@>=2.0.0 <3.0.0", - "_npmVersion": "2.1.5", - "_nodeVersion": "0.10.32", + "_id": "object-assign@2.1.1", + "_shasum": "43c36e5d569ff8e4816c4efa8be02d26967c18aa", + "_from": "object-assign@^2.0.0", + "_npmVersion": "2.10.1", + "_nodeVersion": "0.12.4", "_npmUser": { "name": "sindresorhus", "email": "sindresorhus@gmail.com" }, + "dist": { + "shasum": "43c36e5d569ff8e4816c4efa8be02d26967c18aa", + "tarball": "http://registry.npmjs.org/object-assign/-/object-assign-2.1.1.tgz" + }, "maintainers": [ { "name": "sindresorhus", "email": "sindresorhus@gmail.com" } ], - "dist": { - "shasum": "f8309b09083b01261ece3ef7373f2b57b8dd7042", - "tarball": "http://registry.npmjs.org/object-assign/-/object-assign-2.0.0.tgz" - }, "directories": {}, - "_resolved": "https://registry.npmjs.org/object-assign/-/object-assign-2.0.0.tgz", - "readme": "ERROR: No README data found!" + "_resolved": "https://registry.npmjs.org/object-assign/-/object-assign-2.1.1.tgz" } diff --git a/node_modules/react-router/node_modules/object-assign/readme.md b/node_modules/react-router/node_modules/object-assign/readme.md old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/qs/.jshintignore b/node_modules/react-router/node_modules/qs/.jshintignore old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/qs/.jshintrc b/node_modules/react-router/node_modules/qs/.jshintrc old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/qs/.npmignore b/node_modules/react-router/node_modules/qs/.npmignore old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/qs/.travis.yml b/node_modules/react-router/node_modules/qs/.travis.yml old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/qs/CHANGELOG.md b/node_modules/react-router/node_modules/qs/CHANGELOG.md old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/qs/CONTRIBUTING.md b/node_modules/react-router/node_modules/qs/CONTRIBUTING.md old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/qs/Makefile b/node_modules/react-router/node_modules/qs/Makefile old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/qs/index.js b/node_modules/react-router/node_modules/qs/index.js old mode 100755 new mode 100644 diff --git a/node_modules/react-router/node_modules/qs/package.json b/node_modules/react-router/node_modules/qs/package.json old mode 100755 new mode 100644 index 4cf67cf..4ccd458 --- a/node_modules/react-router/node_modules/qs/package.json +++ b/node_modules/react-router/node_modules/qs/package.json @@ -14,7 +14,7 @@ }, "repository": { "type": "git", - "url": "git+https://github.com/hapijs/qs.git" + "url": "https://github.com/hapijs/qs.git" }, "keywords": [ "querystring", @@ -54,6 +54,5 @@ "tarball": "http://registry.npmjs.org/qs/-/qs-2.4.1.tgz" }, "directories": {}, - "_resolved": "https://registry.npmjs.org/qs/-/qs-2.4.1.tgz", - "readme": "ERROR: No README data found!" + "_resolved": "https://registry.npmjs.org/qs/-/qs-2.4.1.tgz" } diff --git a/node_modules/react-router/package.json b/node_modules/react-router/package.json old mode 100755 new mode 100644 index 60509c7..b803840 --- a/node_modules/react-router/package.json +++ b/node_modules/react-router/package.json @@ -1,11 +1,11 @@ { "name": "react-router", - "version": "0.13.3", + "version": "0.13.5", "description": "A complete routing library for React.js", "main": "lib", "repository": { "type": "git", - "url": "https://github.com/rackt/react-router.git" + "url": "git+https://github.com/rackt/react-router.git" }, "homepage": "https://github.com/rackt/react-router/blob/latest/README.md", "bugs": { @@ -17,9 +17,11 @@ ], "license": "MIT", "peerDependencies": { - "react": "0.13.x" + "react": "0.13.x||0.14.x" }, "dependencies": { + "can-use-dom": "0.1.0", + "invariant": "^2.0.0", "object-assign": "^2.0.0", "qs": "2.4.1" }, @@ -35,13 +37,13 @@ "routes", "router" ], - "_id": "react-router@0.13.3", + "_id": "react-router@0.13.5", "scripts": {}, - "_shasum": "95455dd19d2c04c7b2957ff7fccda76031ac29b1", - "_from": "react-router@>=0.13.2 <0.14.0", - "_resolved": "https://registry.npmjs.org/react-router/-/react-router-0.13.3.tgz", - "_npmVersion": "2.5.1", - "_nodeVersion": "0.12.0", + "_shasum": "02e3e2821c1a38d0573733ab1abfb1c388516733", + "_from": "react-router@0.13.5", + "_resolved": "https://registry.npmjs.org/react-router/-/react-router-0.13.5.tgz", + "_npmVersion": "3.3.10", + "_nodeVersion": "4.2.1", "_npmUser": { "name": "ryanflorence", "email": "rpflorence@gmail.com" @@ -57,8 +59,8 @@ } ], "dist": { - "shasum": "95455dd19d2c04c7b2957ff7fccda76031ac29b1", - "tarball": "http://registry.npmjs.org/react-router/-/react-router-0.13.3.tgz" + "shasum": "02e3e2821c1a38d0573733ab1abfb1c388516733", + "tarball": "http://registry.npmjs.org/react-router/-/react-router-0.13.5.tgz" }, "directories": {} } diff --git a/node_modules/react-router/umd/ReactRouter.js b/node_modules/react-router/umd/ReactRouter.js old mode 100755 new mode 100644 index 81b8307..c73f480 --- a/node_modules/react-router/umd/ReactRouter.js +++ b/node_modules/react-router/umd/ReactRouter.js @@ -7,45 +7,45 @@ exports["ReactRouter"] = factory(require("react")); else root["ReactRouter"] = factory(root["React"]); -})(this, function(__WEBPACK_EXTERNAL_MODULE_21__) { +})(this, function(__WEBPACK_EXTERNAL_MODULE_4__) { return /******/ (function(modules) { // webpackBootstrap /******/ // The module cache /******/ var installedModules = {}; -/******/ + /******/ // The require function /******/ function __webpack_require__(moduleId) { -/******/ + /******/ // Check if module is in cache /******/ if(installedModules[moduleId]) /******/ return installedModules[moduleId].exports; -/******/ + /******/ // Create a new module (and put it into the cache) /******/ var module = installedModules[moduleId] = { /******/ exports: {}, /******/ id: moduleId, /******/ loaded: false /******/ }; -/******/ + /******/ // Execute the module function /******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); -/******/ + /******/ // Flag the module as loaded /******/ module.loaded = true; -/******/ + /******/ // Return the exports of the module /******/ return module.exports; /******/ } -/******/ -/******/ + + /******/ // expose the modules object (__webpack_modules__) /******/ __webpack_require__.m = modules; -/******/ + /******/ // expose the module cache /******/ __webpack_require__.c = installedModules; -/******/ + /******/ // __webpack_public_path__ /******/ __webpack_require__.p = ""; -/******/ + /******/ // Load entry module and return exports /******/ return __webpack_require__(0); /******/ }) @@ -57,34 +57,34 @@ return /******/ (function(modules) { // webpackBootstrap 'use strict'; exports.DefaultRoute = __webpack_require__(1); - exports.Link = __webpack_require__(2); - exports.NotFoundRoute = __webpack_require__(3); - exports.Redirect = __webpack_require__(4); - exports.Route = __webpack_require__(5); - exports.ActiveHandler = __webpack_require__(6); + exports.Link = __webpack_require__(18); + exports.NotFoundRoute = __webpack_require__(19); + exports.Redirect = __webpack_require__(20); + exports.Route = __webpack_require__(17); + exports.ActiveHandler = __webpack_require__(15); exports.RouteHandler = exports.ActiveHandler; - exports.HashLocation = __webpack_require__(7); - exports.HistoryLocation = __webpack_require__(8); - exports.RefreshLocation = __webpack_require__(9); - exports.StaticLocation = __webpack_require__(10); - exports.TestLocation = __webpack_require__(11); + exports.HashLocation = __webpack_require__(21); + exports.HistoryLocation = __webpack_require__(25); + exports.RefreshLocation = __webpack_require__(26); + exports.StaticLocation = __webpack_require__(27); + exports.TestLocation = __webpack_require__(28); - exports.ImitateBrowserBehavior = __webpack_require__(12); - exports.ScrollToTopBehavior = __webpack_require__(13); + exports.ImitateBrowserBehavior = __webpack_require__(29); + exports.ScrollToTopBehavior = __webpack_require__(30); - exports.History = __webpack_require__(14); - exports.Navigation = __webpack_require__(15); - exports.State = __webpack_require__(16); + exports.History = __webpack_require__(23); + exports.Navigation = __webpack_require__(31); + exports.State = __webpack_require__(32); - exports.createRoute = __webpack_require__(17).createRoute; - exports.createDefaultRoute = __webpack_require__(17).createDefaultRoute; - exports.createNotFoundRoute = __webpack_require__(17).createNotFoundRoute; - exports.createRedirect = __webpack_require__(17).createRedirect; - exports.createRoutesFromReactChildren = __webpack_require__(18); + exports.createRoute = __webpack_require__(5).createRoute; + exports.createDefaultRoute = __webpack_require__(5).createDefaultRoute; + exports.createNotFoundRoute = __webpack_require__(5).createNotFoundRoute; + exports.createRedirect = __webpack_require__(5).createRedirect; + exports.createRoutesFromReactChildren = __webpack_require__(33); - exports.create = __webpack_require__(19); - exports.run = __webpack_require__(20); + exports.create = __webpack_require__(34); + exports.run = __webpack_require__(43); /***/ }, /* 1 */ @@ -92,13 +92,15 @@ return /******/ (function(modules) { // webpackBootstrap 'use strict'; - var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; + var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; - var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; + function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } - var PropTypes = __webpack_require__(22); - var RouteHandler = __webpack_require__(6); - var Route = __webpack_require__(5); + function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + + var PropTypes = __webpack_require__(2); + var RouteHandler = __webpack_require__(15); + var Route = __webpack_require__(17); /** * A component is a special kind of that @@ -108,23 +110,21 @@ return /******/ (function(modules) { // webpackBootstrap */ var DefaultRoute = (function (_Route) { + _inherits(DefaultRoute, _Route); + function DefaultRoute() { _classCallCheck(this, DefaultRoute); - if (_Route != null) { - _Route.apply(this, arguments); - } + _get(Object.getPrototypeOf(DefaultRoute.prototype), 'constructor', this).apply(this, arguments); } - _inherits(DefaultRoute, _Route); + // TODO: Include these in the above class definition + // once we can use ES7 property initializers. + // https://github.com/babel/babel/issues/619 return DefaultRoute; })(Route); - // TODO: Include these in the above class definition - // once we can use ES7 property initializers. - // https://github.com/babel/babel/issues/619 - DefaultRoute.propTypes = { name: PropTypes.string, path: PropTypes.falsy, @@ -144,2435 +144,2016 @@ return /******/ (function(modules) { // webpackBootstrap 'use strict'; - var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; + var assign = __webpack_require__(3); + var ReactPropTypes = __webpack_require__(4).PropTypes; + var Route = __webpack_require__(5); - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); + var PropTypes = assign({}, ReactPropTypes, { - var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; + /** + * Indicates that a prop should be falsy. + */ + falsy: function falsy(props, propName, componentName) { + if (props[propName]) return new Error('<' + componentName + '> should not have a "' + propName + '" prop'); + }, - var React = __webpack_require__(21); - var assign = __webpack_require__(33); - var PropTypes = __webpack_require__(22); + /** + * Indicates that a prop should be a Route object. + */ + route: ReactPropTypes.instanceOf(Route), - function isLeftClickEvent(event) { - return event.button === 0; - } + /** + * Indicates that a prop should be a Router object. + */ + //router: ReactPropTypes.instanceOf(Router) // TODO + router: ReactPropTypes.func - function isModifiedEvent(event) { - return !!(event.metaKey || event.altKey || event.ctrlKey || event.shiftKey); - } + }); + + module.exports = PropTypes; + +/***/ }, +/* 3 */ +/***/ function(module, exports) { /** - * components are used to create an element that links to a route. - * When that route is active, the link gets an "active" class name (or the - * value of its `activeClassName` prop). - * - * For example, assuming you have the following route: - * - * - * - * You could use the following component to link to that route: - * - * + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. * - * In addition to params, links may pass along query string parameters - * using the `query` prop. + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. * - * + * @providesModule Object.assign */ - var Link = (function (_React$Component) { - function Link() { - _classCallCheck(this, Link); - - if (_React$Component != null) { - _React$Component.apply(this, arguments); - } - } - - _inherits(Link, _React$Component); - - _createClass(Link, [{ - key: 'handleClick', - value: function handleClick(event) { - var allowTransition = true; - var clickResult; - - if (this.props.onClick) clickResult = this.props.onClick(event); + // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object.assign - if (isModifiedEvent(event) || !isLeftClickEvent(event)) { - return; - }if (clickResult === false || event.defaultPrevented === true) allowTransition = false; + 'use strict'; - event.preventDefault(); + function assign(target, sources) { + if (target == null) { + throw new TypeError('Object.assign target cannot be null or undefined'); + } - if (allowTransition) this.context.router.transitionTo(this.props.to, this.props.params, this.props.query); - } - }, { - key: 'getHref', + var to = Object(target); + var hasOwnProperty = Object.prototype.hasOwnProperty; - /** - * Returns the value of the "href" attribute to use on the DOM element. - */ - value: function getHref() { - return this.context.router.makeHref(this.props.to, this.props.params, this.props.query); + for (var nextIndex = 1; nextIndex < arguments.length; nextIndex++) { + var nextSource = arguments[nextIndex]; + if (nextSource == null) { + continue; } - }, { - key: 'getClassName', - - /** - * Returns the value of the "class" attribute to use on the DOM element, which contains - * the value of the activeClassName property when this is active. - */ - value: function getClassName() { - var className = this.props.className; - if (this.getActiveState()) className += ' ' + this.props.activeClassName; - - return className; - } - }, { - key: 'getActiveState', - value: function getActiveState() { - return this.context.router.isActive(this.props.to, this.props.params, this.props.query); - } - }, { - key: 'render', - value: function render() { - var props = assign({}, this.props, { - href: this.getHref(), - className: this.getClassName(), - onClick: this.handleClick.bind(this) - }); + var from = Object(nextSource); - if (props.activeStyle && this.getActiveState()) props.style = props.activeStyle; + // We don't currently support accessors nor proxies. Therefore this + // copy cannot throw. If we ever supported this then we must handle + // exceptions and side-effects. We don't support symbols so they won't + // be transferred. - return React.DOM.a(props, this.props.children); + for (var key in from) { + if (hasOwnProperty.call(from, key)) { + to[key] = from[key]; + } } - }]); - - return Link; - })(React.Component); - - // TODO: Include these in the above class definition - // once we can use ES7 property initializers. - // https://github.com/babel/babel/issues/619 + } - Link.contextTypes = { - router: PropTypes.router.isRequired - }; + return to; + } - Link.propTypes = { - activeClassName: PropTypes.string.isRequired, - to: PropTypes.oneOfType([PropTypes.string, PropTypes.route]).isRequired, - params: PropTypes.object, - query: PropTypes.object, - activeStyle: PropTypes.object, - onClick: PropTypes.func - }; + module.exports = assign; - Link.defaultProps = { - activeClassName: 'active', - className: '' - }; +/***/ }, +/* 4 */ +/***/ function(module, exports) { - module.exports = Link; + module.exports = __WEBPACK_EXTERNAL_MODULE_4__; /***/ }, -/* 3 */ +/* 5 */ /***/ function(module, exports, __webpack_require__) { 'use strict'; - var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; - - var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; - - var PropTypes = __webpack_require__(22); - var RouteHandler = __webpack_require__(6); - var Route = __webpack_require__(5); - - /** - * A is a special kind of that - * renders when the beginning of its parent's path matches - * but none of its siblings do, including any . - * Only one such route may be used at any given level in the - * route hierarchy. - */ + var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); - var NotFoundRoute = (function (_Route) { - function NotFoundRoute() { - _classCallCheck(this, NotFoundRoute); + function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } - if (_Route != null) { - _Route.apply(this, arguments); - } - } + var assign = __webpack_require__(3); + var invariant = __webpack_require__(6); + var warning = __webpack_require__(7); + var PathUtils = __webpack_require__(8); - _inherits(NotFoundRoute, _Route); + var _currentRoute; - return NotFoundRoute; - })(Route); + var Route = (function () { + _createClass(Route, null, [{ + key: 'createRoute', - // TODO: Include these in the above class definition - // once we can use ES7 property initializers. - // https://github.com/babel/babel/issues/619 + /** + * Creates and returns a new route. Options may be a URL pathname string + * with placeholders for named params or an object with any of the following + * properties: + * + * - name The name of the route. This is used to lookup a + * route relative to its parent route and should be + * unique among all child routes of the same parent + * - path A URL pathname string with optional placeholders + * that specify the names of params to extract from + * the URL when the path matches. Defaults to `/${name}` + * when there is a name given, or the path of the parent + * route, or / + * - ignoreScrollBehavior True to make this route (and all descendants) ignore + * the scroll behavior of the router + * - isDefault True to make this route the default route among all + * its siblings + * - isNotFound True to make this route the "not found" route among + * all its siblings + * - onEnter A transition hook that will be called when the + * router is going to enter this route + * - onLeave A transition hook that will be called when the + * router is going to leave this route + * - handler A React component that will be rendered when + * this route is active + * - parentRoute The parent route to use for this route. This option + * is automatically supplied when creating routes inside + * the callback to another invocation of createRoute. You + * only ever need to use this when declaring routes + * independently of one another to manually piece together + * the route hierarchy + * + * The callback may be used to structure your route hierarchy. Any call to + * createRoute, createDefaultRoute, createNotFoundRoute, or createRedirect + * inside the callback automatically uses this route as its parent. + */ + value: function createRoute(options, callback) { + options = options || {}; - NotFoundRoute.propTypes = { - name: PropTypes.string, - path: PropTypes.falsy, - children: PropTypes.falsy, - handler: PropTypes.func.isRequired - }; + if (typeof options === 'string') options = { path: options }; - NotFoundRoute.defaultProps = { - handler: RouteHandler - }; + var parentRoute = _currentRoute; - module.exports = NotFoundRoute; + if (parentRoute) { + warning(options.parentRoute == null || options.parentRoute === parentRoute, 'You should not use parentRoute with createRoute inside another route\'s child callback; it is ignored'); + } else { + parentRoute = options.parentRoute; + } -/***/ }, -/* 4 */ -/***/ function(module, exports, __webpack_require__) { + var name = options.name; + var path = options.path || name; - 'use strict'; + if (path && !(options.isDefault || options.isNotFound)) { + if (PathUtils.isAbsolute(path)) { + if (parentRoute) { + invariant(path === parentRoute.path || parentRoute.paramNames.length === 0, 'You cannot nest path "%s" inside "%s"; the parent requires URL parameters', path, parentRoute.path); + } + } else if (parentRoute) { + // Relative paths extend their parent. + path = PathUtils.join(parentRoute.path, path); + } else { + path = '/' + path; + } + } else { + path = parentRoute ? parentRoute.path : '/'; + } - var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; + if (options.isNotFound && !/\*$/.test(path)) path += '*'; // Auto-append * to the path of not found routes. - var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; + var route = new Route(name, path, options.ignoreScrollBehavior, options.isDefault, options.isNotFound, options.onEnter, options.onLeave, options.handler); - var PropTypes = __webpack_require__(22); - var Route = __webpack_require__(5); + if (parentRoute) { + if (route.isDefault) { + invariant(parentRoute.defaultRoute == null, '%s may not have more than one default route', parentRoute); - /** - * A component is a special kind of that always - * redirects to another route when it matches. - */ + parentRoute.defaultRoute = route; + } else if (route.isNotFound) { + invariant(parentRoute.notFoundRoute == null, '%s may not have more than one not found route', parentRoute); - var Redirect = (function (_Route) { - function Redirect() { - _classCallCheck(this, Redirect); + parentRoute.notFoundRoute = route; + } + + parentRoute.appendChild(route); + } + + // Any routes created in the callback + // use this route as their parent. + if (typeof callback === 'function') { + var currentRoute = _currentRoute; + _currentRoute = route; + callback.call(route, route); + _currentRoute = currentRoute; + } - if (_Route != null) { - _Route.apply(this, arguments); + return route; } - } - _inherits(Redirect, _Route); + /** + * Creates and returns a route that is rendered when its parent matches + * the current URL. + */ + }, { + key: 'createDefaultRoute', + value: function createDefaultRoute(options) { + return Route.createRoute(assign({}, options, { isDefault: true })); + } - return Redirect; - })(Route); + /** + * Creates and returns a route that is rendered when its parent matches + * the current URL but none of its siblings do. + */ + }, { + key: 'createNotFoundRoute', + value: function createNotFoundRoute(options) { + return Route.createRoute(assign({}, options, { isNotFound: true })); + } - // TODO: Include these in the above class definition - // once we can use ES7 property initializers. - // https://github.com/babel/babel/issues/619 + /** + * Creates and returns a route that automatically redirects the transition + * to another route. In addition to the normal options to createRoute, this + * function accepts the following options: + * + * - from An alias for the `path` option. Defaults to * + * - to The path/route/route name to redirect to + * - params The params to use in the redirect URL. Defaults + * to using the current params + * - query The query to use in the redirect URL. Defaults + * to using the current query + */ + }, { + key: 'createRedirect', + value: function createRedirect(options) { + return Route.createRoute(assign({}, options, { + path: options.path || options.from || '*', + onEnter: function onEnter(transition, params, query) { + transition.redirect(options.to, options.params || params, options.query || query); + } + })); + } + }]); - Redirect.propTypes = { - path: PropTypes.string, - from: PropTypes.string, // Alias for path. - to: PropTypes.string, - handler: PropTypes.falsy - }; + function Route(name, path, ignoreScrollBehavior, isDefault, isNotFound, onEnter, onLeave, handler) { + _classCallCheck(this, Route); - // Redirects should not have a default handler - Redirect.defaultProps = {}; + this.name = name; + this.path = path; + this.paramNames = PathUtils.extractParamNames(this.path); + this.ignoreScrollBehavior = !!ignoreScrollBehavior; + this.isDefault = !!isDefault; + this.isNotFound = !!isNotFound; + this.onEnter = onEnter; + this.onLeave = onLeave; + this.handler = handler; + } - module.exports = Redirect; + /** + * Appends the given route to this route's child routes. + */ -/***/ }, -/* 5 */ -/***/ function(module, exports, __webpack_require__) { + _createClass(Route, [{ + key: 'appendChild', + value: function appendChild(route) { + invariant(route instanceof Route, 'route.appendChild must use a valid Route'); - 'use strict'; + if (!this.childRoutes) this.childRoutes = []; + + this.childRoutes.push(route); + } + }, { + key: 'toString', + value: function toString() { + var string = ''; + + return string; + } + }]); + + return Route; + })(); - var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; + module.exports = Route; - var React = __webpack_require__(21); - var invariant = __webpack_require__(34); - var PropTypes = __webpack_require__(22); - var RouteHandler = __webpack_require__(6); +/***/ }, +/* 6 */ +/***/ function(module, exports, __webpack_require__) { /** - * components specify components that are rendered to the page when the - * URL matches a given pattern. - * - * Routes are arranged in a nested tree structure. When a new URL is requested, - * the tree is searched depth-first to find a route whose path matches the URL. - * When one is found, all routes in the tree that lead to it are considered - * "active" and their components are rendered into the DOM, nested in the same - * order as they are in the tree. - * - * The preferred way to configure a router is using JSX. The XML-like syntax is - * a great way to visualize how routes are laid out in an application. + * Copyright 2013-2015, Facebook, Inc. + * All rights reserved. * - * var routes = [ - * - * - * - * - * - * ]; - * - * Router.run(routes, function (Handler) { - * React.render(, document.body); - * }); + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. * - * Handlers for Route components that contain children can render their active - * child route using a element. + * @providesModule invariant + */ + + 'use strict'; + + /** + * Use invariant() to assert state which your program assumes to be true. * - * var App = React.createClass({ - * render: function () { - * return ( - *
- * - *
- * ); - * } - * }); + * Provide sprintf-style format (only %s is supported) and arguments + * to provide information about what broke and what you were + * expecting. * - * If no handler is provided for the route, it will render a matched child route. + * The invariant message will be stripped in production, but the invariant + * will remain to ensure logic does not differ in production. */ - var Route = (function (_React$Component) { - function Route() { - _classCallCheck(this, Route); - - if (_React$Component != null) { - _React$Component.apply(this, arguments); + var invariant = function invariant(condition, format, a, b, c, d, e, f) { + if (false) { + if (format === undefined) { + throw new Error('invariant requires an error message argument'); } } - _inherits(Route, _React$Component); - - _createClass(Route, [{ - key: 'render', - value: function render() { - invariant(false, '%s elements are for router configuration only and should not be rendered', this.constructor.name); + if (!condition) { + var error; + if (format === undefined) { + error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.'); + } else { + var args = [a, b, c, d, e, f]; + var argIndex = 0; + error = new Error('Invariant Violation: ' + format.replace(/%s/g, function () { + return args[argIndex++]; + })); } - }]); - - return Route; - })(React.Component); - - // TODO: Include these in the above class definition - // once we can use ES7 property initializers. - // https://github.com/babel/babel/issues/619 - - Route.propTypes = { - name: PropTypes.string, - path: PropTypes.string, - handler: PropTypes.func, - ignoreScrollBehavior: PropTypes.bool - }; - Route.defaultProps = { - handler: RouteHandler + error.framesToPop = 1; // we don't care about invariant's own frame + throw error; + } }; - module.exports = Route; + module.exports = invariant; /***/ }, -/* 6 */ +/* 7 */ /***/ function(module, exports, __webpack_require__) { - 'use strict'; + /** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of https://github.com/facebook/react/tree/0.13-stable. + * An additional grant of patent rights can be found in the PATENTS file in the same directory. + * + * @providesModule warning + */ - var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }; + "use strict"; - var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); + /** + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ - var _inherits = function (subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) subClass.__proto__ = superClass; }; + var __DEV__ = ("production") !== 'production'; - var React = __webpack_require__(21); - var ContextWrapper = __webpack_require__(23); - var assign = __webpack_require__(33); - var PropTypes = __webpack_require__(22); + var warning = function warning() {}; - var REF_NAME = '__routeHandler__'; + if (__DEV__) { + warning = function (condition, format) { + for (var _len = arguments.length, args = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) { + args[_key - 2] = arguments[_key]; + } - /** - * A component renders the active child route handler - * when routes are nested. - */ - - var RouteHandler = (function (_React$Component) { - function RouteHandler() { - _classCallCheck(this, RouteHandler); - - if (_React$Component != null) { - _React$Component.apply(this, arguments); + if (format === undefined) { + throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); } - } - - _inherits(RouteHandler, _React$Component); - _createClass(RouteHandler, [{ - key: 'getChildContext', - value: function getChildContext() { - return { - routeDepth: this.context.routeDepth + 1 - }; - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - this._updateRouteComponent(this.refs[REF_NAME]); - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate() { - this._updateRouteComponent(this.refs[REF_NAME]); - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this._updateRouteComponent(null); - } - }, { - key: '_updateRouteComponent', - value: function _updateRouteComponent(component) { - this.context.router.setRouteComponentAtDepth(this.getRouteDepth(), component); + if (format.length < 10 || /^[s\W]*$/.test(format)) { + throw new Error('The warning format should be able to uniquely identify this ' + 'warning. Please, use a more descriptive format than: ' + format); } - }, { - key: 'getRouteDepth', - value: function getRouteDepth() { - return this.context.routeDepth; + + if (format.indexOf('Failed Composite propType: ') === 0) { + return; // Ignore CompositeComponent proptype check. } - }, { - key: 'createChildRouteHandler', - value: function createChildRouteHandler(props) { - var route = this.context.router.getRouteAtDepth(this.getRouteDepth()); - if (route == null) { - return null; - }var childProps = assign({}, props || this.props, { - ref: REF_NAME, - params: this.context.router.getCurrentParams(), - query: this.context.router.getCurrentQuery() + if (!condition) { + var argIndex = 0; + var message = 'Warning: ' + format.replace(/%s/g, function () { + return args[argIndex++]; }); - - return React.createElement(route.handler, childProps); - } - }, { - key: 'render', - value: function render() { - var handler = this.createChildRouteHandler(); - //