├── .editorconfig ├── .env.example ├── .env.prod ├── .env.stage ├── .gitignore ├── .travis.yml ├── CHANGELOG.md ├── CONTRIBUTING.md ├── Dockerfile ├── Dockerfile.prod ├── Dockerfile.stage ├── LICENSE ├── README.md ├── nginx ├── default.conf └── nginx-stage │ └── default.conf ├── package.json ├── src ├── assets │ ├── favicon.png │ ├── fonts │ │ └── Roboto │ │ │ ├── Roboto-Bold.eot │ │ │ ├── Roboto-Bold.svg │ │ │ ├── Roboto-Bold.ttf │ │ │ ├── Roboto-Bold.woff │ │ │ ├── Roboto-Bold.woff2 │ │ │ ├── Roboto-Regular.eot │ │ │ ├── Roboto-Regular.svg │ │ │ ├── Roboto-Regular.ttf │ │ │ ├── Roboto-Regular.woff │ │ │ ├── Roboto-Regular.woff2 │ │ │ └── stylesheet.css │ ├── images │ │ ├── icons │ │ │ └── flags │ │ │ │ ├── china.svg │ │ │ │ ├── en.svg │ │ │ │ ├── fr.svg │ │ │ │ ├── ge.svg │ │ │ │ ├── ru.svg │ │ │ │ └── sp.svg │ │ └── logo.svg │ ├── locales │ │ ├── en │ │ │ ├── auth.json │ │ │ ├── common.json │ │ │ ├── wallet.json │ │ │ └── wallets.json │ │ └── ru │ │ │ ├── auth.json │ │ │ ├── common.json │ │ │ └── wallets.json │ └── main.css ├── components │ ├── _forms │ │ ├── RenderCheckbox │ │ │ └── index.js │ │ ├── RenderInput │ │ │ └── index.js │ │ ├── RenderNumber │ │ │ └── index.js │ │ ├── RenderPassword │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── RenderPaymentPassword │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── RenderSelect │ │ │ └── index.js │ │ └── RenderSlider │ │ │ └── index.js │ ├── app │ │ ├── AppRoute │ │ │ └── index.js │ │ ├── AuthRoute │ │ │ └── index.js │ │ ├── LanguageDropdown │ │ │ └── index.js │ │ ├── NavMenuDropdown │ │ │ └── index.js │ │ └── NavWalletDropdown │ │ │ └── index.js │ ├── auth │ │ ├── ResetPasswordEmailForm │ │ │ └── index.js │ │ ├── ResetPasswordNewPasswordForm │ │ │ └── index.js │ │ ├── SignInForm │ │ │ └── index.js │ │ ├── SignUpForm │ │ │ └── index.js │ │ ├── VerifyResetPasswordForm │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── VerifySignInForm │ │ │ ├── index.js │ │ │ └── styles.css │ │ └── VerifySignUpForm │ │ │ ├── index.js │ │ │ └── styles.css │ ├── common │ │ ├── Alert │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── Block │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── EmptyState │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── Error404 │ │ │ └── index.js │ │ └── Preloader │ │ │ ├── index.js │ │ │ └── styles.css │ ├── help │ │ └── Help │ │ │ └── index.js │ ├── settings │ │ ├── InitChangePasswordForm │ │ │ └── index.js │ │ ├── RegisterTokenAddressForm │ │ │ └── index.js │ │ ├── RegisterTokenForm │ │ │ └── index.js │ │ ├── Settings │ │ │ ├── index.js │ │ │ └── styles.css │ │ └── VerifyChangePasswordForm │ │ │ ├── index.js │ │ │ └── styles.css │ ├── wallet │ │ ├── TransferFundsForm │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── Tx │ │ │ ├── index.js │ │ │ └── styles.css │ │ └── VerifyTransferFundsForm │ │ │ ├── index.js │ │ │ └── styles.css │ └── wallets │ │ ├── CreateWalletForm │ │ ├── index.js │ │ └── styles.css │ │ ├── ExportWallet │ │ ├── index.js │ │ └── styles.css │ │ ├── WalletTile │ │ ├── balances.js │ │ ├── index.js │ │ ├── styles.css │ │ └── variants.js │ │ └── Wallets │ │ ├── index.js │ │ └── styles.css ├── containers │ ├── app │ │ ├── AppWrapper │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── AuthWrapper │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── Main │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── NavigationBar │ │ │ ├── index.js │ │ │ └── styles.css │ │ └── Topbar │ │ │ ├── index.js │ │ │ └── styles.css │ ├── auth │ │ ├── ResetPassword │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── SignUp │ │ │ ├── index.js │ │ │ └── styles.css │ │ └── SingIn │ │ │ ├── index.js │ │ │ └── styles.css │ ├── settings │ │ ├── ChangePassword │ │ │ └── index.js │ │ ├── ChangePasswordPopup │ │ │ └── index.js │ │ ├── ChangeTheme │ │ │ └── index.js │ │ └── RegisterCustomTokenPopup │ │ │ └── index.js │ ├── wallet │ │ ├── Balances │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── DepositFunds │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── TransferFunds │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── TxDetails │ │ │ ├── index.js │ │ │ └── styles.css │ │ ├── Txs │ │ │ └── index.js │ │ └── Wallet │ │ │ ├── index.js │ │ │ └── styles.css │ └── wallets │ │ ├── CreateWalletPopup │ │ └── index.js │ │ ├── EditWalletPopup │ │ └── index.js │ │ ├── ExportWalletPopup │ │ └── index.js │ │ ├── ImportWalletPopup │ │ └── index.js │ │ ├── WalletsControls │ │ ├── index.js │ │ └── styles.css │ │ ├── WalletsList │ │ └── index.js │ │ └── WalletsPopups │ │ └── index.js ├── favicon.png ├── index.html ├── index.js ├── redux │ ├── configureStore.js │ ├── modules │ │ ├── app │ │ │ ├── app.js │ │ │ ├── theme.js │ │ │ └── user.js │ │ ├── auth │ │ │ ├── resetPassword.js │ │ │ ├── signIn.js │ │ │ └── signUp.js │ │ ├── settings │ │ │ ├── changePassword.js │ │ │ └── registerCustomToken.js │ │ ├── wallet │ │ │ ├── balances.js │ │ │ ├── depositFunds.js │ │ │ ├── selectedWallet.js │ │ │ ├── transferFunds.js │ │ │ ├── txDetails.js │ │ │ └── txs.js │ │ └── wallets │ │ │ ├── createWallet.js │ │ │ ├── editWallet.js │ │ │ ├── exportWallet.js │ │ │ ├── importWallet.js │ │ │ └── walletsList.js │ └── rootReducer.js ├── routes.js ├── sagas │ ├── app │ │ ├── appSaga.js │ │ ├── themeSaga.js │ │ └── userSaga.js │ ├── auth │ │ ├── resetPasswordSaga.js │ │ ├── signInSaga.js │ │ └── signUpSaga.js │ ├── rootSaga.js │ ├── settings │ │ ├── changePasswordSaga.js │ │ └── registerTokenSaga.js │ ├── wallet │ │ ├── balancesSaga.js │ │ ├── transferFundsSaga.js │ │ └── txsSaga.js │ └── wallets │ │ ├── createWalletSaga.js │ │ └── walletsListSaga.js ├── utils │ ├── actions │ │ └── index.js │ ├── auth │ │ └── index.js │ ├── fetch │ │ ├── helpers.js │ │ ├── index.js │ │ └── mocks.js │ ├── i18n │ │ ├── index.js │ │ └── registerServiceWorker.js │ ├── numbers │ │ └── index.js │ ├── router │ │ └── index.js │ ├── somefn │ │ ├── index.js │ │ └── index.test.js │ ├── theme │ │ └── index.js │ ├── toaster │ │ └── index.js │ └── validators │ │ └── index.js └── webpack-public-path.js ├── tools ├── analyze.js ├── build.js ├── postcss.config.js ├── serveDist.js ├── start.js └── webpack │ ├── webpack.config.dev.js │ └── webpack.config.prod.js └── yarn.lock /.editorconfig: -------------------------------------------------------------------------------- 1 | # editorconfig.org 2 | root = true 3 | 4 | [*] 5 | indent_style = space 6 | indent_size = 2 7 | end_of_line = lf 8 | charset = utf-8 9 | trim_trailing_whitespace = true 10 | insert_final_newline = true 11 | 12 | [*.md] 13 | trim_trailing_whitespace = false -------------------------------------------------------------------------------- /.env.example: -------------------------------------------------------------------------------- 1 | API_HOST=https://api.moonwallet.tech 2 | ETHERSCAN_URL=https://ropsten.etherscan.io 3 | -------------------------------------------------------------------------------- /.env.prod: -------------------------------------------------------------------------------- 1 | API_HOST=https://api.moonwallet.tech 2 | ETHERSCAN_URL=https://ropsten.etherscan.io 3 | -------------------------------------------------------------------------------- /.env.stage: -------------------------------------------------------------------------------- 1 | API_HOST=https://api.moonwallet.tech 2 | ETHERSCAN_URL=https://ropsten.etherscan.io 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | 8 | # Runtime data 9 | pids 10 | *.pid 11 | *.seed 12 | *.pid.lock 13 | 14 | # Directory for instrumented libs generated by jscoverage/JSCover 15 | lib-cov 16 | 17 | # Coverage directory used by tools like istanbul 18 | coverage 19 | 20 | # nyc test coverage 21 | .nyc_output 22 | 23 | # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) 24 | .grunt 25 | 26 | # Bower dependency directory (https://bower.io/) 27 | bower_components 28 | 29 | # node-waf configuration 30 | .lock-wscript 31 | 32 | # Compiled binary addons (http://nodejs.org/api/addons.html) 33 | build/Release 34 | 35 | # Dependency directories 36 | node_modules/ 37 | jspm_packages/ 38 | 39 | # Typescript v1 declaration files 40 | typings/ 41 | 42 | # Optional npm cache directory 43 | .npm 44 | 45 | # Optional eslint cache 46 | .eslintcache 47 | 48 | # Optional REPL history 49 | .node_repl_history 50 | 51 | # Output of 'npm pack' 52 | *.tgz 53 | 54 | # Yarn Integrity file 55 | .yarn-integrity 56 | 57 | # dotenv environment variables file 58 | .env 59 | 60 | .idea 61 | .DS_Store 62 | dist 63 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | sudo: required 2 | services: 3 | - docker 4 | branches: 5 | only: 6 | - master 7 | - develop 8 | script: 9 | - export ENV_FILE=`if [ "$TRAVIS_BRANCH" == "master" ]; then echo "prod"; else echo 10 | "stage"; fi` 11 | - export TAG=`if [ "$TRAVIS_BRANCH" == "master" ]; then echo "production"; elif [ 12 | "$TRAVIS_BRANCH" == "develop" ]; then echo "stage"; else echo "dev-$(git rev-parse 13 | --short HEAD)"; fi` 14 | - docker build --no-cache -t jincort/frontend-moon-wallet-develop:${TAG} . 15 | - docker run --rm -v $(pwd):/usr/src/app jincort/frontend-moon-wallet-develop:${TAG} 16 | /bin/sh -c "yarn && cp -r .env.${ENV_FILE} .env && yarn build && yarn run lint:all" 17 | after_success: 18 | - export DOCKERFILE=`if [ "$TRAVIS_BRANCH" == "develop" ]; then echo "Dockerfile.stage"; 19 | else echo "Dockerfile.prod" ; fi` 20 | - docker build -f $DOCKERFILE --no-cache -t jincort/frontend-moon-wallet:${TAG} . 21 | - docker login -u $DOCKER_USER -p $DOCKER_PASS 22 | - docker push jincort/frontend-moon-wallet-develop:${TAG} 23 | - docker push jincort/frontend-moon-wallet:${TAG} 24 | notifications: 25 | slack: 26 | secure: JgbatLuzcg2k4DT1wvKGs4hlRZLCILQwKBkXYNHYRx2+JZVzP98uP2upgrEjmufOuM7+cmXu75fN2RyCHv5bVhX6pIweI5PYSYpQ9w19OlCefRW8IrqtPhYx7ROwOYA/u1hzvWu0FiFdh+1Z+MYuerF+ZSsU4XqSgDK3s6B2lhnB7BFVoy1tyQmTOo7Scfr7wKqTwXNUNIuwQ9Ph1xeG5zwXjeU1jMpF63NYPt/AKQCYYqH80DgRSsZI4tPRlW6ranriFLTFGECxtv0SXzClpAWqIjMSO+35+zHPlb+HozMrvqwy5/L8xAnBeVmDMY7vwWmZQe7SOUAr2uBrVq3JiE0BLVzYb51girjvcbwnvol0EOYwMsf2QYXlV5GJUDregJJUNr7MI+9eN3vdvvLzSU51x/+7rlAxOE7zgFFbyRrANrPbk0Kk6sv9Ih0Ubj05/kTkiPb6S9gWRfTF4EylOWh8IsT6BFtwgk4nwIKVOicSCn5ZLcA+4fO1wOXP1bFWHP/2/uDlYGgs/FEU4dpLP5u57UZf70ZyXa4JN3BDRF2eBXW5BMpDHtUY8VNbMbpgZKPHCQ+p37AOb574m8GufrOTaJfkNWtyLkly1l6zlhIDwgLjA9tWRwvn+lt1a9Q6+LgFAzACCg4F0sqVHu+zMktqseysYkNSGm8XIagVKqw= 27 | env: 28 | global: 29 | - secure: eFzMox6YGl9RWseZ3D4QC1g+rBUA2aqS3soqQT46NCq87eO6AVlREYYOADj4elrdBffT/q26LPY982AxfPqN+jGlsRyRbqxgSv+zoER2YiwCCdKN1QcvySQYS/pngMoeTYkuQ0cbXTAWAeDMVSIL3AFaPA6VWE7ULbZClctwJflXoqLAqtQB5srFBKPZhzxuBS+b80iZcQkYAx+I2UbbPJ5V2nW7zL+aS5d7djxG8MdV75ihUwIQgZFO03ieJvIoKfiDub+67xLJZDgllm+uZne5St9oqz791znb6BKv5CJgfLTFD6ytmwF02O/hIHdKomyuMFaAt8JdnmH/5TAxC9x8EXknPboS4/GXs2rAwlfAhEUlO+7S57t6bSZbHdCttQdpi+3Kg9KamXieuEJ4K+TZFJ3XEcugLFfq9LNUDgSt7KthtkCnsoM/DNNuV5qsrN6G4ZlPpJMiODjnvH3pFbuaNm29EJB0bXx7pkqZu24kZVHEFovh0S6g1nfkCSfbI2JpXs2vvDdveUMxWftCO9fFlqsymZ+aPHBBkzZRtCcC4Kh0JKGjXY1wGYHHTLVNTMvBhPMi0D/7C7GVVyB3UZwnDe2hVWr0IqM3opXWcGtXm9BbJ6hJQNx63oLj4VkL2D71ZtbqqS745WVRKuHO+9DAcAVvAc1ttBpSylhShok= 30 | - secure: JR2TIPnFpmj0/6/4+oensJg01D2v2roI3WufoKVSaK3GAOYy8JKMxz8kAgoQB+PG6Lv0PSX6qkPvVd48N2jLEbRJtQo8tDLsFSSKsXWS6H6XD08KQG7DXWUiXNDRjPrug14Xts6UpO2/dXuJrSuZerhZTJJVMOgVO9MjrubvPBQKBLbAXsoSUj5CzuDlPOX+SRQihl7gaXC4ZzIiRevWdIHE3EhRnyeSU6AADzthtA8+8mu134cRC6x5/hs1LOP84JtS5g69YdK1BKLtdIjqhSeVzCjV7xrTIcgRMNvdcj2n1W0Il28/MWO5nmZ8Wwq6rwO9sHoAdXqODFEw/x7NAhbavS2MJdDxDRQgvEcih0dzBYwc4fEzPmFwwMEvqg4Mn4om7gBHSVvfXwZhuYqy4enNKs9whj0Mvw1e5E9WP2/Bx55uYDRjwTVzGrlbBog6X4DrH7uvzkHgE8GBrNtgczLyFAkMVePimud+MBB66XZx22r8GjefQPSlLs713y8lCxPD9hl96dXiEwkc5Vqb6eNGxPem5Jt5X4p5VXwxZ9P3eNPi0M5q5MqVscjE7czev6K5bu0QRmQ836cIqRrIDV7NQ9FmSzWK28p1p+ztGN9EWW6Fe2cJQLcMeGBhfs3Adb5US+bO2q6NS5amUkkyOI+9mpQWP4sv9pazJ9APM6w= 31 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Change Log 2 | 3 | ## [Unreleased](https://github.com/JincorTech/frontend-moon-wallet/tree/HEAD) 4 | 5 | **Closed issues:** 6 | 7 | - Notification system [\#22](https://github.com/JincorTech/frontend-moon-wallet/issues/22) 8 | - SW: balances in sidebar [\#14](https://github.com/JincorTech/frontend-moon-wallet/issues/14) 9 | - SW: transactions list [\#12](https://github.com/JincorTech/frontend-moon-wallet/issues/12) 10 | - Single wallet layout [\#11](https://github.com/JincorTech/frontend-moon-wallet/issues/11) 11 | - Export wallet popup and form [\#9](https://github.com/JincorTech/frontend-moon-wallet/issues/9) 12 | - Create wallet popup [\#7](https://github.com/JincorTech/frontend-moon-wallet/issues/7) 13 | - Wallets list [\#6](https://github.com/JincorTech/frontend-moon-wallet/issues/6) 14 | - Sign In layout and forms [\#3](https://github.com/JincorTech/frontend-moon-wallet/issues/3) 15 | - Sign Up layout and forms [\#2](https://github.com/JincorTech/frontend-moon-wallet/issues/2) 16 | - Integration with blueprintJS [\#1](https://github.com/JincorTech/frontend-moon-wallet/issues/1) 17 | 18 | **Merged pull requests:** 19 | 20 | - Feature/issue 1 [\#24](https://github.com/JincorTech/frontend-moon-wallet/pull/24) ([Amazing-Space-Invader](https://github.com/Amazing-Space-Invader)) 21 | - Feature/issue 1 [\#23](https://github.com/JincorTech/frontend-moon-wallet/pull/23) ([Amazing-Space-Invader](https://github.com/Amazing-Space-Invader)) 22 | 23 | 24 | 25 | \* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)* 26 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM mhart/alpine-node:9 2 | 3 | USER root 4 | ARG ENV_FILE=stage 5 | 6 | VOLUME /usr/src/app 7 | WORKDIR /usr/src/app 8 | -------------------------------------------------------------------------------- /Dockerfile.prod: -------------------------------------------------------------------------------- 1 | FROM node:9.0.0-alpine 2 | RUN apk add --update nginx 3 | RUN rm -rf /var/cache/apk/* 4 | RUN mkdir -p /run/nginx 5 | ADD ./nginx/default.conf /etc/nginx/conf.d/default.conf 6 | WORKDIR /usr/src/app 7 | COPY ./dist /usr/src/app/ 8 | ENTRYPOINT ["/usr/sbin/nginx", "-g", "daemon off;"] 9 | EXPOSE 80 10 | -------------------------------------------------------------------------------- /Dockerfile.stage: -------------------------------------------------------------------------------- 1 | FROM node:9.0.0-alpine 2 | 3 | WORKDIR /usr/src/app 4 | 5 | ARG APIHOST=https://api.com/v1/ 6 | 7 | ENV API_HOST=$APIHOST 8 | 9 | ADD . /usr/src/app/ 10 | ADD .env.stage .env 11 | 12 | RUN apk add --no-cache --update nginx && \ 13 | rm -rf /var/cache/apk/* 14 | 15 | RUN yarn && npm rebuild node-sass && yarn build && \ 16 | rm -rf ./src ./node_modules /usr/local/lib/node_modules /usr/local/share/.cache/yarn/ && \ 17 | mkdir -p /run/nginx 18 | 19 | ADD ./nginx-stage/default.conf /etc/nginx/conf.d/default.conf 20 | 21 | ENTRYPOINT ["/usr/sbin/nginx", "-g", "daemon off;"] 22 | 23 | EXPOSE 80 24 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ![MOON Wallet](https://monosnap.com/file/AWvzmQe6IvNezvjIhYwkSDWbiKB5en.png) 2 | 3 | # Moon Wallet Frontend module 4 | 5 | ![GitHub (pre-)release](https://img.shields.io/github/release/JincorTech/frontend-moon-wallet/all.svg) 6 | [![Build Status](https://travis-ci.org/secret-tech/frontend-moon-wallet.svg?branch=master)](https://travis-ci.org/secret-tech/frontend-moon-wallet) 7 | ![license](https://img.shields.io/github/license/JincorTech/frontend-moon-wallet.svg) 8 | 9 | This is frontend module of [Moon Wallet](https://moonwallet.tech/). Checkout backend [here](https://github.com/JincorTech/backend-token-wallets). 10 | 11 | This web client can be used to connect MOON's backend. Currently it has the following functionality: 12 | 13 | 1. Registration & Authorization 14 | 1. Register any Token by specified contract address 15 | 1. Generate and manage **multiple** Ethereum wallets by one account 16 | 1. Transfer ETH / ERC-20 17 | 1. Transferring is protected by payment password 18 | 1. Displaying transaction history for ETH/ERC-20 19 | 1. Notification management 20 | 1. All important actions are protected with 2FA (email or google authenticator) 21 | by integration with 22 | [Jincor Backend Verify](https://github.com/JincorTech/backend-verify) 23 | You can disable some kind of verifications as well. 24 | 25 | For more info check [**API DOCS**](https://jincortech.github.io/backend-token-wallets) 26 | 27 | ![Moon Wallet Screenshot](https://monosnap.com/file/ju7HjvPDg0csEeInRo11JrudDAJDc3.png) 28 | 29 | ## Technology stack 30 | 31 | 1. React & Redux & Saga. 32 | 1. Webpack 33 | 1. socket.io 34 | 35 | ## How start application loacally? 36 | 37 | 1. Clone this repo. 38 | 1. `$ yarn` 39 | 1. `$ cp .env.example .env` 40 | 1. `$ yarn start` 41 | 1. Go to `localhost:3000/auth/sign-in` 42 | 43 | ## How to build application for production? 44 | 45 | Webpack generate static `dist` directory with production build of app. You just need serve it with your server like nginx. 46 | 47 | 1. `$ yarn` 48 | 1. `$ cp .env.prod .env` 49 | 1. `$ yarn build` 50 | 51 | ## Environment variables 52 | 53 | ``cp .env.example .env`` - copy example dotenv file and specify your own values in `.env` 54 | 55 | You can use different environment variables. Create `.env.stage`, `.env.prod` and `.env.dev` and copy the file you need. 56 | 57 | ## Scripts 58 | 59 | ``yarn start`` - start application in development mode 60 | 61 | ``yarn build`` - build application into `/dist` directory 62 | 63 | ``yarn build:clean`` - remove prev `/dist` and build application 64 | 65 | ``yarn serve`` - serve `/dist` directory. Requires build application before run 66 | 67 | ## [Contributing](https://github.com/JincorTech/frontend-moon-wallet/blob/develop/CONTRIBUTING.md) 68 | 69 | ______________________________ 70 | 71 | [LICENSE](https://github.com/JincorTech/frontend-moon-wallet/blob/develop/LICENSE) @ [secret_tech](http://secrettech.io/) 72 | 73 | -------------------------------------------------------------------------------- /nginx/default.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80 default_server; 3 | listen [::]:80 default_server; 4 | root /usr/src/app/; 5 | location / { 6 | index index.html index.htm; 7 | autoindex off; 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /nginx/nginx-stage/default.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80 default_server; 3 | listen [::]:80 default_server; 4 | 5 | root /usr/src/app/dist; 6 | 7 | location / { 8 | index index.html index.htm; 9 | autoindex off; 10 | try_files $uri /index.html; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/assets/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secret-tech/frontend-moon-wallet/9e7989048b37a1e9c000eefb1fdc65eb427389e9/src/assets/favicon.png -------------------------------------------------------------------------------- /src/assets/fonts/Roboto/Roboto-Bold.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secret-tech/frontend-moon-wallet/9e7989048b37a1e9c000eefb1fdc65eb427389e9/src/assets/fonts/Roboto/Roboto-Bold.eot -------------------------------------------------------------------------------- /src/assets/fonts/Roboto/Roboto-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secret-tech/frontend-moon-wallet/9e7989048b37a1e9c000eefb1fdc65eb427389e9/src/assets/fonts/Roboto/Roboto-Bold.ttf -------------------------------------------------------------------------------- /src/assets/fonts/Roboto/Roboto-Bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secret-tech/frontend-moon-wallet/9e7989048b37a1e9c000eefb1fdc65eb427389e9/src/assets/fonts/Roboto/Roboto-Bold.woff -------------------------------------------------------------------------------- /src/assets/fonts/Roboto/Roboto-Bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secret-tech/frontend-moon-wallet/9e7989048b37a1e9c000eefb1fdc65eb427389e9/src/assets/fonts/Roboto/Roboto-Bold.woff2 -------------------------------------------------------------------------------- /src/assets/fonts/Roboto/Roboto-Regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secret-tech/frontend-moon-wallet/9e7989048b37a1e9c000eefb1fdc65eb427389e9/src/assets/fonts/Roboto/Roboto-Regular.eot -------------------------------------------------------------------------------- /src/assets/fonts/Roboto/Roboto-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secret-tech/frontend-moon-wallet/9e7989048b37a1e9c000eefb1fdc65eb427389e9/src/assets/fonts/Roboto/Roboto-Regular.ttf -------------------------------------------------------------------------------- /src/assets/fonts/Roboto/Roboto-Regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secret-tech/frontend-moon-wallet/9e7989048b37a1e9c000eefb1fdc65eb427389e9/src/assets/fonts/Roboto/Roboto-Regular.woff -------------------------------------------------------------------------------- /src/assets/fonts/Roboto/Roboto-Regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secret-tech/frontend-moon-wallet/9e7989048b37a1e9c000eefb1fdc65eb427389e9/src/assets/fonts/Roboto/Roboto-Regular.woff2 -------------------------------------------------------------------------------- /src/assets/fonts/Roboto/stylesheet.css: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: 'Roboto'; 3 | src: url('Roboto-Regular.eot'); 4 | src: url('Roboto-Regular.eot?#iefix') format('embedded-opentype'), 5 | url('Roboto-Regular.woff2') format('woff2'), 6 | url('Roboto-Regular.woff') format('woff'), 7 | url('Roboto-Regular.ttf') format('truetype'), 8 | url('Roboto-Regular.svg#Roboto-Regular') format('svg'); 9 | font-weight: normal; 10 | font-style: normal; 11 | } 12 | 13 | @font-face { 14 | font-family: 'Roboto'; 15 | src: url('Roboto-Bold.eot'); 16 | src: url('Roboto-Bold.eot?#iefix') format('embedded-opentype'), 17 | url('Roboto-Bold.woff2') format('woff2'), 18 | url('Roboto-Bold.woff') format('woff'), 19 | url('Roboto-Bold.ttf') format('truetype'), 20 | url('Roboto-Bold.svg#Roboto-Bold') format('svg'); 21 | font-weight: bold; 22 | font-style: normal; 23 | } 24 | -------------------------------------------------------------------------------- /src/assets/images/icons/flags/china.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 7 | 8 | 12 | 16 | 20 | 24 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | -------------------------------------------------------------------------------- /src/assets/images/icons/flags/en.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 7 | 8 | 10 | 12 | 14 | 16 | 17 | 18 | 20 | 22 | 24 | 26 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | -------------------------------------------------------------------------------- /src/assets/images/icons/flags/fr.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | -------------------------------------------------------------------------------- /src/assets/images/icons/flags/ge.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /src/assets/images/icons/flags/ru.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 7 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /src/assets/locales/en/auth.json: -------------------------------------------------------------------------------- 1 | { 2 | "backToLandingPage": "Back to landing page", 3 | "resetPassword": { 4 | "signIn": "Sign in", 5 | "notHaveAnAccount": "Not have an account?", 6 | "signUp": "Sign up!", 7 | "form": { 8 | "email": "Email", 9 | "verificationCode": "Verification code", 10 | "newPassword": "New password", 11 | "resetPassword": "Reset password", 12 | "verifyResetPassword": "Verify reset password", 13 | "setNewPassword": "Set new password" 14 | } 15 | }, 16 | "signUp": { 17 | "alreadyHaveAccount": "Already have account?", 18 | "signIn": "Sign in!", 19 | "form": { 20 | "name": "Name", 21 | "email": "Email", 22 | "password": "Password", 23 | "paymentPassword": "Payment password", 24 | "agreement": "Agree terms and conditions", 25 | "verificationCode": "Verification code", 26 | "signUp": "Sign up", 27 | "verifySignUp": "Verify sign up" 28 | } 29 | }, 30 | "signIn": { 31 | "forgotPassword": "Forgot password?", 32 | "notHaveAnAccount": "Not have an account?", 33 | "signUp": "Sign up!", 34 | "form": { 35 | "email": "Email", 36 | "password": "Password", 37 | "verificationCode": "Verification code", 38 | "signIn": "Sign in", 39 | "verifySignIn": "Verify sign in" 40 | } 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /src/assets/locales/en/common.json: -------------------------------------------------------------------------------- 1 | { 2 | "themes": { 3 | "light": "Light theme", 4 | "dark": "Dark theme" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /src/assets/locales/en/wallet.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Transactions", 3 | "balances": { 4 | "title": "Balances", 5 | "transferButton": "Transfer tokens", 6 | "depositButton": "Deposit funds", 7 | "balance": "balance" 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/assets/locales/en/wallets.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Wallets", 3 | "walletsList": { 4 | "notFound": { 5 | "title": "No wallets here", 6 | "text": "Let's try to create or import new one" 7 | } 8 | }, 9 | "walletsControls": { 10 | "createButton": "Create new wallet" 11 | }, 12 | "createWalletPopup": { 13 | "title": "Create wallet" 14 | }, 15 | "createWalletForm": { 16 | "submit": "Create" 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/assets/locales/ru/auth.json: -------------------------------------------------------------------------------- 1 | { 2 | "backToLandingPage": "Вернуться на главную", 3 | "resetPassword": { 4 | "signIn": "Войти", 5 | "notHaveAnAccount": "Нет аккаунта?", 6 | "signUp": "Зарегестрироваться!", 7 | "form": { 8 | "email": "Электропочта", 9 | "verificationCode": "Пин код", 10 | "newPassword": "Новый пароль", 11 | "resetPassword": "Сбросить пароль", 12 | "verifyResetPassword": "Подтвердить сброс пароля", 13 | "setNewPassword": "Сохранить новый пароль" 14 | } 15 | }, 16 | "signUp": { 17 | "alreadyHaveAccount": "Уже есть аккаунт?", 18 | "signIn": "Войти!", 19 | "form": { 20 | "name": "Имя", 21 | "email": "Электропочта", 22 | "password": "Пароль", 23 | "paymentPassword": "Платежный пароль", 24 | "agreement": "Принимаю правила", 25 | "verificationCode": "Пин код", 26 | "signUp": "Зарегестрироваться", 27 | "verifySignUp": "Подтвердить регистрацию" 28 | } 29 | }, 30 | "signIn": { 31 | "forgotPassword": "Забыли пароль?", 32 | "notHaveAnAccount": "Нет аккаунта?", 33 | "signUp": "Зарегестрироваться!", 34 | "form": { 35 | "email": "Электропочта", 36 | "password": "Пароль", 37 | "verificationCode": "Пин код", 38 | "signIn": "Войти", 39 | "verifySignIn": "Подтвердить вход" 40 | } 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /src/assets/locales/ru/common.json: -------------------------------------------------------------------------------- 1 | { 2 | "themes": { 3 | "light": "Светлая тема", 4 | "dark": "Темная тема" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /src/assets/locales/ru/wallets.json: -------------------------------------------------------------------------------- 1 | { 2 | "walletsList": { 3 | "notFound": { 4 | "title": "Нет кошельков", 5 | "text": "Создайте новый кошелек" 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /src/assets/main.css: -------------------------------------------------------------------------------- 1 | .pt-dark, 2 | .pt-dark h1, 3 | .pt-dark h2, 4 | .pt-dark h3, 5 | .pt-dark h4, 6 | .pt-dark h5, 7 | .pt-dark h6 { 8 | color: #f5f8fa; 9 | } 10 | -------------------------------------------------------------------------------- /src/components/_forms/RenderCheckbox/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | import { Checkbox } from '@blueprintjs/core'; 4 | 5 | const RenderCheckbox = (props) => { 6 | const { 7 | input, 8 | meta, 9 | ...restProps 10 | } = props; 11 | 12 | return ( 13 |
14 | 15 |
16 | ); 17 | }; 18 | 19 | export default RenderCheckbox; 20 | -------------------------------------------------------------------------------- /src/components/_forms/RenderInput/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import classnames from 'classnames/bind'; 3 | 4 | const RenderInput = (props) => { 5 | const { 6 | label, 7 | input, 8 | meta, 9 | icon, 10 | large, 11 | fill, 12 | ...restProps 13 | } = props; 14 | 15 | const { 16 | error, 17 | invalid, 18 | active, 19 | dirty 20 | } = meta; 21 | 22 | const isInvalid = () => { 23 | if (!active && invalid && dirty) return true; 24 | if (!invalid) return false; 25 | 26 | return null; 27 | }; 28 | 29 | const inputClassName = classnames( 30 | 'pt-input', 31 | large ? 'pt-large' : null, 32 | fill ? 'pt-fill' : null, 33 | isInvalid() ? 'pt-intent-danger' : null 34 | ); 35 | 36 | const formGroupClassName = classnames( 37 | 'pt-form-group', 38 | isInvalid() ? 'pt-intent-danger' : null 39 | ); 40 | 41 | return ( 42 |
43 | {label 44 | ? () 47 | : null} 48 |
49 | 50 | {isInvalid() ?
{error}
: null} 51 |
52 |
53 | ); 54 | }; 55 | 56 | export default RenderInput; 57 | -------------------------------------------------------------------------------- /src/components/_forms/RenderNumber/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { NumericInput } from '@blueprintjs/core'; 3 | 4 | const RenderNumber = (props) => { 5 | const { 6 | label, 7 | input, 8 | meta, 9 | icon, 10 | ...restProps 11 | } = props; 12 | 13 | return ( 14 |
15 | {label 16 | ? () 19 | : null} 20 |
21 | 22 |
23 |
24 | ); 25 | }; 26 | 27 | export default RenderNumber; 28 | -------------------------------------------------------------------------------- /src/components/_forms/RenderPassword/index.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import classnames from 'classnames/bind'; 3 | 4 | import { Button } from '@blueprintjs/core'; 5 | 6 | import s from './styles.css'; 7 | 8 | class RenderPassword extends Component { 9 | constructor(props) { 10 | super(props); 11 | 12 | this.state = { type: 'password' }; 13 | } 14 | 15 | render() { 16 | const { 17 | label, 18 | input, 19 | meta, 20 | icon, 21 | large, 22 | fill, 23 | tip, 24 | ...restProps 25 | } = this.props; 26 | 27 | const { 28 | error, 29 | invalid, 30 | active, 31 | dirty 32 | } = meta; 33 | 34 | const isInvalid = () => { 35 | if (!active && invalid && dirty) return true; 36 | if (!invalid) return false; 37 | 38 | return null; 39 | }; 40 | 41 | const formGroupClassName = classnames( 42 | 'pt-form-group', 43 | isInvalid() ? 'pt-intent-danger' : null 44 | ); 45 | 46 | const inputGroupClassName = classnames( 47 | 'pt-input-group', 48 | large ? 'pt-large' : null, 49 | fill ? 'pt-fill' : null 50 | ); 51 | 52 | const inputClassName = classnames( 53 | 'pt-input', 54 | fill ? 'pt-fill' : null, 55 | isInvalid() ? 'pt-intent-danger' : null 56 | ); 57 | 58 | const buttonClassName = classnames( 59 | 'pt-minimal', 60 | large ? 'pt-large' : null 61 | ); 62 | 63 | const renderButton = () => { 64 | if (this.state.type === 'password') { 65 | return ( 66 |