diff --git a/.gitignore b/.gitignore index 66ed5bab74..03913194f0 100644 --- a/.gitignore +++ b/.gitignore @@ -7,3 +7,5 @@ dist vendor/* tmp/* .vagrant +lib + diff --git a/mocha.setup.js b/mocha.setup.js index 9350997b7d..86fce3919c 100644 --- a/mocha.setup.js +++ b/mocha.setup.js @@ -1,6 +1,6 @@ require('babel-register')(); -process.env.NODE_PATH = require('path').resolve(__dirname, '.'); +process.env.NODE_PATH = require('path').resolve(__dirname, './src'); require('module').Module._initPaths(); const jsdom = require('jsdom').jsdom; diff --git a/package.json b/package.json index 0fc4b798f2..827826e0c9 100644 --- a/package.json +++ b/package.json @@ -8,13 +8,13 @@ "description": "steemit.com is the koa web server & middleware and react.js in-browser code for the world's first blockchain content + social media monetization platform!", "main": "index.js", "scripts": { - "build": "NODE_ENV=production ./node_modules/babel-cli/bin/babel-node.js ./node_modules/.bin/webpack --stats --config ./webpack/prod.config.js", + "build": "NODE_ENV=production ./node_modules/babel-cli/bin/babel-node.js ./node_modules/.bin/webpack --stats --config ./webpack/prod.config.js; rm -rf ./lib; babel src --out-dir lib -Dq", "mocha": "NODE_ENV=test mocha ./mocha.setup.js", - "test": "npm run mocha -- app/**/*.test.js", + "test": "npm run mocha -- src/app/**/*.test.js", "test:watch:all": "npm test -- --watch --watch-extensions jsx", "test:watch": "npm run mocha -- --watch --watch-extensions jsx", - "production": "NODE_ENV=production ./node_modules/babel-cli/bin/babel-node.js --max-old-space-size=1792 server/index.js", - "start": "./node_modules/babel-cli/bin/babel-node.js ./webpack/dev-server.js", + "production": "NODE_ENV=production node lib/server/index.js", + "start": "NODE_ENV=development ./node_modules/babel-cli/bin/babel-node.js ./webpack/dev-server.js", "webpush": "./node_modules/babel-cli/bin/babel-node.js ./scripts/webpush_notify.js" }, "author": "Steemit, Inc.", @@ -139,7 +139,7 @@ "url-loader": "^0.5.7", "web-push": "^3.2.1", "webpack": "^1.13.2", - "webpack-isomorphic-tools": "^2.2.31", + "webpack-isomorphic-tools": "^3.0.3", "websocket": "^1.0.22", "whatwg-fetch": "^0.11.1", "xmldom": "^0.1.22" @@ -162,7 +162,7 @@ "koa-webpack-dev-middleware": "^1.1.0", "koa-webpack-hot-middleware": "^1.0.3", "mocha": "^2.4.5", - "node-watch": "^0.3.5", + "node-watch": "^0.5.5", "react-addons-perf": "15.4.2", "react-addons-test-utils": "15.4.2", "react-transform-catch-errors": "^1.0.1", diff --git a/server/requesttimings.js b/server/requesttimings.js deleted file mode 100644 index a02cbf0efb..0000000000 --- a/server/requesttimings.js +++ /dev/null @@ -1,12 +0,0 @@ -module.exports = requestTime; - -function requestTime() { - return function *requestTime(next) { - let start = Date.now(); - yield* next; - let delta = Math.ceil(Date.now() - start); - // log all requests that take longer than 150ms - if(delta > 150) - console.log('Request took too long! ' + delta + 'ms: ' + this.request.method + ' ' + this.request.path); - } -} \ No newline at end of file diff --git a/app/Main.js b/src/app/Main.js similarity index 100% rename from app/Main.js rename to src/app/Main.js diff --git a/app/ResolveRoute.js b/src/app/ResolveRoute.js similarity index 100% rename from app/ResolveRoute.js rename to src/app/ResolveRoute.js diff --git a/app/RootRoute.js b/src/app/RootRoute.js similarity index 100% rename from app/RootRoute.js rename to src/app/RootRoute.js diff --git a/app/Translator.js b/src/app/Translator.js similarity index 100% rename from app/Translator.js rename to src/app/Translator.js diff --git a/app/assets/icons/bitcoin.svg b/src/app/assets/icons/bitcoin.svg similarity index 100% rename from app/assets/icons/bitcoin.svg rename to src/app/assets/icons/bitcoin.svg diff --git a/app/assets/icons/bitshares.svg b/src/app/assets/icons/bitshares.svg similarity index 100% rename from app/assets/icons/bitshares.svg rename to src/app/assets/icons/bitshares.svg diff --git a/app/assets/icons/calendar.svg b/src/app/assets/icons/calendar.svg similarity index 100% rename from app/assets/icons/calendar.svg rename to src/app/assets/icons/calendar.svg diff --git a/app/assets/icons/chain.svg b/src/app/assets/icons/chain.svg similarity index 100% rename from app/assets/icons/chain.svg rename to src/app/assets/icons/chain.svg diff --git a/app/assets/icons/chatbox.svg b/src/app/assets/icons/chatbox.svg similarity index 100% rename from app/assets/icons/chatbox.svg rename to src/app/assets/icons/chatbox.svg diff --git a/app/assets/icons/chatboxes.svg b/src/app/assets/icons/chatboxes.svg similarity index 100% rename from app/assets/icons/chatboxes.svg rename to src/app/assets/icons/chatboxes.svg diff --git a/app/assets/icons/chevron-down-circle.svg b/src/app/assets/icons/chevron-down-circle.svg similarity index 100% rename from app/assets/icons/chevron-down-circle.svg rename to src/app/assets/icons/chevron-down-circle.svg diff --git a/app/assets/icons/chevron-left.svg b/src/app/assets/icons/chevron-left.svg similarity index 100% rename from app/assets/icons/chevron-left.svg rename to src/app/assets/icons/chevron-left.svg diff --git a/app/assets/icons/chevron-up-circle.svg b/src/app/assets/icons/chevron-up-circle.svg similarity index 100% rename from app/assets/icons/chevron-up-circle.svg rename to src/app/assets/icons/chevron-up-circle.svg diff --git a/app/assets/icons/clock.svg b/src/app/assets/icons/clock.svg similarity index 100% rename from app/assets/icons/clock.svg rename to src/app/assets/icons/clock.svg diff --git a/app/assets/icons/cog.svg b/src/app/assets/icons/cog.svg similarity index 100% rename from app/assets/icons/cog.svg rename to src/app/assets/icons/cog.svg diff --git a/app/assets/icons/dropdown-arrow.svg b/src/app/assets/icons/dropdown-arrow.svg similarity index 100% rename from app/assets/icons/dropdown-arrow.svg rename to src/app/assets/icons/dropdown-arrow.svg diff --git a/app/assets/icons/empty.svg b/src/app/assets/icons/empty.svg similarity index 100% rename from app/assets/icons/empty.svg rename to src/app/assets/icons/empty.svg diff --git a/app/assets/icons/enter.svg b/src/app/assets/icons/enter.svg similarity index 100% rename from app/assets/icons/enter.svg rename to src/app/assets/icons/enter.svg diff --git a/app/assets/icons/ether.svg b/src/app/assets/icons/ether.svg similarity index 100% rename from app/assets/icons/ether.svg rename to src/app/assets/icons/ether.svg diff --git a/app/assets/icons/extlink.svg b/src/app/assets/icons/extlink.svg similarity index 100% rename from app/assets/icons/extlink.svg rename to src/app/assets/icons/extlink.svg diff --git a/app/assets/icons/eye.svg b/src/app/assets/icons/eye.svg similarity index 100% rename from app/assets/icons/eye.svg rename to src/app/assets/icons/eye.svg diff --git a/app/assets/icons/facebook.svg b/src/app/assets/icons/facebook.svg similarity index 100% rename from app/assets/icons/facebook.svg rename to src/app/assets/icons/facebook.svg diff --git a/app/assets/icons/flag1.svg b/src/app/assets/icons/flag1.svg similarity index 100% rename from app/assets/icons/flag1.svg rename to src/app/assets/icons/flag1.svg diff --git a/app/assets/icons/flag2.svg b/src/app/assets/icons/flag2.svg similarity index 100% rename from app/assets/icons/flag2.svg rename to src/app/assets/icons/flag2.svg diff --git a/app/assets/icons/home.svg b/src/app/assets/icons/home.svg similarity index 100% rename from app/assets/icons/home.svg rename to src/app/assets/icons/home.svg diff --git a/app/assets/icons/key.svg b/src/app/assets/icons/key.svg similarity index 100% rename from app/assets/icons/key.svg rename to src/app/assets/icons/key.svg diff --git a/app/assets/icons/line.svg b/src/app/assets/icons/line.svg similarity index 100% rename from app/assets/icons/line.svg rename to src/app/assets/icons/line.svg diff --git a/app/assets/icons/link.svg b/src/app/assets/icons/link.svg similarity index 100% rename from app/assets/icons/link.svg rename to src/app/assets/icons/link.svg diff --git a/app/assets/icons/linkedin.svg b/src/app/assets/icons/linkedin.svg similarity index 100% rename from app/assets/icons/linkedin.svg rename to src/app/assets/icons/linkedin.svg diff --git a/app/assets/icons/location.svg b/src/app/assets/icons/location.svg similarity index 100% rename from app/assets/icons/location.svg rename to src/app/assets/icons/location.svg diff --git a/app/assets/icons/menu.svg b/src/app/assets/icons/menu.svg similarity index 100% rename from app/assets/icons/menu.svg rename to src/app/assets/icons/menu.svg diff --git a/app/assets/icons/pencil2.svg b/src/app/assets/icons/pencil2.svg similarity index 100% rename from app/assets/icons/pencil2.svg rename to src/app/assets/icons/pencil2.svg diff --git a/app/assets/icons/person.svg b/src/app/assets/icons/person.svg similarity index 100% rename from app/assets/icons/person.svg rename to src/app/assets/icons/person.svg diff --git a/app/assets/icons/photo.svg b/src/app/assets/icons/photo.svg similarity index 100% rename from app/assets/icons/photo.svg rename to src/app/assets/icons/photo.svg diff --git a/app/assets/icons/printer.svg b/src/app/assets/icons/printer.svg similarity index 98% rename from app/assets/icons/printer.svg rename to src/app/assets/icons/printer.svg index d423f5eef2..7ed4f67e4e 100644 --- a/app/assets/icons/printer.svg +++ b/src/app/assets/icons/printer.svg @@ -1,8 +1,8 @@ - - - - - - + + + + + + diff --git a/app/assets/icons/profile.svg b/src/app/assets/icons/profile.svg similarity index 100% rename from app/assets/icons/profile.svg rename to src/app/assets/icons/profile.svg diff --git a/app/assets/icons/quill.svg b/src/app/assets/icons/quill.svg similarity index 100% rename from app/assets/icons/quill.svg rename to src/app/assets/icons/quill.svg diff --git a/app/assets/icons/reblog.svg b/src/app/assets/icons/reblog.svg similarity index 100% rename from app/assets/icons/reblog.svg rename to src/app/assets/icons/reblog.svg diff --git a/app/assets/icons/replies.svg b/src/app/assets/icons/replies.svg similarity index 100% rename from app/assets/icons/replies.svg rename to src/app/assets/icons/replies.svg diff --git a/app/assets/icons/reply.svg b/src/app/assets/icons/reply.svg similarity index 100% rename from app/assets/icons/reply.svg rename to src/app/assets/icons/reply.svg diff --git a/app/assets/icons/search.svg b/src/app/assets/icons/search.svg similarity index 100% rename from app/assets/icons/search.svg rename to src/app/assets/icons/search.svg diff --git a/app/assets/icons/share.svg b/src/app/assets/icons/share.svg similarity index 100% rename from app/assets/icons/share.svg rename to src/app/assets/icons/share.svg diff --git a/app/assets/icons/steem.svg b/src/app/assets/icons/steem.svg similarity index 100% rename from app/assets/icons/steem.svg rename to src/app/assets/icons/steem.svg diff --git a/app/assets/icons/steemd.svg b/src/app/assets/icons/steemd.svg similarity index 100% rename from app/assets/icons/steemd.svg rename to src/app/assets/icons/steemd.svg diff --git a/app/assets/icons/steemdb.svg b/src/app/assets/icons/steemdb.svg similarity index 100% rename from app/assets/icons/steemdb.svg rename to src/app/assets/icons/steemdb.svg diff --git a/app/assets/icons/twitter.svg b/src/app/assets/icons/twitter.svg similarity index 100% rename from app/assets/icons/twitter.svg rename to src/app/assets/icons/twitter.svg diff --git a/app/assets/icons/user.svg b/src/app/assets/icons/user.svg similarity index 100% rename from app/assets/icons/user.svg rename to src/app/assets/icons/user.svg diff --git a/app/assets/icons/video.svg b/src/app/assets/icons/video.svg similarity index 100% rename from app/assets/icons/video.svg rename to src/app/assets/icons/video.svg diff --git a/app/assets/icons/voter.svg b/src/app/assets/icons/voter.svg similarity index 100% rename from app/assets/icons/voter.svg rename to src/app/assets/icons/voter.svg diff --git a/app/assets/icons/voters.svg b/src/app/assets/icons/voters.svg similarity index 100% rename from app/assets/icons/voters.svg rename to src/app/assets/icons/voters.svg diff --git a/app/assets/icons/wallet.svg b/src/app/assets/icons/wallet.svg similarity index 100% rename from app/assets/icons/wallet.svg rename to src/app/assets/icons/wallet.svg diff --git a/app/assets/images/404.svg b/src/app/assets/images/404.svg similarity index 100% rename from app/assets/images/404.svg rename to src/app/assets/images/404.svg diff --git a/app/assets/images/500.svg b/src/app/assets/images/500.svg similarity index 100% rename from app/assets/images/500.svg rename to src/app/assets/images/500.svg diff --git a/app/assets/images/facebook.svg b/src/app/assets/images/facebook.svg similarity index 100% rename from app/assets/images/facebook.svg rename to src/app/assets/images/facebook.svg diff --git a/app/assets/images/favicon.ico b/src/app/assets/images/favicon.ico similarity index 100% rename from app/assets/images/favicon.ico rename to src/app/assets/images/favicon.ico diff --git a/app/assets/images/favicons/apple-touch-icon-114x114.png b/src/app/assets/images/favicons/apple-touch-icon-114x114.png similarity index 100% rename from app/assets/images/favicons/apple-touch-icon-114x114.png rename to src/app/assets/images/favicons/apple-touch-icon-114x114.png diff --git a/app/assets/images/favicons/apple-touch-icon-120x120.png b/src/app/assets/images/favicons/apple-touch-icon-120x120.png similarity index 100% rename from app/assets/images/favicons/apple-touch-icon-120x120.png rename to src/app/assets/images/favicons/apple-touch-icon-120x120.png diff --git a/app/assets/images/favicons/apple-touch-icon-144x144.png b/src/app/assets/images/favicons/apple-touch-icon-144x144.png similarity index 100% rename from app/assets/images/favicons/apple-touch-icon-144x144.png rename to src/app/assets/images/favicons/apple-touch-icon-144x144.png diff --git a/app/assets/images/favicons/apple-touch-icon-152x152.png b/src/app/assets/images/favicons/apple-touch-icon-152x152.png similarity index 100% rename from app/assets/images/favicons/apple-touch-icon-152x152.png rename to src/app/assets/images/favicons/apple-touch-icon-152x152.png diff --git a/app/assets/images/favicons/apple-touch-icon-57x57.png b/src/app/assets/images/favicons/apple-touch-icon-57x57.png similarity index 100% rename from app/assets/images/favicons/apple-touch-icon-57x57.png rename to src/app/assets/images/favicons/apple-touch-icon-57x57.png diff --git a/app/assets/images/favicons/apple-touch-icon-60x60.png b/src/app/assets/images/favicons/apple-touch-icon-60x60.png similarity index 100% rename from app/assets/images/favicons/apple-touch-icon-60x60.png rename to src/app/assets/images/favicons/apple-touch-icon-60x60.png diff --git a/app/assets/images/favicons/apple-touch-icon-72x72.png b/src/app/assets/images/favicons/apple-touch-icon-72x72.png similarity index 100% rename from app/assets/images/favicons/apple-touch-icon-72x72.png rename to src/app/assets/images/favicons/apple-touch-icon-72x72.png diff --git a/app/assets/images/favicons/apple-touch-icon-76x76.png b/src/app/assets/images/favicons/apple-touch-icon-76x76.png similarity index 100% rename from app/assets/images/favicons/apple-touch-icon-76x76.png rename to src/app/assets/images/favicons/apple-touch-icon-76x76.png diff --git a/app/assets/images/favicons/browserconfig.xml b/src/app/assets/images/favicons/browserconfig.xml similarity index 100% rename from app/assets/images/favicons/browserconfig.xml rename to src/app/assets/images/favicons/browserconfig.xml diff --git a/app/assets/images/favicons/favicon-128.png b/src/app/assets/images/favicons/favicon-128.png similarity index 100% rename from app/assets/images/favicons/favicon-128.png rename to src/app/assets/images/favicons/favicon-128.png diff --git a/app/assets/images/favicons/favicon-16x16.png b/src/app/assets/images/favicons/favicon-16x16.png similarity index 100% rename from app/assets/images/favicons/favicon-16x16.png rename to src/app/assets/images/favicons/favicon-16x16.png diff --git a/app/assets/images/favicons/favicon-196x196.png b/src/app/assets/images/favicons/favicon-196x196.png similarity index 100% rename from app/assets/images/favicons/favicon-196x196.png rename to src/app/assets/images/favicons/favicon-196x196.png diff --git a/app/assets/images/favicons/favicon-32x32.png b/src/app/assets/images/favicons/favicon-32x32.png similarity index 100% rename from app/assets/images/favicons/favicon-32x32.png rename to src/app/assets/images/favicons/favicon-32x32.png diff --git a/app/assets/images/favicons/favicon-96x96.png b/src/app/assets/images/favicons/favicon-96x96.png similarity index 100% rename from app/assets/images/favicons/favicon-96x96.png rename to src/app/assets/images/favicons/favicon-96x96.png diff --git a/app/assets/images/favicons/favicon.ico b/src/app/assets/images/favicons/favicon.ico similarity index 100% rename from app/assets/images/favicons/favicon.ico rename to src/app/assets/images/favicons/favicon.ico diff --git a/app/assets/images/favicons/manifest.json b/src/app/assets/images/favicons/manifest.json similarity index 100% rename from app/assets/images/favicons/manifest.json rename to src/app/assets/images/favicons/manifest.json diff --git a/app/assets/images/favicons/mstile-144x144.png b/src/app/assets/images/favicons/mstile-144x144.png similarity index 100% rename from app/assets/images/favicons/mstile-144x144.png rename to src/app/assets/images/favicons/mstile-144x144.png diff --git a/app/assets/images/favicons/mstile-150x150.png b/src/app/assets/images/favicons/mstile-150x150.png similarity index 100% rename from app/assets/images/favicons/mstile-150x150.png rename to src/app/assets/images/favicons/mstile-150x150.png diff --git a/app/assets/images/favicons/mstile-310x150.png b/src/app/assets/images/favicons/mstile-310x150.png similarity index 100% rename from app/assets/images/favicons/mstile-310x150.png rename to src/app/assets/images/favicons/mstile-310x150.png diff --git a/app/assets/images/favicons/mstile-310x310.png b/src/app/assets/images/favicons/mstile-310x310.png similarity index 100% rename from app/assets/images/favicons/mstile-310x310.png rename to src/app/assets/images/favicons/mstile-310x310.png diff --git a/app/assets/images/favicons/mstile-70x70.png b/src/app/assets/images/favicons/mstile-70x70.png similarity index 100% rename from app/assets/images/favicons/mstile-70x70.png rename to src/app/assets/images/favicons/mstile-70x70.png diff --git a/app/assets/images/lp-bottom.jpg b/src/app/assets/images/lp-bottom.jpg similarity index 100% rename from app/assets/images/lp-bottom.jpg rename to src/app/assets/images/lp-bottom.jpg diff --git a/app/assets/images/qrcode.png b/src/app/assets/images/qrcode.png similarity index 100% rename from app/assets/images/qrcode.png rename to src/app/assets/images/qrcode.png diff --git a/app/assets/images/reddit.svg b/src/app/assets/images/reddit.svg similarity index 100% rename from app/assets/images/reddit.svg rename to src/app/assets/images/reddit.svg diff --git a/app/assets/images/steemit-1024x1024.png b/src/app/assets/images/steemit-1024x1024.png similarity index 100% rename from app/assets/images/steemit-1024x1024.png rename to src/app/assets/images/steemit-1024x1024.png diff --git a/app/assets/images/steemit-halloween.png b/src/app/assets/images/steemit-halloween.png similarity index 100% rename from app/assets/images/steemit-halloween.png rename to src/app/assets/images/steemit-halloween.png diff --git a/app/assets/images/steemit-share.png b/src/app/assets/images/steemit-share.png similarity index 100% rename from app/assets/images/steemit-share.png rename to src/app/assets/images/steemit-share.png diff --git a/app/assets/images/steemit-twshare.png b/src/app/assets/images/steemit-twshare.png similarity index 100% rename from app/assets/images/steemit-twshare.png rename to src/app/assets/images/steemit-twshare.png diff --git a/app/assets/images/steemit.svg b/src/app/assets/images/steemit.svg similarity index 100% rename from app/assets/images/steemit.svg rename to src/app/assets/images/steemit.svg diff --git a/app/assets/images/user.png b/src/app/assets/images/user.png similarity index 100% rename from app/assets/images/user.png rename to src/app/assets/images/user.png diff --git a/app/assets/images/welcome.jpg b/src/app/assets/images/welcome.jpg similarity index 100% rename from app/assets/images/welcome.jpg rename to src/app/assets/images/welcome.jpg diff --git a/app/assets/static/manifest.json b/src/app/assets/static/manifest.json similarity index 100% rename from app/assets/static/manifest.json rename to src/app/assets/static/manifest.json diff --git a/app/assets/static/search.html b/src/app/assets/static/search.html similarity index 100% rename from app/assets/static/search.html rename to src/app/assets/static/search.html diff --git a/app/assets/stylesheets/app.scss b/src/app/assets/stylesheets/app.scss similarity index 98% rename from app/assets/stylesheets/app.scss rename to src/app/assets/stylesheets/app.scss index 75c189d4e8..b5aeab710d 100644 --- a/app/assets/stylesheets/app.scss +++ b/src/app/assets/stylesheets/app.scss @@ -9,7 +9,7 @@ @import "./mixins"; @import "./markdown"; @import "./notifications"; -@import "app/components/all"; +@import "src/app/components/all"; /* Small only */ @media screen and (max-width: 39.9375em) { diff --git a/app/assets/stylesheets/fonts.scss b/src/app/assets/stylesheets/fonts.scss similarity index 100% rename from app/assets/stylesheets/fonts.scss rename to src/app/assets/stylesheets/fonts.scss diff --git a/app/assets/stylesheets/forms.scss b/src/app/assets/stylesheets/forms.scss similarity index 100% rename from app/assets/stylesheets/forms.scss rename to src/app/assets/stylesheets/forms.scss diff --git a/app/assets/stylesheets/foundation-overrides.scss b/src/app/assets/stylesheets/foundation-overrides.scss similarity index 100% rename from app/assets/stylesheets/foundation-overrides.scss rename to src/app/assets/stylesheets/foundation-overrides.scss diff --git a/app/assets/stylesheets/foundation-settings.scss b/src/app/assets/stylesheets/foundation-settings.scss similarity index 100% rename from app/assets/stylesheets/foundation-settings.scss rename to src/app/assets/stylesheets/foundation-settings.scss diff --git a/app/assets/stylesheets/markdown.scss b/src/app/assets/stylesheets/markdown.scss similarity index 100% rename from app/assets/stylesheets/markdown.scss rename to src/app/assets/stylesheets/markdown.scss diff --git a/app/assets/stylesheets/mixins.scss b/src/app/assets/stylesheets/mixins.scss similarity index 100% rename from app/assets/stylesheets/mixins.scss rename to src/app/assets/stylesheets/mixins.scss diff --git a/app/assets/stylesheets/notifications.scss b/src/app/assets/stylesheets/notifications.scss similarity index 100% rename from app/assets/stylesheets/notifications.scss rename to src/app/assets/stylesheets/notifications.scss diff --git a/app/client_config.js b/src/app/client_config.js similarity index 100% rename from app/client_config.js rename to src/app/client_config.js diff --git a/app/components/App.jsx b/src/app/components/App.jsx similarity index 99% rename from app/components/App.jsx rename to src/app/components/App.jsx index c403dea1df..6a9ff43fcb 100644 --- a/app/components/App.jsx +++ b/src/app/components/App.jsx @@ -266,7 +266,7 @@ class App extends React.Component {
  • - {tt('navigation.steemit_api_docs')}  + {tt('navigation.api_docs')} 
  • diff --git a/app/components/App.scss b/src/app/components/App.scss similarity index 100% rename from app/components/App.scss rename to src/app/components/App.scss diff --git a/app/components/all.scss b/src/app/components/all.scss similarity index 100% rename from app/components/all.scss rename to src/app/components/all.scss diff --git a/app/components/cards/CardView.js b/src/app/components/cards/CardView.js similarity index 100% rename from app/components/cards/CardView.js rename to src/app/components/cards/CardView.js diff --git a/app/components/cards/CategorySelector.jsx b/src/app/components/cards/CategorySelector.jsx similarity index 100% rename from app/components/cards/CategorySelector.jsx rename to src/app/components/cards/CategorySelector.jsx diff --git a/app/components/cards/Comment.jsx b/src/app/components/cards/Comment.jsx similarity index 100% rename from app/components/cards/Comment.jsx rename to src/app/components/cards/Comment.jsx diff --git a/app/components/cards/Comment.scss b/src/app/components/cards/Comment.scss similarity index 100% rename from app/components/cards/Comment.scss rename to src/app/components/cards/Comment.scss diff --git a/app/components/cards/MarkdownViewer.jsx b/src/app/components/cards/MarkdownViewer.jsx similarity index 100% rename from app/components/cards/MarkdownViewer.jsx rename to src/app/components/cards/MarkdownViewer.jsx diff --git a/app/components/cards/MarkdownViewer.scss b/src/app/components/cards/MarkdownViewer.scss similarity index 100% rename from app/components/cards/MarkdownViewer.scss rename to src/app/components/cards/MarkdownViewer.scss diff --git a/app/components/cards/PostFull.jsx b/src/app/components/cards/PostFull.jsx similarity index 100% rename from app/components/cards/PostFull.jsx rename to src/app/components/cards/PostFull.jsx diff --git a/app/components/cards/PostFull.scss b/src/app/components/cards/PostFull.scss similarity index 100% rename from app/components/cards/PostFull.scss rename to src/app/components/cards/PostFull.scss diff --git a/app/components/cards/PostHistoryRow.jsx b/src/app/components/cards/PostHistoryRow.jsx similarity index 100% rename from app/components/cards/PostHistoryRow.jsx rename to src/app/components/cards/PostHistoryRow.jsx diff --git a/app/components/cards/PostSummary.jsx b/src/app/components/cards/PostSummary.jsx similarity index 100% rename from app/components/cards/PostSummary.jsx rename to src/app/components/cards/PostSummary.jsx diff --git a/app/components/cards/PostSummary.scss b/src/app/components/cards/PostSummary.scss similarity index 100% rename from app/components/cards/PostSummary.scss rename to src/app/components/cards/PostSummary.scss diff --git a/app/components/cards/PostsList.jsx b/src/app/components/cards/PostsList.jsx similarity index 100% rename from app/components/cards/PostsList.jsx rename to src/app/components/cards/PostsList.jsx diff --git a/app/components/cards/PostsList.scss b/src/app/components/cards/PostsList.scss similarity index 100% rename from app/components/cards/PostsList.scss rename to src/app/components/cards/PostsList.scss diff --git a/app/components/cards/TransferHistoryRow.jsx b/src/app/components/cards/TransferHistoryRow.jsx similarity index 100% rename from app/components/cards/TransferHistoryRow.jsx rename to src/app/components/cards/TransferHistoryRow.jsx diff --git a/app/components/cards/UserListRow.jsx b/src/app/components/cards/UserListRow.jsx similarity index 100% rename from app/components/cards/UserListRow.jsx rename to src/app/components/cards/UserListRow.jsx diff --git a/app/components/cards/VoteHistoryRow.jsx b/src/app/components/cards/VoteHistoryRow.jsx similarity index 100% rename from app/components/cards/VoteHistoryRow.jsx rename to src/app/components/cards/VoteHistoryRow.jsx diff --git a/app/components/elements/Author.jsx b/src/app/components/elements/Author.jsx similarity index 100% rename from app/components/elements/Author.jsx rename to src/app/components/elements/Author.jsx diff --git a/app/components/elements/Author.scss b/src/app/components/elements/Author.scss similarity index 100% rename from app/components/elements/Author.scss rename to src/app/components/elements/Author.scss diff --git a/app/components/elements/Callout.jsx b/src/app/components/elements/Callout.jsx similarity index 100% rename from app/components/elements/Callout.jsx rename to src/app/components/elements/Callout.jsx diff --git a/app/components/elements/ChangePassword.jsx b/src/app/components/elements/ChangePassword.jsx similarity index 100% rename from app/components/elements/ChangePassword.jsx rename to src/app/components/elements/ChangePassword.jsx diff --git a/app/components/elements/ChangePassword.scss b/src/app/components/elements/ChangePassword.scss similarity index 100% rename from app/components/elements/ChangePassword.scss rename to src/app/components/elements/ChangePassword.scss diff --git a/app/components/elements/CheckLoginOwner.jsx b/src/app/components/elements/CheckLoginOwner.jsx similarity index 100% rename from app/components/elements/CheckLoginOwner.jsx rename to src/app/components/elements/CheckLoginOwner.jsx diff --git a/app/components/elements/ConvertToSteem.jsx b/src/app/components/elements/ConvertToSteem.jsx similarity index 100% rename from app/components/elements/ConvertToSteem.jsx rename to src/app/components/elements/ConvertToSteem.jsx diff --git a/app/components/elements/CountryCode.jsx b/src/app/components/elements/CountryCode.jsx similarity index 100% rename from app/components/elements/CountryCode.jsx rename to src/app/components/elements/CountryCode.jsx diff --git a/app/components/elements/DateJoinWrapper.jsx b/src/app/components/elements/DateJoinWrapper.jsx similarity index 100% rename from app/components/elements/DateJoinWrapper.jsx rename to src/app/components/elements/DateJoinWrapper.jsx diff --git a/app/components/elements/DepthChart.jsx b/src/app/components/elements/DepthChart.jsx similarity index 100% rename from app/components/elements/DepthChart.jsx rename to src/app/components/elements/DepthChart.jsx diff --git a/app/components/elements/DropdownMenu.jsx b/src/app/components/elements/DropdownMenu.jsx similarity index 98% rename from app/components/elements/DropdownMenu.jsx rename to src/app/components/elements/DropdownMenu.jsx index fbe5177b6d..9ed5f921e9 100644 --- a/app/components/elements/DropdownMenu.jsx +++ b/src/app/components/elements/DropdownMenu.jsx @@ -1,6 +1,6 @@ import React from 'react'; import { browserHistory } from 'react-router'; -import Icon from 'app/components/elements/Icon.jsx'; +import Icon from 'app/components/elements/Icon'; import VerticalMenu from './VerticalMenu'; import {findParent} from 'app/utils/DomUtils'; diff --git a/app/components/elements/DropdownMenu.scss b/src/app/components/elements/DropdownMenu.scss similarity index 100% rename from app/components/elements/DropdownMenu.scss rename to src/app/components/elements/DropdownMenu.scss diff --git a/app/components/elements/ExperimentWrapper.jsx b/src/app/components/elements/ExperimentWrapper.jsx similarity index 100% rename from app/components/elements/ExperimentWrapper.jsx rename to src/app/components/elements/ExperimentWrapper.jsx diff --git a/app/components/elements/Follow.jsx b/src/app/components/elements/Follow.jsx similarity index 100% rename from app/components/elements/Follow.jsx rename to src/app/components/elements/Follow.jsx diff --git a/app/components/elements/FormattedAsset.jsx b/src/app/components/elements/FormattedAsset.jsx similarity index 100% rename from app/components/elements/FormattedAsset.jsx rename to src/app/components/elements/FormattedAsset.jsx diff --git a/app/components/elements/FormattedAsset.scss b/src/app/components/elements/FormattedAsset.scss similarity index 100% rename from app/components/elements/FormattedAsset.scss rename to src/app/components/elements/FormattedAsset.scss diff --git a/app/components/elements/FoundationDropdown.jsx b/src/app/components/elements/FoundationDropdown.jsx similarity index 100% rename from app/components/elements/FoundationDropdown.jsx rename to src/app/components/elements/FoundationDropdown.jsx diff --git a/app/components/elements/FoundationDropdownMenu.jsx b/src/app/components/elements/FoundationDropdownMenu.jsx similarity index 100% rename from app/components/elements/FoundationDropdownMenu.jsx rename to src/app/components/elements/FoundationDropdownMenu.jsx diff --git a/app/components/elements/FoundationDropdownMenu.scss b/src/app/components/elements/FoundationDropdownMenu.scss similarity index 100% rename from app/components/elements/FoundationDropdownMenu.scss rename to src/app/components/elements/FoundationDropdownMenu.scss diff --git a/app/components/elements/GeneratedPasswordInput.jsx b/src/app/components/elements/GeneratedPasswordInput.jsx similarity index 100% rename from app/components/elements/GeneratedPasswordInput.jsx rename to src/app/components/elements/GeneratedPasswordInput.jsx diff --git a/app/components/elements/GeneratedPasswordInput.scss b/src/app/components/elements/GeneratedPasswordInput.scss similarity index 100% rename from app/components/elements/GeneratedPasswordInput.scss rename to src/app/components/elements/GeneratedPasswordInput.scss diff --git a/app/components/elements/HelpContent.jsx b/src/app/components/elements/HelpContent.jsx similarity index 100% rename from app/components/elements/HelpContent.jsx rename to src/app/components/elements/HelpContent.jsx diff --git a/app/components/elements/HorizontalMenu.jsx b/src/app/components/elements/HorizontalMenu.jsx similarity index 95% rename from app/components/elements/HorizontalMenu.jsx rename to src/app/components/elements/HorizontalMenu.jsx index 9fdaaab001..52979cb3a5 100644 --- a/app/components/elements/HorizontalMenu.jsx +++ b/src/app/components/elements/HorizontalMenu.jsx @@ -1,6 +1,6 @@ import React from 'react'; import { Link } from 'react-router' -import Icon from 'app/components/elements/Icon.jsx'; +import Icon from 'app/components/elements/Icon'; export default class HorizontalMenu extends React.Component { static propTypes = { diff --git a/app/components/elements/HorizontalMenu.scss b/src/app/components/elements/HorizontalMenu.scss similarity index 100% rename from app/components/elements/HorizontalMenu.scss rename to src/app/components/elements/HorizontalMenu.scss diff --git a/app/components/elements/Icon.jsx b/src/app/components/elements/Icon.jsx similarity index 95% rename from app/components/elements/Icon.jsx rename to src/app/components/elements/Icon.jsx index 242e5e4e0c..77076d978c 100644 --- a/app/components/elements/Icon.jsx +++ b/src/app/components/elements/Icon.jsx @@ -48,7 +48,7 @@ const icons = [ 'pencil2' ]; const icons_map = {}; -for (const i of icons) icons_map[i] = require(`app/assets/icons/${i}.svg`); +for (const i of icons) icons_map[i] = require(`assets/icons/${i}.svg`); const rem_sizes = {'1x': '1.12', '1_5x': '1.5', '2x': '2', '3x': '3.45', '4x': '4.60', '5x': '5.75', '10x': '10.0'}; diff --git a/app/components/elements/Icon.scss b/src/app/components/elements/Icon.scss similarity index 100% rename from app/components/elements/Icon.scss rename to src/app/components/elements/Icon.scss diff --git a/app/components/elements/KeyEdit.js b/src/app/components/elements/KeyEdit.js similarity index 100% rename from app/components/elements/KeyEdit.js rename to src/app/components/elements/KeyEdit.js diff --git a/app/components/elements/Keys.jsx b/src/app/components/elements/Keys.jsx similarity index 100% rename from app/components/elements/Keys.jsx rename to src/app/components/elements/Keys.jsx diff --git a/app/components/elements/Link.js b/src/app/components/elements/Link.js similarity index 100% rename from app/components/elements/Link.js rename to src/app/components/elements/Link.js diff --git a/app/components/elements/LoadingIndicator.jsx b/src/app/components/elements/LoadingIndicator.jsx similarity index 100% rename from app/components/elements/LoadingIndicator.jsx rename to src/app/components/elements/LoadingIndicator.jsx diff --git a/app/components/elements/LoadingIndicator.scss b/src/app/components/elements/LoadingIndicator.scss similarity index 100% rename from app/components/elements/LoadingIndicator.scss rename to src/app/components/elements/LoadingIndicator.scss diff --git a/app/components/elements/LocalizedCurrency.jsx b/src/app/components/elements/LocalizedCurrency.jsx similarity index 100% rename from app/components/elements/LocalizedCurrency.jsx rename to src/app/components/elements/LocalizedCurrency.jsx diff --git a/app/components/elements/MarkNotificationRead.jsx b/src/app/components/elements/MarkNotificationRead.jsx similarity index 100% rename from app/components/elements/MarkNotificationRead.jsx rename to src/app/components/elements/MarkNotificationRead.jsx diff --git a/app/components/elements/Memo.js b/src/app/components/elements/Memo.js similarity index 100% rename from app/components/elements/Memo.js rename to src/app/components/elements/Memo.js diff --git a/app/components/elements/NotifiCounter.jsx b/src/app/components/elements/NotifiCounter.jsx similarity index 100% rename from app/components/elements/NotifiCounter.jsx rename to src/app/components/elements/NotifiCounter.jsx diff --git a/app/components/elements/NotifiCounter.scss b/src/app/components/elements/NotifiCounter.scss similarity index 100% rename from app/components/elements/NotifiCounter.scss rename to src/app/components/elements/NotifiCounter.scss diff --git a/app/components/elements/OrderHistory.jsx b/src/app/components/elements/OrderHistory.jsx similarity index 98% rename from app/components/elements/OrderHistory.jsx rename to src/app/components/elements/OrderHistory.jsx index 015b66c0ba..317d49ea18 100644 --- a/app/components/elements/OrderHistory.jsx +++ b/src/app/components/elements/OrderHistory.jsx @@ -1,5 +1,5 @@ import React from "react"; -import HistoryRow from "./OrderhistoryRow.jsx"; +import HistoryRow from "./OrderhistoryRow"; import tt from 'counterpart'; import { DEBT_TOKEN_SHORT, LIQUID_TOKEN, CURRENCY_SIGN } from 'app/client_config'; diff --git a/app/components/elements/Orderbook.jsx b/src/app/components/elements/Orderbook.jsx similarity index 100% rename from app/components/elements/Orderbook.jsx rename to src/app/components/elements/Orderbook.jsx diff --git a/app/components/elements/OrderbookRow.jsx b/src/app/components/elements/OrderbookRow.jsx similarity index 100% rename from app/components/elements/OrderbookRow.jsx rename to src/app/components/elements/OrderbookRow.jsx diff --git a/app/components/elements/OrderhistoryRow.jsx b/src/app/components/elements/OrderhistoryRow.jsx similarity index 100% rename from app/components/elements/OrderhistoryRow.jsx rename to src/app/components/elements/OrderhistoryRow.jsx diff --git a/app/components/elements/PageViewsCounter.jsx b/src/app/components/elements/PageViewsCounter.jsx similarity index 100% rename from app/components/elements/PageViewsCounter.jsx rename to src/app/components/elements/PageViewsCounter.jsx diff --git a/app/components/elements/PasswordInput.jsx b/src/app/components/elements/PasswordInput.jsx similarity index 100% rename from app/components/elements/PasswordInput.jsx rename to src/app/components/elements/PasswordInput.jsx diff --git a/app/components/elements/PasswordReset.jsx b/src/app/components/elements/PasswordReset.jsx similarity index 100% rename from app/components/elements/PasswordReset.jsx rename to src/app/components/elements/PasswordReset.jsx diff --git a/app/components/elements/QrKeyView.jsx b/src/app/components/elements/QrKeyView.jsx similarity index 100% rename from app/components/elements/QrKeyView.jsx rename to src/app/components/elements/QrKeyView.jsx diff --git a/app/components/elements/QrKeyView.scss b/src/app/components/elements/QrKeyView.scss similarity index 100% rename from app/components/elements/QrKeyView.scss rename to src/app/components/elements/QrKeyView.scss diff --git a/app/components/elements/QrReader.jsx b/src/app/components/elements/QrReader.jsx similarity index 100% rename from app/components/elements/QrReader.jsx rename to src/app/components/elements/QrReader.jsx diff --git a/app/components/elements/Reblog.jsx b/src/app/components/elements/Reblog.jsx similarity index 100% rename from app/components/elements/Reblog.jsx rename to src/app/components/elements/Reblog.jsx diff --git a/app/components/elements/Reblog.scss b/src/app/components/elements/Reblog.scss similarity index 100% rename from app/components/elements/Reblog.scss rename to src/app/components/elements/Reblog.scss diff --git a/app/components/elements/ReplyEditor.jsx b/src/app/components/elements/ReplyEditor.jsx similarity index 100% rename from app/components/elements/ReplyEditor.jsx rename to src/app/components/elements/ReplyEditor.jsx diff --git a/app/components/elements/ReplyEditor.scss b/src/app/components/elements/ReplyEditor.scss similarity index 100% rename from app/components/elements/ReplyEditor.scss rename to src/app/components/elements/ReplyEditor.scss diff --git a/app/components/elements/Reputation.jsx b/src/app/components/elements/Reputation.jsx similarity index 100% rename from app/components/elements/Reputation.jsx rename to src/app/components/elements/Reputation.jsx diff --git a/app/components/elements/Reputation.scss b/src/app/components/elements/Reputation.scss similarity index 100% rename from app/components/elements/Reputation.scss rename to src/app/components/elements/Reputation.scss diff --git a/app/components/elements/SaveLogin.jsx b/src/app/components/elements/SaveLogin.jsx similarity index 100% rename from app/components/elements/SaveLogin.jsx rename to src/app/components/elements/SaveLogin.jsx diff --git a/app/components/elements/SavingsWithdrawHistory.jsx b/src/app/components/elements/SavingsWithdrawHistory.jsx similarity index 100% rename from app/components/elements/SavingsWithdrawHistory.jsx rename to src/app/components/elements/SavingsWithdrawHistory.jsx diff --git a/app/components/elements/ShareMenu.jsx b/src/app/components/elements/ShareMenu.jsx similarity index 95% rename from app/components/elements/ShareMenu.jsx rename to src/app/components/elements/ShareMenu.jsx index 5f879c0564..ad9f1d20e1 100644 --- a/app/components/elements/ShareMenu.jsx +++ b/src/app/components/elements/ShareMenu.jsx @@ -1,6 +1,6 @@ import React from 'react' import { Link } from 'react-router' -import Icon from 'app/components/elements/Icon.jsx'; +import Icon from 'app/components/elements/Icon'; export default class ShareMenu extends React.Component { diff --git a/app/components/elements/ShareMenu.scss b/src/app/components/elements/ShareMenu.scss similarity index 100% rename from app/components/elements/ShareMenu.scss rename to src/app/components/elements/ShareMenu.scss diff --git a/app/components/elements/ShowKey.js b/src/app/components/elements/ShowKey.js similarity index 100% rename from app/components/elements/ShowKey.js rename to src/app/components/elements/ShowKey.js diff --git a/app/components/elements/SignupProgressBar.jsx b/src/app/components/elements/SignupProgressBar.jsx similarity index 100% rename from app/components/elements/SignupProgressBar.jsx rename to src/app/components/elements/SignupProgressBar.jsx diff --git a/app/components/elements/SignupProgressBar.scss b/src/app/components/elements/SignupProgressBar.scss similarity index 100% rename from app/components/elements/SignupProgressBar.scss rename to src/app/components/elements/SignupProgressBar.scss diff --git a/app/components/elements/SlateEditor.jsx b/src/app/components/elements/SlateEditor.jsx similarity index 100% rename from app/components/elements/SlateEditor.jsx rename to src/app/components/elements/SlateEditor.jsx diff --git a/app/components/elements/SlateEditor.scss b/src/app/components/elements/SlateEditor.scss similarity index 100% rename from app/components/elements/SlateEditor.scss rename to src/app/components/elements/SlateEditor.scss diff --git a/app/components/elements/SuggestPassword.jsx b/src/app/components/elements/SuggestPassword.jsx similarity index 100% rename from app/components/elements/SuggestPassword.jsx rename to src/app/components/elements/SuggestPassword.jsx diff --git a/app/components/elements/SvgImage.jsx b/src/app/components/elements/SvgImage.jsx similarity index 89% rename from app/components/elements/SvgImage.jsx rename to src/app/components/elements/SvgImage.jsx index cb944f2873..cdb4d68737 100644 --- a/app/components/elements/SvgImage.jsx +++ b/src/app/components/elements/SvgImage.jsx @@ -9,7 +9,7 @@ export default class SvgImage extends React.Component { }; render() { const style = {display: 'inline-block', width: this.props.width, height: this.props.height}; - const image = require(`app/assets/images/${this.props.name}.svg`); + const image = require(`assets/images/${this.props.name}.svg`); const cn = 'SvgImage' + (this.props.className ? ' ' + this.props.className : ''); return ; } diff --git a/app/components/elements/TagList.jsx b/src/app/components/elements/TagList.jsx similarity index 100% rename from app/components/elements/TagList.jsx rename to src/app/components/elements/TagList.jsx diff --git a/app/components/elements/TagList.scss b/src/app/components/elements/TagList.scss similarity index 100% rename from app/components/elements/TagList.scss rename to src/app/components/elements/TagList.scss diff --git a/app/components/elements/Template.jsx b/src/app/components/elements/Template.jsx similarity index 100% rename from app/components/elements/Template.jsx rename to src/app/components/elements/Template.jsx diff --git a/app/components/elements/TimeAgoWrapper.js b/src/app/components/elements/TimeAgoWrapper.js similarity index 100% rename from app/components/elements/TimeAgoWrapper.js rename to src/app/components/elements/TimeAgoWrapper.js diff --git a/app/components/elements/Tooltip.jsx b/src/app/components/elements/Tooltip.jsx similarity index 100% rename from app/components/elements/Tooltip.jsx rename to src/app/components/elements/Tooltip.jsx diff --git a/app/components/elements/TransactionError.jsx b/src/app/components/elements/TransactionError.jsx similarity index 100% rename from app/components/elements/TransactionError.jsx rename to src/app/components/elements/TransactionError.jsx diff --git a/app/components/elements/UserKeys.jsx b/src/app/components/elements/UserKeys.jsx similarity index 100% rename from app/components/elements/UserKeys.jsx rename to src/app/components/elements/UserKeys.jsx diff --git a/app/components/elements/UserList.jsx b/src/app/components/elements/UserList.jsx similarity index 100% rename from app/components/elements/UserList.jsx rename to src/app/components/elements/UserList.jsx diff --git a/app/components/elements/UserNames.jsx b/src/app/components/elements/UserNames.jsx similarity index 100% rename from app/components/elements/UserNames.jsx rename to src/app/components/elements/UserNames.jsx diff --git a/app/components/elements/UserNames.scss b/src/app/components/elements/UserNames.scss similarity index 100% rename from app/components/elements/UserNames.scss rename to src/app/components/elements/UserNames.scss diff --git a/app/components/elements/Userpic.jsx b/src/app/components/elements/Userpic.jsx similarity index 96% rename from app/components/elements/Userpic.jsx rename to src/app/components/elements/Userpic.jsx index 9aba7d7036..964826f6ce 100644 --- a/app/components/elements/Userpic.jsx +++ b/src/app/components/elements/Userpic.jsx @@ -30,7 +30,7 @@ class Userpic extends Component { if(hideIfDefault) { return null; } - url = require('app/assets/images/user.png'); + url = require('assets/images/user.png'); } const style = {backgroundImage: 'url(' + url + ')', diff --git a/app/components/elements/Userpic.scss b/src/app/components/elements/Userpic.scss similarity index 100% rename from app/components/elements/Userpic.scss rename to src/app/components/elements/Userpic.scss diff --git a/app/components/elements/VerticalMenu.jsx b/src/app/components/elements/VerticalMenu.jsx similarity index 96% rename from app/components/elements/VerticalMenu.jsx rename to src/app/components/elements/VerticalMenu.jsx index 9133a4ce18..7416800dd2 100644 --- a/app/components/elements/VerticalMenu.jsx +++ b/src/app/components/elements/VerticalMenu.jsx @@ -1,6 +1,6 @@ import React from 'react'; import { Link } from 'react-router' -import Icon from 'app/components/elements/Icon.jsx'; +import Icon from 'app/components/elements/Icon'; export default class VerticalMenu extends React.Component { static propTypes = { diff --git a/app/components/elements/VerticalMenu.scss b/src/app/components/elements/VerticalMenu.scss similarity index 100% rename from app/components/elements/VerticalMenu.scss rename to src/app/components/elements/VerticalMenu.scss diff --git a/app/components/elements/VotesAndComments.jsx b/src/app/components/elements/VotesAndComments.jsx similarity index 100% rename from app/components/elements/VotesAndComments.jsx rename to src/app/components/elements/VotesAndComments.jsx diff --git a/app/components/elements/VotesAndComments.scss b/src/app/components/elements/VotesAndComments.scss similarity index 100% rename from app/components/elements/VotesAndComments.scss rename to src/app/components/elements/VotesAndComments.scss diff --git a/app/components/elements/Voting.jsx b/src/app/components/elements/Voting.jsx similarity index 100% rename from app/components/elements/Voting.jsx rename to src/app/components/elements/Voting.jsx diff --git a/app/components/elements/Voting.scss b/src/app/components/elements/Voting.scss similarity index 100% rename from app/components/elements/Voting.scss rename to src/app/components/elements/Voting.scss diff --git a/app/components/elements/WalletSubMenu.jsx b/src/app/components/elements/WalletSubMenu.jsx similarity index 100% rename from app/components/elements/WalletSubMenu.jsx rename to src/app/components/elements/WalletSubMenu.jsx diff --git a/app/components/elements/YoutubePreview.jsx b/src/app/components/elements/YoutubePreview.jsx similarity index 100% rename from app/components/elements/YoutubePreview.jsx rename to src/app/components/elements/YoutubePreview.jsx diff --git a/app/components/elements/YoutubePreview.scss b/src/app/components/elements/YoutubePreview.scss similarity index 100% rename from app/components/elements/YoutubePreview.scss rename to src/app/components/elements/YoutubePreview.scss diff --git a/app/components/modules/AddToWaitingList.jsx b/src/app/components/modules/AddToWaitingList.jsx similarity index 100% rename from app/components/modules/AddToWaitingList.jsx rename to src/app/components/modules/AddToWaitingList.jsx diff --git a/app/components/modules/AuthorRewards.jsx b/src/app/components/modules/AuthorRewards.jsx similarity index 100% rename from app/components/modules/AuthorRewards.jsx rename to src/app/components/modules/AuthorRewards.jsx diff --git a/app/components/modules/BlocktradesDeposit.jsx b/src/app/components/modules/BlocktradesDeposit.jsx similarity index 100% rename from app/components/modules/BlocktradesDeposit.jsx rename to src/app/components/modules/BlocktradesDeposit.jsx diff --git a/app/components/modules/BlocktradesDeposit.scss b/src/app/components/modules/BlocktradesDeposit.scss similarity index 100% rename from app/components/modules/BlocktradesDeposit.scss rename to src/app/components/modules/BlocktradesDeposit.scss diff --git a/app/components/modules/BottomPanel.jsx b/src/app/components/modules/BottomPanel.jsx similarity index 100% rename from app/components/modules/BottomPanel.jsx rename to src/app/components/modules/BottomPanel.jsx diff --git a/app/components/modules/BottomPanel.scss b/src/app/components/modules/BottomPanel.scss similarity index 100% rename from app/components/modules/BottomPanel.scss rename to src/app/components/modules/BottomPanel.scss diff --git a/app/components/modules/ConfirmTransactionForm.jsx b/src/app/components/modules/ConfirmTransactionForm.jsx similarity index 100% rename from app/components/modules/ConfirmTransactionForm.jsx rename to src/app/components/modules/ConfirmTransactionForm.jsx diff --git a/app/components/modules/CurationRewards.jsx b/src/app/components/modules/CurationRewards.jsx similarity index 100% rename from app/components/modules/CurationRewards.jsx rename to src/app/components/modules/CurationRewards.jsx diff --git a/app/components/modules/Dialogs.jsx b/src/app/components/modules/Dialogs.jsx similarity index 100% rename from app/components/modules/Dialogs.jsx rename to src/app/components/modules/Dialogs.jsx diff --git a/app/components/modules/ExplorePost.jsx b/src/app/components/modules/ExplorePost.jsx similarity index 100% rename from app/components/modules/ExplorePost.jsx rename to src/app/components/modules/ExplorePost.jsx diff --git a/app/components/modules/Footer.jsx b/src/app/components/modules/Footer.jsx similarity index 100% rename from app/components/modules/Footer.jsx rename to src/app/components/modules/Footer.jsx diff --git a/app/components/modules/Footer.scss b/src/app/components/modules/Footer.scss similarity index 100% rename from app/components/modules/Footer.scss rename to src/app/components/modules/Footer.scss diff --git a/app/components/modules/Header.jsx b/src/app/components/modules/Header.jsx similarity index 99% rename from app/components/modules/Header.jsx rename to src/app/components/modules/Header.jsx index b87fe6e725..2d9e056850 100644 --- a/app/components/modules/Header.jsx +++ b/src/app/components/modules/Header.jsx @@ -2,7 +2,7 @@ import React from 'react'; import { Link } from 'react-router'; import {connect} from 'react-redux'; import TopRightMenu from 'app/components/modules/TopRightMenu'; -import Icon from 'app/components/elements/Icon.jsx'; +import Icon from 'app/components/elements/Icon'; import resolveRoute from 'app/ResolveRoute'; import DropdownMenu from 'app/components/elements/DropdownMenu'; import shouldComponentUpdate from 'app/utils/shouldComponentUpdate'; diff --git a/app/components/modules/Header.scss b/src/app/components/modules/Header.scss similarity index 100% rename from app/components/modules/Header.scss rename to src/app/components/modules/Header.scss diff --git a/app/components/modules/Header.test.js b/src/app/components/modules/Header.test.js similarity index 88% rename from app/components/modules/Header.test.js rename to src/app/components/modules/Header.test.js index 6380bf2668..c8ff7f5f91 100644 --- a/app/components/modules/Header.test.js +++ b/src/app/components/modules/Header.test.js @@ -2,7 +2,7 @@ import React from 'react'; import { expect } from 'chai'; import { shallow } from 'enzyme'; -import {_Header_} from './Header.jsx'; +import {_Header_} from './Header'; describe('Header', () => { it('contains class .header', () => { diff --git a/app/components/modules/LoginForm.jsx b/src/app/components/modules/LoginForm.jsx similarity index 100% rename from app/components/modules/LoginForm.jsx rename to src/app/components/modules/LoginForm.jsx diff --git a/app/components/modules/LoginForm.scss b/src/app/components/modules/LoginForm.scss similarity index 100% rename from app/components/modules/LoginForm.scss rename to src/app/components/modules/LoginForm.scss diff --git a/app/components/modules/MiniHeader.jsx b/src/app/components/modules/MiniHeader.jsx similarity index 93% rename from app/components/modules/MiniHeader.jsx rename to src/app/components/modules/MiniHeader.jsx index b7b159d3c3..3def66bab8 100644 --- a/app/components/modules/MiniHeader.jsx +++ b/src/app/components/modules/MiniHeader.jsx @@ -1,5 +1,5 @@ import React from 'react'; -import Icon from 'app/components/elements/Icon.jsx'; +import Icon from 'app/components/elements/Icon'; import { APP_NAME } from 'app/client_config'; export default function MiniHeader() { diff --git a/app/components/modules/Modals.jsx b/src/app/components/modules/Modals.jsx similarity index 100% rename from app/components/modules/Modals.jsx rename to src/app/components/modules/Modals.jsx diff --git a/app/components/modules/PromotePost.jsx b/src/app/components/modules/PromotePost.jsx similarity index 100% rename from app/components/modules/PromotePost.jsx rename to src/app/components/modules/PromotePost.jsx diff --git a/app/components/modules/Settings.jsx b/src/app/components/modules/Settings.jsx similarity index 100% rename from app/components/modules/Settings.jsx rename to src/app/components/modules/Settings.jsx diff --git a/app/components/modules/SidePanel.jsx b/src/app/components/modules/SidePanel.jsx similarity index 100% rename from app/components/modules/SidePanel.jsx rename to src/app/components/modules/SidePanel.jsx diff --git a/app/components/modules/SidePanel.scss b/src/app/components/modules/SidePanel.scss similarity index 100% rename from app/components/modules/SidePanel.scss rename to src/app/components/modules/SidePanel.scss diff --git a/app/components/modules/SignUp.jsx b/src/app/components/modules/SignUp.jsx similarity index 100% rename from app/components/modules/SignUp.jsx rename to src/app/components/modules/SignUp.jsx diff --git a/app/components/modules/SignUp.scss b/src/app/components/modules/SignUp.scss similarity index 100% rename from app/components/modules/SignUp.scss rename to src/app/components/modules/SignUp.scss diff --git a/app/components/modules/TermsAgree.jsx b/src/app/components/modules/TermsAgree.jsx similarity index 100% rename from app/components/modules/TermsAgree.jsx rename to src/app/components/modules/TermsAgree.jsx diff --git a/app/components/modules/TopRightMenu.jsx b/src/app/components/modules/TopRightMenu.jsx similarity index 100% rename from app/components/modules/TopRightMenu.jsx rename to src/app/components/modules/TopRightMenu.jsx diff --git a/app/components/modules/TopRightMenu.scss b/src/app/components/modules/TopRightMenu.scss similarity index 100% rename from app/components/modules/TopRightMenu.scss rename to src/app/components/modules/TopRightMenu.scss diff --git a/app/components/modules/Transfer.jsx b/src/app/components/modules/Transfer.jsx similarity index 99% rename from app/components/modules/Transfer.jsx rename to src/app/components/modules/Transfer.jsx index d56b03f8f5..dc112d0972 100644 --- a/app/components/modules/Transfer.jsx +++ b/src/app/components/modules/Transfer.jsx @@ -72,7 +72,7 @@ class TransferForm extends Component { initialValues: props.initialValues, validation: values => ({ to: - ! values.to ? tt('g.required') : validate_account_name(values.to), + ! values.to ? tt('g.required') : validate_account_name(values.to, values.memo), amount: ! values.amount ? 'Required' : ! /^\d+(\.\d+)?$/.test(values.amount) ? tt('transfer_jsx.amount_is_in_form') : diff --git a/app/components/modules/UserWallet.jsx b/src/app/components/modules/UserWallet.jsx similarity index 100% rename from app/components/modules/UserWallet.jsx rename to src/app/components/modules/UserWallet.jsx diff --git a/app/components/modules/UserWallet.scss b/src/app/components/modules/UserWallet.scss similarity index 100% rename from app/components/modules/UserWallet.scss rename to src/app/components/modules/UserWallet.scss diff --git a/app/components/modules/lp/LpFooter.jsx b/src/app/components/modules/lp/LpFooter.jsx similarity index 100% rename from app/components/modules/lp/LpFooter.jsx rename to src/app/components/modules/lp/LpFooter.jsx diff --git a/app/components/modules/lp/LpFooter.scss b/src/app/components/modules/lp/LpFooter.scss similarity index 100% rename from app/components/modules/lp/LpFooter.scss rename to src/app/components/modules/lp/LpFooter.scss diff --git a/app/components/modules/lp/LpHeader.jsx b/src/app/components/modules/lp/LpHeader.jsx similarity index 100% rename from app/components/modules/lp/LpHeader.jsx rename to src/app/components/modules/lp/LpHeader.jsx diff --git a/app/components/modules/lp/LpHeader.scss b/src/app/components/modules/lp/LpHeader.scss similarity index 100% rename from app/components/modules/lp/LpHeader.scss rename to src/app/components/modules/lp/LpHeader.scss diff --git a/app/components/pages/About.jsx b/src/app/components/pages/About.jsx similarity index 100% rename from app/components/pages/About.jsx rename to src/app/components/pages/About.jsx diff --git a/app/components/pages/Approval.jsx b/src/app/components/pages/Approval.jsx similarity index 100% rename from app/components/pages/Approval.jsx rename to src/app/components/pages/Approval.jsx diff --git a/app/components/pages/ChangePasswordPage.jsx b/src/app/components/pages/ChangePasswordPage.jsx similarity index 100% rename from app/components/pages/ChangePasswordPage.jsx rename to src/app/components/pages/ChangePasswordPage.jsx diff --git a/app/components/pages/CreateAccount.jsx b/src/app/components/pages/CreateAccount.jsx similarity index 100% rename from app/components/pages/CreateAccount.jsx rename to src/app/components/pages/CreateAccount.jsx diff --git a/app/components/pages/CreateAccount.scss b/src/app/components/pages/CreateAccount.scss similarity index 100% rename from app/components/pages/CreateAccount.scss rename to src/app/components/pages/CreateAccount.scss diff --git a/app/components/pages/Faq.jsx b/src/app/components/pages/Faq.jsx similarity index 100% rename from app/components/pages/Faq.jsx rename to src/app/components/pages/Faq.jsx diff --git a/app/components/pages/Index.jsx b/src/app/components/pages/Index.jsx similarity index 100% rename from app/components/pages/Index.jsx rename to src/app/components/pages/Index.jsx diff --git a/app/components/pages/Login.jsx b/src/app/components/pages/Login.jsx similarity index 100% rename from app/components/pages/Login.jsx rename to src/app/components/pages/Login.jsx diff --git a/app/components/pages/Market.jsx b/src/app/components/pages/Market.jsx similarity index 100% rename from app/components/pages/Market.jsx rename to src/app/components/pages/Market.jsx diff --git a/app/components/pages/Market.scss b/src/app/components/pages/Market.scss similarity index 100% rename from app/components/pages/Market.scss rename to src/app/components/pages/Market.scss diff --git a/app/components/pages/NotFound.jsx b/src/app/components/pages/NotFound.jsx similarity index 97% rename from app/components/pages/NotFound.jsx rename to src/app/components/pages/NotFound.jsx index cacaa482c8..38eb645d7b 100644 --- a/app/components/pages/NotFound.jsx +++ b/src/app/components/pages/NotFound.jsx @@ -1,7 +1,7 @@ import React from 'react'; import SvgImage from 'app/components/elements/SvgImage'; import { Link } from 'react-router'; -import Icon from 'app/components/elements/Icon.jsx'; +import Icon from 'app/components/elements/Icon'; class NotFound extends React.Component { diff --git a/app/components/pages/PickAccount.jsx b/src/app/components/pages/PickAccount.jsx similarity index 100% rename from app/components/pages/PickAccount.jsx rename to src/app/components/pages/PickAccount.jsx diff --git a/app/components/pages/Post.jsx b/src/app/components/pages/Post.jsx similarity index 100% rename from app/components/pages/Post.jsx rename to src/app/components/pages/Post.jsx diff --git a/app/components/pages/Post.scss b/src/app/components/pages/Post.scss similarity index 100% rename from app/components/pages/Post.scss rename to src/app/components/pages/Post.scss diff --git a/app/components/pages/PostPage.jsx b/src/app/components/pages/PostPage.jsx similarity index 100% rename from app/components/pages/PostPage.jsx rename to src/app/components/pages/PostPage.jsx diff --git a/app/components/pages/PostPageNoCategory.jsx b/src/app/components/pages/PostPageNoCategory.jsx similarity index 100% rename from app/components/pages/PostPageNoCategory.jsx rename to src/app/components/pages/PostPageNoCategory.jsx diff --git a/app/components/pages/PostsIndex.jsx b/src/app/components/pages/PostsIndex.jsx similarity index 100% rename from app/components/pages/PostsIndex.jsx rename to src/app/components/pages/PostsIndex.jsx diff --git a/app/components/pages/PostsIndex.scss b/src/app/components/pages/PostsIndex.scss similarity index 100% rename from app/components/pages/PostsIndex.scss rename to src/app/components/pages/PostsIndex.scss diff --git a/app/components/pages/Privacy.jsx b/src/app/components/pages/Privacy.jsx similarity index 100% rename from app/components/pages/Privacy.jsx rename to src/app/components/pages/Privacy.jsx diff --git a/app/components/pages/Privacy.scss b/src/app/components/pages/Privacy.scss similarity index 100% rename from app/components/pages/Privacy.scss rename to src/app/components/pages/Privacy.scss diff --git a/app/components/pages/RecoverAccountStep1.jsx b/src/app/components/pages/RecoverAccountStep1.jsx similarity index 100% rename from app/components/pages/RecoverAccountStep1.jsx rename to src/app/components/pages/RecoverAccountStep1.jsx diff --git a/app/components/pages/RecoverAccountStep2.jsx b/src/app/components/pages/RecoverAccountStep2.jsx similarity index 100% rename from app/components/pages/RecoverAccountStep2.jsx rename to src/app/components/pages/RecoverAccountStep2.jsx diff --git a/app/components/pages/SubmitPost.jsx b/src/app/components/pages/SubmitPost.jsx similarity index 100% rename from app/components/pages/SubmitPost.jsx rename to src/app/components/pages/SubmitPost.jsx diff --git a/app/components/pages/SubmitPostServerRender.jsx b/src/app/components/pages/SubmitPostServerRender.jsx similarity index 100% rename from app/components/pages/SubmitPostServerRender.jsx rename to src/app/components/pages/SubmitPostServerRender.jsx diff --git a/app/components/pages/Support.jsx b/src/app/components/pages/Support.jsx similarity index 100% rename from app/components/pages/Support.jsx rename to src/app/components/pages/Support.jsx diff --git a/app/components/pages/TagsIndex.jsx b/src/app/components/pages/TagsIndex.jsx similarity index 100% rename from app/components/pages/TagsIndex.jsx rename to src/app/components/pages/TagsIndex.jsx diff --git a/app/components/pages/TagsIndex.scss b/src/app/components/pages/TagsIndex.scss similarity index 100% rename from app/components/pages/TagsIndex.scss rename to src/app/components/pages/TagsIndex.scss diff --git a/app/components/pages/Topics.jsx b/src/app/components/pages/Topics.jsx similarity index 100% rename from app/components/pages/Topics.jsx rename to src/app/components/pages/Topics.jsx diff --git a/app/components/pages/Topics.scss b/src/app/components/pages/Topics.scss similarity index 100% rename from app/components/pages/Topics.scss rename to src/app/components/pages/Topics.scss diff --git a/app/components/pages/Tos.jsx b/src/app/components/pages/Tos.jsx similarity index 100% rename from app/components/pages/Tos.jsx rename to src/app/components/pages/Tos.jsx diff --git a/app/components/pages/Tos.scss b/src/app/components/pages/Tos.scss similarity index 100% rename from app/components/pages/Tos.scss rename to src/app/components/pages/Tos.scss diff --git a/app/components/pages/UserProfile.jsx b/src/app/components/pages/UserProfile.jsx similarity index 100% rename from app/components/pages/UserProfile.jsx rename to src/app/components/pages/UserProfile.jsx diff --git a/app/components/pages/UserProfile.scss b/src/app/components/pages/UserProfile.scss similarity index 100% rename from app/components/pages/UserProfile.scss rename to src/app/components/pages/UserProfile.scss diff --git a/app/components/pages/WaitingList.jsx b/src/app/components/pages/WaitingList.jsx similarity index 100% rename from app/components/pages/WaitingList.jsx rename to src/app/components/pages/WaitingList.jsx diff --git a/app/components/pages/Welcome.jsx b/src/app/components/pages/Welcome.jsx similarity index 100% rename from app/components/pages/Welcome.jsx rename to src/app/components/pages/Welcome.jsx diff --git a/app/components/pages/Welcome.scss b/src/app/components/pages/Welcome.scss similarity index 100% rename from app/components/pages/Welcome.scss rename to src/app/components/pages/Welcome.scss diff --git a/app/components/pages/Witnesses.jsx b/src/app/components/pages/Witnesses.jsx similarity index 100% rename from app/components/pages/Witnesses.jsx rename to src/app/components/pages/Witnesses.jsx diff --git a/app/components/pages/XSS.jsx b/src/app/components/pages/XSS.jsx similarity index 100% rename from app/components/pages/XSS.jsx rename to src/app/components/pages/XSS.jsx diff --git a/app/help/en/faq.md b/src/app/help/en/faq.md similarity index 100% rename from app/help/en/faq.md rename to src/app/help/en/faq.md diff --git a/app/help/en/welcome.md b/src/app/help/en/welcome.md similarity index 100% rename from app/help/en/welcome.md rename to src/app/help/en/welcome.md diff --git a/app/locales/README.md b/src/app/locales/README.md similarity index 100% rename from app/locales/README.md rename to src/app/locales/README.md diff --git a/app/locales/en.js b/src/app/locales/en.js similarity index 100% rename from app/locales/en.js rename to src/app/locales/en.js diff --git a/app/locales/en.json b/src/app/locales/en.json similarity index 99% rename from app/locales/en.json rename to src/app/locales/en.json index 0757b2ffff..e24a749f72 100644 --- a/app/locales/en.json +++ b/src/app/locales/en.json @@ -254,7 +254,11 @@ "terms_of_service": "Terms of Service", "sign_up": "Sign Up", "welcome": "Welcome", - "faq": "FAQ" + "faq": "FAQ", + "chat": "Steemit Chat", + "app_center": "Steemit App Center", + "api_docs": "Steemit API Docs", + "whitepaper": "Steem Whitepaper" }, "main_menu": { "hot": "hot", @@ -742,7 +746,8 @@ "start_with_a_letter": "start with a letter.", "have_only_letters_digits_or_dashes": "have only letters, digits, or dashes.", "have_only_one_dash_in_a_row": "have only one dash in a row.", - "end_with_a_letter_or_digit": "end with a letter or digit." + "end_with_a_letter_or_digit": "end with a letter or digit.", + "verified_exchange_no_memo": "You must include a memo for your exchange transfer." }, "settings_jsx": { "invalid_url": "Invalid URL", diff --git a/app/locales/es.js b/src/app/locales/es.js similarity index 100% rename from app/locales/es.js rename to src/app/locales/es.js diff --git a/app/locales/es_AR.js b/src/app/locales/es_AR.js similarity index 100% rename from app/locales/es_AR.js rename to src/app/locales/es_AR.js diff --git a/app/locales/fr.js b/src/app/locales/fr.js similarity index 100% rename from app/locales/fr.js rename to src/app/locales/fr.js diff --git a/app/locales/it.js b/src/app/locales/it.js similarity index 100% rename from app/locales/it.js rename to src/app/locales/it.js diff --git a/app/locales/jp.js b/src/app/locales/jp.js similarity index 100% rename from app/locales/jp.js rename to src/app/locales/jp.js diff --git a/app/locales/normalize.sh b/src/app/locales/normalize.sh similarity index 100% rename from app/locales/normalize.sh rename to src/app/locales/normalize.sh diff --git a/app/locales/ru.js b/src/app/locales/ru.js similarity index 100% rename from app/locales/ru.js rename to src/app/locales/ru.js diff --git a/app/redux/AppReducer.js b/src/app/redux/AppReducer.js similarity index 100% rename from app/redux/AppReducer.js rename to src/app/redux/AppReducer.js diff --git a/app/redux/AuthSaga.js b/src/app/redux/AuthSaga.js similarity index 100% rename from app/redux/AuthSaga.js rename to src/app/redux/AuthSaga.js diff --git a/app/redux/DemoState.js b/src/app/redux/DemoState.js similarity index 100% rename from app/redux/DemoState.js rename to src/app/redux/DemoState.js diff --git a/app/redux/EmptyState.js b/src/app/redux/EmptyState.js similarity index 100% rename from app/redux/EmptyState.js rename to src/app/redux/EmptyState.js diff --git a/app/redux/FetchDataSaga.js b/src/app/redux/FetchDataSaga.js similarity index 100% rename from app/redux/FetchDataSaga.js rename to src/app/redux/FetchDataSaga.js diff --git a/app/redux/FetchDataSaga.test.js b/src/app/redux/FetchDataSaga.test.js similarity index 100% rename from app/redux/FetchDataSaga.test.js rename to src/app/redux/FetchDataSaga.test.js diff --git a/app/redux/FollowSaga.js b/src/app/redux/FollowSaga.js similarity index 100% rename from app/redux/FollowSaga.js rename to src/app/redux/FollowSaga.js diff --git a/app/redux/GlobalReducer.js b/src/app/redux/GlobalReducer.js similarity index 100% rename from app/redux/GlobalReducer.js rename to src/app/redux/GlobalReducer.js diff --git a/app/redux/MarketReducer.js b/src/app/redux/MarketReducer.js similarity index 100% rename from app/redux/MarketReducer.js rename to src/app/redux/MarketReducer.js diff --git a/app/redux/MarketSaga.js b/src/app/redux/MarketSaga.js similarity index 100% rename from app/redux/MarketSaga.js rename to src/app/redux/MarketSaga.js diff --git a/app/redux/Offchain.jsx b/src/app/redux/Offchain.jsx similarity index 100% rename from app/redux/Offchain.jsx rename to src/app/redux/Offchain.jsx diff --git a/app/redux/PollDataSaga.js b/src/app/redux/PollDataSaga.js similarity index 100% rename from app/redux/PollDataSaga.js rename to src/app/redux/PollDataSaga.js diff --git a/app/redux/RootReducer.js b/src/app/redux/RootReducer.js similarity index 100% rename from app/redux/RootReducer.js rename to src/app/redux/RootReducer.js diff --git a/app/redux/SagaShared.js b/src/app/redux/SagaShared.js similarity index 100% rename from app/redux/SagaShared.js rename to src/app/redux/SagaShared.js diff --git a/app/redux/Transaction.js b/src/app/redux/Transaction.js similarity index 100% rename from app/redux/Transaction.js rename to src/app/redux/Transaction.js diff --git a/app/redux/TransactionSaga.js b/src/app/redux/TransactionSaga.js similarity index 100% rename from app/redux/TransactionSaga.js rename to src/app/redux/TransactionSaga.js diff --git a/app/redux/User.js b/src/app/redux/User.js similarity index 100% rename from app/redux/User.js rename to src/app/redux/User.js diff --git a/app/redux/UserActions.js b/src/app/redux/UserActions.js similarity index 100% rename from app/redux/UserActions.js rename to src/app/redux/UserActions.js diff --git a/app/redux/UserSaga.js b/src/app/redux/UserSaga.js similarity index 100% rename from app/redux/UserSaga.js rename to src/app/redux/UserSaga.js diff --git a/app/redux/constants.js b/src/app/redux/constants.js similarity index 100% rename from app/redux/constants.js rename to src/app/redux/constants.js diff --git a/app/redux/tests/AppReducer.test.js b/src/app/redux/tests/AppReducer.test.js similarity index 100% rename from app/redux/tests/AppReducer.test.js rename to src/app/redux/tests/AppReducer.test.js diff --git a/app/redux/tests/global.json b/src/app/redux/tests/global.json similarity index 100% rename from app/redux/tests/global.json rename to src/app/redux/tests/global.json diff --git a/app/redux/tests/global.test.js b/src/app/redux/tests/global.test.js similarity index 100% rename from app/redux/tests/global.test.js rename to src/app/redux/tests/global.test.js diff --git a/app/utils/Accessors.js b/src/app/utils/Accessors.js similarity index 100% rename from app/utils/Accessors.js rename to src/app/utils/Accessors.js diff --git a/app/utils/AppPropTypes.js b/src/app/utils/AppPropTypes.js similarity index 100% rename from app/utils/AppPropTypes.js rename to src/app/utils/AppPropTypes.js diff --git a/app/utils/BadActorList.js b/src/app/utils/BadActorList.js similarity index 100% rename from app/utils/BadActorList.js rename to src/app/utils/BadActorList.js diff --git a/app/utils/BrowserTests.js b/src/app/utils/BrowserTests.js similarity index 100% rename from app/utils/BrowserTests.js rename to src/app/utils/BrowserTests.js diff --git a/app/utils/ChainValidation.js b/src/app/utils/ChainValidation.js similarity index 89% rename from app/utils/ChainValidation.js rename to src/app/utils/ChainValidation.js index 8e2f0f15e8..b3e3417e7c 100644 --- a/app/utils/ChainValidation.js +++ b/src/app/utils/ChainValidation.js @@ -1,8 +1,9 @@ import tt from 'counterpart'; import BadActorList from 'app/utils/BadActorList'; +import VerifiedExchangeList from 'app/utils/VerifiedExchangeList'; import {PrivateKey, PublicKey} from 'steem/lib/auth/ecc'; -export function validate_account_name(value) { +export function validate_account_name(value, memo) { let i, label, len, length, ref, suffix; suffix = tt('chainvalidation_js.account_name_should'); @@ -22,6 +23,9 @@ export function validate_account_name(value) { if (BadActorList.includes(value)) { return 'Use caution sending to this account. Please double check your spelling for possible phishing. '; } + if (VerifiedExchangeList.includes(value) && !memo) { + return tt('chainvalidation_js.verified_exchange_no_memo') + } ref = value.split('.'); for (i = 0, len = ref.length; i < len; i++) { label = ref[i]; diff --git a/app/utils/ComponentFormatters.jsx b/src/app/utils/ComponentFormatters.jsx similarity index 100% rename from app/utils/ComponentFormatters.jsx rename to src/app/utils/ComponentFormatters.jsx diff --git a/app/utils/ConsoleExports.js b/src/app/utils/ConsoleExports.js similarity index 100% rename from app/utils/ConsoleExports.js rename to src/app/utils/ConsoleExports.js diff --git a/app/utils/ContentPreview.js b/src/app/utils/ContentPreview.js similarity index 100% rename from app/utils/ContentPreview.js rename to src/app/utils/ContentPreview.js diff --git a/app/utils/DMCAList.js b/src/app/utils/DMCAList.js similarity index 100% rename from app/utils/DMCAList.js rename to src/app/utils/DMCAList.js diff --git a/app/utils/DMCAUserList.js b/src/app/utils/DMCAUserList.js similarity index 100% rename from app/utils/DMCAUserList.js rename to src/app/utils/DMCAUserList.js diff --git a/app/utils/DomUtils.js b/src/app/utils/DomUtils.js similarity index 100% rename from app/utils/DomUtils.js rename to src/app/utils/DomUtils.js diff --git a/app/utils/ExtractContent.js b/src/app/utils/ExtractContent.js similarity index 100% rename from app/utils/ExtractContent.js rename to src/app/utils/ExtractContent.js diff --git a/app/utils/ExtractMeta.js b/src/app/utils/ExtractMeta.js similarity index 100% rename from app/utils/ExtractMeta.js rename to src/app/utils/ExtractMeta.js diff --git a/app/utils/FormatCoins.js b/src/app/utils/FormatCoins.js similarity index 100% rename from app/utils/FormatCoins.js rename to src/app/utils/FormatCoins.js diff --git a/app/utils/FormatDecimal.test.js b/src/app/utils/FormatDecimal.test.js similarity index 100% rename from app/utils/FormatDecimal.test.js rename to src/app/utils/FormatDecimal.test.js diff --git a/app/utils/Html.js b/src/app/utils/Html.js similarity index 100% rename from app/utils/Html.js rename to src/app/utils/Html.js diff --git a/app/utils/JsPlugins.js b/src/app/utils/JsPlugins.js similarity index 100% rename from app/utils/JsPlugins.js rename to src/app/utils/JsPlugins.js diff --git a/app/utils/Links.js b/src/app/utils/Links.js similarity index 100% rename from app/utils/Links.js rename to src/app/utils/Links.js diff --git a/app/utils/Links.test.js b/src/app/utils/Links.test.js similarity index 100% rename from app/utils/Links.test.js rename to src/app/utils/Links.test.js diff --git a/app/utils/MarketClasses.js b/src/app/utils/MarketClasses.js similarity index 100% rename from app/utils/MarketClasses.js rename to src/app/utils/MarketClasses.js diff --git a/app/utils/MarketUtils.js b/src/app/utils/MarketUtils.js similarity index 100% rename from app/utils/MarketUtils.js rename to src/app/utils/MarketUtils.js diff --git a/app/utils/NormalizeProfile.js b/src/app/utils/NormalizeProfile.js similarity index 100% rename from app/utils/NormalizeProfile.js rename to src/app/utils/NormalizeProfile.js diff --git a/app/utils/Notifications.js b/src/app/utils/Notifications.js similarity index 100% rename from app/utils/Notifications.js rename to src/app/utils/Notifications.js diff --git a/app/utils/ParsersAndFormatters.js b/src/app/utils/ParsersAndFormatters.js similarity index 100% rename from app/utils/ParsersAndFormatters.js rename to src/app/utils/ParsersAndFormatters.js diff --git a/app/utils/ReactForm.js b/src/app/utils/ReactForm.js similarity index 100% rename from app/utils/ReactForm.js rename to src/app/utils/ReactForm.js diff --git a/app/utils/ReduxForms.js b/src/app/utils/ReduxForms.js similarity index 100% rename from app/utils/ReduxForms.js rename to src/app/utils/ReduxForms.js diff --git a/app/utils/RegisterServiceWorker.js b/src/app/utils/RegisterServiceWorker.js similarity index 100% rename from app/utils/RegisterServiceWorker.js rename to src/app/utils/RegisterServiceWorker.js diff --git a/app/utils/RemarkablePlugin.js b/src/app/utils/RemarkablePlugin.js similarity index 100% rename from app/utils/RemarkablePlugin.js rename to src/app/utils/RemarkablePlugin.js diff --git a/app/utils/RemarkableStripper.js b/src/app/utils/RemarkableStripper.js similarity index 100% rename from app/utils/RemarkableStripper.js rename to src/app/utils/RemarkableStripper.js diff --git a/app/utils/SanitizeConfig.js b/src/app/utils/SanitizeConfig.js similarity index 100% rename from app/utils/SanitizeConfig.js rename to src/app/utils/SanitizeConfig.js diff --git a/app/utils/ServerApiClient.js b/src/app/utils/ServerApiClient.js similarity index 100% rename from app/utils/ServerApiClient.js rename to src/app/utils/ServerApiClient.js diff --git a/app/utils/SlateEditor/Align.js b/src/app/utils/SlateEditor/Align.js similarity index 100% rename from app/utils/SlateEditor/Align.js rename to src/app/utils/SlateEditor/Align.js diff --git a/app/utils/SlateEditor/DemoState.js b/src/app/utils/SlateEditor/DemoState.js similarity index 100% rename from app/utils/SlateEditor/DemoState.js rename to src/app/utils/SlateEditor/DemoState.js diff --git a/app/utils/SlateEditor/HRule.js b/src/app/utils/SlateEditor/HRule.js similarity index 100% rename from app/utils/SlateEditor/HRule.js rename to src/app/utils/SlateEditor/HRule.js diff --git a/app/utils/SlateEditor/Helpers.js b/src/app/utils/SlateEditor/Helpers.js similarity index 100% rename from app/utils/SlateEditor/Helpers.js rename to src/app/utils/SlateEditor/Helpers.js diff --git a/app/utils/SlateEditor/Iframe.js b/src/app/utils/SlateEditor/Iframe.js similarity index 100% rename from app/utils/SlateEditor/Iframe.js rename to src/app/utils/SlateEditor/Iframe.js diff --git a/app/utils/SlateEditor/Image.js b/src/app/utils/SlateEditor/Image.js similarity index 100% rename from app/utils/SlateEditor/Image.js rename to src/app/utils/SlateEditor/Image.js diff --git a/app/utils/SlateEditor/Link.js b/src/app/utils/SlateEditor/Link.js similarity index 100% rename from app/utils/SlateEditor/Link.js rename to src/app/utils/SlateEditor/Link.js diff --git a/app/utils/SlateEditor/Schema.js b/src/app/utils/SlateEditor/Schema.js similarity index 100% rename from app/utils/SlateEditor/Schema.js rename to src/app/utils/SlateEditor/Schema.js diff --git a/app/utils/StateFunctions.js b/src/app/utils/StateFunctions.js similarity index 100% rename from app/utils/StateFunctions.js rename to src/app/utils/StateFunctions.js diff --git a/src/app/utils/VerifiedExchangeList.js b/src/app/utils/VerifiedExchangeList.js new file mode 100644 index 0000000000..0a86b57a23 --- /dev/null +++ b/src/app/utils/VerifiedExchangeList.js @@ -0,0 +1,6 @@ +const list = ` +poloniex +bittrex +`.trim().split('\n'); + +export default list; diff --git a/app/utils/shouldComponentUpdate.js b/src/app/utils/shouldComponentUpdate.js similarity index 100% rename from app/utils/shouldComponentUpdate.js rename to src/app/utils/shouldComponentUpdate.js diff --git a/app/utils/userIllegalContent.js b/src/app/utils/userIllegalContent.js similarity index 100% rename from app/utils/userIllegalContent.js rename to src/app/utils/userIllegalContent.js diff --git a/db/config/config.json b/src/db/config/config.json similarity index 100% rename from db/config/config.json rename to src/db/config/config.json diff --git a/db/migrations/20160419161331-create-user.js b/src/db/migrations/20160419161331-create-user.js similarity index 100% rename from db/migrations/20160419161331-create-user.js rename to src/db/migrations/20160419161331-create-user.js diff --git a/db/migrations/20160420133848-create-identity.js b/src/db/migrations/20160420133848-create-identity.js similarity index 100% rename from db/migrations/20160420133848-create-identity.js rename to src/db/migrations/20160420133848-create-identity.js diff --git a/db/migrations/20160420151336-create-account.js b/src/db/migrations/20160420151336-create-account.js similarity index 100% rename from db/migrations/20160420151336-create-account.js rename to src/db/migrations/20160420151336-create-account.js diff --git a/db/migrations/20160506223257-create-web-events.js b/src/db/migrations/20160506223257-create-web-events.js similarity index 100% rename from db/migrations/20160506223257-create-web-events.js rename to src/db/migrations/20160506223257-create-web-events.js diff --git a/db/migrations/20160519211043-users-waiting-list.js b/src/db/migrations/20160519211043-users-waiting-list.js similarity index 100% rename from db/migrations/20160519211043-users-waiting-list.js rename to src/db/migrations/20160519211043-users-waiting-list.js diff --git a/db/migrations/20160715233035-account-recovery-request.js b/src/db/migrations/20160715233035-account-recovery-request.js similarity index 100% rename from db/migrations/20160715233035-account-recovery-request.js rename to src/db/migrations/20160715233035-account-recovery-request.js diff --git a/db/migrations/20160930210310-create-list.js b/src/db/migrations/20160930210310-create-list.js similarity index 100% rename from db/migrations/20160930210310-create-list.js rename to src/db/migrations/20160930210310-create-list.js diff --git a/db/migrations/20161129170500-create-page.js b/src/db/migrations/20161129170500-create-page.js similarity index 100% rename from db/migrations/20161129170500-create-page.js rename to src/db/migrations/20161129170500-create-page.js diff --git a/db/migrations/20170426204791-wait-columns.js b/src/db/migrations/20170426204791-wait-columns.js similarity index 100% rename from db/migrations/20170426204791-wait-columns.js rename to src/db/migrations/20170426204791-wait-columns.js diff --git a/db/migrations/20170511160822-not_unique_account_names.js b/src/db/migrations/20170511160822-not_unique_account_names.js similarity index 100% rename from db/migrations/20170511160822-not_unique_account_names.js rename to src/db/migrations/20170511160822-not_unique_account_names.js diff --git a/db/migrations/20170518201152-create-attributes.js b/src/db/migrations/20170518201152-create-attributes.js similarity index 100% rename from db/migrations/20170518201152-create-attributes.js rename to src/db/migrations/20170518201152-create-attributes.js diff --git a/db/models/account.js b/src/db/models/account.js similarity index 100% rename from db/models/account.js rename to src/db/models/account.js diff --git a/db/models/account_recovery_request.js b/src/db/models/account_recovery_request.js similarity index 100% rename from db/models/account_recovery_request.js rename to src/db/models/account_recovery_request.js diff --git a/db/models/identity.js b/src/db/models/identity.js similarity index 100% rename from db/models/identity.js rename to src/db/models/identity.js diff --git a/db/models/index.js b/src/db/models/index.js similarity index 100% rename from db/models/index.js rename to src/db/models/index.js diff --git a/db/models/list.js b/src/db/models/list.js similarity index 100% rename from db/models/list.js rename to src/db/models/list.js diff --git a/db/models/page.js b/src/db/models/page.js similarity index 100% rename from db/models/page.js rename to src/db/models/page.js diff --git a/db/models/user.js b/src/db/models/user.js similarity index 100% rename from db/models/user.js rename to src/db/models/user.js diff --git a/db/models/user_attributes.js b/src/db/models/user_attributes.js similarity index 100% rename from db/models/user_attributes.js rename to src/db/models/user_attributes.js diff --git a/db/models/web_event.js b/src/db/models/web_event.js similarity index 100% rename from db/models/web_event.js rename to src/db/models/web_event.js diff --git a/db/models/web_events.js b/src/db/models/web_events.js similarity index 100% rename from db/models/web_events.js rename to src/db/models/web_events.js diff --git a/db/tarantool.js b/src/db/tarantool.js similarity index 100% rename from db/tarantool.js rename to src/db/tarantool.js diff --git a/db/utils/find_user.js b/src/db/utils/find_user.js similarity index 100% rename from db/utils/find_user.js rename to src/db/utils/find_user.js diff --git a/server/api/account_recovery.js b/src/server/api/account_recovery.js similarity index 100% rename from server/api/account_recovery.js rename to src/server/api/account_recovery.js diff --git a/server/api/general.js b/src/server/api/general.js similarity index 100% rename from server/api/general.js rename to src/server/api/general.js diff --git a/server/api/notifications.js b/src/server/api/notifications.js similarity index 100% rename from server/api/notifications.js rename to src/server/api/notifications.js diff --git a/server/api/oauth.js b/src/server/api/oauth.js similarity index 100% rename from server/api/oauth.js rename to src/server/api/oauth.js diff --git a/server/app_render.jsx b/src/server/app_render.jsx similarity index 95% rename from server/app_render.jsx rename to src/server/app_render.jsx index 6bc9e3e0d2..05a1171f53 100644 --- a/server/app_render.jsx +++ b/src/server/app_render.jsx @@ -7,6 +7,9 @@ import models from 'db/models'; import secureRandom from 'secure-random'; import ErrorPage from 'server/server-error'; +const path = require('path'); +const ROOT = path.join(__dirname, '../..'); + const DB_RECONNECT_TIMEOUT = process.env.NODE_ENV === 'development' ? 1000 * 60 * 60 : 1000 * 60 * 10; async function appRender(ctx) { @@ -84,7 +87,7 @@ async function appRender(ctx) { const { body, title, statusCode, meta } = await universalRender({location: ctx.request.url, store, offchain, ErrorPage, tarantool: Tarantool.instance()}); // Assets name are found in `webpack-stats` file - const assets_filename = process.env.NODE_ENV === 'production' ? 'tmp/webpack-stats-prod.json' : 'tmp/webpack-stats-dev.json'; + const assets_filename = ROOT + (process.env.NODE_ENV === 'production' ? '/tmp/webpack-stats-prod.json' : '/tmp/webpack-stats-dev.json'); const assets = require(assets_filename); // Don't cache assets name on dev diff --git a/server/hardwarestats.js b/src/server/hardwarestats.js similarity index 100% rename from server/hardwarestats.js rename to src/server/hardwarestats.js diff --git a/server/index.js b/src/server/index.js similarity index 95% rename from server/index.js rename to src/server/index.js index 4e6fbe1c82..4580736835 100644 --- a/server/index.js +++ b/src/server/index.js @@ -6,7 +6,7 @@ import * as steem from 'steem'; delete process.env.BROWSER; const path = require('path'); -const ROOT = path.join(__dirname, '..'); +const ROOT = path.join(__dirname, '../..'); // Tell `require` calls to look into `/app` also // it will avoid `../../../../../` require strings @@ -33,7 +33,7 @@ global.$STM_Config = { const WebpackIsomorphicTools = require('webpack-isomorphic-tools'); const WebpackIsomorphicToolsConfig = require( - '../webpack/webpack-isotools-config' + '../../webpack/webpack-isotools-config' ); global.webpackIsomorphicTools = new WebpackIsomorphicTools( diff --git a/server/json/post_json.jsx b/src/server/json/post_json.jsx similarity index 100% rename from server/json/post_json.jsx rename to src/server/json/post_json.jsx diff --git a/server/json/user_json.jsx b/src/server/json/user_json.jsx similarity index 100% rename from server/json/user_json.jsx rename to src/server/json/user_json.jsx diff --git a/server/prod_logger.js b/src/server/prod_logger.js similarity index 100% rename from server/prod_logger.js rename to src/server/prod_logger.js diff --git a/server/record_web_event.js b/src/server/record_web_event.js similarity index 100% rename from server/record_web_event.js rename to src/server/record_web_event.js diff --git a/server/redirects.js b/src/server/redirects.js similarity index 100% rename from server/redirects.js rename to src/server/redirects.js diff --git a/src/server/requesttimings.js b/src/server/requesttimings.js new file mode 100644 index 0000000000..671cabf763 --- /dev/null +++ b/src/server/requesttimings.js @@ -0,0 +1,16 @@ +function requestTime(numProcesses) { + let number_of_requests = 0; + return function *(next) { + number_of_requests += 1; + const start = Date.now(); + yield* next; + const delta = Math.ceil(Date.now() - start); + // log all requests that take longer than 150ms + if (delta > 150) + console.log(`Request took too long! ${delta}ms: ${this.request.method} ${this.request.path}. Number of parallel requests: ${number_of_requests}, number of processes: ${numProcesses}`); + number_of_requests -= 1; + } +} + +module.exports = requestTime; + diff --git a/server/sendEmail.js b/src/server/sendEmail.js similarity index 100% rename from server/sendEmail.js rename to src/server/sendEmail.js diff --git a/server/server-error.jsx b/src/server/server-error.jsx similarity index 100% rename from server/server-error.jsx rename to src/server/server-error.jsx diff --git a/server/server-html.jsx b/src/server/server-html.jsx similarity index 100% rename from server/server-html.jsx rename to src/server/server-html.jsx diff --git a/server/server.js b/src/server/server.js similarity index 98% rename from server/server.js rename to src/server/server.js index 66fe9af594..4d0184d0f5 100644 --- a/server/server.js +++ b/src/server/server.js @@ -47,7 +47,7 @@ const cacheOpts = { maxAge: 86400000, gzip: true }; // (unless passed in as an env var) const numProcesses = process.env.NUM_PROCESSES || os.cpus().length; -app.use(requestTime()); +app.use(requestTime(numProcesses)); app.keys = [config.get('session_key')]; @@ -260,7 +260,7 @@ if (env === 'development') { app.use( mount( '/assets', - staticCache(path.join(__dirname, '../dist'), cacheOpts) + staticCache(path.join(__dirname, '../../dist'), cacheOpts) ) ); } diff --git a/server/server.test.js b/src/server/server.test.js similarity index 100% rename from server/server.test.js rename to src/server/server.test.js diff --git a/server/service-worker.js b/src/server/service-worker.js similarity index 100% rename from server/service-worker.js rename to src/server/service-worker.js diff --git a/server/sign_up_pages/enter_confirm_email.jsx b/src/server/sign_up_pages/enter_confirm_email.jsx similarity index 98% rename from server/sign_up_pages/enter_confirm_email.jsx rename to src/server/sign_up_pages/enter_confirm_email.jsx index 6c4e0ab989..ba4fc623cc 100644 --- a/server/sign_up_pages/enter_confirm_email.jsx +++ b/src/server/sign_up_pages/enter_confirm_email.jsx @@ -14,15 +14,18 @@ import Mixpanel from "mixpanel"; import Progress from "react-foundation-components/lib/global/progress-bar"; import {api} from 'steem'; +const path = require('path'); +const ROOT = path.join(__dirname, '../../..'); + // FIXME copy paste code, refactor mixpanel out let mixpanel = null; if (config.has("mixpanel") && config.get("mixpanel")) { mixpanel = Mixpanel.init(config.get("mixpanel")); } -let assets_file = "tmp/webpack-stats-dev.json"; +let assets_file = ROOT + "/tmp/webpack-stats-dev.json"; if (process.env.NODE_ENV === "production") { - assets_file = "tmp/webpack-stats-prod.json"; + assets_file = ROOT + "/tmp/webpack-stats-prod.json"; } const assets = Object.assign({}, require(assets_file), { script: [] }); diff --git a/server/sign_up_pages/enter_confirm_mobile.jsx b/src/server/sign_up_pages/enter_confirm_mobile.jsx similarity index 98% rename from server/sign_up_pages/enter_confirm_mobile.jsx rename to src/server/sign_up_pages/enter_confirm_mobile.jsx index eb26161447..c7a54703ea 100644 --- a/server/sign_up_pages/enter_confirm_mobile.jsx +++ b/src/server/sign_up_pages/enter_confirm_mobile.jsx @@ -14,15 +14,18 @@ import config from "config"; import Mixpanel from "mixpanel"; import Progress from 'react-foundation-components/lib/global/progress-bar'; +const path = require('path'); +const ROOT = path.join(__dirname, '../../..'); + // FIXME copy paste code, refactor mixpanel out var mixpanel = null; if (config.has("mixpanel") && config.get("mixpanel")) { mixpanel = Mixpanel.init(config.get("mixpanel")); } -var assets_file = "tmp/webpack-stats-dev.json"; +var assets_file = ROOT + "/tmp/webpack-stats-dev.json"; if (process.env.NODE_ENV === "production") { - assets_file = "tmp/webpack-stats-prod.json"; + assets_file = ROOT + "/tmp/webpack-stats-prod.json"; } const assets = Object.assign({}, require(assets_file), { script: [] }); diff --git a/server/utils/misc.js b/src/server/utils/misc.js similarity index 100% rename from server/utils/misc.js rename to src/server/utils/misc.js diff --git a/server/utils/teleSign.js b/src/server/utils/teleSign.js similarity index 100% rename from server/utils/teleSign.js rename to src/server/utils/teleSign.js diff --git a/server/utils/twilio.js b/src/server/utils/twilio.js similarity index 100% rename from server/utils/twilio.js rename to src/server/utils/twilio.js diff --git a/shared/HtmlReady.js b/src/shared/HtmlReady.js similarity index 100% rename from shared/HtmlReady.js rename to src/shared/HtmlReady.js diff --git a/shared/UniversalRender.jsx b/src/shared/UniversalRender.jsx similarity index 100% rename from shared/UniversalRender.jsx rename to src/shared/UniversalRender.jsx diff --git a/shared/api_client/ChainConfig.js b/src/shared/api_client/ChainConfig.js similarity index 100% rename from shared/api_client/ChainConfig.js rename to src/shared/api_client/ChainConfig.js diff --git a/shared/api_client/index.js b/src/shared/api_client/index.js similarity index 100% rename from shared/api_client/index.js rename to src/shared/api_client/index.js diff --git a/shared/clash/object2json.js b/src/shared/clash/object2json.js similarity index 100% rename from shared/clash/object2json.js rename to src/shared/clash/object2json.js diff --git a/webpack/base.config.js b/webpack/base.config.js index 8dc7dd5bca..21876c7b1b 100644 --- a/webpack/base.config.js +++ b/webpack/base.config.js @@ -9,7 +9,7 @@ const webpack_isomorphic_tools_plugin = export default { entry: { - app: ['babel-polyfill', './app/Main.js'], + app: ['babel-polyfill', './src/app/Main.js'], vendor: ['react', 'react-dom', 'react-router'] }, output: { @@ -55,10 +55,11 @@ export default { ], resolve: { root: [ - path.resolve(__dirname, '..') + path.resolve(__dirname, '../src') ], alias: { - react: path.join(__dirname, '../node_modules', 'react') + react: path.join(__dirname, '../node_modules', 'react'), + assets: path.join(__dirname, '../src/app/assets') }, extensions: ['', '.js', '.json', '.jsx'], modulesDirectories: ['node_modules'] diff --git a/webpack/dev.config.js b/webpack/dev.config.js index c62a3f1821..a4f8908419 100644 --- a/webpack/dev.config.js +++ b/webpack/dev.config.js @@ -31,7 +31,7 @@ export default { devtool: 'source-map', entry: { app: [ - './app/Main.js', + './src/app/Main.js', //`webpack-hot-middleware/client?path=//${HOST}:${PORT}/__webpack_hmr`, ] }, diff --git a/webpack/utils/start-koa.js b/webpack/utils/start-koa.js index 72fc21eb80..0fbb6458e5 100644 --- a/webpack/utils/start-koa.js +++ b/webpack/utils/start-koa.js @@ -5,7 +5,7 @@ import watch from 'node-watch'; let server; let started; let serverReload; -const KOA_PATH = path.join(__dirname, '../../server/index'); +const KOA_PATH = path.join(__dirname, '../../src/server/index'); const startServer = () => { @@ -40,7 +40,7 @@ const startServer = () => { }); // Start watcher on server files and restart server on change - const server_path = path.join(__dirname, '../../server'); + const server_path = path.join(__dirname, '../../src/server'); // const app_path = path.join(__dirname, '../../app'); watch([server_path], () => restartServer()); } diff --git a/webpack/webpack-isotools-config.js b/webpack/webpack-isotools-config.js index e023c6f9d3..480506e6d5 100644 --- a/webpack/webpack-isotools-config.js +++ b/webpack/webpack-isotools-config.js @@ -1,31 +1,24 @@ const webpack_isomorphic_tools_plugin = require('webpack-isomorphic-tools/plugin'); +const path = require('path'); +const ROOT = path.join(__dirname, '..'); module.exports = { - webpack_assets_file_path: process.env.NODE_ENV === 'production' ? 'tmp/webpack-isotools-assets-prod.json' : 'tmp/webpack-isotools-assets-dev.json', + webpack_assets_file_path: ROOT + (process.env.NODE_ENV === 'production' ? '/tmp/webpack-isotools-assets-prod.json' : '/tmp/webpack-isotools-assets-dev.json'), + webpack_stats_file_path: './tmp/webpack-stats.json', + alias: { + assets: path.join(__dirname, '../src/app/assets') + }, assets: { images: { - extensions: ['png', 'jpg'] + extensions: ['png', 'jpg', 'svg'] }, fonts: { extensions: ['woff', 'ttf'] }, - //png_images: { - // extension: 'png', // - // filter: function(module, regular_expression, options, log) - // { - // return regular_expression.test(module.name) - // }, - // path: function(module, options, log) - // { - // return module.name - // }, - // - //}, styles: { extensions: ['css', 'scss'], - // which `module`s to parse CSS from: filter(module, regular_expression, options, log) { if (options.development) { @@ -58,22 +51,22 @@ module.exports = { // basically takes `module.source` and modifies `module.exports` a little. parser: webpack_isomorphic_tools_plugin.css_loader_parser }, - svg: { - extension: 'svg', - parser: webpack_isomorphic_tools_plugin.url_loader_parser - //parser: function(m, options) { - // console.log("-- exports.parser -->", m.source); - // //if (m.source) { - // // var regex = /module\.exports = "((.|\n)*)"/; - // // var match = m.source.match(regex); - // // var r = match ? match[1] : ""; - // // //console.log("-- exports.parser res 0 -->", r); - // // r = decodeURI(r); //.replace(/"/g,'"'); - // // console.log("-- exports.parser res 1 -->", r); - // // return r; - // //} - // return m.source.replace(/"/g, "'"); - //} - } + // svg: { + // extension: 'svg', + // parser: webpack_isomorphic_tools_plugin.url_loader_parser + // //parser: function(m, options) { + // // console.log("-- exports.parser -->", m.source); + // // //if (m.source) { + // // // var regex = /module\.exports = "((.|\n)*)"/; + // // // var match = m.source.match(regex); + // // // var r = match ? match[1] : ""; + // // // //console.log("-- exports.parser res 0 -->", r); + // // // r = decodeURI(r); //.replace(/"/g,'"'); + // // // console.log("-- exports.parser res 1 -->", r); + // // // return r; + // // //} + // // return m.source.replace(/"/g, "'"); + // //} + // } } }; diff --git a/yarn.lock b/yarn.lock index 83fddc7979..0342ab1120 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4946,9 +4946,9 @@ node-uuid@~1.4.0, node-uuid@~1.4.7: version "1.4.8" resolved "https://registry.yarnpkg.com/node-uuid/-/node-uuid-1.4.8.tgz#b040eb0923968afabf8d32fb1f17f1167fdab907" -node-watch@^0.3.5: - version "0.3.5" - resolved "https://registry.yarnpkg.com/node-watch/-/node-watch-0.3.5.tgz#a07f253a4f538de9d4ca522dd7f1996eeec0d97e" +node-watch@^0.5.5: + version "0.5.5" + resolved "https://registry.yarnpkg.com/node-watch/-/node-watch-0.5.5.tgz#34865ba8bc6861ab086acdcc3403e40ed55c3274" "nopt@2 || 3", nopt@~3.0.1: version "3.0.6" @@ -6260,9 +6260,9 @@ require-directory@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" -require-hacker@^2.1.3: - version "2.1.4" - resolved "https://registry.yarnpkg.com/require-hacker/-/require-hacker-2.1.4.tgz#1683da866119495e0ffcda8ebed9bbcf556849f2" +require-hacker@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/require-hacker/-/require-hacker-3.0.0.tgz#ec5947e5ba2e2f5b88d738d291364442ef70bfe0" dependencies: babel-runtime "^6.6.1" colors "^1.1.2" @@ -7401,14 +7401,15 @@ webpack-hot-middleware@2.x: querystring "^0.2.0" strip-ansi "^3.0.0" -webpack-isomorphic-tools@^2.2.31: - version "2.6.6" - resolved "https://registry.yarnpkg.com/webpack-isomorphic-tools/-/webpack-isomorphic-tools-2.6.6.tgz#b52196bc5378fc6b584ccb1c480a159a51ebd94c" +webpack-isomorphic-tools@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/webpack-isomorphic-tools/-/webpack-isomorphic-tools-3.0.3.tgz#303a3757ce205ed66f223944b544bd134d1787cd" dependencies: babel-runtime "^6.6.1" colors "^1.1.2" fs-extra "^0.30.0" - require-hacker "^2.1.3" + require-hacker "^3.0.0" + semver "^5.3.0" sync-request "^3.0.1" uglify-js "^2.7.0"