Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 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 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 | 5x 5x 5x 2x 13x 5x 2x | import { Pair, SwapIDL } from '@/declarations';
import { Principal } from '@dfinity/principal';
import { parseAllPairs } from 'integrations';
export const mockPair = ({
blockTimestampLast,
creator,
id,
kLast,
lptoken,
price0CumulativeLast,
price1CumulativeLast,
reserve0,
reserve1,
token0,
token1,
totalSupply,
}: Partial<Pair.Model> = {}): Pair.Model => {
return {
id: id || 'token0:token1',
price0CumulativeLast:
price0CumulativeLast || BigInt('169791302182046275273065174512383941'),
creator:
creator ||
Principal.fromText(
'4qehi-lqyo6-afz4c-hwqwo-lubfi-4evgk-5vrn5-rldx2-lheha-xs7a4-gae'
),
reserve0: reserve0 || BigInt('378214020982958035'),
reserve1: reserve1 || BigInt('2599045918344'),
lptoken:
lptoken || 'aanaa-xaaaa-aaaah-aaeiq-cai:utozz-siaaa-aaaam-qaaxq-cai',
totalSupply: totalSupply || BigInt('963930372035355'),
token0: token0 || 'aanaa-xaaaa-aaaah-aaeiq-cai',
token1: token1 || 'utozz-siaaa-aaaam-qaaxq-cai',
price1CumulativeLast:
price1CumulativeLast ||
BigInt('3595528899597139115174922580717493355824760828'),
kLast: kLast || BigInt('0'),
blockTimestampLast: blockTimestampLast || BigInt('1643382877493031694'),
};
};
export const mockAllPairsResponse = (): SwapIDL.PairInfoExt[] => [
{
id: 'aanaa-xaaaa-aaaah-aaeiq-cai:utozz-siaaa-aaaam-qaaxq-cai',
price0CumulativeLast: BigInt('109155824020700857063784541336863933'),
creator: Principal.fromText(
'4qehi-lqyo6-afz4c-hwqwo-lubfi-4evgk-5vrn5-rldx2-lheha-xs7a4-gae'
),
reserve0: BigInt('565778441300902550'),
reserve1: BigInt('3628629825164'),
lptoken: 'aanaa-xaaaa-aaaah-aaeiq-cai:utozz-siaaa-aaaam-qaaxq-cai',
totalSupply: BigInt('1390958371708314'),
token0: 'aanaa-xaaaa-aaaah-aaeiq-cai',
token1: 'utozz-siaaa-aaaam-qaaxq-cai',
price1CumulativeLast: BigInt(
'2653715557084971846979439344462581521897640242'
),
kLast: BigInt('0'),
blockTimestampLast: BigInt('1643812963540835297'),
},
{
id: 'a7saq-3aaaa-aaaai-qbcdq-cai:wjsrf-myaaa-aaaam-qaayq-cai',
price0CumulativeLast: BigInt('103334672102411617944258660971823473471340'),
creator: Principal.fromText(
'lkqmh-5vihe-t5x5j-smuot-vitei-tgfyx-losfh-bbud4-fp2rq-353dj-yqe'
),
reserve0: BigInt('97396835'),
reserve1: BigInt('84339953'),
lptoken: 'a7saq-3aaaa-aaaai-qbcdq-cai:wjsrf-myaaa-aaaam-qaayq-cai',
totalSupply: BigInt('90401944'),
token0: 'a7saq-3aaaa-aaaai-qbcdq-cai',
token1: 'wjsrf-myaaa-aaaam-qaayq-cai',
price1CumulativeLast: BigInt('137806291317899640340088878161901233279230'),
kLast: BigInt('8207934346650000'),
blockTimestampLast: BigInt('1639001350592394056'),
},
{
id: 'oexpe-biaaa-aaaah-qcf6q-cai:wjsrf-myaaa-aaaam-qaayq-cai',
price0CumulativeLast: BigInt('0'),
creator: Principal.fromText('2vxsx-fae'),
reserve0: BigInt('0'),
reserve1: BigInt('0'),
lptoken: 'oexpe-biaaa-aaaah-qcf6q-cai:wjsrf-myaaa-aaaam-qaayq-cai',
totalSupply: BigInt('0'),
token0: 'oexpe-biaaa-aaaah-qcf6q-cai',
token1: 'wjsrf-myaaa-aaaam-qaayq-cai',
price1CumulativeLast: BigInt('0'),
kLast: BigInt('0'),
blockTimestampLast: BigInt('0'),
},
{
id: 'cfoim-fqaaa-aaaai-qbcmq-cai:xe4vl-dqaaa-aaaam-qaa7a-cai',
price0CumulativeLast: BigInt('0'),
creator: Principal.fromText('2vxsx-fae'),
reserve0: BigInt('0'),
reserve1: BigInt('0'),
lptoken: 'cfoim-fqaaa-aaaai-qbcmq-cai:xe4vl-dqaaa-aaaam-qaa7a-cai',
totalSupply: BigInt('0'),
token0: 'cfoim-fqaaa-aaaai-qbcmq-cai',
token1: 'xe4vl-dqaaa-aaaam-qaa7a-cai',
price1CumulativeLast: BigInt('0'),
kLast: BigInt('0'),
blockTimestampLast: BigInt('0'),
},
{
id: 'a7saq-3aaaa-aaaai-qbcdq-cai:cfoim-fqaaa-aaaai-qbcmq-cai',
price0CumulativeLast: BigInt(
'55829381825894764350487484407522750263915544'
),
creator: Principal.fromText(
'tqjnl-eteua-vbnza-3yuzm-a3pnk-mk7zw-ehhwr-eert4-dhlhu-aycmo-zae'
),
reserve0: BigInt('1351108753'),
reserve1: BigInt('2188009872'),
lptoken: 'a7saq-3aaaa-aaaai-qbcdq-cai:cfoim-fqaaa-aaaai-qbcmq-cai',
totalSupply: BigInt('1700199266'),
token0: 'a7saq-3aaaa-aaaai-qbcdq-cai',
token1: 'cfoim-fqaaa-aaaai-qbcmq-cai',
price1CumulativeLast: BigInt(
'21288491078524716889706976605438884419345868'
),
kLast: BigInt('2954492946802563695'),
blockTimestampLast: BigInt('1639609398465893790'),
},
{
id: 'oexpe-biaaa-aaaah-qcf6q-cai:onuey-xaaaa-aaaah-qcf7a-cai',
price0CumulativeLast: BigInt('0'),
creator: Principal.fromText(
'4qehi-lqyo6-afz4c-hwqwo-lubfi-4evgk-5vrn5-rldx2-lheha-xs7a4-gae'
),
reserve0: BigInt('5000000000000'),
reserve1: BigInt('5000000000000'),
lptoken: 'oexpe-biaaa-aaaah-qcf6q-cai:onuey-xaaaa-aaaah-qcf7a-cai',
totalSupply: BigInt('4999999999000'),
token0: 'oexpe-biaaa-aaaah-qcf6q-cai',
token1: 'onuey-xaaaa-aaaah-qcf7a-cai',
price1CumulativeLast: BigInt('0'),
kLast: BigInt('25000000000000000000000000'),
blockTimestampLast: BigInt('1636524536787902866'),
},
{
id: 'gagfc-iqaaa-aaaah-qcdvq-cai:gvbup-jyaaa-aaaah-qcdwa-cai',
price0CumulativeLast: BigInt(
'75860386083320136473922812321869497466131066'
),
creator: Principal.fromText(
'4qehi-lqyo6-afz4c-hwqwo-lubfi-4evgk-5vrn5-rldx2-lheha-xs7a4-gae'
),
reserve0: BigInt('4949571804783'),
reserve1: BigInt('5051500000000'),
lptoken: 'gagfc-iqaaa-aaaah-qcdvq-cai:gvbup-jyaaa-aaaah-qcdwa-cai',
totalSupply: BigInt('5000199998998'),
token0: 'gagfc-iqaaa-aaaah-qcdvq-cai',
token1: 'gvbup-jyaaa-aaaah-qcdwa-cai',
price1CumulativeLast: BigInt(
'72829879624849960903550725329066824091591549'
),
kLast: BigInt('25002000040000000000000000'),
blockTimestampLast: BigInt('1636555135500526085'),
},
{
id: 'gagfc-iqaaa-aaaah-qcdvq-cai:onuey-xaaaa-aaaah-qcf7a-cai',
price0CumulativeLast: BigInt('4954335781000000000000000000000000000000'),
creator: Principal.fromText(
'4qehi-lqyo6-afz4c-hwqwo-lubfi-4evgk-5vrn5-rldx2-lheha-xs7a4-gae'
),
reserve0: BigInt('10000000000000'),
reserve1: BigInt('10000000000000'),
lptoken: 'gagfc-iqaaa-aaaah-qcdvq-cai:onuey-xaaaa-aaaah-qcf7a-cai',
totalSupply: BigInt('9999999998000'),
token0: 'gagfc-iqaaa-aaaah-qcdvq-cai',
token1: 'onuey-xaaaa-aaaah-qcf7a-cai',
price1CumulativeLast: BigInt('4954335781000000000000000000000000000000'),
kLast: BigInt('100000000000000000000000000'),
blockTimestampLast: BigInt('1636524565869303906'),
},
{
id: 'gagfc-iqaaa-aaaah-qcdvq-cai:oexpe-biaaa-aaaah-qcf6q-cai',
price0CumulativeLast: BigInt('0'),
creator: Principal.fromText(
'4qehi-lqyo6-afz4c-hwqwo-lubfi-4evgk-5vrn5-rldx2-lheha-xs7a4-gae'
),
reserve0: BigInt('5000000000000'),
reserve1: BigInt('5000000000000'),
lptoken: 'gagfc-iqaaa-aaaah-qcdvq-cai:oexpe-biaaa-aaaah-qcf6q-cai',
totalSupply: BigInt('4999999999000'),
token0: 'gagfc-iqaaa-aaaah-qcdvq-cai',
token1: 'oexpe-biaaa-aaaah-qcf6q-cai',
price1CumulativeLast: BigInt('0'),
kLast: BigInt('25000000000000000000000000'),
blockTimestampLast: BigInt('1636523989958558122'),
},
];
export const mockPairList = (): Pair.List =>
parseAllPairs(mockAllPairsResponse());
|