diff --git a/.dockerignore b/.dockerignore index 9735aca..46f9cac 100644 --- a/.dockerignore +++ b/.dockerignore @@ -13,6 +13,7 @@ docker/ packages/*/node_modules packages/*/dist packages/*/coverage +packages/*/*.env* # TO-NEVER-DO: exclude the build folder of the contracts package, it's needed for building the application image. packages/concordia-app/build diff --git a/docker/README.md b/docker/README.md index 8f0d350..b069dd7 100644 --- a/docker/README.md +++ b/docker/README.md @@ -36,7 +36,7 @@ Furthermore, we provide an image that builds the contracts and handles their mig ### Ganache The Dockerfile is provided in the path `./ganache`. The image makes use of the environment variables described -bellow. +below. | Environment variable | Default value | Usage | | --- | --- | --- | @@ -66,7 +66,7 @@ This is a provision system that compiles and deploys the contracts to any Ethere A Dockerfile is provided in the path `./concordia-contracts` that will build the contracts used by Concordia and handle their deployment to any Ethereum network defined using env-vars upon container run. Dockerfile contains three -useful stages, described in the table bellow. +useful stages, described in the table below. | Stage name | Entrypoint | Usage | | --- | --- | --- | @@ -74,7 +74,7 @@ useful stages, described in the table bellow. | test | Runs contract tests | Compiles contracts and runs tests using blockchain defined by env vars | | runtime | Migrates contracts | Compiles contracts and migrates to the blockchain defined by env vars. Does **not** run tests | -The image makes use of the environment variables described bellow. +The image makes use of the environment variables described below. | Environment variable | Default value | Usage | | --- | --- | --- | @@ -92,7 +92,7 @@ the image. ### Application The Dockerfile provided in the path `./concordia-application` builds the application for production and serves -the resulting build using an nginx server. Dockerfile contains two useful stages, described in the table bellow. +the resulting build using an nginx server. Dockerfile contains two useful stages, described in the table below. | Stage name | Entrypoint | Usage | | --- | --- | --- | @@ -100,7 +100,7 @@ the resulting build using an nginx server. Dockerfile contains two useful stages | runtime | Serves application | Builds for production and serves it through nginx | -The image makes use of the environment variables described bellow. +The image makes use of the environment variables described below. | Environment variable | Default value | Usage | | --- | --- | --- | diff --git a/packages/concordia-app/.env.development.example b/packages/concordia-app/.env.development.example index eeeb884..4565811 100644 --- a/packages/concordia-app/.env.development.example +++ b/packages/concordia-app/.env.development.example @@ -7,6 +7,5 @@ HOST=localhost PORT=7000 # Variables needed in runtime (in browser) -# Carefull, IPFS won't accept localhost as a valid hostname REACT_APP_RENDEZVOUS_HOST=127.0.0.1 REACT_APP_RENDEZVOUS_PORT=9090 diff --git a/packages/concordia-app/package.json b/packages/concordia-app/package.json index 6645ee2..ef95c96 100644 --- a/packages/concordia-app/package.json +++ b/packages/concordia-app/package.json @@ -3,9 +3,9 @@ "version": "0.1.0", "private": true, "scripts": { - "start": "react-scripts start", - "build": "react-scripts build", - "test": "react-scripts test", + "start": "cross-env REACT_APP_VERSION=$npm_package_version REACT_APP_NAME=$npm_package_name react-scripts start", + "build": "cross-env REACT_APP_VERSION=$npm_package_version REACT_APP_NAME=$npm_package_name react-scripts build", + "test": "cross-env REACT_APP_VERSION=$npm_package_version REACT_APP_NAME=$npm_package_name react-scripts test", "eject": "react-scripts eject", "postinstall": "patch-package", "analyze": "react-scripts build && source-map-explorer 'build/static/js/*.js' --gzip", @@ -38,18 +38,20 @@ "react": "~16.13.1", "react-dom": "~16.13.1", "react-i18next": "^11.7.3", + "react-markdown": "^5.0.3", "react-particles-js": "^3.4.0", "react-redux": "~7.2.1", "react-router": "^5.2.0", "react-router-dom": "^5.2.0", "react-scripts": "~3.4.3", - "redux-saga": "~1.1.3", "react-timeago": "~5.2.0", + "redux-saga": "~1.1.3", "semantic-ui-css": "~2.4.1", "semantic-ui-react": "~1.2.1", "web3": "1.3.0" }, "devDependencies": { + "cross-env": "^7.0.3", "eslint": "^6.8.0", "eslint-config-airbnb": "^18.1.0", "eslint-plugin-import": "^2.20.2", diff --git a/packages/concordia-app/public/locales/en/translation.json b/packages/concordia-app/public/locales/en/translation.json index 74f1e18..33a1c4d 100644 --- a/packages/concordia-app/public/locales/en/translation.json +++ b/packages/concordia-app/public/locales/en/translation.json @@ -62,6 +62,7 @@ "register.form.sign.up.step.error.message.header": "Form contains errors", "register.form.sign.up.step.title": "Sign Up", "register.p.account.address": "Account address:", + "topbar.button.about": "About", "topbar.button.clear.databases": "Clear databases", "topbar.button.create.topic": "Create topic", "topbar.button.profile": "Profile", diff --git a/packages/concordia-app/src/Routes.jsx b/packages/concordia-app/src/Routes.jsx index 15a11b2..8a46785 100644 --- a/packages/concordia-app/src/Routes.jsx +++ b/packages/concordia-app/src/Routes.jsx @@ -39,6 +39,11 @@ const routesConfig = [ path: '/home', component: lazy(() => import('./views/Home')), }, + { + exact: true, + path: '/about', + component: lazy(() => import('./views/About')), + }, { exact: true, path: '/topics/:id(\\bnew\\b|\\d+)', diff --git a/packages/concordia-app/src/assets/About.md b/packages/concordia-app/src/assets/About.md new file mode 100644 index 0000000..b9a5885 --- /dev/null +++ b/packages/concordia-app/src/assets/About.md @@ -0,0 +1,35 @@ +# About Concordia + +## What + +Concordia is a forum platform (remember forums? 🤩) that focuses on user privacy and direct democratic voting. It is a +FOSS distributed via its Gitlab [repository][concordia-repository] and Docker [repository][concordia-docker-hub] under +the [MIT][concordia-license] license. + +## Why + +The value of privacy, freedom of speech and democracy are diminishing in modern software. Even more so in social media +platforms. Users are called to select between being the product of companies that sell their personal information and +being shut out of the modern, digital society. + +Concordia, much like other projects of this kind, provides an alternative to this predicament. + +## How + +Concordia uses decentralized technologies, namely the Ethereum blockchain and its smart contracts, as well as the +distributed database OrbitDB that's based on the decentralized network IPFS. These technologies make Concordia +impervious to censorship and guaranty the immutability of user information and anonymity while enabling user +authentication that makes trusted, direct voting possible. + +You can read more about the technological stack in Concordia's [whitepaper][concordia-whitepaper]. + +--- + +Developed by [apostolof][devs-apostolof-profile], [ezerous][devs-ezerous-profile] + +[concordia-repository]: https://gitlab.com/ecentrics/apella +[concordia-docker-hub]: https://hub.docker.com/repository/docker/ecentrics/apella-app +[concordia-license]: https://gitlab.com/ecentrics/apella/-/blob/master/LICENSE.md +[devs-apostolof-profile]: https://gitlab.com/Apostolof +[devs-ezerous-profile]: https://gitlab.com/Ezerous +[concordia-whitepaper]: https://whitepaper.concordia.ecentrics.net diff --git a/packages/concordia-app/src/assets/images/app_logo_circle.svg b/packages/concordia-app/src/assets/images/app_logo_circle.svg new file mode 100644 index 0000000..c1634d0 --- /dev/null +++ b/packages/concordia-app/src/assets/images/app_logo_circle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/concordia-app/src/layouts/MainLayout/MainLayoutMenu/index.jsx b/packages/concordia-app/src/layouts/MainLayout/MainLayoutMenu/index.jsx index cd79a9a..0a52901 100644 --- a/packages/concordia-app/src/layouts/MainLayout/MainLayoutMenu/index.jsx +++ b/packages/concordia-app/src/layouts/MainLayout/MainLayoutMenu/index.jsx @@ -35,7 +35,7 @@ const MainLayoutMenu = () => { link name="home" key="home" - onClick={() => { history.push('/'); }} + onClick={() => history.push('/')} > @@ -45,7 +45,7 @@ const MainLayoutMenu = () => { link name="create-topic" key="create-topic" - onClick={() => { history.push('/topics/new'); }} + onClick={() => history.push('/topics/new')} position="right" > {t('topbar.button.create.topic')} @@ -57,7 +57,7 @@ const MainLayoutMenu = () => { link name="profile" key="profile" - onClick={() => { history.push('/profile'); }} + onClick={() => history.push('/profile')} > {t('topbar.button.profile')} @@ -67,16 +67,23 @@ const MainLayoutMenu = () => { link name="register" key="register" - onClick={() => { history.push('/auth/register'); }} + onClick={() => history.push('/auth/register')} > {t('topbar.button.register')} )} +