Skip to content

Commit

Permalink
Merge recent changes from RaidGuild repo
Browse files Browse the repository at this point in the history
  • Loading branch information
akolotov authored Feb 4, 2021
2 parents fda8689 + ca12f9f commit 9888f12
Show file tree
Hide file tree
Showing 102 changed files with 6,619 additions and 3,203 deletions.
4 changes: 3 additions & 1 deletion .firebaserc
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{
"projects": {
"default": "xdai-omnibridge"
"production": "xdai-omnibridge",
"sokol": "sokol-omnibridge",
"staging": "omnibridge-staging",
}
}
28 changes: 0 additions & 28 deletions .github/workflows/main.yml

This file was deleted.

54 changes: 54 additions & 0 deletions .github/workflows/production.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Build and Deploy to production
on:
push:
branches:
- master

jobs:
deploy:
name: Build & Deploy to production
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 12.x

- uses: actions/cache@v2
with:
path: '**/node_modules'
key: nodeModules-${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}

- name: Install Dependencies
run: yarn --frozen-lockfile
env:
CI: true

- name: Build
run: yarn react-app:build
env:
CI: true
REACT_APP_INFURA_ID: ${{ secrets.INFURA_ID }}
REACT_APP_HOME_NETWORK: xdai
REACT_APP_HOME_RPC_URL: https://rpc.xdaichain.com/
REACT_APP_ENABLE_REVERSED_BRIDGE: false
REACT_APP_DEBUG_LOGS: false
REACT_APP_TITLE: OmniBridge - %c
REACT_APP_DESCRIPTION: 'The OmniBridge multi-token extension for the Arbitrary Message Bridge between Ethereum and the xDai chain is the simplest way to transfer ANY ERC20/ERC677/ERC827 token to the xDai chain.'
REACT_APP_GAS_PRICE_SUPPLIER_URL: https://gasprice.poa.network/
REACT_APP_GAS_PRICE_SPEED_TYPE: fast
REACT_APP_GAS_PRICE_UPDATE_INTERVAL: 15000
REACT_APP_ETH_PRICE_API_URL: 'https://api.coingecko.com/api/v3/simple/price?ids=ethereum&vs_currencies=USD'
REACT_APP_ETH_PRICE_UPDATE_INTERVAL: 15000

- name: Deploy to Firebase
uses: w9jds/firebase-action@master
with:
args: deploy --only hosting --project production
env:
CI: true
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }}
51 changes: 51 additions & 0 deletions .github/workflows/sokol.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Build and Deploy Sokol
on:
push:
branches:
- develop

jobs:
deploy:
name: Build & Deploy Sokol
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 12.x

- uses: actions/cache@v2
with:
path: '**/node_modules'
key: nodeModules-${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}

- name: Install Dependencies
run: yarn --frozen-lockfile
env:
CI: true

- name: Build
run: yarn react-app:build
env:
CI: true
REACT_APP_INFURA_ID: ${{ secrets.PERSONAL_INFURA_ID }}
REACT_APP_HOME_NETWORK: sokol
REACT_APP_ENABLE_REVERSED_BRIDGE: true
REACT_APP_DEBUG_LOGS: true
REACT_APP_TITLE: OmniBridge - %c
REACT_APP_DESCRIPTION: 'The Sokol OmniBridge multi-token extension for the Arbitrary Message Bridge between Kovan Testnet and the POA Sokol Testnet is the simplest way to transfer ANY ERC20/ERC677/ERC827 token to and from the POA Sokol Testnet.'
REACT_APP_GAS_PRICE_FALLBACK_GWEI: 5
REACT_APP_ETH_PRICE_API_URL: 'https://api.coingecko.com/api/v3/simple/price?ids=ethereum&vs_currencies=USD'
REACT_APP_ETH_PRICE_UPDATE_INTERVAL: 15000

- name: Deploy to Firebase
uses: w9jds/firebase-action@master
with:
args: deploy --only hosting --project sokol
env:
CI: true
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }}
53 changes: 53 additions & 0 deletions .github/workflows/staging.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Build and Deploy xDai Staging
on:
push:
branches:
- staging

jobs:
deploy:
name: Build & Deploy xDai Staging
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 12.x

- uses: actions/cache@v2
with:
path: '**/node_modules'
key: nodeModules-${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}

- name: Install Dependencies
run: yarn --frozen-lockfile
env:
CI: true

- name: Build
run: yarn react-app:build
env:
CI: true
REACT_APP_INFURA_ID: ${{ secrets.PERSONAL_INFURA_ID }}
REACT_APP_HOME_NETWORK: xdai
REACT_APP_ENABLE_REVERSED_BRIDGE: false
REACT_APP_DEBUG_LOGS: true
REACT_APP_TITLE: OmniBridge - %c
REACT_APP_DESCRIPTION: 'The OmniBridge multi-token extension for the Arbitrary Message Bridge between Ethereum and the xDai chain is the simplest way to transfer ANY ERC20/ERC677/ERC827 token to the xDai chain.'
REACT_APP_GAS_PRICE_SUPPLIER_URL: https://gasprice.poa.network/
REACT_APP_GAS_PRICE_SPEED_TYPE: standard
REACT_APP_GAS_PRICE_UPDATE_INTERVAL: 15000
REACT_APP_ETH_PRICE_API_URL: 'https://api.coingecko.com/api/v3/simple/price?ids=ethereum&vs_currencies=USD'
REACT_APP_ETH_PRICE_UPDATE_INTERVAL: 15000

- name: Deploy to Firebase
uses: w9jds/firebase-action@master
with:
args: deploy --only hosting --project staging
env:
CI: true
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }}
51 changes: 42 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# xDAI omnibridge
# Omnibridge

The [multi-token extension](https://docs.tokenbridge.net/eth-xdai-amb-bridge/multi-token-extension) for the Arbitrary Message Bridge between Ethereum and the xDai chain is the simplest way to transfer ANY ERC20/ERC677/ERC827 token to the xDai chain.
The OmniBridge [multi-token extension](https://docs.tokenbridge.net/eth-xdai-amb-bridge/multi-token-extension) for the Arbitrary Message Bridge between Ethereum and the xDai chain is the simplest way to transfer ANY ERC20/ERC677/ERC827 token to the xDai chain.

## Project Structure

Expand All @@ -14,15 +14,15 @@ xdai-omnibridge
├── .firebaserc
├── .github
│   └── workflows
│   └── main.yml
│   ├── sokol.yml
│   └── staging.yml
├── .gitignore
├── .prettierrc.json
├── README.md
├── firebase.json
├── package.json
├── packages
│   ├── react-app
│   │   ├── README.md
│   │   ├── package.json
│   │   ├── public
│   │   │   ├── android-chrome-192x192.png
Expand All @@ -41,47 +41,76 @@ xdai-omnibridge
│   │   ├── App.jsx
│   │   ├── Routes.jsx
│   │   ├── assets
│   │   │   ├── advanced.svg
│   │   │   ├── alert.svg
│   │   │   ├── blue-tick.svg
│   │   │   ├── change-network.png
│   │   │   ├── claim.svg
│   │   │   ├── close.svg
│   │   │   ├── confirm-transfer.svg
│   │   │   ├── custom-token.svg
│   │   │   ├── details.svg
│   │   │   ├── down-triangle.svg
│   │   │   ├── drop-down.svg
│   │   │   ├── error.svg
│   │   │   ├── eth-logo.png
│   │   │   ├── eth.png
│   │   │   ├── info.svg
│   │   │   ├── loading.svg
│   │   │   ├── logo.svg
│   │   │   ├── multiple-claim.svg
│   │   │   ├── no-history.svg
│   │   │   ├── right-arrow.svg
│   │   │   ├── search.svg
│   │   │   ├── settings.svg
│   │   │   ├── transfer.svg
│   │   │   ├── unlock.svg
│   │   │   ├── up-triangle.svg
│   │   │   └── xdai-logo.png
│   │   ├── components
│   │   │   ├── AdvancedMenu.jsx
│   │   │   ├── BridgeHistory.jsx
│   │   │   ├── BridgeLoadingModal.jsx
│   │   │   ├── BridgeTokens.jsx
│   │   │   ├── ClaimTokensModal.jsx
│   │   │   ├── ClaimTransferModal.jsx
│   │   │   ├── ConfirmTransferModal.jsx
│   │   │   ├── ConnectWeb3.jsx
│   │   │   ├── CustomTokenModal.jsx
│   │   │   ├── DaiWarning.jsx
│   │   │   ├── ErrorBoundary.jsx
│   │   │   ├── ErrorModal.jsx
│   │   │   ├── Footer.jsx
│   │   │   ├── FromToken.jsx
│   │   │   ├── Header.jsx
│   │   │   ├── HistoryItem.jsx
│   │   │   ├── HistoryPagination.jsx
│   │   │   ├── Layout.jsx
│   │   │   ├── LoadingModal.jsx
│   │   │   ├── NetworkSelector.jsx
│   │   │   ├── Logo.jsx
│   │   │   ├── NeedsConfirmationModal.jsx
│   │   │   ├── NeedsTransactions.jsx
│   │   │   ├── NoHistory.jsx
│   │   │   ├── ProgressRing.jsx
│   │   │   ├── ReverseWarning.jsx
│   │   │   ├── SelectTokenModal.jsx
│   │   │   ├── SystemFeedback.jsx
│   │   │   ├── TermsOfServiceModal.jsx
│   │   │   ├── ToToken.jsx
│   │   │   ├── TokenSelectorModal.jsx
│   │   │   ├── TransferButton.jsx
│   │   │   ├── TxLink.jsx
│   │   │   ├── UnlockButton.jsx
│   │   │   ├── UpdateSettings.jsx
│   │   │   └── WalletSelector.jsx
│   │   ├── config.js
│   │   ├── contexts
│   │   │   ├── BridgeContext.jsx
│   │   │   └── Web3Context.jsx
│   │   ├── hooks
│   │   │   ├── useCurrentDay.js
│   │   │   ├── useFeeType.js
│   │   │   ├── useRewardAddress.js
│   │   │   ├── useTotalConfirms.js
│   │   │   └── useTransactionStatus.js
│   │   ├── icons
│   │   │   ├── DownArrowIcon.jsx
│   │   │   ├── ErrorIcon.jsx
Expand All @@ -93,17 +122,22 @@ xdai-omnibridge
│   │   │   ├── PlusIcon.jsx
│   │   │   ├── RaidGuildIcon.jsx
│   │   │   ├── RightIcon.jsx
│   │   │   ├── SettingsIcon.jsx
│   │   │   ├── TelegramIcon.jsx
│   │   │   ├── TwitterIcon.jsx
│   │   │   ├── WalletFilledIcon.jsx
│   │   │   ├── WalletIcon.jsx
│   │   │   └── XDaiIcon.jsx
│   │   ├── index.jsx
│   │   ├── lib
│   │   │   ├── amb.js
│   │   │   ├── bridge.js
│   │   │   ├── constants.jsx
│   │   │   ├── constants.js
│   │   │   ├── ethPrice.js
│   │   │   ├── gasPrice.js
│   │   │   ├── helpers.js
│   │   │   ├── history.js
│   │   │   ├── overrides.js
│   │   │   ├── providers.js
│   │   │   ├── proxy.js
│   │   │   ├── token.js
Expand All @@ -113,7 +147,6 @@ xdai-omnibridge
│   │   │   └── Home.jsx
│   │   └── theme.js
│   └── subgraph
│   ├── README.md
│   ├── config
│   │   ├── kovan.json
│   │   ├── mainnet.json
Expand Down
38 changes: 19 additions & 19 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "xdai-omnibridge",
"name": "omnibridge",
"version": "1.0.0",
"keywords": [
"ethereum",
Expand All @@ -9,24 +9,24 @@
],
"private": true,
"scripts": {
"subgraph:auth": "yarn workspace @project/subgraph auth",
"subgraph:codegen": "yarn workspace @project/subgraph codegen",
"subgraph:build": "yarn workspace @project/subgraph build",
"subgraph:prepare-kovan": "yarn workspace @project/subgraph prepare-kovan",
"subgraph:deploy-kovan": "yarn workspace @project/subgraph deploy-kovan",
"subgraph:prepare-sokol": "yarn workspace @project/subgraph prepare-sokol",
"subgraph:deploy-sokol": "yarn workspace @project/subgraph deploy-sokol",
"subgraph:prepare-xdai": "yarn workspace @project/subgraph prepare-xdai",
"subgraph:deploy-xdai": "yarn workspace @project/subgraph deploy-xdai",
"subgraph:prepare-mainnet": "yarn workspace @project/subgraph prepare-mainnet",
"subgraph:deploy-mainnet": "yarn workspace @project/subgraph deploy-mainnet",
"react-app:build": "yarn workspace @project/react-app build",
"react-app:eject": "yarn workspace @project/react-app eject",
"react-app:start": "yarn workspace @project/react-app start",
"react-app:test": "yarn workspace @project/react-app test",
"react-app:lint": "yarn workspace @project/react-app lint",
"subgraph:auth": "yarn workspace @omnibridge/subgraph auth",
"subgraph:codegen": "yarn workspace @omnibridge/subgraph codegen",
"subgraph:build": "yarn workspace @omnibridge/subgraph build",
"subgraph:prepare-kovan": "yarn workspace @omnibridge/subgraph prepare-kovan",
"subgraph:deploy-kovan": "yarn workspace @omnibridge/subgraph deploy-kovan",
"subgraph:prepare-sokol": "yarn workspace @omnibridge/subgraph prepare-sokol",
"subgraph:deploy-sokol": "yarn workspace @omnibridge/subgraph deploy-sokol",
"subgraph:prepare-xdai": "yarn workspace @omnibridge/subgraph prepare-xdai",
"subgraph:deploy-xdai": "yarn workspace @omnibridge/subgraph deploy-xdai",
"subgraph:prepare-mainnet": "yarn workspace @omnibridge/subgraph prepare-mainnet",
"subgraph:deploy-mainnet": "yarn workspace @omnibridge/subgraph deploy-mainnet",
"react-app:build": "yarn workspace @omnibridge/react-app build",
"react-app:eject": "yarn workspace @omnibridge/react-app eject",
"react-app:start": "yarn workspace @omnibridge/react-app start",
"react-app:test": "yarn workspace @omnibridge/react-app test",
"react-app:lint": "yarn workspace @omnibridge/react-app lint",
"lint": "eslint --ignore-path .gitignore \"./packages/**/*.{ts,tsx,js,jsx}\" --fix",
"format": "prettier --ignore-path .gitignore --write \"{*,**/*}.{ts,tsx,js,jsx,json,yml,yaml,md}\""
"format": "prettier --ignore-path .gitignore --write \"{*,**/*}.{ts,tsx,js,jsx,json,md}\""
},
"husky": {
"hooks": {
Expand Down Expand Up @@ -57,6 +57,6 @@
"license": "UNLICENSED",
"lint-staged": {
"*.{js,jsx}": "eslint --fix",
"*.{ts,tsx,js,jsx,json,yml,yaml,md}": "prettier --write"
"*.{ts,tsx,js,jsx,json,md}": "prettier --write"
}
}
Loading

0 comments on commit 9888f12

Please sign in to comment.