|
|
@ -27,7 +27,7 @@ var ReactBootstrap = require('react-bootstrap') |
|
|
|
|
|
|
|
|
|
|
|
var React = require('react'); |
|
|
|
var React = require('react'); |
|
|
|
var Router = require('react-router'); |
|
|
|
var Router = require('react-router'); |
|
|
|
var { Route, DefaultRoute, RouteHandler, Link } = Router; |
|
|
|
var Route = Router.Route; var DefaultRoute = Router.DefaultRoute; var RouteHandler = Router.RouteHandler; var Link = Router.Link; |
|
|
|
|
|
|
|
|
|
|
|
var Home = require("./home/Home.js"); |
|
|
|
var Home = require("./home/Home.js"); |
|
|
|
var Profile = require("./profile/Profile.js"); |
|
|
|
var Profile = require("./profile/Profile.js"); |
|
|
@ -51,7 +51,7 @@ App = React.createClass({displayName: "App", |
|
|
|
|
|
|
|
|
|
|
|
getHandlerKey: function () { |
|
|
|
getHandlerKey: function () { |
|
|
|
var childDepth = 1; // assuming App is top-level route
|
|
|
|
var childDepth = 1; // assuming App is top-level route
|
|
|
|
var { router } = this.context; |
|
|
|
var router = this.context.router |
|
|
|
//console.log(router.getCurrentParams())
|
|
|
|
//console.log(router.getCurrentParams())
|
|
|
|
if ( router.getCurrentRoutes()[childDepth] ) { |
|
|
|
if ( router.getCurrentRoutes()[childDepth] ) { |
|
|
|
var key = router.getCurrentRoutes()[childDepth].name; |
|
|
|
var key = router.getCurrentRoutes()[childDepth].name; |
|
|
@ -240,7 +240,7 @@ if (accounts.length==0) { |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
Twister.loadServerAccounts(function(){ |
|
|
|
Twister.importClientSideAccount("pampalulu","L12kz6tabDN6VmPes1rfEpiznztPF6vgkHp8UZVBgZadxzebHhAp",function(){ |
|
|
|
|
|
|
|
|
|
|
|
var activeAccount = localStorage.getItem("twister-react-activeAccount"); |
|
|
|
var activeAccount = localStorage.getItem("twister-react-activeAccount"); |
|
|
|
|
|
|
|
|
|
|
@ -1888,7 +1888,7 @@ var ReactBootstrap = require('react-bootstrap') |
|
|
|
|
|
|
|
|
|
|
|
var React = require('react'); |
|
|
|
var React = require('react'); |
|
|
|
var Router = require('react-router'); |
|
|
|
var Router = require('react-router'); |
|
|
|
var { Route, DefaultRoute, RouteHandler, Link } = Router; |
|
|
|
var Route = Router.Route; var DefaultRoute = Router.DefaultRoute; var RouteHandler = Router.RouteHandler; var Link = Router.Link; |
|
|
|
|
|
|
|
|
|
|
|
var SetIntervalMixin = require("../common/SetIntervalMixin.js"); |
|
|
|
var SetIntervalMixin = require("../common/SetIntervalMixin.js"); |
|
|
|
var SafeStateChangeMixin = require('../common/SafeStateChangeMixin.js'); |
|
|
|
var SafeStateChangeMixin = require('../common/SafeStateChangeMixin.js'); |
|
|
@ -1901,7 +1901,7 @@ module.exports = Post = React.createClass({displayName: "Post", |
|
|
|
}, |
|
|
|
}, |
|
|
|
getHandlerKey: function () { |
|
|
|
getHandlerKey: function () { |
|
|
|
var childDepth = 2; // assuming App is top-level route
|
|
|
|
var childDepth = 2; // assuming App is top-level route
|
|
|
|
var { router } = this.context; |
|
|
|
var router = this.context.router; |
|
|
|
//console.log(router.getCurrentParams())
|
|
|
|
//console.log(router.getCurrentParams())
|
|
|
|
if ( router.getCurrentRoutes()[childDepth] ) { |
|
|
|
if ( router.getCurrentRoutes()[childDepth] ) { |
|
|
|
var key = router.getCurrentRoutes()[childDepth].name; |
|
|
|
var key = router.getCurrentRoutes()[childDepth].name; |
|
|
|