Skip to content

Commit

Permalink
Merge pull request #226 from QuickSwap/dev
Browse files Browse the repository at this point in the history
Merge updates in analytics pages to beta
  • Loading branch information
sameepsi authored Jul 11, 2022
2 parents 43bfbfc + 252eab6 commit f1c4428
Show file tree
Hide file tree
Showing 28 changed files with 640 additions and 539 deletions.
3 changes: 2 additions & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@ REACT_APP_PORTIS_ID="e086c1f2-2d26-4443-804f-3398bbab069e"
REACT_APP_FORTMATIC_KEY="pk_live_F937DF033A1666BF"
REACT_APP_MOONPAY_KEY="pk_live_72EGoobLnlgc8WB7AaxyiWu2S43dj8eY"
REACT_APP_TRANSAK_KEY="258960cf-1e17-4419-bf7f-77443282f5da"
REACT_APP_GRAPH_API_URL="https://polygon.furadao.org/subgraphs/name/quickswap"
REACT_APP_GRAPH_API_URL="https://api.fura.org/subgraphs/name/quickswap"
REACT_APP_PRDT_URL="https://prdt-quickswap-main.pages.dev/"
REACT_APP_SCAN_BASE_URL="https://polygonscan.com"
REACT_APP_TOKEN_LIST_DEFAULT_URL="https://unpkg.com/quickswap-default-token-list@latest/build/quickswap-default.tokenlist.json"
REACT_APP_STAKING_LIST_DEFAULT_URL="https://unpkg.com/quickswap-default-staking-list@latest/build/quickswap-default.lpfarms.json"
REACT_APP_DUAL_STAKING_LIST_DEFAULT_URL="https://unpkg.com/quickswap-default-staking-list@latest/build/quickswap-default.dualfarms.json"
REACT_APP_SYRUP_LIST_DEFAULT_URL="https://unpkg.com/quickswap-default-staking-list@latest/build/quickswap-default.syrups.json"
REACT_APP_LEGACY_APP_URL="https://legacy.quickswap.exchange"
2 changes: 1 addition & 1 deletion .env.production
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ REACT_APP_FORTMATIC_KEY="pk_live_F937DF033A1666BF"
REACT_APP_GOOGLE_ANALYTICS_ID="UA-188438708-1"
REACT_APP_MOONPAY_KEY="pk_live_72EGoobLnlgc8WB7AaxyiWu2S43dj8eY"
REACT_APP_TRANSAK_KEY="258960cf-1e17-4419-bf7f-77443282f5da"
REACT_APP_GRAPH_API_URL="https://polygon.furadao.org/subgraphs/name/quickswap"
REACT_APP_GRAPH_API_URL="https://api.fura.org/subgraphs/name/quickswap"
4 changes: 2 additions & 2 deletions public/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@
"transactionsWillAppear": "Your transactions will appear here",
"copied": "Copied",
"showPortis": "Show Portis",
"betaWarningDesc": "This site is in beta. By using this software, you understand, acknowledge and accept that Quickswap and/or the underlying software are provided “as is” and “as available” basis and without warranties or representations of any kind either expressed or implied.",
"betaWarningDesc": "You're on the new productions site if you'd like to use the old site please navigate to: ",
"fiatProviders": "Fiat gateway providers",
"buy": "Buy",
"fiatServiceDesc": "Fiat services on Quickswap are provided by third-parties. Quickswap is not associated with, responsible or liable for the performance of these third-party services. Any claims & questions should be addressed with the selected provider.",
Expand Down Expand Up @@ -288,7 +288,7 @@
"timeRemaining": "Time Remaining",
"rewardsEnded": "Rewards Ended",
"24hPer": "24H %",
"24hTopMovers": "24h TOP MOVERS",
"24hMostVolume": "24h MOST VOLUME",
"waitingConfirm": "Waiting For Confirmation",
"confirmTxinWallet": "Please confirm this transaction in your wallet.",
"txSubmitted": "Transaction Submitted",
Expand Down
28 changes: 10 additions & 18 deletions src/apollo/queries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ export const TOKEN_SEARCH = gql`
symbol
name
decimals
tradeVolumeUSD
totalLiquidity
}
asName: tokens(
Expand All @@ -40,6 +41,7 @@ export const TOKEN_SEARCH = gql`
symbol
name
decimals
tradeVolumeUSD
totalLiquidity
}
asAddress: tokens(
Expand All @@ -51,6 +53,7 @@ export const TOKEN_SEARCH = gql`
symbol
name
decimals
tradeVolumeUSD
totalLiquidity
}
}
Expand All @@ -60,6 +63,7 @@ export const PAIR_SEARCH = gql`
query pairs($tokens: [Bytes]!, $id: String) {
as0: pairs(where: { token0_in: $tokens }) {
id
trackedReserveETH
token0 {
id
symbol
Expand All @@ -75,6 +79,7 @@ export const PAIR_SEARCH = gql`
}
as1: pairs(where: { token1_in: $tokens }) {
id
trackedReserveETH
token0 {
id
symbol
Expand All @@ -90,6 +95,7 @@ export const PAIR_SEARCH = gql`
}
asAddress: pairs(where: { id: $id }) {
id
trackedReserveETH
token0 {
id
symbol
Expand Down Expand Up @@ -219,6 +225,7 @@ export const ALL_TOKENS = gql`
name
symbol
decimals
tradeVolumeUSD
totalLiquidity
}
}
Expand All @@ -233,6 +240,7 @@ export const ALL_PAIRS = gql`
orderDirection: desc
) {
id
trackedReserveETH
token0 {
id
symbol
Expand Down Expand Up @@ -418,10 +426,10 @@ export const TOKEN_DATA1: any = (
export const TOKEN_DATA2: any = (tokenAddress: string) => {
const queryString = `
query tokens {
pairs0: pairs(where: {token0: "${tokenAddress}"}, first: 100, orderBy: reserveUSD, orderDirection: desc){
pairs0: pairs(where: {token0: "${tokenAddress}"}, first: 50, orderBy: reserveUSD, orderDirection: desc){
id
}
pairs1: pairs(where: {token1: "${tokenAddress}"}, first: 100, orderBy: reserveUSD, orderDirection: desc){
pairs1: pairs(where: {token1: "${tokenAddress}"}, first: 50, orderBy: reserveUSD, orderDirection: desc){
id
}
}
Expand Down Expand Up @@ -462,22 +470,6 @@ export const ETH_PRICE: any = (block?: number) => {
return gql(queryString);
};

export const ETH_ALLPRICE: any = (block?: number) => {
const queryString = `
query bundles {
oneDayBackPrice: bundles(where: { id: ${GlobalConst.utils.BUNDLE_ID} } block: {number: ${block}}) {
id
ethPrice
}
currentPrice: bundles(where: { id: ${GlobalConst.utils.BUNDLE_ID} }) {
id
ethPrice
}
}
`;
return gql(queryString);
};

export const PAIRS_HISTORICAL_BULK: any = (block: number, pairs: any[]) => {
let pairsString = `[`;
pairs.map((pair) => {
Expand Down
Loading

0 comments on commit f1c4428

Please sign in to comment.