From 5f5e7bb83e71e9b21ff43a3bae6291f6917bd0e8 Mon Sep 17 00:00:00 2001 From: Nejc Date: Fri, 8 Dec 2023 10:50:10 +0100 Subject: [PATCH 01/58] chore: install --- package.json | 1 + yarn.lock | 16 ++++++++++++++++ 2 files changed, 17 insertions(+) diff --git a/package.json b/package.json index 3f860ebd..6fa51efd 100644 --- a/package.json +++ b/package.json @@ -22,6 +22,7 @@ "@heroicons/react": "^2.0.18", "@hookform/resolvers": "^2.9.11", "@pendulum-chain/api": "^0.3.1", + "@pendulum-chain/api-solang": "^0.0.6", "@polkadot/api": "^9.9.1", "@polkadot/api-base": "^9.9.1", "@polkadot/api-contract": "^9.9.1", diff --git a/yarn.lock b/yarn.lock index 9a0c40d9..77c1838e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3495,6 +3495,21 @@ __metadata: languageName: node linkType: hard +"@pendulum-chain/api-solang@npm:^0.0.6": + version: 0.0.6 + resolution: "@pendulum-chain/api-solang@npm:0.0.6" + peerDependencies: + "@polkadot/api": ^10.9.1 + "@polkadot/api-contract": ^10.9.1 + "@polkadot/keyring": ^12.3.2 + "@polkadot/types": ^10.9.1 + "@polkadot/types-codec": ^10.9.1 + "@polkadot/util": ^12.3.2 + "@polkadot/util-crypto": ^12.3.2 + checksum: 2c2d2b9d6360e9b867f0d3ae902ebb55d57780d9529306259fd6590aae70dfcd2d89aca7233412b93c7b1238d9557bf369ff8e2537cf724a0813cb381754d00a + languageName: node + linkType: hard + "@pendulum-chain/api@npm:^0.3.1": version: 0.3.8 resolution: "@pendulum-chain/api@npm:0.3.8" @@ -14697,6 +14712,7 @@ __metadata: "@heroicons/react": "npm:^2.0.18" "@hookform/resolvers": "npm:^2.9.11" "@pendulum-chain/api": "npm:^0.3.1" + "@pendulum-chain/api-solang": "npm:^0.0.6" "@pendulum-chain/types": "npm:^0.2.3" "@polkadot/api": "npm:^9.9.1" "@polkadot/api-base": "npm:^9.9.1" From 6a5c25ce03afaf2a6e7c9584fbd10d70c30b6907 Mon Sep 17 00:00:00 2001 From: Nejc Date: Tue, 19 Dec 2023 21:47:21 +0100 Subject: [PATCH 02/58] refactor: replace library --- src/shared/useContract.ts | 2 +- src/shared/useContractWrite.ts | 49 +++++++++++++++++++++++----------- 2 files changed, 35 insertions(+), 16 deletions(-) diff --git a/src/shared/useContract.ts b/src/shared/useContract.ts index dac586c3..cfa6cddd 100644 --- a/src/shared/useContract.ts +++ b/src/shared/useContract.ts @@ -1,3 +1,4 @@ +// https://www.npmjs.com/package/@pendulum-chain/api-solang?activeTab=readme /* eslint-disable @typescript-eslint/no-explicit-any */ /* eslint-disable @typescript-eslint/ban-types */ import { ApiPromise } from '@polkadot/api'; @@ -22,7 +23,6 @@ const getOptions = (options: ContractOpts | undefined, api: ApiPromise) => typeof options === 'function' ? options(api) : options || { - // { gasLimit: -1 } gasLimit: api.createType('WeightV2', gasDefaults), storageDepositLimit: null, }; diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index 565b48e3..088a447a 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -1,15 +1,13 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ /* eslint-disable @typescript-eslint/ban-types */ +import { Limits, messageCall } from '@pendulum-chain/api-solang'; import { ApiPromise } from '@polkadot/api'; -import { SubmittableResultValue } from '@polkadot/api-base/types'; -import { Abi, ContractPromise } from '@polkadot/api-contract'; -import { ContractOptions } from '@polkadot/api-contract/types'; +import { Abi } from '@polkadot/api-contract'; import { DispatchError, ExtrinsicStatus } from '@polkadot/types/interfaces'; import { MutationOptions, useMutation } from '@tanstack/react-query'; -import { useMemo, useState } from 'preact/compat'; +import { useState } from 'preact/compat'; import { createWriteOptions } from '../services/api/helpers'; import { useSharedState } from './Provider'; -import { parseTransactionError } from './helpers'; // TODO: fix/improve types export type TransactionsStatus = { @@ -24,7 +22,15 @@ export type UseContractWriteProps = R address?: string; method: string; args?: any[]; - options?: ContractOptions | ((api: ApiPromise) => ContractOptions); + options?: Limits | ((api: ApiPromise) => Limits); +}; + +const defaultLimits: Limits = { + gas: { + refTime: '18000000000', + proofSize: '1750000', + }, + storageDeposit: undefined, }; export const useContractWrite = >({ @@ -36,20 +42,17 @@ export const useContractWrite = >({ ...rest }: UseContractWriteProps) => { const { api, signer, address: walletAddress } = useSharedState(); - const [transaction, setTransaction] = useState(); - const contract = useMemo( - () => (api && address ? new ContractPromise(api, abi, address) : undefined), - [abi, address, api], - ); - const isReady = !!contract && !!api && !!walletAddress && !!signer; - const submit = async (submitArgs?: any[] | void) => { - if (!isReady) throw undefined; + + const isReady = !!abi && !!address && !!api && !!walletAddress && !!signer; + const submit = async (submitArgs?: any[] | void): Promise => { + if (!isReady) throw 'Missing data'; setTransaction({ status: 'Pending' }); const fnArgs = submitArgs || args || []; const contractOptions = (typeof options === 'function' ? options(api) : options) || createWriteOptions(api); - return new Promise((resolve, reject) => { + /** + * return new Promise((resolve, reject) => { const unsubPromise = contract.tx[method](contractOptions || {}, ...fnArgs) .signAndSend(walletAddress, { signer }, (result: SubmittableResultValue) => { const tx = { @@ -74,6 +77,22 @@ export const useContractWrite = >({ reject(err); }); }); + */ + return messageCall({ + abi: abi as Abi, + api, + callerAddress: address, + contractDeploymentAddress: '', + getSigner: () => + Promise.resolve({ + type: 'signer', + address: walletAddress, + signer: signer, + }), + messageName: method, + messageArguments: fnArgs, + limits: { ...defaultLimits, ...contractOptions }, + }); }; const mutation = useMutation(submit, rest); return { ...mutation, data: transaction, isReady }; From 3716ecc561e87b273766fd66b9b80b178b91dab5 Mon Sep 17 00:00:00 2001 From: Nejc Date: Tue, 26 Dec 2023 14:15:17 +0100 Subject: [PATCH 03/58] feat: filter indexer data --- gql/gql.ts | 12 +- gql/graphql.ts | 2834 ++++++++++++++++++++++++++- src/config/apps/nabla.ts | 20 +- src/hooks/nabla/useBackstopPools.ts | 13 +- src/hooks/nabla/useSwapPools.ts | 12 +- src/hooks/nabla/useTokens.ts | 12 +- src/shared/useContractWrite.ts | 1 + src/shared/useTokenApproval.ts | 7 +- vite.config.ts | 2 + 9 files changed, 2837 insertions(+), 76 deletions(-) diff --git a/gql/gql.ts b/gql/gql.ts index ede20cee..50876297 100644 --- a/gql/gql.ts +++ b/gql/gql.ts @@ -14,9 +14,9 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/ */ const documents = { "\n query getBackstopPool($id: String!) {\n backstopPoolById(id: $id) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n decimals\n id\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n decimals\n id\n name\n symbol\n }\n }\n id\n }\n }\n }\n": types.GetBackstopPoolDocument, - "\n query getBackstopPools {\n backstopPools(where: { paused_eq: false }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n decimals\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n }\n id\n }\n }\n }\n": types.GetBackstopPoolsDocument, - "\n query getSwapPools {\n swapPools(where: { paused_eq: false }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n name\n symbol\n decimals\n }\n router {\n id\n paused\n }\n backstop {\n id\n liabilities\n paused\n reserves\n totalSupply\n }\n }\n }\n": types.GetSwapPoolsDocument, - "\n query getTokens {\n nablaTokens {\n id\n name\n symbol\n decimals\n }\n }\n": types.GetTokensDocument, + "\n query getBackstopPools($ids: [String!]) {\n backstopPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n decimals\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n }\n id\n }\n }\n }\n": types.GetBackstopPoolsDocument, + "\n query getSwapPools($ids: [String!]) {\n swapPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n name\n symbol\n decimals\n }\n router {\n id\n paused\n }\n backstop {\n id\n liabilities\n paused\n reserves\n totalSupply\n }\n }\n }\n": types.GetSwapPoolsDocument, + "\n query getTokens($ids: [String!]) {\n nablaTokens(where: { id_in: $ids }) {\n id\n name\n symbol\n decimals\n }\n }\n": types.GetTokensDocument, }; /** @@ -40,15 +40,15 @@ export function graphql(source: "\n query getBackstopPool($id: String!) {\n /** * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. */ -export function graphql(source: "\n query getBackstopPools {\n backstopPools(where: { paused_eq: false }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n decimals\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n }\n id\n }\n }\n }\n"): (typeof documents)["\n query getBackstopPools {\n backstopPools(where: { paused_eq: false }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n decimals\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n }\n id\n }\n }\n }\n"]; +export function graphql(source: "\n query getBackstopPools($ids: [String!]) {\n backstopPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n decimals\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n }\n id\n }\n }\n }\n"): (typeof documents)["\n query getBackstopPools($ids: [String!]) {\n backstopPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n decimals\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n }\n id\n }\n }\n }\n"]; /** * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. */ -export function graphql(source: "\n query getSwapPools {\n swapPools(where: { paused_eq: false }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n name\n symbol\n decimals\n }\n router {\n id\n paused\n }\n backstop {\n id\n liabilities\n paused\n reserves\n totalSupply\n }\n }\n }\n"): (typeof documents)["\n query getSwapPools {\n swapPools(where: { paused_eq: false }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n name\n symbol\n decimals\n }\n router {\n id\n paused\n }\n backstop {\n id\n liabilities\n paused\n reserves\n totalSupply\n }\n }\n }\n"]; +export function graphql(source: "\n query getSwapPools($ids: [String!]) {\n swapPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n name\n symbol\n decimals\n }\n router {\n id\n paused\n }\n backstop {\n id\n liabilities\n paused\n reserves\n totalSupply\n }\n }\n }\n"): (typeof documents)["\n query getSwapPools($ids: [String!]) {\n swapPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n name\n symbol\n decimals\n }\n router {\n id\n paused\n }\n backstop {\n id\n liabilities\n paused\n reserves\n totalSupply\n }\n }\n }\n"]; /** * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. */ -export function graphql(source: "\n query getTokens {\n nablaTokens {\n id\n name\n symbol\n decimals\n }\n }\n"): (typeof documents)["\n query getTokens {\n nablaTokens {\n id\n name\n symbol\n decimals\n }\n }\n"]; +export function graphql(source: "\n query getTokens($ids: [String!]) {\n nablaTokens(where: { id_in: $ids }) {\n id\n name\n symbol\n decimals\n }\n }\n"): (typeof documents)["\n query getTokens($ids: [String!]) {\n nablaTokens(where: { id_in: $ids }) {\n id\n name\n symbol\n decimals\n }\n }\n"]; export function graphql(source: string) { return (documents as any)[source] ?? {}; diff --git a/gql/graphql.ts b/gql/graphql.ts index 80b1c990..f604d748 100644 --- a/gql/graphql.ts +++ b/gql/graphql.ts @@ -20,6 +20,8 @@ export type Scalars = { Bytes: { input: any; output: any; } /** A date-time string in simplified extended ISO 8601 format (YYYY-MM-DDTHH:mm:ss.sssZ) */ DateTime: { input: any; output: any; } + /** A scalar that can represent any JSON value */ + JSON: { input: any; output: any; } }; export type BackstopPool = { @@ -41,27 +43,49 @@ export type BackstopPoolEdge = { export enum BackstopPoolOrderByInput { IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiabilitiesAsc = 'liabilities_ASC', + LiabilitiesAscNullsFirst = 'liabilities_ASC_NULLS_FIRST', LiabilitiesDesc = 'liabilities_DESC', + LiabilitiesDescNullsLast = 'liabilities_DESC_NULLS_LAST', PausedAsc = 'paused_ASC', + PausedAscNullsFirst = 'paused_ASC_NULLS_FIRST', PausedDesc = 'paused_DESC', + PausedDescNullsLast = 'paused_DESC_NULLS_LAST', ReservesAsc = 'reserves_ASC', + ReservesAscNullsFirst = 'reserves_ASC_NULLS_FIRST', ReservesDesc = 'reserves_DESC', + ReservesDescNullsLast = 'reserves_DESC_NULLS_LAST', RouterIdAsc = 'router_id_ASC', + RouterIdAscNullsFirst = 'router_id_ASC_NULLS_FIRST', RouterIdDesc = 'router_id_DESC', + RouterIdDescNullsLast = 'router_id_DESC_NULLS_LAST', RouterPausedAsc = 'router_paused_ASC', + RouterPausedAscNullsFirst = 'router_paused_ASC_NULLS_FIRST', RouterPausedDesc = 'router_paused_DESC', + RouterPausedDescNullsLast = 'router_paused_DESC_NULLS_LAST', TokenDecimalsAsc = 'token_decimals_ASC', + TokenDecimalsAscNullsFirst = 'token_decimals_ASC_NULLS_FIRST', TokenDecimalsDesc = 'token_decimals_DESC', + TokenDecimalsDescNullsLast = 'token_decimals_DESC_NULLS_LAST', TokenIdAsc = 'token_id_ASC', + TokenIdAscNullsFirst = 'token_id_ASC_NULLS_FIRST', TokenIdDesc = 'token_id_DESC', + TokenIdDescNullsLast = 'token_id_DESC_NULLS_LAST', TokenNameAsc = 'token_name_ASC', + TokenNameAscNullsFirst = 'token_name_ASC_NULLS_FIRST', TokenNameDesc = 'token_name_DESC', + TokenNameDescNullsLast = 'token_name_DESC_NULLS_LAST', TokenSymbolAsc = 'token_symbol_ASC', + TokenSymbolAscNullsFirst = 'token_symbol_ASC_NULLS_FIRST', TokenSymbolDesc = 'token_symbol_DESC', + TokenSymbolDescNullsLast = 'token_symbol_DESC_NULLS_LAST', TotalSupplyAsc = 'totalSupply_ASC', - TotalSupplyDesc = 'totalSupply_DESC' + TotalSupplyAscNullsFirst = 'totalSupply_ASC_NULLS_FIRST', + TotalSupplyDesc = 'totalSupply_DESC', + TotalSupplyDescNullsLast = 'totalSupply_DESC_NULLS_LAST' } export type BackstopPoolWhereInput = { @@ -127,6 +151,272 @@ export type BackstopPoolsConnection = { totalCount: Scalars['Int']['output']; }; +export type Block = { + __typename?: 'Block'; + calls: Array; + callsCount: Scalars['Int']['output']; + events: Array; + eventsCount: Scalars['Int']['output']; + extrinsics: Array; + extrinsicsCount: Scalars['Int']['output']; + extrinsicsicRoot: Scalars['Bytes']['output']; + hash: Scalars['Bytes']['output']; + height: Scalars['Int']['output']; + /** BlockHeight-blockHash - e.g. 0001812319-0001c */ + id: Scalars['String']['output']; + implName: Scalars['String']['output']; + implVersion: Scalars['Int']['output']; + parentHash: Scalars['Bytes']['output']; + specName: Scalars['String']['output']; + specVersion: Scalars['Int']['output']; + stateRoot: Scalars['Bytes']['output']; + timestamp: Scalars['DateTime']['output']; + validator?: Maybe; +}; + + +export type BlockCallsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type BlockEventsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type BlockExtrinsicsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + +export type BlockEdge = { + __typename?: 'BlockEdge'; + cursor: Scalars['String']['output']; + node: Block; +}; + +export enum BlockOrderByInput { + CallsCountAsc = 'callsCount_ASC', + CallsCountAscNullsFirst = 'callsCount_ASC_NULLS_FIRST', + CallsCountDesc = 'callsCount_DESC', + CallsCountDescNullsLast = 'callsCount_DESC_NULLS_LAST', + EventsCountAsc = 'eventsCount_ASC', + EventsCountAscNullsFirst = 'eventsCount_ASC_NULLS_FIRST', + EventsCountDesc = 'eventsCount_DESC', + EventsCountDescNullsLast = 'eventsCount_DESC_NULLS_LAST', + ExtrinsicsCountAsc = 'extrinsicsCount_ASC', + ExtrinsicsCountAscNullsFirst = 'extrinsicsCount_ASC_NULLS_FIRST', + ExtrinsicsCountDesc = 'extrinsicsCount_DESC', + ExtrinsicsCountDescNullsLast = 'extrinsicsCount_DESC_NULLS_LAST', + ExtrinsicsicRootAsc = 'extrinsicsicRoot_ASC', + ExtrinsicsicRootAscNullsFirst = 'extrinsicsicRoot_ASC_NULLS_FIRST', + ExtrinsicsicRootDesc = 'extrinsicsicRoot_DESC', + ExtrinsicsicRootDescNullsLast = 'extrinsicsicRoot_DESC_NULLS_LAST', + HashAsc = 'hash_ASC', + HashAscNullsFirst = 'hash_ASC_NULLS_FIRST', + HashDesc = 'hash_DESC', + HashDescNullsLast = 'hash_DESC_NULLS_LAST', + HeightAsc = 'height_ASC', + HeightAscNullsFirst = 'height_ASC_NULLS_FIRST', + HeightDesc = 'height_DESC', + HeightDescNullsLast = 'height_DESC_NULLS_LAST', + IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', + IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', + ImplNameAsc = 'implName_ASC', + ImplNameAscNullsFirst = 'implName_ASC_NULLS_FIRST', + ImplNameDesc = 'implName_DESC', + ImplNameDescNullsLast = 'implName_DESC_NULLS_LAST', + ImplVersionAsc = 'implVersion_ASC', + ImplVersionAscNullsFirst = 'implVersion_ASC_NULLS_FIRST', + ImplVersionDesc = 'implVersion_DESC', + ImplVersionDescNullsLast = 'implVersion_DESC_NULLS_LAST', + ParentHashAsc = 'parentHash_ASC', + ParentHashAscNullsFirst = 'parentHash_ASC_NULLS_FIRST', + ParentHashDesc = 'parentHash_DESC', + ParentHashDescNullsLast = 'parentHash_DESC_NULLS_LAST', + SpecNameAsc = 'specName_ASC', + SpecNameAscNullsFirst = 'specName_ASC_NULLS_FIRST', + SpecNameDesc = 'specName_DESC', + SpecNameDescNullsLast = 'specName_DESC_NULLS_LAST', + SpecVersionAsc = 'specVersion_ASC', + SpecVersionAscNullsFirst = 'specVersion_ASC_NULLS_FIRST', + SpecVersionDesc = 'specVersion_DESC', + SpecVersionDescNullsLast = 'specVersion_DESC_NULLS_LAST', + StateRootAsc = 'stateRoot_ASC', + StateRootAscNullsFirst = 'stateRoot_ASC_NULLS_FIRST', + StateRootDesc = 'stateRoot_DESC', + StateRootDescNullsLast = 'stateRoot_DESC_NULLS_LAST', + TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', + TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', + ValidatorAsc = 'validator_ASC', + ValidatorAscNullsFirst = 'validator_ASC_NULLS_FIRST', + ValidatorDesc = 'validator_DESC', + ValidatorDescNullsLast = 'validator_DESC_NULLS_LAST' +} + +export type BlockWhereInput = { + AND?: InputMaybe>; + OR?: InputMaybe>; + callsCount_eq?: InputMaybe; + callsCount_gt?: InputMaybe; + callsCount_gte?: InputMaybe; + callsCount_in?: InputMaybe>; + callsCount_isNull?: InputMaybe; + callsCount_lt?: InputMaybe; + callsCount_lte?: InputMaybe; + callsCount_not_eq?: InputMaybe; + callsCount_not_in?: InputMaybe>; + calls_every?: InputMaybe; + calls_none?: InputMaybe; + calls_some?: InputMaybe; + eventsCount_eq?: InputMaybe; + eventsCount_gt?: InputMaybe; + eventsCount_gte?: InputMaybe; + eventsCount_in?: InputMaybe>; + eventsCount_isNull?: InputMaybe; + eventsCount_lt?: InputMaybe; + eventsCount_lte?: InputMaybe; + eventsCount_not_eq?: InputMaybe; + eventsCount_not_in?: InputMaybe>; + events_every?: InputMaybe; + events_none?: InputMaybe; + events_some?: InputMaybe; + extrinsicsCount_eq?: InputMaybe; + extrinsicsCount_gt?: InputMaybe; + extrinsicsCount_gte?: InputMaybe; + extrinsicsCount_in?: InputMaybe>; + extrinsicsCount_isNull?: InputMaybe; + extrinsicsCount_lt?: InputMaybe; + extrinsicsCount_lte?: InputMaybe; + extrinsicsCount_not_eq?: InputMaybe; + extrinsicsCount_not_in?: InputMaybe>; + extrinsics_every?: InputMaybe; + extrinsics_none?: InputMaybe; + extrinsics_some?: InputMaybe; + extrinsicsicRoot_eq?: InputMaybe; + extrinsicsicRoot_isNull?: InputMaybe; + extrinsicsicRoot_not_eq?: InputMaybe; + hash_eq?: InputMaybe; + hash_isNull?: InputMaybe; + hash_not_eq?: InputMaybe; + height_eq?: InputMaybe; + height_gt?: InputMaybe; + height_gte?: InputMaybe; + height_in?: InputMaybe>; + height_isNull?: InputMaybe; + height_lt?: InputMaybe; + height_lte?: InputMaybe; + height_not_eq?: InputMaybe; + height_not_in?: InputMaybe>; + id_contains?: InputMaybe; + id_containsInsensitive?: InputMaybe; + id_endsWith?: InputMaybe; + id_eq?: InputMaybe; + id_gt?: InputMaybe; + id_gte?: InputMaybe; + id_in?: InputMaybe>; + id_isNull?: InputMaybe; + id_lt?: InputMaybe; + id_lte?: InputMaybe; + id_not_contains?: InputMaybe; + id_not_containsInsensitive?: InputMaybe; + id_not_endsWith?: InputMaybe; + id_not_eq?: InputMaybe; + id_not_in?: InputMaybe>; + id_not_startsWith?: InputMaybe; + id_startsWith?: InputMaybe; + implName_contains?: InputMaybe; + implName_containsInsensitive?: InputMaybe; + implName_endsWith?: InputMaybe; + implName_eq?: InputMaybe; + implName_gt?: InputMaybe; + implName_gte?: InputMaybe; + implName_in?: InputMaybe>; + implName_isNull?: InputMaybe; + implName_lt?: InputMaybe; + implName_lte?: InputMaybe; + implName_not_contains?: InputMaybe; + implName_not_containsInsensitive?: InputMaybe; + implName_not_endsWith?: InputMaybe; + implName_not_eq?: InputMaybe; + implName_not_in?: InputMaybe>; + implName_not_startsWith?: InputMaybe; + implName_startsWith?: InputMaybe; + implVersion_eq?: InputMaybe; + implVersion_gt?: InputMaybe; + implVersion_gte?: InputMaybe; + implVersion_in?: InputMaybe>; + implVersion_isNull?: InputMaybe; + implVersion_lt?: InputMaybe; + implVersion_lte?: InputMaybe; + implVersion_not_eq?: InputMaybe; + implVersion_not_in?: InputMaybe>; + parentHash_eq?: InputMaybe; + parentHash_isNull?: InputMaybe; + parentHash_not_eq?: InputMaybe; + specName_contains?: InputMaybe; + specName_containsInsensitive?: InputMaybe; + specName_endsWith?: InputMaybe; + specName_eq?: InputMaybe; + specName_gt?: InputMaybe; + specName_gte?: InputMaybe; + specName_in?: InputMaybe>; + specName_isNull?: InputMaybe; + specName_lt?: InputMaybe; + specName_lte?: InputMaybe; + specName_not_contains?: InputMaybe; + specName_not_containsInsensitive?: InputMaybe; + specName_not_endsWith?: InputMaybe; + specName_not_eq?: InputMaybe; + specName_not_in?: InputMaybe>; + specName_not_startsWith?: InputMaybe; + specName_startsWith?: InputMaybe; + specVersion_eq?: InputMaybe; + specVersion_gt?: InputMaybe; + specVersion_gte?: InputMaybe; + specVersion_in?: InputMaybe>; + specVersion_isNull?: InputMaybe; + specVersion_lt?: InputMaybe; + specVersion_lte?: InputMaybe; + specVersion_not_eq?: InputMaybe; + specVersion_not_in?: InputMaybe>; + stateRoot_eq?: InputMaybe; + stateRoot_isNull?: InputMaybe; + stateRoot_not_eq?: InputMaybe; + timestamp_eq?: InputMaybe; + timestamp_gt?: InputMaybe; + timestamp_gte?: InputMaybe; + timestamp_in?: InputMaybe>; + timestamp_isNull?: InputMaybe; + timestamp_lt?: InputMaybe; + timestamp_lte?: InputMaybe; + timestamp_not_eq?: InputMaybe; + timestamp_not_in?: InputMaybe>; + validator_eq?: InputMaybe; + validator_isNull?: InputMaybe; + validator_not_eq?: InputMaybe; +}; + +export type BlocksConnection = { + __typename?: 'BlocksConnection'; + edges: Array; + pageInfo: PageInfo; + totalCount: Scalars['Int']['output']; +}; + export type Bundle = { __typename?: 'Bundle'; /** BigDecimal */ @@ -142,9 +432,13 @@ export type BundleEdge = { export enum BundleOrderByInput { EthPriceAsc = 'ethPrice_ASC', + EthPriceAscNullsFirst = 'ethPrice_ASC_NULLS_FIRST', EthPriceDesc = 'ethPrice_DESC', + EthPriceDescNullsLast = 'ethPrice_DESC_NULLS_LAST', IdAsc = 'id_ASC', - IdDesc = 'id_DESC' + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', + IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST' } export type BundleWhereInput = { @@ -219,69 +513,133 @@ export type BurnEdge = { export enum BurnOrderByInput { Amount0Asc = 'amount0_ASC', + Amount0AscNullsFirst = 'amount0_ASC_NULLS_FIRST', Amount0Desc = 'amount0_DESC', + Amount0DescNullsLast = 'amount0_DESC_NULLS_LAST', Amount1Asc = 'amount1_ASC', + Amount1AscNullsFirst = 'amount1_ASC_NULLS_FIRST', Amount1Desc = 'amount1_DESC', + Amount1DescNullsLast = 'amount1_DESC_NULLS_LAST', AmountUsdAsc = 'amountUSD_ASC', + AmountUsdAscNullsFirst = 'amountUSD_ASC_NULLS_FIRST', AmountUsdDesc = 'amountUSD_DESC', + AmountUsdDescNullsLast = 'amountUSD_DESC_NULLS_LAST', FeeLiquidityAsc = 'feeLiquidity_ASC', + FeeLiquidityAscNullsFirst = 'feeLiquidity_ASC_NULLS_FIRST', FeeLiquidityDesc = 'feeLiquidity_DESC', + FeeLiquidityDescNullsLast = 'feeLiquidity_DESC_NULLS_LAST', FeeToAsc = 'feeTo_ASC', + FeeToAscNullsFirst = 'feeTo_ASC_NULLS_FIRST', FeeToDesc = 'feeTo_DESC', + FeeToDescNullsLast = 'feeTo_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiquidityAsc = 'liquidity_ASC', + LiquidityAscNullsFirst = 'liquidity_ASC_NULLS_FIRST', LiquidityDesc = 'liquidity_DESC', + LiquidityDescNullsLast = 'liquidity_DESC_NULLS_LAST', LogIndexAsc = 'logIndex_ASC', + LogIndexAscNullsFirst = 'logIndex_ASC_NULLS_FIRST', LogIndexDesc = 'logIndex_DESC', + LogIndexDescNullsLast = 'logIndex_DESC_NULLS_LAST', NeedsCompleteAsc = 'needsComplete_ASC', + NeedsCompleteAscNullsFirst = 'needsComplete_ASC_NULLS_FIRST', NeedsCompleteDesc = 'needsComplete_DESC', + NeedsCompleteDescNullsLast = 'needsComplete_DESC_NULLS_LAST', PairCreatedAtBlockNumberAsc = 'pair_createdAtBlockNumber_ASC', + PairCreatedAtBlockNumberAscNullsFirst = 'pair_createdAtBlockNumber_ASC_NULLS_FIRST', PairCreatedAtBlockNumberDesc = 'pair_createdAtBlockNumber_DESC', + PairCreatedAtBlockNumberDescNullsLast = 'pair_createdAtBlockNumber_DESC_NULLS_LAST', PairCreatedAtTimestampAsc = 'pair_createdAtTimestamp_ASC', + PairCreatedAtTimestampAscNullsFirst = 'pair_createdAtTimestamp_ASC_NULLS_FIRST', PairCreatedAtTimestampDesc = 'pair_createdAtTimestamp_DESC', + PairCreatedAtTimestampDescNullsLast = 'pair_createdAtTimestamp_DESC_NULLS_LAST', PairIdAsc = 'pair_id_ASC', + PairIdAscNullsFirst = 'pair_id_ASC_NULLS_FIRST', PairIdDesc = 'pair_id_DESC', + PairIdDescNullsLast = 'pair_id_DESC_NULLS_LAST', PairLiquidityProviderCountAsc = 'pair_liquidityProviderCount_ASC', + PairLiquidityProviderCountAscNullsFirst = 'pair_liquidityProviderCount_ASC_NULLS_FIRST', PairLiquidityProviderCountDesc = 'pair_liquidityProviderCount_DESC', + PairLiquidityProviderCountDescNullsLast = 'pair_liquidityProviderCount_DESC_NULLS_LAST', PairReserve0Asc = 'pair_reserve0_ASC', + PairReserve0AscNullsFirst = 'pair_reserve0_ASC_NULLS_FIRST', PairReserve0Desc = 'pair_reserve0_DESC', + PairReserve0DescNullsLast = 'pair_reserve0_DESC_NULLS_LAST', PairReserve1Asc = 'pair_reserve1_ASC', + PairReserve1AscNullsFirst = 'pair_reserve1_ASC_NULLS_FIRST', PairReserve1Desc = 'pair_reserve1_DESC', + PairReserve1DescNullsLast = 'pair_reserve1_DESC_NULLS_LAST', PairReserveEthAsc = 'pair_reserveETH_ASC', + PairReserveEthAscNullsFirst = 'pair_reserveETH_ASC_NULLS_FIRST', PairReserveEthDesc = 'pair_reserveETH_DESC', + PairReserveEthDescNullsLast = 'pair_reserveETH_DESC_NULLS_LAST', PairReserveUsdAsc = 'pair_reserveUSD_ASC', + PairReserveUsdAscNullsFirst = 'pair_reserveUSD_ASC_NULLS_FIRST', PairReserveUsdDesc = 'pair_reserveUSD_DESC', + PairReserveUsdDescNullsLast = 'pair_reserveUSD_DESC_NULLS_LAST', PairToken0PriceAsc = 'pair_token0Price_ASC', + PairToken0PriceAscNullsFirst = 'pair_token0Price_ASC_NULLS_FIRST', PairToken0PriceDesc = 'pair_token0Price_DESC', + PairToken0PriceDescNullsLast = 'pair_token0Price_DESC_NULLS_LAST', PairToken1PriceAsc = 'pair_token1Price_ASC', + PairToken1PriceAscNullsFirst = 'pair_token1Price_ASC_NULLS_FIRST', PairToken1PriceDesc = 'pair_token1Price_DESC', + PairToken1PriceDescNullsLast = 'pair_token1Price_DESC_NULLS_LAST', PairTotalSupplyAsc = 'pair_totalSupply_ASC', + PairTotalSupplyAscNullsFirst = 'pair_totalSupply_ASC_NULLS_FIRST', PairTotalSupplyDesc = 'pair_totalSupply_DESC', + PairTotalSupplyDescNullsLast = 'pair_totalSupply_DESC_NULLS_LAST', PairTrackedReserveEthAsc = 'pair_trackedReserveETH_ASC', + PairTrackedReserveEthAscNullsFirst = 'pair_trackedReserveETH_ASC_NULLS_FIRST', PairTrackedReserveEthDesc = 'pair_trackedReserveETH_DESC', + PairTrackedReserveEthDescNullsLast = 'pair_trackedReserveETH_DESC_NULLS_LAST', PairTxCountAsc = 'pair_txCount_ASC', + PairTxCountAscNullsFirst = 'pair_txCount_ASC_NULLS_FIRST', PairTxCountDesc = 'pair_txCount_DESC', + PairTxCountDescNullsLast = 'pair_txCount_DESC_NULLS_LAST', PairUntrackedVolumeUsdAsc = 'pair_untrackedVolumeUSD_ASC', + PairUntrackedVolumeUsdAscNullsFirst = 'pair_untrackedVolumeUSD_ASC_NULLS_FIRST', PairUntrackedVolumeUsdDesc = 'pair_untrackedVolumeUSD_DESC', + PairUntrackedVolumeUsdDescNullsLast = 'pair_untrackedVolumeUSD_DESC_NULLS_LAST', PairVolumeToken0Asc = 'pair_volumeToken0_ASC', + PairVolumeToken0AscNullsFirst = 'pair_volumeToken0_ASC_NULLS_FIRST', PairVolumeToken0Desc = 'pair_volumeToken0_DESC', + PairVolumeToken0DescNullsLast = 'pair_volumeToken0_DESC_NULLS_LAST', PairVolumeToken1Asc = 'pair_volumeToken1_ASC', + PairVolumeToken1AscNullsFirst = 'pair_volumeToken1_ASC_NULLS_FIRST', PairVolumeToken1Desc = 'pair_volumeToken1_DESC', + PairVolumeToken1DescNullsLast = 'pair_volumeToken1_DESC_NULLS_LAST', PairVolumeUsdAsc = 'pair_volumeUSD_ASC', + PairVolumeUsdAscNullsFirst = 'pair_volumeUSD_ASC_NULLS_FIRST', PairVolumeUsdDesc = 'pair_volumeUSD_DESC', + PairVolumeUsdDescNullsLast = 'pair_volumeUSD_DESC_NULLS_LAST', SenderAsc = 'sender_ASC', + SenderAscNullsFirst = 'sender_ASC_NULLS_FIRST', SenderDesc = 'sender_DESC', + SenderDescNullsLast = 'sender_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', ToAsc = 'to_ASC', + ToAscNullsFirst = 'to_ASC_NULLS_FIRST', ToDesc = 'to_DESC', + ToDescNullsLast = 'to_DESC_NULLS_LAST', TransactionBlockNumberAsc = 'transaction_blockNumber_ASC', + TransactionBlockNumberAscNullsFirst = 'transaction_blockNumber_ASC_NULLS_FIRST', TransactionBlockNumberDesc = 'transaction_blockNumber_DESC', + TransactionBlockNumberDescNullsLast = 'transaction_blockNumber_DESC_NULLS_LAST', TransactionIdAsc = 'transaction_id_ASC', + TransactionIdAscNullsFirst = 'transaction_id_ASC_NULLS_FIRST', TransactionIdDesc = 'transaction_id_DESC', + TransactionIdDescNullsLast = 'transaction_id_DESC_NULLS_LAST', TransactionTimestampAsc = 'transaction_timestamp_ASC', - TransactionTimestampDesc = 'transaction_timestamp_DESC' + TransactionTimestampAscNullsFirst = 'transaction_timestamp_ASC_NULLS_FIRST', + TransactionTimestampDesc = 'transaction_timestamp_DESC', + TransactionTimestampDescNullsLast = 'transaction_timestamp_DESC_NULLS_LAST' } export type BurnWhereInput = { @@ -474,6 +832,781 @@ export type BurnsConnection = { totalCount: Scalars['Int']['output']; }; +export type Call = { + __typename?: 'Call'; + address: Array; + args?: Maybe; + argsStr?: Maybe>>; + block: Block; + error?: Maybe; + events: Array; + extrinsic?: Maybe; + id: Scalars['String']['output']; + name: Scalars['String']['output']; + pallet: Scalars['String']['output']; + parent?: Maybe; + subcalls: Array; + success: Scalars['Boolean']['output']; +}; + + +export type CallEventsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type CallSubcallsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + +export type CallEdge = { + __typename?: 'CallEdge'; + cursor: Scalars['String']['output']; + node: Call; +}; + +export enum CallOrderByInput { + BlockCallsCountAsc = 'block_callsCount_ASC', + BlockCallsCountAscNullsFirst = 'block_callsCount_ASC_NULLS_FIRST', + BlockCallsCountDesc = 'block_callsCount_DESC', + BlockCallsCountDescNullsLast = 'block_callsCount_DESC_NULLS_LAST', + BlockEventsCountAsc = 'block_eventsCount_ASC', + BlockEventsCountAscNullsFirst = 'block_eventsCount_ASC_NULLS_FIRST', + BlockEventsCountDesc = 'block_eventsCount_DESC', + BlockEventsCountDescNullsLast = 'block_eventsCount_DESC_NULLS_LAST', + BlockExtrinsicsCountAsc = 'block_extrinsicsCount_ASC', + BlockExtrinsicsCountAscNullsFirst = 'block_extrinsicsCount_ASC_NULLS_FIRST', + BlockExtrinsicsCountDesc = 'block_extrinsicsCount_DESC', + BlockExtrinsicsCountDescNullsLast = 'block_extrinsicsCount_DESC_NULLS_LAST', + BlockExtrinsicsicRootAsc = 'block_extrinsicsicRoot_ASC', + BlockExtrinsicsicRootAscNullsFirst = 'block_extrinsicsicRoot_ASC_NULLS_FIRST', + BlockExtrinsicsicRootDesc = 'block_extrinsicsicRoot_DESC', + BlockExtrinsicsicRootDescNullsLast = 'block_extrinsicsicRoot_DESC_NULLS_LAST', + BlockHashAsc = 'block_hash_ASC', + BlockHashAscNullsFirst = 'block_hash_ASC_NULLS_FIRST', + BlockHashDesc = 'block_hash_DESC', + BlockHashDescNullsLast = 'block_hash_DESC_NULLS_LAST', + BlockHeightAsc = 'block_height_ASC', + BlockHeightAscNullsFirst = 'block_height_ASC_NULLS_FIRST', + BlockHeightDesc = 'block_height_DESC', + BlockHeightDescNullsLast = 'block_height_DESC_NULLS_LAST', + BlockIdAsc = 'block_id_ASC', + BlockIdAscNullsFirst = 'block_id_ASC_NULLS_FIRST', + BlockIdDesc = 'block_id_DESC', + BlockIdDescNullsLast = 'block_id_DESC_NULLS_LAST', + BlockImplNameAsc = 'block_implName_ASC', + BlockImplNameAscNullsFirst = 'block_implName_ASC_NULLS_FIRST', + BlockImplNameDesc = 'block_implName_DESC', + BlockImplNameDescNullsLast = 'block_implName_DESC_NULLS_LAST', + BlockImplVersionAsc = 'block_implVersion_ASC', + BlockImplVersionAscNullsFirst = 'block_implVersion_ASC_NULLS_FIRST', + BlockImplVersionDesc = 'block_implVersion_DESC', + BlockImplVersionDescNullsLast = 'block_implVersion_DESC_NULLS_LAST', + BlockParentHashAsc = 'block_parentHash_ASC', + BlockParentHashAscNullsFirst = 'block_parentHash_ASC_NULLS_FIRST', + BlockParentHashDesc = 'block_parentHash_DESC', + BlockParentHashDescNullsLast = 'block_parentHash_DESC_NULLS_LAST', + BlockSpecNameAsc = 'block_specName_ASC', + BlockSpecNameAscNullsFirst = 'block_specName_ASC_NULLS_FIRST', + BlockSpecNameDesc = 'block_specName_DESC', + BlockSpecNameDescNullsLast = 'block_specName_DESC_NULLS_LAST', + BlockSpecVersionAsc = 'block_specVersion_ASC', + BlockSpecVersionAscNullsFirst = 'block_specVersion_ASC_NULLS_FIRST', + BlockSpecVersionDesc = 'block_specVersion_DESC', + BlockSpecVersionDescNullsLast = 'block_specVersion_DESC_NULLS_LAST', + BlockStateRootAsc = 'block_stateRoot_ASC', + BlockStateRootAscNullsFirst = 'block_stateRoot_ASC_NULLS_FIRST', + BlockStateRootDesc = 'block_stateRoot_DESC', + BlockStateRootDescNullsLast = 'block_stateRoot_DESC_NULLS_LAST', + BlockTimestampAsc = 'block_timestamp_ASC', + BlockTimestampAscNullsFirst = 'block_timestamp_ASC_NULLS_FIRST', + BlockTimestampDesc = 'block_timestamp_DESC', + BlockTimestampDescNullsLast = 'block_timestamp_DESC_NULLS_LAST', + BlockValidatorAsc = 'block_validator_ASC', + BlockValidatorAscNullsFirst = 'block_validator_ASC_NULLS_FIRST', + BlockValidatorDesc = 'block_validator_DESC', + BlockValidatorDescNullsLast = 'block_validator_DESC_NULLS_LAST', + ExtrinsicFeeAsc = 'extrinsic_fee_ASC', + ExtrinsicFeeAscNullsFirst = 'extrinsic_fee_ASC_NULLS_FIRST', + ExtrinsicFeeDesc = 'extrinsic_fee_DESC', + ExtrinsicFeeDescNullsLast = 'extrinsic_fee_DESC_NULLS_LAST', + ExtrinsicHashAsc = 'extrinsic_hash_ASC', + ExtrinsicHashAscNullsFirst = 'extrinsic_hash_ASC_NULLS_FIRST', + ExtrinsicHashDesc = 'extrinsic_hash_DESC', + ExtrinsicHashDescNullsLast = 'extrinsic_hash_DESC_NULLS_LAST', + ExtrinsicIdAsc = 'extrinsic_id_ASC', + ExtrinsicIdAscNullsFirst = 'extrinsic_id_ASC_NULLS_FIRST', + ExtrinsicIdDesc = 'extrinsic_id_DESC', + ExtrinsicIdDescNullsLast = 'extrinsic_id_DESC_NULLS_LAST', + ExtrinsicIndexAsc = 'extrinsic_index_ASC', + ExtrinsicIndexAscNullsFirst = 'extrinsic_index_ASC_NULLS_FIRST', + ExtrinsicIndexDesc = 'extrinsic_index_DESC', + ExtrinsicIndexDescNullsLast = 'extrinsic_index_DESC_NULLS_LAST', + ExtrinsicSuccessAsc = 'extrinsic_success_ASC', + ExtrinsicSuccessAscNullsFirst = 'extrinsic_success_ASC_NULLS_FIRST', + ExtrinsicSuccessDesc = 'extrinsic_success_DESC', + ExtrinsicSuccessDescNullsLast = 'extrinsic_success_DESC_NULLS_LAST', + ExtrinsicTipAsc = 'extrinsic_tip_ASC', + ExtrinsicTipAscNullsFirst = 'extrinsic_tip_ASC_NULLS_FIRST', + ExtrinsicTipDesc = 'extrinsic_tip_DESC', + ExtrinsicTipDescNullsLast = 'extrinsic_tip_DESC_NULLS_LAST', + ExtrinsicVersionAsc = 'extrinsic_version_ASC', + ExtrinsicVersionAscNullsFirst = 'extrinsic_version_ASC_NULLS_FIRST', + ExtrinsicVersionDesc = 'extrinsic_version_DESC', + ExtrinsicVersionDescNullsLast = 'extrinsic_version_DESC_NULLS_LAST', + IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', + IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', + NameAsc = 'name_ASC', + NameAscNullsFirst = 'name_ASC_NULLS_FIRST', + NameDesc = 'name_DESC', + NameDescNullsLast = 'name_DESC_NULLS_LAST', + PalletAsc = 'pallet_ASC', + PalletAscNullsFirst = 'pallet_ASC_NULLS_FIRST', + PalletDesc = 'pallet_DESC', + PalletDescNullsLast = 'pallet_DESC_NULLS_LAST', + ParentIdAsc = 'parent_id_ASC', + ParentIdAscNullsFirst = 'parent_id_ASC_NULLS_FIRST', + ParentIdDesc = 'parent_id_DESC', + ParentIdDescNullsLast = 'parent_id_DESC_NULLS_LAST', + ParentNameAsc = 'parent_name_ASC', + ParentNameAscNullsFirst = 'parent_name_ASC_NULLS_FIRST', + ParentNameDesc = 'parent_name_DESC', + ParentNameDescNullsLast = 'parent_name_DESC_NULLS_LAST', + ParentPalletAsc = 'parent_pallet_ASC', + ParentPalletAscNullsFirst = 'parent_pallet_ASC_NULLS_FIRST', + ParentPalletDesc = 'parent_pallet_DESC', + ParentPalletDescNullsLast = 'parent_pallet_DESC_NULLS_LAST', + ParentSuccessAsc = 'parent_success_ASC', + ParentSuccessAscNullsFirst = 'parent_success_ASC_NULLS_FIRST', + ParentSuccessDesc = 'parent_success_DESC', + ParentSuccessDescNullsLast = 'parent_success_DESC_NULLS_LAST', + SuccessAsc = 'success_ASC', + SuccessAscNullsFirst = 'success_ASC_NULLS_FIRST', + SuccessDesc = 'success_DESC', + SuccessDescNullsLast = 'success_DESC_NULLS_LAST' +} + +export type CallWhereInput = { + AND?: InputMaybe>; + OR?: InputMaybe>; + address_containsAll?: InputMaybe>; + address_containsAny?: InputMaybe>; + address_containsNone?: InputMaybe>; + address_isNull?: InputMaybe; + argsStr_containsAll?: InputMaybe>>; + argsStr_containsAny?: InputMaybe>>; + argsStr_containsNone?: InputMaybe>>; + argsStr_isNull?: InputMaybe; + args_eq?: InputMaybe; + args_isNull?: InputMaybe; + args_jsonContains?: InputMaybe; + args_jsonHasKey?: InputMaybe; + args_not_eq?: InputMaybe; + block?: InputMaybe; + block_isNull?: InputMaybe; + error_eq?: InputMaybe; + error_isNull?: InputMaybe; + error_jsonContains?: InputMaybe; + error_jsonHasKey?: InputMaybe; + error_not_eq?: InputMaybe; + events_every?: InputMaybe; + events_none?: InputMaybe; + events_some?: InputMaybe; + extrinsic?: InputMaybe; + extrinsic_isNull?: InputMaybe; + id_contains?: InputMaybe; + id_containsInsensitive?: InputMaybe; + id_endsWith?: InputMaybe; + id_eq?: InputMaybe; + id_gt?: InputMaybe; + id_gte?: InputMaybe; + id_in?: InputMaybe>; + id_isNull?: InputMaybe; + id_lt?: InputMaybe; + id_lte?: InputMaybe; + id_not_contains?: InputMaybe; + id_not_containsInsensitive?: InputMaybe; + id_not_endsWith?: InputMaybe; + id_not_eq?: InputMaybe; + id_not_in?: InputMaybe>; + id_not_startsWith?: InputMaybe; + id_startsWith?: InputMaybe; + name_contains?: InputMaybe; + name_containsInsensitive?: InputMaybe; + name_endsWith?: InputMaybe; + name_eq?: InputMaybe; + name_gt?: InputMaybe; + name_gte?: InputMaybe; + name_in?: InputMaybe>; + name_isNull?: InputMaybe; + name_lt?: InputMaybe; + name_lte?: InputMaybe; + name_not_contains?: InputMaybe; + name_not_containsInsensitive?: InputMaybe; + name_not_endsWith?: InputMaybe; + name_not_eq?: InputMaybe; + name_not_in?: InputMaybe>; + name_not_startsWith?: InputMaybe; + name_startsWith?: InputMaybe; + pallet_contains?: InputMaybe; + pallet_containsInsensitive?: InputMaybe; + pallet_endsWith?: InputMaybe; + pallet_eq?: InputMaybe; + pallet_gt?: InputMaybe; + pallet_gte?: InputMaybe; + pallet_in?: InputMaybe>; + pallet_isNull?: InputMaybe; + pallet_lt?: InputMaybe; + pallet_lte?: InputMaybe; + pallet_not_contains?: InputMaybe; + pallet_not_containsInsensitive?: InputMaybe; + pallet_not_endsWith?: InputMaybe; + pallet_not_eq?: InputMaybe; + pallet_not_in?: InputMaybe>; + pallet_not_startsWith?: InputMaybe; + pallet_startsWith?: InputMaybe; + parent?: InputMaybe; + parent_isNull?: InputMaybe; + subcalls_every?: InputMaybe; + subcalls_none?: InputMaybe; + subcalls_some?: InputMaybe; + success_eq?: InputMaybe; + success_isNull?: InputMaybe; + success_not_eq?: InputMaybe; +}; + +export type CallsConnection = { + __typename?: 'CallsConnection'; + edges: Array; + pageInfo: PageInfo; + totalCount: Scalars['Int']['output']; +}; + +export enum CounterLevel { + Global = 'Global', + Item = 'Item', + Pallet = 'Pallet' +} + +export type Event = { + __typename?: 'Event'; + args?: Maybe; + argsStr?: Maybe>>; + block: Block; + call?: Maybe; + extrinsic?: Maybe; + /** Event id - e.g. 0000000001-000000-272d6 */ + id: Scalars['String']['output']; + index: Scalars['Int']['output']; + name: Scalars['String']['output']; + pallet: Scalars['String']['output']; + phase: Scalars['String']['output']; +}; + +export type EventEdge = { + __typename?: 'EventEdge'; + cursor: Scalars['String']['output']; + node: Event; +}; + +export enum EventOrderByInput { + BlockCallsCountAsc = 'block_callsCount_ASC', + BlockCallsCountAscNullsFirst = 'block_callsCount_ASC_NULLS_FIRST', + BlockCallsCountDesc = 'block_callsCount_DESC', + BlockCallsCountDescNullsLast = 'block_callsCount_DESC_NULLS_LAST', + BlockEventsCountAsc = 'block_eventsCount_ASC', + BlockEventsCountAscNullsFirst = 'block_eventsCount_ASC_NULLS_FIRST', + BlockEventsCountDesc = 'block_eventsCount_DESC', + BlockEventsCountDescNullsLast = 'block_eventsCount_DESC_NULLS_LAST', + BlockExtrinsicsCountAsc = 'block_extrinsicsCount_ASC', + BlockExtrinsicsCountAscNullsFirst = 'block_extrinsicsCount_ASC_NULLS_FIRST', + BlockExtrinsicsCountDesc = 'block_extrinsicsCount_DESC', + BlockExtrinsicsCountDescNullsLast = 'block_extrinsicsCount_DESC_NULLS_LAST', + BlockExtrinsicsicRootAsc = 'block_extrinsicsicRoot_ASC', + BlockExtrinsicsicRootAscNullsFirst = 'block_extrinsicsicRoot_ASC_NULLS_FIRST', + BlockExtrinsicsicRootDesc = 'block_extrinsicsicRoot_DESC', + BlockExtrinsicsicRootDescNullsLast = 'block_extrinsicsicRoot_DESC_NULLS_LAST', + BlockHashAsc = 'block_hash_ASC', + BlockHashAscNullsFirst = 'block_hash_ASC_NULLS_FIRST', + BlockHashDesc = 'block_hash_DESC', + BlockHashDescNullsLast = 'block_hash_DESC_NULLS_LAST', + BlockHeightAsc = 'block_height_ASC', + BlockHeightAscNullsFirst = 'block_height_ASC_NULLS_FIRST', + BlockHeightDesc = 'block_height_DESC', + BlockHeightDescNullsLast = 'block_height_DESC_NULLS_LAST', + BlockIdAsc = 'block_id_ASC', + BlockIdAscNullsFirst = 'block_id_ASC_NULLS_FIRST', + BlockIdDesc = 'block_id_DESC', + BlockIdDescNullsLast = 'block_id_DESC_NULLS_LAST', + BlockImplNameAsc = 'block_implName_ASC', + BlockImplNameAscNullsFirst = 'block_implName_ASC_NULLS_FIRST', + BlockImplNameDesc = 'block_implName_DESC', + BlockImplNameDescNullsLast = 'block_implName_DESC_NULLS_LAST', + BlockImplVersionAsc = 'block_implVersion_ASC', + BlockImplVersionAscNullsFirst = 'block_implVersion_ASC_NULLS_FIRST', + BlockImplVersionDesc = 'block_implVersion_DESC', + BlockImplVersionDescNullsLast = 'block_implVersion_DESC_NULLS_LAST', + BlockParentHashAsc = 'block_parentHash_ASC', + BlockParentHashAscNullsFirst = 'block_parentHash_ASC_NULLS_FIRST', + BlockParentHashDesc = 'block_parentHash_DESC', + BlockParentHashDescNullsLast = 'block_parentHash_DESC_NULLS_LAST', + BlockSpecNameAsc = 'block_specName_ASC', + BlockSpecNameAscNullsFirst = 'block_specName_ASC_NULLS_FIRST', + BlockSpecNameDesc = 'block_specName_DESC', + BlockSpecNameDescNullsLast = 'block_specName_DESC_NULLS_LAST', + BlockSpecVersionAsc = 'block_specVersion_ASC', + BlockSpecVersionAscNullsFirst = 'block_specVersion_ASC_NULLS_FIRST', + BlockSpecVersionDesc = 'block_specVersion_DESC', + BlockSpecVersionDescNullsLast = 'block_specVersion_DESC_NULLS_LAST', + BlockStateRootAsc = 'block_stateRoot_ASC', + BlockStateRootAscNullsFirst = 'block_stateRoot_ASC_NULLS_FIRST', + BlockStateRootDesc = 'block_stateRoot_DESC', + BlockStateRootDescNullsLast = 'block_stateRoot_DESC_NULLS_LAST', + BlockTimestampAsc = 'block_timestamp_ASC', + BlockTimestampAscNullsFirst = 'block_timestamp_ASC_NULLS_FIRST', + BlockTimestampDesc = 'block_timestamp_DESC', + BlockTimestampDescNullsLast = 'block_timestamp_DESC_NULLS_LAST', + BlockValidatorAsc = 'block_validator_ASC', + BlockValidatorAscNullsFirst = 'block_validator_ASC_NULLS_FIRST', + BlockValidatorDesc = 'block_validator_DESC', + BlockValidatorDescNullsLast = 'block_validator_DESC_NULLS_LAST', + CallIdAsc = 'call_id_ASC', + CallIdAscNullsFirst = 'call_id_ASC_NULLS_FIRST', + CallIdDesc = 'call_id_DESC', + CallIdDescNullsLast = 'call_id_DESC_NULLS_LAST', + CallNameAsc = 'call_name_ASC', + CallNameAscNullsFirst = 'call_name_ASC_NULLS_FIRST', + CallNameDesc = 'call_name_DESC', + CallNameDescNullsLast = 'call_name_DESC_NULLS_LAST', + CallPalletAsc = 'call_pallet_ASC', + CallPalletAscNullsFirst = 'call_pallet_ASC_NULLS_FIRST', + CallPalletDesc = 'call_pallet_DESC', + CallPalletDescNullsLast = 'call_pallet_DESC_NULLS_LAST', + CallSuccessAsc = 'call_success_ASC', + CallSuccessAscNullsFirst = 'call_success_ASC_NULLS_FIRST', + CallSuccessDesc = 'call_success_DESC', + CallSuccessDescNullsLast = 'call_success_DESC_NULLS_LAST', + ExtrinsicFeeAsc = 'extrinsic_fee_ASC', + ExtrinsicFeeAscNullsFirst = 'extrinsic_fee_ASC_NULLS_FIRST', + ExtrinsicFeeDesc = 'extrinsic_fee_DESC', + ExtrinsicFeeDescNullsLast = 'extrinsic_fee_DESC_NULLS_LAST', + ExtrinsicHashAsc = 'extrinsic_hash_ASC', + ExtrinsicHashAscNullsFirst = 'extrinsic_hash_ASC_NULLS_FIRST', + ExtrinsicHashDesc = 'extrinsic_hash_DESC', + ExtrinsicHashDescNullsLast = 'extrinsic_hash_DESC_NULLS_LAST', + ExtrinsicIdAsc = 'extrinsic_id_ASC', + ExtrinsicIdAscNullsFirst = 'extrinsic_id_ASC_NULLS_FIRST', + ExtrinsicIdDesc = 'extrinsic_id_DESC', + ExtrinsicIdDescNullsLast = 'extrinsic_id_DESC_NULLS_LAST', + ExtrinsicIndexAsc = 'extrinsic_index_ASC', + ExtrinsicIndexAscNullsFirst = 'extrinsic_index_ASC_NULLS_FIRST', + ExtrinsicIndexDesc = 'extrinsic_index_DESC', + ExtrinsicIndexDescNullsLast = 'extrinsic_index_DESC_NULLS_LAST', + ExtrinsicSuccessAsc = 'extrinsic_success_ASC', + ExtrinsicSuccessAscNullsFirst = 'extrinsic_success_ASC_NULLS_FIRST', + ExtrinsicSuccessDesc = 'extrinsic_success_DESC', + ExtrinsicSuccessDescNullsLast = 'extrinsic_success_DESC_NULLS_LAST', + ExtrinsicTipAsc = 'extrinsic_tip_ASC', + ExtrinsicTipAscNullsFirst = 'extrinsic_tip_ASC_NULLS_FIRST', + ExtrinsicTipDesc = 'extrinsic_tip_DESC', + ExtrinsicTipDescNullsLast = 'extrinsic_tip_DESC_NULLS_LAST', + ExtrinsicVersionAsc = 'extrinsic_version_ASC', + ExtrinsicVersionAscNullsFirst = 'extrinsic_version_ASC_NULLS_FIRST', + ExtrinsicVersionDesc = 'extrinsic_version_DESC', + ExtrinsicVersionDescNullsLast = 'extrinsic_version_DESC_NULLS_LAST', + IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', + IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', + IndexAsc = 'index_ASC', + IndexAscNullsFirst = 'index_ASC_NULLS_FIRST', + IndexDesc = 'index_DESC', + IndexDescNullsLast = 'index_DESC_NULLS_LAST', + NameAsc = 'name_ASC', + NameAscNullsFirst = 'name_ASC_NULLS_FIRST', + NameDesc = 'name_DESC', + NameDescNullsLast = 'name_DESC_NULLS_LAST', + PalletAsc = 'pallet_ASC', + PalletAscNullsFirst = 'pallet_ASC_NULLS_FIRST', + PalletDesc = 'pallet_DESC', + PalletDescNullsLast = 'pallet_DESC_NULLS_LAST', + PhaseAsc = 'phase_ASC', + PhaseAscNullsFirst = 'phase_ASC_NULLS_FIRST', + PhaseDesc = 'phase_DESC', + PhaseDescNullsLast = 'phase_DESC_NULLS_LAST' +} + +export type EventWhereInput = { + AND?: InputMaybe>; + OR?: InputMaybe>; + argsStr_containsAll?: InputMaybe>>; + argsStr_containsAny?: InputMaybe>>; + argsStr_containsNone?: InputMaybe>>; + argsStr_isNull?: InputMaybe; + args_eq?: InputMaybe; + args_isNull?: InputMaybe; + args_jsonContains?: InputMaybe; + args_jsonHasKey?: InputMaybe; + args_not_eq?: InputMaybe; + block?: InputMaybe; + block_isNull?: InputMaybe; + call?: InputMaybe; + call_isNull?: InputMaybe; + extrinsic?: InputMaybe; + extrinsic_isNull?: InputMaybe; + id_contains?: InputMaybe; + id_containsInsensitive?: InputMaybe; + id_endsWith?: InputMaybe; + id_eq?: InputMaybe; + id_gt?: InputMaybe; + id_gte?: InputMaybe; + id_in?: InputMaybe>; + id_isNull?: InputMaybe; + id_lt?: InputMaybe; + id_lte?: InputMaybe; + id_not_contains?: InputMaybe; + id_not_containsInsensitive?: InputMaybe; + id_not_endsWith?: InputMaybe; + id_not_eq?: InputMaybe; + id_not_in?: InputMaybe>; + id_not_startsWith?: InputMaybe; + id_startsWith?: InputMaybe; + index_eq?: InputMaybe; + index_gt?: InputMaybe; + index_gte?: InputMaybe; + index_in?: InputMaybe>; + index_isNull?: InputMaybe; + index_lt?: InputMaybe; + index_lte?: InputMaybe; + index_not_eq?: InputMaybe; + index_not_in?: InputMaybe>; + name_contains?: InputMaybe; + name_containsInsensitive?: InputMaybe; + name_endsWith?: InputMaybe; + name_eq?: InputMaybe; + name_gt?: InputMaybe; + name_gte?: InputMaybe; + name_in?: InputMaybe>; + name_isNull?: InputMaybe; + name_lt?: InputMaybe; + name_lte?: InputMaybe; + name_not_contains?: InputMaybe; + name_not_containsInsensitive?: InputMaybe; + name_not_endsWith?: InputMaybe; + name_not_eq?: InputMaybe; + name_not_in?: InputMaybe>; + name_not_startsWith?: InputMaybe; + name_startsWith?: InputMaybe; + pallet_contains?: InputMaybe; + pallet_containsInsensitive?: InputMaybe; + pallet_endsWith?: InputMaybe; + pallet_eq?: InputMaybe; + pallet_gt?: InputMaybe; + pallet_gte?: InputMaybe; + pallet_in?: InputMaybe>; + pallet_isNull?: InputMaybe; + pallet_lt?: InputMaybe; + pallet_lte?: InputMaybe; + pallet_not_contains?: InputMaybe; + pallet_not_containsInsensitive?: InputMaybe; + pallet_not_endsWith?: InputMaybe; + pallet_not_eq?: InputMaybe; + pallet_not_in?: InputMaybe>; + pallet_not_startsWith?: InputMaybe; + pallet_startsWith?: InputMaybe; + phase_contains?: InputMaybe; + phase_containsInsensitive?: InputMaybe; + phase_endsWith?: InputMaybe; + phase_eq?: InputMaybe; + phase_gt?: InputMaybe; + phase_gte?: InputMaybe; + phase_in?: InputMaybe>; + phase_isNull?: InputMaybe; + phase_lt?: InputMaybe; + phase_lte?: InputMaybe; + phase_not_contains?: InputMaybe; + phase_not_containsInsensitive?: InputMaybe; + phase_not_endsWith?: InputMaybe; + phase_not_eq?: InputMaybe; + phase_not_in?: InputMaybe>; + phase_not_startsWith?: InputMaybe; + phase_startsWith?: InputMaybe; +}; + +export type EventsConnection = { + __typename?: 'EventsConnection'; + edges: Array; + pageInfo: PageInfo; + totalCount: Scalars['Int']['output']; +}; + +export type Extrinsic = { + __typename?: 'Extrinsic'; + block: Block; + call: Call; + calls: Array; + error?: Maybe; + events: Array; + fee?: Maybe; + hash: Scalars['Bytes']['output']; + id: Scalars['String']['output']; + index: Scalars['Int']['output']; + signature?: Maybe; + success?: Maybe; + tip?: Maybe; + version: Scalars['Int']['output']; +}; + + +export type ExtrinsicCallsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type ExtrinsicEventsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + +export type ExtrinsicEdge = { + __typename?: 'ExtrinsicEdge'; + cursor: Scalars['String']['output']; + node: Extrinsic; +}; + +export enum ExtrinsicOrderByInput { + BlockCallsCountAsc = 'block_callsCount_ASC', + BlockCallsCountAscNullsFirst = 'block_callsCount_ASC_NULLS_FIRST', + BlockCallsCountDesc = 'block_callsCount_DESC', + BlockCallsCountDescNullsLast = 'block_callsCount_DESC_NULLS_LAST', + BlockEventsCountAsc = 'block_eventsCount_ASC', + BlockEventsCountAscNullsFirst = 'block_eventsCount_ASC_NULLS_FIRST', + BlockEventsCountDesc = 'block_eventsCount_DESC', + BlockEventsCountDescNullsLast = 'block_eventsCount_DESC_NULLS_LAST', + BlockExtrinsicsCountAsc = 'block_extrinsicsCount_ASC', + BlockExtrinsicsCountAscNullsFirst = 'block_extrinsicsCount_ASC_NULLS_FIRST', + BlockExtrinsicsCountDesc = 'block_extrinsicsCount_DESC', + BlockExtrinsicsCountDescNullsLast = 'block_extrinsicsCount_DESC_NULLS_LAST', + BlockExtrinsicsicRootAsc = 'block_extrinsicsicRoot_ASC', + BlockExtrinsicsicRootAscNullsFirst = 'block_extrinsicsicRoot_ASC_NULLS_FIRST', + BlockExtrinsicsicRootDesc = 'block_extrinsicsicRoot_DESC', + BlockExtrinsicsicRootDescNullsLast = 'block_extrinsicsicRoot_DESC_NULLS_LAST', + BlockHashAsc = 'block_hash_ASC', + BlockHashAscNullsFirst = 'block_hash_ASC_NULLS_FIRST', + BlockHashDesc = 'block_hash_DESC', + BlockHashDescNullsLast = 'block_hash_DESC_NULLS_LAST', + BlockHeightAsc = 'block_height_ASC', + BlockHeightAscNullsFirst = 'block_height_ASC_NULLS_FIRST', + BlockHeightDesc = 'block_height_DESC', + BlockHeightDescNullsLast = 'block_height_DESC_NULLS_LAST', + BlockIdAsc = 'block_id_ASC', + BlockIdAscNullsFirst = 'block_id_ASC_NULLS_FIRST', + BlockIdDesc = 'block_id_DESC', + BlockIdDescNullsLast = 'block_id_DESC_NULLS_LAST', + BlockImplNameAsc = 'block_implName_ASC', + BlockImplNameAscNullsFirst = 'block_implName_ASC_NULLS_FIRST', + BlockImplNameDesc = 'block_implName_DESC', + BlockImplNameDescNullsLast = 'block_implName_DESC_NULLS_LAST', + BlockImplVersionAsc = 'block_implVersion_ASC', + BlockImplVersionAscNullsFirst = 'block_implVersion_ASC_NULLS_FIRST', + BlockImplVersionDesc = 'block_implVersion_DESC', + BlockImplVersionDescNullsLast = 'block_implVersion_DESC_NULLS_LAST', + BlockParentHashAsc = 'block_parentHash_ASC', + BlockParentHashAscNullsFirst = 'block_parentHash_ASC_NULLS_FIRST', + BlockParentHashDesc = 'block_parentHash_DESC', + BlockParentHashDescNullsLast = 'block_parentHash_DESC_NULLS_LAST', + BlockSpecNameAsc = 'block_specName_ASC', + BlockSpecNameAscNullsFirst = 'block_specName_ASC_NULLS_FIRST', + BlockSpecNameDesc = 'block_specName_DESC', + BlockSpecNameDescNullsLast = 'block_specName_DESC_NULLS_LAST', + BlockSpecVersionAsc = 'block_specVersion_ASC', + BlockSpecVersionAscNullsFirst = 'block_specVersion_ASC_NULLS_FIRST', + BlockSpecVersionDesc = 'block_specVersion_DESC', + BlockSpecVersionDescNullsLast = 'block_specVersion_DESC_NULLS_LAST', + BlockStateRootAsc = 'block_stateRoot_ASC', + BlockStateRootAscNullsFirst = 'block_stateRoot_ASC_NULLS_FIRST', + BlockStateRootDesc = 'block_stateRoot_DESC', + BlockStateRootDescNullsLast = 'block_stateRoot_DESC_NULLS_LAST', + BlockTimestampAsc = 'block_timestamp_ASC', + BlockTimestampAscNullsFirst = 'block_timestamp_ASC_NULLS_FIRST', + BlockTimestampDesc = 'block_timestamp_DESC', + BlockTimestampDescNullsLast = 'block_timestamp_DESC_NULLS_LAST', + BlockValidatorAsc = 'block_validator_ASC', + BlockValidatorAscNullsFirst = 'block_validator_ASC_NULLS_FIRST', + BlockValidatorDesc = 'block_validator_DESC', + BlockValidatorDescNullsLast = 'block_validator_DESC_NULLS_LAST', + CallIdAsc = 'call_id_ASC', + CallIdAscNullsFirst = 'call_id_ASC_NULLS_FIRST', + CallIdDesc = 'call_id_DESC', + CallIdDescNullsLast = 'call_id_DESC_NULLS_LAST', + CallNameAsc = 'call_name_ASC', + CallNameAscNullsFirst = 'call_name_ASC_NULLS_FIRST', + CallNameDesc = 'call_name_DESC', + CallNameDescNullsLast = 'call_name_DESC_NULLS_LAST', + CallPalletAsc = 'call_pallet_ASC', + CallPalletAscNullsFirst = 'call_pallet_ASC_NULLS_FIRST', + CallPalletDesc = 'call_pallet_DESC', + CallPalletDescNullsLast = 'call_pallet_DESC_NULLS_LAST', + CallSuccessAsc = 'call_success_ASC', + CallSuccessAscNullsFirst = 'call_success_ASC_NULLS_FIRST', + CallSuccessDesc = 'call_success_DESC', + CallSuccessDescNullsLast = 'call_success_DESC_NULLS_LAST', + FeeAsc = 'fee_ASC', + FeeAscNullsFirst = 'fee_ASC_NULLS_FIRST', + FeeDesc = 'fee_DESC', + FeeDescNullsLast = 'fee_DESC_NULLS_LAST', + HashAsc = 'hash_ASC', + HashAscNullsFirst = 'hash_ASC_NULLS_FIRST', + HashDesc = 'hash_DESC', + HashDescNullsLast = 'hash_DESC_NULLS_LAST', + IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', + IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', + IndexAsc = 'index_ASC', + IndexAscNullsFirst = 'index_ASC_NULLS_FIRST', + IndexDesc = 'index_DESC', + IndexDescNullsLast = 'index_DESC_NULLS_LAST', + SuccessAsc = 'success_ASC', + SuccessAscNullsFirst = 'success_ASC_NULLS_FIRST', + SuccessDesc = 'success_DESC', + SuccessDescNullsLast = 'success_DESC_NULLS_LAST', + TipAsc = 'tip_ASC', + TipAscNullsFirst = 'tip_ASC_NULLS_FIRST', + TipDesc = 'tip_DESC', + TipDescNullsLast = 'tip_DESC_NULLS_LAST', + VersionAsc = 'version_ASC', + VersionAscNullsFirst = 'version_ASC_NULLS_FIRST', + VersionDesc = 'version_DESC', + VersionDescNullsLast = 'version_DESC_NULLS_LAST' +} + +export type ExtrinsicSignature = { + __typename?: 'ExtrinsicSignature'; + address?: Maybe; + signature?: Maybe; + signedExtensions?: Maybe; +}; + +export type ExtrinsicSignatureWhereInput = { + address_eq?: InputMaybe; + address_isNull?: InputMaybe; + address_jsonContains?: InputMaybe; + address_jsonHasKey?: InputMaybe; + address_not_eq?: InputMaybe; + signature_eq?: InputMaybe; + signature_isNull?: InputMaybe; + signature_jsonContains?: InputMaybe; + signature_jsonHasKey?: InputMaybe; + signature_not_eq?: InputMaybe; + signedExtensions_eq?: InputMaybe; + signedExtensions_isNull?: InputMaybe; + signedExtensions_jsonContains?: InputMaybe; + signedExtensions_jsonHasKey?: InputMaybe; + signedExtensions_not_eq?: InputMaybe; +}; + +export type ExtrinsicWhereInput = { + AND?: InputMaybe>; + OR?: InputMaybe>; + block?: InputMaybe; + block_isNull?: InputMaybe; + call?: InputMaybe; + call_isNull?: InputMaybe; + calls_every?: InputMaybe; + calls_none?: InputMaybe; + calls_some?: InputMaybe; + error_eq?: InputMaybe; + error_isNull?: InputMaybe; + error_jsonContains?: InputMaybe; + error_jsonHasKey?: InputMaybe; + error_not_eq?: InputMaybe; + events_every?: InputMaybe; + events_none?: InputMaybe; + events_some?: InputMaybe; + fee_eq?: InputMaybe; + fee_gt?: InputMaybe; + fee_gte?: InputMaybe; + fee_in?: InputMaybe>; + fee_isNull?: InputMaybe; + fee_lt?: InputMaybe; + fee_lte?: InputMaybe; + fee_not_eq?: InputMaybe; + fee_not_in?: InputMaybe>; + hash_eq?: InputMaybe; + hash_isNull?: InputMaybe; + hash_not_eq?: InputMaybe; + id_contains?: InputMaybe; + id_containsInsensitive?: InputMaybe; + id_endsWith?: InputMaybe; + id_eq?: InputMaybe; + id_gt?: InputMaybe; + id_gte?: InputMaybe; + id_in?: InputMaybe>; + id_isNull?: InputMaybe; + id_lt?: InputMaybe; + id_lte?: InputMaybe; + id_not_contains?: InputMaybe; + id_not_containsInsensitive?: InputMaybe; + id_not_endsWith?: InputMaybe; + id_not_eq?: InputMaybe; + id_not_in?: InputMaybe>; + id_not_startsWith?: InputMaybe; + id_startsWith?: InputMaybe; + index_eq?: InputMaybe; + index_gt?: InputMaybe; + index_gte?: InputMaybe; + index_in?: InputMaybe>; + index_isNull?: InputMaybe; + index_lt?: InputMaybe; + index_lte?: InputMaybe; + index_not_eq?: InputMaybe; + index_not_in?: InputMaybe>; + signature?: InputMaybe; + signature_isNull?: InputMaybe; + success_eq?: InputMaybe; + success_isNull?: InputMaybe; + success_not_eq?: InputMaybe; + tip_eq?: InputMaybe; + tip_gt?: InputMaybe; + tip_gte?: InputMaybe; + tip_in?: InputMaybe>; + tip_isNull?: InputMaybe; + tip_lt?: InputMaybe; + tip_lte?: InputMaybe; + tip_not_eq?: InputMaybe; + tip_not_in?: InputMaybe>; + version_eq?: InputMaybe; + version_gt?: InputMaybe; + version_gte?: InputMaybe; + version_in?: InputMaybe>; + version_isNull?: InputMaybe; + version_lt?: InputMaybe; + version_lte?: InputMaybe; + version_not_eq?: InputMaybe; + version_not_in?: InputMaybe>; +}; + +export type ExtrinsicsConnection = { + __typename?: 'ExtrinsicsConnection'; + edges: Array; + pageInfo: PageInfo; + totalCount: Scalars['Int']['output']; +}; + export type FactoriesConnection = { __typename?: 'FactoriesConnection'; edges: Array; @@ -527,25 +1660,45 @@ export type FactoryDayDataEdge = { export enum FactoryDayDataOrderByInput { DailyVolumeEthAsc = 'dailyVolumeETH_ASC', + DailyVolumeEthAscNullsFirst = 'dailyVolumeETH_ASC_NULLS_FIRST', DailyVolumeEthDesc = 'dailyVolumeETH_DESC', + DailyVolumeEthDescNullsLast = 'dailyVolumeETH_DESC_NULLS_LAST', DailyVolumeUsdAsc = 'dailyVolumeUSD_ASC', + DailyVolumeUsdAscNullsFirst = 'dailyVolumeUSD_ASC_NULLS_FIRST', DailyVolumeUsdDesc = 'dailyVolumeUSD_DESC', + DailyVolumeUsdDescNullsLast = 'dailyVolumeUSD_DESC_NULLS_LAST', DailyVolumeUntrackedAsc = 'dailyVolumeUntracked_ASC', + DailyVolumeUntrackedAscNullsFirst = 'dailyVolumeUntracked_ASC_NULLS_FIRST', DailyVolumeUntrackedDesc = 'dailyVolumeUntracked_DESC', + DailyVolumeUntrackedDescNullsLast = 'dailyVolumeUntracked_DESC_NULLS_LAST', DateAsc = 'date_ASC', + DateAscNullsFirst = 'date_ASC_NULLS_FIRST', DateDesc = 'date_DESC', + DateDescNullsLast = 'date_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', TotalLiquidityEthAsc = 'totalLiquidityETH_ASC', + TotalLiquidityEthAscNullsFirst = 'totalLiquidityETH_ASC_NULLS_FIRST', TotalLiquidityEthDesc = 'totalLiquidityETH_DESC', + TotalLiquidityEthDescNullsLast = 'totalLiquidityETH_DESC_NULLS_LAST', TotalLiquidityUsdAsc = 'totalLiquidityUSD_ASC', + TotalLiquidityUsdAscNullsFirst = 'totalLiquidityUSD_ASC_NULLS_FIRST', TotalLiquidityUsdDesc = 'totalLiquidityUSD_DESC', + TotalLiquidityUsdDescNullsLast = 'totalLiquidityUSD_DESC_NULLS_LAST', TotalVolumeEthAsc = 'totalVolumeETH_ASC', + TotalVolumeEthAscNullsFirst = 'totalVolumeETH_ASC_NULLS_FIRST', TotalVolumeEthDesc = 'totalVolumeETH_DESC', + TotalVolumeEthDescNullsLast = 'totalVolumeETH_DESC_NULLS_LAST', TotalVolumeUsdAsc = 'totalVolumeUSD_ASC', + TotalVolumeUsdAscNullsFirst = 'totalVolumeUSD_ASC_NULLS_FIRST', TotalVolumeUsdDesc = 'totalVolumeUSD_DESC', + TotalVolumeUsdDescNullsLast = 'totalVolumeUSD_DESC_NULLS_LAST', TxCountAsc = 'txCount_ASC', - TxCountDesc = 'txCount_DESC' + TxCountAscNullsFirst = 'txCount_ASC_NULLS_FIRST', + TxCountDesc = 'txCount_DESC', + TxCountDescNullsLast = 'txCount_DESC_NULLS_LAST' } export type FactoryDayDataWhereInput = { @@ -715,21 +1868,37 @@ export type FactoryEdge = { export enum FactoryOrderByInput { IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', PairCountAsc = 'pairCount_ASC', + PairCountAscNullsFirst = 'pairCount_ASC_NULLS_FIRST', PairCountDesc = 'pairCount_DESC', + PairCountDescNullsLast = 'pairCount_DESC_NULLS_LAST', TotalLiquidityEthAsc = 'totalLiquidityETH_ASC', + TotalLiquidityEthAscNullsFirst = 'totalLiquidityETH_ASC_NULLS_FIRST', TotalLiquidityEthDesc = 'totalLiquidityETH_DESC', + TotalLiquidityEthDescNullsLast = 'totalLiquidityETH_DESC_NULLS_LAST', TotalLiquidityUsdAsc = 'totalLiquidityUSD_ASC', + TotalLiquidityUsdAscNullsFirst = 'totalLiquidityUSD_ASC_NULLS_FIRST', TotalLiquidityUsdDesc = 'totalLiquidityUSD_DESC', + TotalLiquidityUsdDescNullsLast = 'totalLiquidityUSD_DESC_NULLS_LAST', TotalVolumeEthAsc = 'totalVolumeETH_ASC', + TotalVolumeEthAscNullsFirst = 'totalVolumeETH_ASC_NULLS_FIRST', TotalVolumeEthDesc = 'totalVolumeETH_DESC', + TotalVolumeEthDescNullsLast = 'totalVolumeETH_DESC_NULLS_LAST', TotalVolumeUsdAsc = 'totalVolumeUSD_ASC', + TotalVolumeUsdAscNullsFirst = 'totalVolumeUSD_ASC_NULLS_FIRST', TotalVolumeUsdDesc = 'totalVolumeUSD_DESC', + TotalVolumeUsdDescNullsLast = 'totalVolumeUSD_DESC_NULLS_LAST', TxCountAsc = 'txCount_ASC', + TxCountAscNullsFirst = 'txCount_ASC_NULLS_FIRST', TxCountDesc = 'txCount_DESC', + TxCountDescNullsLast = 'txCount_DESC_NULLS_LAST', UntrackedVolumeUsdAsc = 'untrackedVolumeUSD_ASC', - UntrackedVolumeUsdDesc = 'untrackedVolumeUSD_DESC' + UntrackedVolumeUsdAscNullsFirst = 'untrackedVolumeUSD_ASC_NULLS_FIRST', + UntrackedVolumeUsdDesc = 'untrackedVolumeUSD_DESC', + UntrackedVolumeUsdDescNullsLast = 'untrackedVolumeUSD_DESC_NULLS_LAST' } export type FactoryWhereInput = { @@ -899,89 +2068,173 @@ export type FarmEdge = { export enum FarmOrderByInput { CreatedAtBlockAsc = 'createdAtBlock_ASC', + CreatedAtBlockAscNullsFirst = 'createdAtBlock_ASC_NULLS_FIRST', CreatedAtBlockDesc = 'createdAtBlock_DESC', + CreatedAtBlockDescNullsLast = 'createdAtBlock_DESC_NULLS_LAST', CreatedAtTimestampAsc = 'createdAtTimestamp_ASC', + CreatedAtTimestampAscNullsFirst = 'createdAtTimestamp_ASC_NULLS_FIRST', CreatedAtTimestampDesc = 'createdAtTimestamp_DESC', + CreatedAtTimestampDescNullsLast = 'createdAtTimestamp_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiquidityStakedAsc = 'liquidityStaked_ASC', + LiquidityStakedAscNullsFirst = 'liquidityStaked_ASC_NULLS_FIRST', LiquidityStakedDesc = 'liquidityStaked_DESC', + LiquidityStakedDescNullsLast = 'liquidityStaked_DESC_NULLS_LAST', PairCreatedAtBlockNumberAsc = 'pair_createdAtBlockNumber_ASC', + PairCreatedAtBlockNumberAscNullsFirst = 'pair_createdAtBlockNumber_ASC_NULLS_FIRST', PairCreatedAtBlockNumberDesc = 'pair_createdAtBlockNumber_DESC', + PairCreatedAtBlockNumberDescNullsLast = 'pair_createdAtBlockNumber_DESC_NULLS_LAST', PairCreatedAtTimestampAsc = 'pair_createdAtTimestamp_ASC', + PairCreatedAtTimestampAscNullsFirst = 'pair_createdAtTimestamp_ASC_NULLS_FIRST', PairCreatedAtTimestampDesc = 'pair_createdAtTimestamp_DESC', + PairCreatedAtTimestampDescNullsLast = 'pair_createdAtTimestamp_DESC_NULLS_LAST', PairIdAsc = 'pair_id_ASC', + PairIdAscNullsFirst = 'pair_id_ASC_NULLS_FIRST', PairIdDesc = 'pair_id_DESC', + PairIdDescNullsLast = 'pair_id_DESC_NULLS_LAST', PairLiquidityProviderCountAsc = 'pair_liquidityProviderCount_ASC', + PairLiquidityProviderCountAscNullsFirst = 'pair_liquidityProviderCount_ASC_NULLS_FIRST', PairLiquidityProviderCountDesc = 'pair_liquidityProviderCount_DESC', + PairLiquidityProviderCountDescNullsLast = 'pair_liquidityProviderCount_DESC_NULLS_LAST', PairReserve0Asc = 'pair_reserve0_ASC', + PairReserve0AscNullsFirst = 'pair_reserve0_ASC_NULLS_FIRST', PairReserve0Desc = 'pair_reserve0_DESC', + PairReserve0DescNullsLast = 'pair_reserve0_DESC_NULLS_LAST', PairReserve1Asc = 'pair_reserve1_ASC', + PairReserve1AscNullsFirst = 'pair_reserve1_ASC_NULLS_FIRST', PairReserve1Desc = 'pair_reserve1_DESC', + PairReserve1DescNullsLast = 'pair_reserve1_DESC_NULLS_LAST', PairReserveEthAsc = 'pair_reserveETH_ASC', + PairReserveEthAscNullsFirst = 'pair_reserveETH_ASC_NULLS_FIRST', PairReserveEthDesc = 'pair_reserveETH_DESC', + PairReserveEthDescNullsLast = 'pair_reserveETH_DESC_NULLS_LAST', PairReserveUsdAsc = 'pair_reserveUSD_ASC', + PairReserveUsdAscNullsFirst = 'pair_reserveUSD_ASC_NULLS_FIRST', PairReserveUsdDesc = 'pair_reserveUSD_DESC', + PairReserveUsdDescNullsLast = 'pair_reserveUSD_DESC_NULLS_LAST', PairToken0PriceAsc = 'pair_token0Price_ASC', + PairToken0PriceAscNullsFirst = 'pair_token0Price_ASC_NULLS_FIRST', PairToken0PriceDesc = 'pair_token0Price_DESC', + PairToken0PriceDescNullsLast = 'pair_token0Price_DESC_NULLS_LAST', PairToken1PriceAsc = 'pair_token1Price_ASC', + PairToken1PriceAscNullsFirst = 'pair_token1Price_ASC_NULLS_FIRST', PairToken1PriceDesc = 'pair_token1Price_DESC', + PairToken1PriceDescNullsLast = 'pair_token1Price_DESC_NULLS_LAST', PairTotalSupplyAsc = 'pair_totalSupply_ASC', + PairTotalSupplyAscNullsFirst = 'pair_totalSupply_ASC_NULLS_FIRST', PairTotalSupplyDesc = 'pair_totalSupply_DESC', + PairTotalSupplyDescNullsLast = 'pair_totalSupply_DESC_NULLS_LAST', PairTrackedReserveEthAsc = 'pair_trackedReserveETH_ASC', + PairTrackedReserveEthAscNullsFirst = 'pair_trackedReserveETH_ASC_NULLS_FIRST', PairTrackedReserveEthDesc = 'pair_trackedReserveETH_DESC', + PairTrackedReserveEthDescNullsLast = 'pair_trackedReserveETH_DESC_NULLS_LAST', PairTxCountAsc = 'pair_txCount_ASC', + PairTxCountAscNullsFirst = 'pair_txCount_ASC_NULLS_FIRST', PairTxCountDesc = 'pair_txCount_DESC', + PairTxCountDescNullsLast = 'pair_txCount_DESC_NULLS_LAST', PairUntrackedVolumeUsdAsc = 'pair_untrackedVolumeUSD_ASC', + PairUntrackedVolumeUsdAscNullsFirst = 'pair_untrackedVolumeUSD_ASC_NULLS_FIRST', PairUntrackedVolumeUsdDesc = 'pair_untrackedVolumeUSD_DESC', + PairUntrackedVolumeUsdDescNullsLast = 'pair_untrackedVolumeUSD_DESC_NULLS_LAST', PairVolumeToken0Asc = 'pair_volumeToken0_ASC', + PairVolumeToken0AscNullsFirst = 'pair_volumeToken0_ASC_NULLS_FIRST', PairVolumeToken0Desc = 'pair_volumeToken0_DESC', + PairVolumeToken0DescNullsLast = 'pair_volumeToken0_DESC_NULLS_LAST', PairVolumeToken1Asc = 'pair_volumeToken1_ASC', + PairVolumeToken1AscNullsFirst = 'pair_volumeToken1_ASC_NULLS_FIRST', PairVolumeToken1Desc = 'pair_volumeToken1_DESC', + PairVolumeToken1DescNullsLast = 'pair_volumeToken1_DESC_NULLS_LAST', PairVolumeUsdAsc = 'pair_volumeUSD_ASC', + PairVolumeUsdAscNullsFirst = 'pair_volumeUSD_ASC_NULLS_FIRST', PairVolumeUsdDesc = 'pair_volumeUSD_DESC', + PairVolumeUsdDescNullsLast = 'pair_volumeUSD_DESC_NULLS_LAST', PidAsc = 'pid_ASC', + PidAscNullsFirst = 'pid_ASC_NULLS_FIRST', PidDesc = 'pid_DESC', + PidDescNullsLast = 'pid_DESC_NULLS_LAST', RewardUsdPerDayAsc = 'rewardUSDPerDay_ASC', + RewardUsdPerDayAscNullsFirst = 'rewardUSDPerDay_ASC_NULLS_FIRST', RewardUsdPerDayDesc = 'rewardUSDPerDay_DESC', + RewardUsdPerDayDescNullsLast = 'rewardUSDPerDay_DESC_NULLS_LAST', SingleTokenLockIdAsc = 'singleTokenLock_id_ASC', + SingleTokenLockIdAscNullsFirst = 'singleTokenLock_id_ASC_NULLS_FIRST', SingleTokenLockIdDesc = 'singleTokenLock_id_DESC', + SingleTokenLockIdDescNullsLast = 'singleTokenLock_id_DESC_NULLS_LAST', SingleTokenLockTotalLiquidityEthAsc = 'singleTokenLock_totalLiquidityETH_ASC', + SingleTokenLockTotalLiquidityEthAscNullsFirst = 'singleTokenLock_totalLiquidityETH_ASC_NULLS_FIRST', SingleTokenLockTotalLiquidityEthDesc = 'singleTokenLock_totalLiquidityETH_DESC', + SingleTokenLockTotalLiquidityEthDescNullsLast = 'singleTokenLock_totalLiquidityETH_DESC_NULLS_LAST', SingleTokenLockTotalLiquidityUsdAsc = 'singleTokenLock_totalLiquidityUSD_ASC', + SingleTokenLockTotalLiquidityUsdAscNullsFirst = 'singleTokenLock_totalLiquidityUSD_ASC_NULLS_FIRST', SingleTokenLockTotalLiquidityUsdDesc = 'singleTokenLock_totalLiquidityUSD_DESC', + SingleTokenLockTotalLiquidityUsdDescNullsLast = 'singleTokenLock_totalLiquidityUSD_DESC_NULLS_LAST', SingleTokenLockTotalLiquidityAsc = 'singleTokenLock_totalLiquidity_ASC', + SingleTokenLockTotalLiquidityAscNullsFirst = 'singleTokenLock_totalLiquidity_ASC_NULLS_FIRST', SingleTokenLockTotalLiquidityDesc = 'singleTokenLock_totalLiquidity_DESC', + SingleTokenLockTotalLiquidityDescNullsLast = 'singleTokenLock_totalLiquidity_DESC_NULLS_LAST', StableSwapAAsc = 'stableSwap_a_ASC', + StableSwapAAscNullsFirst = 'stableSwap_a_ASC_NULLS_FIRST', StableSwapADesc = 'stableSwap_a_DESC', + StableSwapADescNullsLast = 'stableSwap_a_DESC_NULLS_LAST', StableSwapAddressAsc = 'stableSwap_address_ASC', + StableSwapAddressAscNullsFirst = 'stableSwap_address_ASC_NULLS_FIRST', StableSwapAddressDesc = 'stableSwap_address_DESC', + StableSwapAddressDescNullsLast = 'stableSwap_address_DESC_NULLS_LAST', StableSwapAdminFeeAsc = 'stableSwap_adminFee_ASC', + StableSwapAdminFeeAscNullsFirst = 'stableSwap_adminFee_ASC_NULLS_FIRST', StableSwapAdminFeeDesc = 'stableSwap_adminFee_DESC', + StableSwapAdminFeeDescNullsLast = 'stableSwap_adminFee_DESC_NULLS_LAST', StableSwapBaseSwapAddressAsc = 'stableSwap_baseSwapAddress_ASC', + StableSwapBaseSwapAddressAscNullsFirst = 'stableSwap_baseSwapAddress_ASC_NULLS_FIRST', StableSwapBaseSwapAddressDesc = 'stableSwap_baseSwapAddress_DESC', + StableSwapBaseSwapAddressDescNullsLast = 'stableSwap_baseSwapAddress_DESC_NULLS_LAST', StableSwapIdAsc = 'stableSwap_id_ASC', + StableSwapIdAscNullsFirst = 'stableSwap_id_ASC_NULLS_FIRST', StableSwapIdDesc = 'stableSwap_id_DESC', + StableSwapIdDescNullsLast = 'stableSwap_id_DESC_NULLS_LAST', StableSwapLpTokenAsc = 'stableSwap_lpToken_ASC', + StableSwapLpTokenAscNullsFirst = 'stableSwap_lpToken_ASC_NULLS_FIRST', StableSwapLpTokenDesc = 'stableSwap_lpToken_DESC', + StableSwapLpTokenDescNullsLast = 'stableSwap_lpToken_DESC_NULLS_LAST', StableSwapLpTotalSupplyAsc = 'stableSwap_lpTotalSupply_ASC', + StableSwapLpTotalSupplyAscNullsFirst = 'stableSwap_lpTotalSupply_ASC_NULLS_FIRST', StableSwapLpTotalSupplyDesc = 'stableSwap_lpTotalSupply_DESC', + StableSwapLpTotalSupplyDescNullsLast = 'stableSwap_lpTotalSupply_DESC_NULLS_LAST', StableSwapNumTokensAsc = 'stableSwap_numTokens_ASC', + StableSwapNumTokensAscNullsFirst = 'stableSwap_numTokens_ASC_NULLS_FIRST', StableSwapNumTokensDesc = 'stableSwap_numTokens_DESC', + StableSwapNumTokensDescNullsLast = 'stableSwap_numTokens_DESC_NULLS_LAST', StableSwapSwapFeeAsc = 'stableSwap_swapFee_ASC', + StableSwapSwapFeeAscNullsFirst = 'stableSwap_swapFee_ASC_NULLS_FIRST', StableSwapSwapFeeDesc = 'stableSwap_swapFee_DESC', + StableSwapSwapFeeDescNullsLast = 'stableSwap_swapFee_DESC_NULLS_LAST', StableSwapTvlUsdAsc = 'stableSwap_tvlUSD_ASC', + StableSwapTvlUsdAscNullsFirst = 'stableSwap_tvlUSD_ASC_NULLS_FIRST', StableSwapTvlUsdDesc = 'stableSwap_tvlUSD_DESC', + StableSwapTvlUsdDescNullsLast = 'stableSwap_tvlUSD_DESC_NULLS_LAST', StableSwapVirtualPriceAsc = 'stableSwap_virtualPrice_ASC', + StableSwapVirtualPriceAscNullsFirst = 'stableSwap_virtualPrice_ASC_NULLS_FIRST', StableSwapVirtualPriceDesc = 'stableSwap_virtualPrice_DESC', + StableSwapVirtualPriceDescNullsLast = 'stableSwap_virtualPrice_DESC_NULLS_LAST', StableSwapVolumeUsdAsc = 'stableSwap_volumeUSD_ASC', + StableSwapVolumeUsdAscNullsFirst = 'stableSwap_volumeUSD_ASC_NULLS_FIRST', StableSwapVolumeUsdDesc = 'stableSwap_volumeUSD_DESC', + StableSwapVolumeUsdDescNullsLast = 'stableSwap_volumeUSD_DESC_NULLS_LAST', StakeAprAsc = 'stakeApr_ASC', + StakeAprAscNullsFirst = 'stakeApr_ASC_NULLS_FIRST', StakeAprDesc = 'stakeApr_DESC', + StakeAprDescNullsLast = 'stakeApr_DESC_NULLS_LAST', StakeTokenAsc = 'stakeToken_ASC', + StakeTokenAscNullsFirst = 'stakeToken_ASC_NULLS_FIRST', StakeTokenDesc = 'stakeToken_DESC', + StakeTokenDescNullsLast = 'stakeToken_DESC_NULLS_LAST', StakedUsdAsc = 'stakedUSD_ASC', - StakedUsdDesc = 'stakedUSD_DESC' + StakedUsdAscNullsFirst = 'stakedUSD_ASC_NULLS_FIRST', + StakedUsdDesc = 'stakedUSD_DESC', + StakedUsdDescNullsLast = 'stakedUSD_DESC_NULLS_LAST' } export type FarmWhereInput = { @@ -1145,49 +2398,93 @@ export type IncentiveEdge = { export enum IncentiveOrderByInput { FarmCreatedAtBlockAsc = 'farm_createdAtBlock_ASC', + FarmCreatedAtBlockAscNullsFirst = 'farm_createdAtBlock_ASC_NULLS_FIRST', FarmCreatedAtBlockDesc = 'farm_createdAtBlock_DESC', + FarmCreatedAtBlockDescNullsLast = 'farm_createdAtBlock_DESC_NULLS_LAST', FarmCreatedAtTimestampAsc = 'farm_createdAtTimestamp_ASC', + FarmCreatedAtTimestampAscNullsFirst = 'farm_createdAtTimestamp_ASC_NULLS_FIRST', FarmCreatedAtTimestampDesc = 'farm_createdAtTimestamp_DESC', + FarmCreatedAtTimestampDescNullsLast = 'farm_createdAtTimestamp_DESC_NULLS_LAST', FarmIdAsc = 'farm_id_ASC', + FarmIdAscNullsFirst = 'farm_id_ASC_NULLS_FIRST', FarmIdDesc = 'farm_id_DESC', + FarmIdDescNullsLast = 'farm_id_DESC_NULLS_LAST', FarmLiquidityStakedAsc = 'farm_liquidityStaked_ASC', + FarmLiquidityStakedAscNullsFirst = 'farm_liquidityStaked_ASC_NULLS_FIRST', FarmLiquidityStakedDesc = 'farm_liquidityStaked_DESC', + FarmLiquidityStakedDescNullsLast = 'farm_liquidityStaked_DESC_NULLS_LAST', FarmPidAsc = 'farm_pid_ASC', + FarmPidAscNullsFirst = 'farm_pid_ASC_NULLS_FIRST', FarmPidDesc = 'farm_pid_DESC', + FarmPidDescNullsLast = 'farm_pid_DESC_NULLS_LAST', FarmRewardUsdPerDayAsc = 'farm_rewardUSDPerDay_ASC', + FarmRewardUsdPerDayAscNullsFirst = 'farm_rewardUSDPerDay_ASC_NULLS_FIRST', FarmRewardUsdPerDayDesc = 'farm_rewardUSDPerDay_DESC', + FarmRewardUsdPerDayDescNullsLast = 'farm_rewardUSDPerDay_DESC_NULLS_LAST', FarmStakeAprAsc = 'farm_stakeApr_ASC', + FarmStakeAprAscNullsFirst = 'farm_stakeApr_ASC_NULLS_FIRST', FarmStakeAprDesc = 'farm_stakeApr_DESC', + FarmStakeAprDescNullsLast = 'farm_stakeApr_DESC_NULLS_LAST', FarmStakeTokenAsc = 'farm_stakeToken_ASC', + FarmStakeTokenAscNullsFirst = 'farm_stakeToken_ASC_NULLS_FIRST', FarmStakeTokenDesc = 'farm_stakeToken_DESC', + FarmStakeTokenDescNullsLast = 'farm_stakeToken_DESC_NULLS_LAST', FarmStakedUsdAsc = 'farm_stakedUSD_ASC', + FarmStakedUsdAscNullsFirst = 'farm_stakedUSD_ASC_NULLS_FIRST', FarmStakedUsdDesc = 'farm_stakedUSD_DESC', + FarmStakedUsdDescNullsLast = 'farm_stakedUSD_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', RewardPerDayAsc = 'rewardPerDay_ASC', + RewardPerDayAscNullsFirst = 'rewardPerDay_ASC_NULLS_FIRST', RewardPerDayDesc = 'rewardPerDay_DESC', + RewardPerDayDescNullsLast = 'rewardPerDay_DESC_NULLS_LAST', RewardTokenDecimalsAsc = 'rewardToken_decimals_ASC', + RewardTokenDecimalsAscNullsFirst = 'rewardToken_decimals_ASC_NULLS_FIRST', RewardTokenDecimalsDesc = 'rewardToken_decimals_DESC', + RewardTokenDecimalsDescNullsLast = 'rewardToken_decimals_DESC_NULLS_LAST', RewardTokenDerivedEthAsc = 'rewardToken_derivedETH_ASC', + RewardTokenDerivedEthAscNullsFirst = 'rewardToken_derivedETH_ASC_NULLS_FIRST', RewardTokenDerivedEthDesc = 'rewardToken_derivedETH_DESC', + RewardTokenDerivedEthDescNullsLast = 'rewardToken_derivedETH_DESC_NULLS_LAST', RewardTokenIdAsc = 'rewardToken_id_ASC', + RewardTokenIdAscNullsFirst = 'rewardToken_id_ASC_NULLS_FIRST', RewardTokenIdDesc = 'rewardToken_id_DESC', + RewardTokenIdDescNullsLast = 'rewardToken_id_DESC_NULLS_LAST', RewardTokenNameAsc = 'rewardToken_name_ASC', + RewardTokenNameAscNullsFirst = 'rewardToken_name_ASC_NULLS_FIRST', RewardTokenNameDesc = 'rewardToken_name_DESC', + RewardTokenNameDescNullsLast = 'rewardToken_name_DESC_NULLS_LAST', RewardTokenSymbolAsc = 'rewardToken_symbol_ASC', + RewardTokenSymbolAscNullsFirst = 'rewardToken_symbol_ASC_NULLS_FIRST', RewardTokenSymbolDesc = 'rewardToken_symbol_DESC', + RewardTokenSymbolDescNullsLast = 'rewardToken_symbol_DESC_NULLS_LAST', RewardTokenTotalLiquidityAsc = 'rewardToken_totalLiquidity_ASC', + RewardTokenTotalLiquidityAscNullsFirst = 'rewardToken_totalLiquidity_ASC_NULLS_FIRST', RewardTokenTotalLiquidityDesc = 'rewardToken_totalLiquidity_DESC', + RewardTokenTotalLiquidityDescNullsLast = 'rewardToken_totalLiquidity_DESC_NULLS_LAST', RewardTokenTotalSupplyAsc = 'rewardToken_totalSupply_ASC', + RewardTokenTotalSupplyAscNullsFirst = 'rewardToken_totalSupply_ASC_NULLS_FIRST', RewardTokenTotalSupplyDesc = 'rewardToken_totalSupply_DESC', + RewardTokenTotalSupplyDescNullsLast = 'rewardToken_totalSupply_DESC_NULLS_LAST', RewardTokenTradeVolumeUsdAsc = 'rewardToken_tradeVolumeUSD_ASC', + RewardTokenTradeVolumeUsdAscNullsFirst = 'rewardToken_tradeVolumeUSD_ASC_NULLS_FIRST', RewardTokenTradeVolumeUsdDesc = 'rewardToken_tradeVolumeUSD_DESC', + RewardTokenTradeVolumeUsdDescNullsLast = 'rewardToken_tradeVolumeUSD_DESC_NULLS_LAST', RewardTokenTradeVolumeAsc = 'rewardToken_tradeVolume_ASC', + RewardTokenTradeVolumeAscNullsFirst = 'rewardToken_tradeVolume_ASC_NULLS_FIRST', RewardTokenTradeVolumeDesc = 'rewardToken_tradeVolume_DESC', + RewardTokenTradeVolumeDescNullsLast = 'rewardToken_tradeVolume_DESC_NULLS_LAST', RewardTokenTxCountAsc = 'rewardToken_txCount_ASC', + RewardTokenTxCountAscNullsFirst = 'rewardToken_txCount_ASC_NULLS_FIRST', RewardTokenTxCountDesc = 'rewardToken_txCount_DESC', + RewardTokenTxCountDescNullsLast = 'rewardToken_txCount_DESC_NULLS_LAST', RewardTokenUntrackedVolumeUsdAsc = 'rewardToken_untrackedVolumeUSD_ASC', - RewardTokenUntrackedVolumeUsdDesc = 'rewardToken_untrackedVolumeUSD_DESC' + RewardTokenUntrackedVolumeUsdAscNullsFirst = 'rewardToken_untrackedVolumeUSD_ASC_NULLS_FIRST', + RewardTokenUntrackedVolumeUsdDesc = 'rewardToken_untrackedVolumeUSD_DESC', + RewardTokenUntrackedVolumeUsdDescNullsLast = 'rewardToken_untrackedVolumeUSD_DESC_NULLS_LAST' } export type IncentiveWhereInput = { @@ -1240,6 +2537,93 @@ export type IncentivesConnection = { totalCount: Scalars['Int']['output']; }; +export enum ItemType { + Calls = 'Calls', + Events = 'Events', + Extrinsics = 'Extrinsics' +} + +export type ItemsCounter = { + __typename?: 'ItemsCounter'; + id: Scalars['String']['output']; + level: CounterLevel; + total: Scalars['Int']['output']; + type: ItemType; +}; + +export type ItemsCounterEdge = { + __typename?: 'ItemsCounterEdge'; + cursor: Scalars['String']['output']; + node: ItemsCounter; +}; + +export enum ItemsCounterOrderByInput { + IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', + IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', + LevelAsc = 'level_ASC', + LevelAscNullsFirst = 'level_ASC_NULLS_FIRST', + LevelDesc = 'level_DESC', + LevelDescNullsLast = 'level_DESC_NULLS_LAST', + TotalAsc = 'total_ASC', + TotalAscNullsFirst = 'total_ASC_NULLS_FIRST', + TotalDesc = 'total_DESC', + TotalDescNullsLast = 'total_DESC_NULLS_LAST', + TypeAsc = 'type_ASC', + TypeAscNullsFirst = 'type_ASC_NULLS_FIRST', + TypeDesc = 'type_DESC', + TypeDescNullsLast = 'type_DESC_NULLS_LAST' +} + +export type ItemsCounterWhereInput = { + AND?: InputMaybe>; + OR?: InputMaybe>; + id_contains?: InputMaybe; + id_containsInsensitive?: InputMaybe; + id_endsWith?: InputMaybe; + id_eq?: InputMaybe; + id_gt?: InputMaybe; + id_gte?: InputMaybe; + id_in?: InputMaybe>; + id_isNull?: InputMaybe; + id_lt?: InputMaybe; + id_lte?: InputMaybe; + id_not_contains?: InputMaybe; + id_not_containsInsensitive?: InputMaybe; + id_not_endsWith?: InputMaybe; + id_not_eq?: InputMaybe; + id_not_in?: InputMaybe>; + id_not_startsWith?: InputMaybe; + id_startsWith?: InputMaybe; + level_eq?: InputMaybe; + level_in?: InputMaybe>; + level_isNull?: InputMaybe; + level_not_eq?: InputMaybe; + level_not_in?: InputMaybe>; + total_eq?: InputMaybe; + total_gt?: InputMaybe; + total_gte?: InputMaybe; + total_in?: InputMaybe>; + total_isNull?: InputMaybe; + total_lt?: InputMaybe; + total_lte?: InputMaybe; + total_not_eq?: InputMaybe; + total_not_in?: InputMaybe>; + type_eq?: InputMaybe; + type_in?: InputMaybe>; + type_isNull?: InputMaybe; + type_not_eq?: InputMaybe; + type_not_in?: InputMaybe>; +}; + +export type ItemsCountersConnection = { + __typename?: 'ItemsCountersConnection'; + edges: Array; + pageInfo: PageInfo; + totalCount: Scalars['Int']['output']; +}; + export type LiquidityPosition = { __typename?: 'LiquidityPosition'; id: Scalars['String']['output']; @@ -1257,47 +2641,89 @@ export type LiquidityPositionEdge = { export enum LiquidityPositionOrderByInput { IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiquidityTokenBalanceAsc = 'liquidityTokenBalance_ASC', + LiquidityTokenBalanceAscNullsFirst = 'liquidityTokenBalance_ASC_NULLS_FIRST', LiquidityTokenBalanceDesc = 'liquidityTokenBalance_DESC', + LiquidityTokenBalanceDescNullsLast = 'liquidityTokenBalance_DESC_NULLS_LAST', PairCreatedAtBlockNumberAsc = 'pair_createdAtBlockNumber_ASC', + PairCreatedAtBlockNumberAscNullsFirst = 'pair_createdAtBlockNumber_ASC_NULLS_FIRST', PairCreatedAtBlockNumberDesc = 'pair_createdAtBlockNumber_DESC', + PairCreatedAtBlockNumberDescNullsLast = 'pair_createdAtBlockNumber_DESC_NULLS_LAST', PairCreatedAtTimestampAsc = 'pair_createdAtTimestamp_ASC', + PairCreatedAtTimestampAscNullsFirst = 'pair_createdAtTimestamp_ASC_NULLS_FIRST', PairCreatedAtTimestampDesc = 'pair_createdAtTimestamp_DESC', + PairCreatedAtTimestampDescNullsLast = 'pair_createdAtTimestamp_DESC_NULLS_LAST', PairIdAsc = 'pair_id_ASC', + PairIdAscNullsFirst = 'pair_id_ASC_NULLS_FIRST', PairIdDesc = 'pair_id_DESC', + PairIdDescNullsLast = 'pair_id_DESC_NULLS_LAST', PairLiquidityProviderCountAsc = 'pair_liquidityProviderCount_ASC', + PairLiquidityProviderCountAscNullsFirst = 'pair_liquidityProviderCount_ASC_NULLS_FIRST', PairLiquidityProviderCountDesc = 'pair_liquidityProviderCount_DESC', + PairLiquidityProviderCountDescNullsLast = 'pair_liquidityProviderCount_DESC_NULLS_LAST', PairReserve0Asc = 'pair_reserve0_ASC', + PairReserve0AscNullsFirst = 'pair_reserve0_ASC_NULLS_FIRST', PairReserve0Desc = 'pair_reserve0_DESC', + PairReserve0DescNullsLast = 'pair_reserve0_DESC_NULLS_LAST', PairReserve1Asc = 'pair_reserve1_ASC', + PairReserve1AscNullsFirst = 'pair_reserve1_ASC_NULLS_FIRST', PairReserve1Desc = 'pair_reserve1_DESC', + PairReserve1DescNullsLast = 'pair_reserve1_DESC_NULLS_LAST', PairReserveEthAsc = 'pair_reserveETH_ASC', + PairReserveEthAscNullsFirst = 'pair_reserveETH_ASC_NULLS_FIRST', PairReserveEthDesc = 'pair_reserveETH_DESC', + PairReserveEthDescNullsLast = 'pair_reserveETH_DESC_NULLS_LAST', PairReserveUsdAsc = 'pair_reserveUSD_ASC', + PairReserveUsdAscNullsFirst = 'pair_reserveUSD_ASC_NULLS_FIRST', PairReserveUsdDesc = 'pair_reserveUSD_DESC', + PairReserveUsdDescNullsLast = 'pair_reserveUSD_DESC_NULLS_LAST', PairToken0PriceAsc = 'pair_token0Price_ASC', + PairToken0PriceAscNullsFirst = 'pair_token0Price_ASC_NULLS_FIRST', PairToken0PriceDesc = 'pair_token0Price_DESC', + PairToken0PriceDescNullsLast = 'pair_token0Price_DESC_NULLS_LAST', PairToken1PriceAsc = 'pair_token1Price_ASC', + PairToken1PriceAscNullsFirst = 'pair_token1Price_ASC_NULLS_FIRST', PairToken1PriceDesc = 'pair_token1Price_DESC', + PairToken1PriceDescNullsLast = 'pair_token1Price_DESC_NULLS_LAST', PairTotalSupplyAsc = 'pair_totalSupply_ASC', + PairTotalSupplyAscNullsFirst = 'pair_totalSupply_ASC_NULLS_FIRST', PairTotalSupplyDesc = 'pair_totalSupply_DESC', + PairTotalSupplyDescNullsLast = 'pair_totalSupply_DESC_NULLS_LAST', PairTrackedReserveEthAsc = 'pair_trackedReserveETH_ASC', + PairTrackedReserveEthAscNullsFirst = 'pair_trackedReserveETH_ASC_NULLS_FIRST', PairTrackedReserveEthDesc = 'pair_trackedReserveETH_DESC', + PairTrackedReserveEthDescNullsLast = 'pair_trackedReserveETH_DESC_NULLS_LAST', PairTxCountAsc = 'pair_txCount_ASC', + PairTxCountAscNullsFirst = 'pair_txCount_ASC_NULLS_FIRST', PairTxCountDesc = 'pair_txCount_DESC', + PairTxCountDescNullsLast = 'pair_txCount_DESC_NULLS_LAST', PairUntrackedVolumeUsdAsc = 'pair_untrackedVolumeUSD_ASC', + PairUntrackedVolumeUsdAscNullsFirst = 'pair_untrackedVolumeUSD_ASC_NULLS_FIRST', PairUntrackedVolumeUsdDesc = 'pair_untrackedVolumeUSD_DESC', + PairUntrackedVolumeUsdDescNullsLast = 'pair_untrackedVolumeUSD_DESC_NULLS_LAST', PairVolumeToken0Asc = 'pair_volumeToken0_ASC', + PairVolumeToken0AscNullsFirst = 'pair_volumeToken0_ASC_NULLS_FIRST', PairVolumeToken0Desc = 'pair_volumeToken0_DESC', + PairVolumeToken0DescNullsLast = 'pair_volumeToken0_DESC_NULLS_LAST', PairVolumeToken1Asc = 'pair_volumeToken1_ASC', + PairVolumeToken1AscNullsFirst = 'pair_volumeToken1_ASC_NULLS_FIRST', PairVolumeToken1Desc = 'pair_volumeToken1_DESC', + PairVolumeToken1DescNullsLast = 'pair_volumeToken1_DESC_NULLS_LAST', PairVolumeUsdAsc = 'pair_volumeUSD_ASC', + PairVolumeUsdAscNullsFirst = 'pair_volumeUSD_ASC_NULLS_FIRST', PairVolumeUsdDesc = 'pair_volumeUSD_DESC', + PairVolumeUsdDescNullsLast = 'pair_volumeUSD_DESC_NULLS_LAST', UserIdAsc = 'user_id_ASC', + UserIdAscNullsFirst = 'user_id_ASC_NULLS_FIRST', UserIdDesc = 'user_id_DESC', + UserIdDescNullsLast = 'user_id_DESC_NULLS_LAST', UserUsdSwappedAsc = 'user_usdSwapped_ASC', - UserUsdSwappedDesc = 'user_usdSwapped_DESC' + UserUsdSwappedAscNullsFirst = 'user_usdSwapped_ASC_NULLS_FIRST', + UserUsdSwappedDesc = 'user_usdSwapped_DESC', + UserUsdSwappedDescNullsLast = 'user_usdSwapped_DESC_NULLS_LAST' } export type LiquidityPositionSnapshot = { @@ -1332,67 +2758,129 @@ export type LiquidityPositionSnapshotEdge = { export enum LiquidityPositionSnapshotOrderByInput { BlockAsc = 'block_ASC', + BlockAscNullsFirst = 'block_ASC_NULLS_FIRST', BlockDesc = 'block_DESC', + BlockDescNullsLast = 'block_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiquidityPositionIdAsc = 'liquidityPosition_id_ASC', + LiquidityPositionIdAscNullsFirst = 'liquidityPosition_id_ASC_NULLS_FIRST', LiquidityPositionIdDesc = 'liquidityPosition_id_DESC', + LiquidityPositionIdDescNullsLast = 'liquidityPosition_id_DESC_NULLS_LAST', LiquidityPositionLiquidityTokenBalanceAsc = 'liquidityPosition_liquidityTokenBalance_ASC', + LiquidityPositionLiquidityTokenBalanceAscNullsFirst = 'liquidityPosition_liquidityTokenBalance_ASC_NULLS_FIRST', LiquidityPositionLiquidityTokenBalanceDesc = 'liquidityPosition_liquidityTokenBalance_DESC', + LiquidityPositionLiquidityTokenBalanceDescNullsLast = 'liquidityPosition_liquidityTokenBalance_DESC_NULLS_LAST', LiquidityTokenBalanceAsc = 'liquidityTokenBalance_ASC', + LiquidityTokenBalanceAscNullsFirst = 'liquidityTokenBalance_ASC_NULLS_FIRST', LiquidityTokenBalanceDesc = 'liquidityTokenBalance_DESC', + LiquidityTokenBalanceDescNullsLast = 'liquidityTokenBalance_DESC_NULLS_LAST', LiquidityTokenTotalSupplyAsc = 'liquidityTokenTotalSupply_ASC', + LiquidityTokenTotalSupplyAscNullsFirst = 'liquidityTokenTotalSupply_ASC_NULLS_FIRST', LiquidityTokenTotalSupplyDesc = 'liquidityTokenTotalSupply_DESC', + LiquidityTokenTotalSupplyDescNullsLast = 'liquidityTokenTotalSupply_DESC_NULLS_LAST', PairCreatedAtBlockNumberAsc = 'pair_createdAtBlockNumber_ASC', + PairCreatedAtBlockNumberAscNullsFirst = 'pair_createdAtBlockNumber_ASC_NULLS_FIRST', PairCreatedAtBlockNumberDesc = 'pair_createdAtBlockNumber_DESC', + PairCreatedAtBlockNumberDescNullsLast = 'pair_createdAtBlockNumber_DESC_NULLS_LAST', PairCreatedAtTimestampAsc = 'pair_createdAtTimestamp_ASC', + PairCreatedAtTimestampAscNullsFirst = 'pair_createdAtTimestamp_ASC_NULLS_FIRST', PairCreatedAtTimestampDesc = 'pair_createdAtTimestamp_DESC', + PairCreatedAtTimestampDescNullsLast = 'pair_createdAtTimestamp_DESC_NULLS_LAST', PairIdAsc = 'pair_id_ASC', + PairIdAscNullsFirst = 'pair_id_ASC_NULLS_FIRST', PairIdDesc = 'pair_id_DESC', + PairIdDescNullsLast = 'pair_id_DESC_NULLS_LAST', PairLiquidityProviderCountAsc = 'pair_liquidityProviderCount_ASC', + PairLiquidityProviderCountAscNullsFirst = 'pair_liquidityProviderCount_ASC_NULLS_FIRST', PairLiquidityProviderCountDesc = 'pair_liquidityProviderCount_DESC', + PairLiquidityProviderCountDescNullsLast = 'pair_liquidityProviderCount_DESC_NULLS_LAST', PairReserve0Asc = 'pair_reserve0_ASC', + PairReserve0AscNullsFirst = 'pair_reserve0_ASC_NULLS_FIRST', PairReserve0Desc = 'pair_reserve0_DESC', + PairReserve0DescNullsLast = 'pair_reserve0_DESC_NULLS_LAST', PairReserve1Asc = 'pair_reserve1_ASC', + PairReserve1AscNullsFirst = 'pair_reserve1_ASC_NULLS_FIRST', PairReserve1Desc = 'pair_reserve1_DESC', + PairReserve1DescNullsLast = 'pair_reserve1_DESC_NULLS_LAST', PairReserveEthAsc = 'pair_reserveETH_ASC', + PairReserveEthAscNullsFirst = 'pair_reserveETH_ASC_NULLS_FIRST', PairReserveEthDesc = 'pair_reserveETH_DESC', + PairReserveEthDescNullsLast = 'pair_reserveETH_DESC_NULLS_LAST', PairReserveUsdAsc = 'pair_reserveUSD_ASC', + PairReserveUsdAscNullsFirst = 'pair_reserveUSD_ASC_NULLS_FIRST', PairReserveUsdDesc = 'pair_reserveUSD_DESC', + PairReserveUsdDescNullsLast = 'pair_reserveUSD_DESC_NULLS_LAST', PairToken0PriceAsc = 'pair_token0Price_ASC', + PairToken0PriceAscNullsFirst = 'pair_token0Price_ASC_NULLS_FIRST', PairToken0PriceDesc = 'pair_token0Price_DESC', + PairToken0PriceDescNullsLast = 'pair_token0Price_DESC_NULLS_LAST', PairToken1PriceAsc = 'pair_token1Price_ASC', + PairToken1PriceAscNullsFirst = 'pair_token1Price_ASC_NULLS_FIRST', PairToken1PriceDesc = 'pair_token1Price_DESC', + PairToken1PriceDescNullsLast = 'pair_token1Price_DESC_NULLS_LAST', PairTotalSupplyAsc = 'pair_totalSupply_ASC', + PairTotalSupplyAscNullsFirst = 'pair_totalSupply_ASC_NULLS_FIRST', PairTotalSupplyDesc = 'pair_totalSupply_DESC', + PairTotalSupplyDescNullsLast = 'pair_totalSupply_DESC_NULLS_LAST', PairTrackedReserveEthAsc = 'pair_trackedReserveETH_ASC', + PairTrackedReserveEthAscNullsFirst = 'pair_trackedReserveETH_ASC_NULLS_FIRST', PairTrackedReserveEthDesc = 'pair_trackedReserveETH_DESC', + PairTrackedReserveEthDescNullsLast = 'pair_trackedReserveETH_DESC_NULLS_LAST', PairTxCountAsc = 'pair_txCount_ASC', + PairTxCountAscNullsFirst = 'pair_txCount_ASC_NULLS_FIRST', PairTxCountDesc = 'pair_txCount_DESC', + PairTxCountDescNullsLast = 'pair_txCount_DESC_NULLS_LAST', PairUntrackedVolumeUsdAsc = 'pair_untrackedVolumeUSD_ASC', + PairUntrackedVolumeUsdAscNullsFirst = 'pair_untrackedVolumeUSD_ASC_NULLS_FIRST', PairUntrackedVolumeUsdDesc = 'pair_untrackedVolumeUSD_DESC', + PairUntrackedVolumeUsdDescNullsLast = 'pair_untrackedVolumeUSD_DESC_NULLS_LAST', PairVolumeToken0Asc = 'pair_volumeToken0_ASC', + PairVolumeToken0AscNullsFirst = 'pair_volumeToken0_ASC_NULLS_FIRST', PairVolumeToken0Desc = 'pair_volumeToken0_DESC', + PairVolumeToken0DescNullsLast = 'pair_volumeToken0_DESC_NULLS_LAST', PairVolumeToken1Asc = 'pair_volumeToken1_ASC', + PairVolumeToken1AscNullsFirst = 'pair_volumeToken1_ASC_NULLS_FIRST', PairVolumeToken1Desc = 'pair_volumeToken1_DESC', + PairVolumeToken1DescNullsLast = 'pair_volumeToken1_DESC_NULLS_LAST', PairVolumeUsdAsc = 'pair_volumeUSD_ASC', + PairVolumeUsdAscNullsFirst = 'pair_volumeUSD_ASC_NULLS_FIRST', PairVolumeUsdDesc = 'pair_volumeUSD_DESC', + PairVolumeUsdDescNullsLast = 'pair_volumeUSD_DESC_NULLS_LAST', Reserve0Asc = 'reserve0_ASC', + Reserve0AscNullsFirst = 'reserve0_ASC_NULLS_FIRST', Reserve0Desc = 'reserve0_DESC', + Reserve0DescNullsLast = 'reserve0_DESC_NULLS_LAST', Reserve1Asc = 'reserve1_ASC', + Reserve1AscNullsFirst = 'reserve1_ASC_NULLS_FIRST', Reserve1Desc = 'reserve1_DESC', + Reserve1DescNullsLast = 'reserve1_DESC_NULLS_LAST', ReserveUsdAsc = 'reserveUSD_ASC', + ReserveUsdAscNullsFirst = 'reserveUSD_ASC_NULLS_FIRST', ReserveUsdDesc = 'reserveUSD_DESC', + ReserveUsdDescNullsLast = 'reserveUSD_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', Token0PriceUsdAsc = 'token0PriceUSD_ASC', + Token0PriceUsdAscNullsFirst = 'token0PriceUSD_ASC_NULLS_FIRST', Token0PriceUsdDesc = 'token0PriceUSD_DESC', + Token0PriceUsdDescNullsLast = 'token0PriceUSD_DESC_NULLS_LAST', Token1PriceUsdAsc = 'token1PriceUSD_ASC', + Token1PriceUsdAscNullsFirst = 'token1PriceUSD_ASC_NULLS_FIRST', Token1PriceUsdDesc = 'token1PriceUSD_DESC', + Token1PriceUsdDescNullsLast = 'token1PriceUSD_DESC_NULLS_LAST', UserIdAsc = 'user_id_ASC', + UserIdAscNullsFirst = 'user_id_ASC_NULLS_FIRST', UserIdDesc = 'user_id_DESC', + UserIdDescNullsLast = 'user_id_DESC_NULLS_LAST', UserUsdSwappedAsc = 'user_usdSwapped_ASC', - UserUsdSwappedDesc = 'user_usdSwapped_DESC' + UserUsdSwappedAscNullsFirst = 'user_usdSwapped_ASC_NULLS_FIRST', + UserUsdSwappedDesc = 'user_usdSwapped_DESC', + UserUsdSwappedDescNullsLast = 'user_usdSwapped_DESC_NULLS_LAST' } export type LiquidityPositionSnapshotWhereInput = { @@ -1642,67 +3130,129 @@ export type MintEdge = { export enum MintOrderByInput { Amount0Asc = 'amount0_ASC', + Amount0AscNullsFirst = 'amount0_ASC_NULLS_FIRST', Amount0Desc = 'amount0_DESC', + Amount0DescNullsLast = 'amount0_DESC_NULLS_LAST', Amount1Asc = 'amount1_ASC', + Amount1AscNullsFirst = 'amount1_ASC_NULLS_FIRST', Amount1Desc = 'amount1_DESC', + Amount1DescNullsLast = 'amount1_DESC_NULLS_LAST', AmountUsdAsc = 'amountUSD_ASC', + AmountUsdAscNullsFirst = 'amountUSD_ASC_NULLS_FIRST', AmountUsdDesc = 'amountUSD_DESC', + AmountUsdDescNullsLast = 'amountUSD_DESC_NULLS_LAST', FeeLiquidityAsc = 'feeLiquidity_ASC', + FeeLiquidityAscNullsFirst = 'feeLiquidity_ASC_NULLS_FIRST', FeeLiquidityDesc = 'feeLiquidity_DESC', + FeeLiquidityDescNullsLast = 'feeLiquidity_DESC_NULLS_LAST', FeeToAsc = 'feeTo_ASC', + FeeToAscNullsFirst = 'feeTo_ASC_NULLS_FIRST', FeeToDesc = 'feeTo_DESC', + FeeToDescNullsLast = 'feeTo_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiquidityAsc = 'liquidity_ASC', + LiquidityAscNullsFirst = 'liquidity_ASC_NULLS_FIRST', LiquidityDesc = 'liquidity_DESC', + LiquidityDescNullsLast = 'liquidity_DESC_NULLS_LAST', LogIndexAsc = 'logIndex_ASC', + LogIndexAscNullsFirst = 'logIndex_ASC_NULLS_FIRST', LogIndexDesc = 'logIndex_DESC', + LogIndexDescNullsLast = 'logIndex_DESC_NULLS_LAST', PairCreatedAtBlockNumberAsc = 'pair_createdAtBlockNumber_ASC', + PairCreatedAtBlockNumberAscNullsFirst = 'pair_createdAtBlockNumber_ASC_NULLS_FIRST', PairCreatedAtBlockNumberDesc = 'pair_createdAtBlockNumber_DESC', + PairCreatedAtBlockNumberDescNullsLast = 'pair_createdAtBlockNumber_DESC_NULLS_LAST', PairCreatedAtTimestampAsc = 'pair_createdAtTimestamp_ASC', + PairCreatedAtTimestampAscNullsFirst = 'pair_createdAtTimestamp_ASC_NULLS_FIRST', PairCreatedAtTimestampDesc = 'pair_createdAtTimestamp_DESC', + PairCreatedAtTimestampDescNullsLast = 'pair_createdAtTimestamp_DESC_NULLS_LAST', PairIdAsc = 'pair_id_ASC', + PairIdAscNullsFirst = 'pair_id_ASC_NULLS_FIRST', PairIdDesc = 'pair_id_DESC', + PairIdDescNullsLast = 'pair_id_DESC_NULLS_LAST', PairLiquidityProviderCountAsc = 'pair_liquidityProviderCount_ASC', + PairLiquidityProviderCountAscNullsFirst = 'pair_liquidityProviderCount_ASC_NULLS_FIRST', PairLiquidityProviderCountDesc = 'pair_liquidityProviderCount_DESC', + PairLiquidityProviderCountDescNullsLast = 'pair_liquidityProviderCount_DESC_NULLS_LAST', PairReserve0Asc = 'pair_reserve0_ASC', + PairReserve0AscNullsFirst = 'pair_reserve0_ASC_NULLS_FIRST', PairReserve0Desc = 'pair_reserve0_DESC', + PairReserve0DescNullsLast = 'pair_reserve0_DESC_NULLS_LAST', PairReserve1Asc = 'pair_reserve1_ASC', + PairReserve1AscNullsFirst = 'pair_reserve1_ASC_NULLS_FIRST', PairReserve1Desc = 'pair_reserve1_DESC', + PairReserve1DescNullsLast = 'pair_reserve1_DESC_NULLS_LAST', PairReserveEthAsc = 'pair_reserveETH_ASC', + PairReserveEthAscNullsFirst = 'pair_reserveETH_ASC_NULLS_FIRST', PairReserveEthDesc = 'pair_reserveETH_DESC', + PairReserveEthDescNullsLast = 'pair_reserveETH_DESC_NULLS_LAST', PairReserveUsdAsc = 'pair_reserveUSD_ASC', + PairReserveUsdAscNullsFirst = 'pair_reserveUSD_ASC_NULLS_FIRST', PairReserveUsdDesc = 'pair_reserveUSD_DESC', + PairReserveUsdDescNullsLast = 'pair_reserveUSD_DESC_NULLS_LAST', PairToken0PriceAsc = 'pair_token0Price_ASC', + PairToken0PriceAscNullsFirst = 'pair_token0Price_ASC_NULLS_FIRST', PairToken0PriceDesc = 'pair_token0Price_DESC', + PairToken0PriceDescNullsLast = 'pair_token0Price_DESC_NULLS_LAST', PairToken1PriceAsc = 'pair_token1Price_ASC', + PairToken1PriceAscNullsFirst = 'pair_token1Price_ASC_NULLS_FIRST', PairToken1PriceDesc = 'pair_token1Price_DESC', + PairToken1PriceDescNullsLast = 'pair_token1Price_DESC_NULLS_LAST', PairTotalSupplyAsc = 'pair_totalSupply_ASC', + PairTotalSupplyAscNullsFirst = 'pair_totalSupply_ASC_NULLS_FIRST', PairTotalSupplyDesc = 'pair_totalSupply_DESC', + PairTotalSupplyDescNullsLast = 'pair_totalSupply_DESC_NULLS_LAST', PairTrackedReserveEthAsc = 'pair_trackedReserveETH_ASC', + PairTrackedReserveEthAscNullsFirst = 'pair_trackedReserveETH_ASC_NULLS_FIRST', PairTrackedReserveEthDesc = 'pair_trackedReserveETH_DESC', + PairTrackedReserveEthDescNullsLast = 'pair_trackedReserveETH_DESC_NULLS_LAST', PairTxCountAsc = 'pair_txCount_ASC', + PairTxCountAscNullsFirst = 'pair_txCount_ASC_NULLS_FIRST', PairTxCountDesc = 'pair_txCount_DESC', + PairTxCountDescNullsLast = 'pair_txCount_DESC_NULLS_LAST', PairUntrackedVolumeUsdAsc = 'pair_untrackedVolumeUSD_ASC', + PairUntrackedVolumeUsdAscNullsFirst = 'pair_untrackedVolumeUSD_ASC_NULLS_FIRST', PairUntrackedVolumeUsdDesc = 'pair_untrackedVolumeUSD_DESC', + PairUntrackedVolumeUsdDescNullsLast = 'pair_untrackedVolumeUSD_DESC_NULLS_LAST', PairVolumeToken0Asc = 'pair_volumeToken0_ASC', + PairVolumeToken0AscNullsFirst = 'pair_volumeToken0_ASC_NULLS_FIRST', PairVolumeToken0Desc = 'pair_volumeToken0_DESC', + PairVolumeToken0DescNullsLast = 'pair_volumeToken0_DESC_NULLS_LAST', PairVolumeToken1Asc = 'pair_volumeToken1_ASC', + PairVolumeToken1AscNullsFirst = 'pair_volumeToken1_ASC_NULLS_FIRST', PairVolumeToken1Desc = 'pair_volumeToken1_DESC', + PairVolumeToken1DescNullsLast = 'pair_volumeToken1_DESC_NULLS_LAST', PairVolumeUsdAsc = 'pair_volumeUSD_ASC', + PairVolumeUsdAscNullsFirst = 'pair_volumeUSD_ASC_NULLS_FIRST', PairVolumeUsdDesc = 'pair_volumeUSD_DESC', + PairVolumeUsdDescNullsLast = 'pair_volumeUSD_DESC_NULLS_LAST', SenderAsc = 'sender_ASC', + SenderAscNullsFirst = 'sender_ASC_NULLS_FIRST', SenderDesc = 'sender_DESC', + SenderDescNullsLast = 'sender_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', ToAsc = 'to_ASC', + ToAscNullsFirst = 'to_ASC_NULLS_FIRST', ToDesc = 'to_DESC', + ToDescNullsLast = 'to_DESC_NULLS_LAST', TransactionBlockNumberAsc = 'transaction_blockNumber_ASC', + TransactionBlockNumberAscNullsFirst = 'transaction_blockNumber_ASC_NULLS_FIRST', TransactionBlockNumberDesc = 'transaction_blockNumber_DESC', + TransactionBlockNumberDescNullsLast = 'transaction_blockNumber_DESC_NULLS_LAST', TransactionIdAsc = 'transaction_id_ASC', + TransactionIdAscNullsFirst = 'transaction_id_ASC_NULLS_FIRST', TransactionIdDesc = 'transaction_id_DESC', + TransactionIdDescNullsLast = 'transaction_id_DESC_NULLS_LAST', TransactionTimestampAsc = 'transaction_timestamp_ASC', - TransactionTimestampDesc = 'transaction_timestamp_DESC' + TransactionTimestampAscNullsFirst = 'transaction_timestamp_ASC_NULLS_FIRST', + TransactionTimestampDesc = 'transaction_timestamp_DESC', + TransactionTimestampDescNullsLast = 'transaction_timestamp_DESC_NULLS_LAST' } export type MintWhereInput = { @@ -1908,13 +3458,21 @@ export type NablaTokenEdge = { export enum NablaTokenOrderByInput { DecimalsAsc = 'decimals_ASC', + DecimalsAscNullsFirst = 'decimals_ASC_NULLS_FIRST', DecimalsDesc = 'decimals_DESC', + DecimalsDescNullsLast = 'decimals_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', NameAsc = 'name_ASC', + NameAscNullsFirst = 'name_ASC_NULLS_FIRST', NameDesc = 'name_DESC', + NameDescNullsLast = 'name_DESC_NULLS_LAST', SymbolAsc = 'symbol_ASC', - SymbolDesc = 'symbol_DESC' + SymbolAscNullsFirst = 'symbol_ASC_NULLS_FIRST', + SymbolDesc = 'symbol_DESC', + SymbolDescNullsLast = 'symbol_DESC_NULLS_LAST' } export type NablaTokenWhereInput = { @@ -2011,21 +3569,37 @@ export type OraclePriceEdge = { export enum OraclePriceOrderByInput { BlockchainAsc = 'blockchain_ASC', + BlockchainAscNullsFirst = 'blockchain_ASC_NULLS_FIRST', BlockchainDesc = 'blockchain_DESC', + BlockchainDescNullsLast = 'blockchain_DESC_NULLS_LAST', DecimalsAsc = 'decimals_ASC', + DecimalsAscNullsFirst = 'decimals_ASC_NULLS_FIRST', DecimalsDesc = 'decimals_DESC', + DecimalsDescNullsLast = 'decimals_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', NameAsc = 'name_ASC', + NameAscNullsFirst = 'name_ASC_NULLS_FIRST', NameDesc = 'name_DESC', + NameDescNullsLast = 'name_DESC_NULLS_LAST', PriceAsc = 'price_ASC', + PriceAscNullsFirst = 'price_ASC_NULLS_FIRST', PriceDesc = 'price_DESC', + PriceDescNullsLast = 'price_DESC_NULLS_LAST', SupplyAsc = 'supply_ASC', + SupplyAscNullsFirst = 'supply_ASC_NULLS_FIRST', SupplyDesc = 'supply_DESC', + SupplyDescNullsLast = 'supply_DESC_NULLS_LAST', SymbolAsc = 'symbol_ASC', + SymbolAscNullsFirst = 'symbol_ASC_NULLS_FIRST', SymbolDesc = 'symbol_DESC', + SymbolDescNullsLast = 'symbol_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', - TimestampDesc = 'timestamp_DESC' + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', + TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST' } export type OraclePriceWhereInput = { @@ -2309,105 +3883,205 @@ export type PairDayDataEdge = { export enum PairDayDataOrderByInput { DailyTxnsAsc = 'dailyTxns_ASC', + DailyTxnsAscNullsFirst = 'dailyTxns_ASC_NULLS_FIRST', DailyTxnsDesc = 'dailyTxns_DESC', + DailyTxnsDescNullsLast = 'dailyTxns_DESC_NULLS_LAST', DailyVolumeToken0Asc = 'dailyVolumeToken0_ASC', + DailyVolumeToken0AscNullsFirst = 'dailyVolumeToken0_ASC_NULLS_FIRST', DailyVolumeToken0Desc = 'dailyVolumeToken0_DESC', + DailyVolumeToken0DescNullsLast = 'dailyVolumeToken0_DESC_NULLS_LAST', DailyVolumeToken1Asc = 'dailyVolumeToken1_ASC', + DailyVolumeToken1AscNullsFirst = 'dailyVolumeToken1_ASC_NULLS_FIRST', DailyVolumeToken1Desc = 'dailyVolumeToken1_DESC', + DailyVolumeToken1DescNullsLast = 'dailyVolumeToken1_DESC_NULLS_LAST', DailyVolumeUsdAsc = 'dailyVolumeUSD_ASC', + DailyVolumeUsdAscNullsFirst = 'dailyVolumeUSD_ASC_NULLS_FIRST', DailyVolumeUsdDesc = 'dailyVolumeUSD_DESC', + DailyVolumeUsdDescNullsLast = 'dailyVolumeUSD_DESC_NULLS_LAST', DateAsc = 'date_ASC', + DateAscNullsFirst = 'date_ASC_NULLS_FIRST', DateDesc = 'date_DESC', + DateDescNullsLast = 'date_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', PairAddressAsc = 'pairAddress_ASC', + PairAddressAscNullsFirst = 'pairAddress_ASC_NULLS_FIRST', PairAddressDesc = 'pairAddress_DESC', + PairAddressDescNullsLast = 'pairAddress_DESC_NULLS_LAST', PairCreatedAtBlockNumberAsc = 'pair_createdAtBlockNumber_ASC', + PairCreatedAtBlockNumberAscNullsFirst = 'pair_createdAtBlockNumber_ASC_NULLS_FIRST', PairCreatedAtBlockNumberDesc = 'pair_createdAtBlockNumber_DESC', + PairCreatedAtBlockNumberDescNullsLast = 'pair_createdAtBlockNumber_DESC_NULLS_LAST', PairCreatedAtTimestampAsc = 'pair_createdAtTimestamp_ASC', + PairCreatedAtTimestampAscNullsFirst = 'pair_createdAtTimestamp_ASC_NULLS_FIRST', PairCreatedAtTimestampDesc = 'pair_createdAtTimestamp_DESC', + PairCreatedAtTimestampDescNullsLast = 'pair_createdAtTimestamp_DESC_NULLS_LAST', PairIdAsc = 'pair_id_ASC', + PairIdAscNullsFirst = 'pair_id_ASC_NULLS_FIRST', PairIdDesc = 'pair_id_DESC', + PairIdDescNullsLast = 'pair_id_DESC_NULLS_LAST', PairLiquidityProviderCountAsc = 'pair_liquidityProviderCount_ASC', + PairLiquidityProviderCountAscNullsFirst = 'pair_liquidityProviderCount_ASC_NULLS_FIRST', PairLiquidityProviderCountDesc = 'pair_liquidityProviderCount_DESC', + PairLiquidityProviderCountDescNullsLast = 'pair_liquidityProviderCount_DESC_NULLS_LAST', PairReserve0Asc = 'pair_reserve0_ASC', + PairReserve0AscNullsFirst = 'pair_reserve0_ASC_NULLS_FIRST', PairReserve0Desc = 'pair_reserve0_DESC', + PairReserve0DescNullsLast = 'pair_reserve0_DESC_NULLS_LAST', PairReserve1Asc = 'pair_reserve1_ASC', + PairReserve1AscNullsFirst = 'pair_reserve1_ASC_NULLS_FIRST', PairReserve1Desc = 'pair_reserve1_DESC', + PairReserve1DescNullsLast = 'pair_reserve1_DESC_NULLS_LAST', PairReserveEthAsc = 'pair_reserveETH_ASC', + PairReserveEthAscNullsFirst = 'pair_reserveETH_ASC_NULLS_FIRST', PairReserveEthDesc = 'pair_reserveETH_DESC', + PairReserveEthDescNullsLast = 'pair_reserveETH_DESC_NULLS_LAST', PairReserveUsdAsc = 'pair_reserveUSD_ASC', + PairReserveUsdAscNullsFirst = 'pair_reserveUSD_ASC_NULLS_FIRST', PairReserveUsdDesc = 'pair_reserveUSD_DESC', + PairReserveUsdDescNullsLast = 'pair_reserveUSD_DESC_NULLS_LAST', PairToken0PriceAsc = 'pair_token0Price_ASC', + PairToken0PriceAscNullsFirst = 'pair_token0Price_ASC_NULLS_FIRST', PairToken0PriceDesc = 'pair_token0Price_DESC', + PairToken0PriceDescNullsLast = 'pair_token0Price_DESC_NULLS_LAST', PairToken1PriceAsc = 'pair_token1Price_ASC', + PairToken1PriceAscNullsFirst = 'pair_token1Price_ASC_NULLS_FIRST', PairToken1PriceDesc = 'pair_token1Price_DESC', + PairToken1PriceDescNullsLast = 'pair_token1Price_DESC_NULLS_LAST', PairTotalSupplyAsc = 'pair_totalSupply_ASC', + PairTotalSupplyAscNullsFirst = 'pair_totalSupply_ASC_NULLS_FIRST', PairTotalSupplyDesc = 'pair_totalSupply_DESC', + PairTotalSupplyDescNullsLast = 'pair_totalSupply_DESC_NULLS_LAST', PairTrackedReserveEthAsc = 'pair_trackedReserveETH_ASC', + PairTrackedReserveEthAscNullsFirst = 'pair_trackedReserveETH_ASC_NULLS_FIRST', PairTrackedReserveEthDesc = 'pair_trackedReserveETH_DESC', + PairTrackedReserveEthDescNullsLast = 'pair_trackedReserveETH_DESC_NULLS_LAST', PairTxCountAsc = 'pair_txCount_ASC', + PairTxCountAscNullsFirst = 'pair_txCount_ASC_NULLS_FIRST', PairTxCountDesc = 'pair_txCount_DESC', + PairTxCountDescNullsLast = 'pair_txCount_DESC_NULLS_LAST', PairUntrackedVolumeUsdAsc = 'pair_untrackedVolumeUSD_ASC', + PairUntrackedVolumeUsdAscNullsFirst = 'pair_untrackedVolumeUSD_ASC_NULLS_FIRST', PairUntrackedVolumeUsdDesc = 'pair_untrackedVolumeUSD_DESC', + PairUntrackedVolumeUsdDescNullsLast = 'pair_untrackedVolumeUSD_DESC_NULLS_LAST', PairVolumeToken0Asc = 'pair_volumeToken0_ASC', + PairVolumeToken0AscNullsFirst = 'pair_volumeToken0_ASC_NULLS_FIRST', PairVolumeToken0Desc = 'pair_volumeToken0_DESC', + PairVolumeToken0DescNullsLast = 'pair_volumeToken0_DESC_NULLS_LAST', PairVolumeToken1Asc = 'pair_volumeToken1_ASC', + PairVolumeToken1AscNullsFirst = 'pair_volumeToken1_ASC_NULLS_FIRST', PairVolumeToken1Desc = 'pair_volumeToken1_DESC', + PairVolumeToken1DescNullsLast = 'pair_volumeToken1_DESC_NULLS_LAST', PairVolumeUsdAsc = 'pair_volumeUSD_ASC', + PairVolumeUsdAscNullsFirst = 'pair_volumeUSD_ASC_NULLS_FIRST', PairVolumeUsdDesc = 'pair_volumeUSD_DESC', + PairVolumeUsdDescNullsLast = 'pair_volumeUSD_DESC_NULLS_LAST', Reserve0Asc = 'reserve0_ASC', + Reserve0AscNullsFirst = 'reserve0_ASC_NULLS_FIRST', Reserve0Desc = 'reserve0_DESC', + Reserve0DescNullsLast = 'reserve0_DESC_NULLS_LAST', Reserve1Asc = 'reserve1_ASC', + Reserve1AscNullsFirst = 'reserve1_ASC_NULLS_FIRST', Reserve1Desc = 'reserve1_DESC', + Reserve1DescNullsLast = 'reserve1_DESC_NULLS_LAST', ReserveUsdAsc = 'reserveUSD_ASC', + ReserveUsdAscNullsFirst = 'reserveUSD_ASC_NULLS_FIRST', ReserveUsdDesc = 'reserveUSD_DESC', + ReserveUsdDescNullsLast = 'reserveUSD_DESC_NULLS_LAST', Token0DecimalsAsc = 'token0_decimals_ASC', + Token0DecimalsAscNullsFirst = 'token0_decimals_ASC_NULLS_FIRST', Token0DecimalsDesc = 'token0_decimals_DESC', + Token0DecimalsDescNullsLast = 'token0_decimals_DESC_NULLS_LAST', Token0DerivedEthAsc = 'token0_derivedETH_ASC', + Token0DerivedEthAscNullsFirst = 'token0_derivedETH_ASC_NULLS_FIRST', Token0DerivedEthDesc = 'token0_derivedETH_DESC', + Token0DerivedEthDescNullsLast = 'token0_derivedETH_DESC_NULLS_LAST', Token0IdAsc = 'token0_id_ASC', + Token0IdAscNullsFirst = 'token0_id_ASC_NULLS_FIRST', Token0IdDesc = 'token0_id_DESC', + Token0IdDescNullsLast = 'token0_id_DESC_NULLS_LAST', Token0NameAsc = 'token0_name_ASC', + Token0NameAscNullsFirst = 'token0_name_ASC_NULLS_FIRST', Token0NameDesc = 'token0_name_DESC', + Token0NameDescNullsLast = 'token0_name_DESC_NULLS_LAST', Token0SymbolAsc = 'token0_symbol_ASC', + Token0SymbolAscNullsFirst = 'token0_symbol_ASC_NULLS_FIRST', Token0SymbolDesc = 'token0_symbol_DESC', + Token0SymbolDescNullsLast = 'token0_symbol_DESC_NULLS_LAST', Token0TotalLiquidityAsc = 'token0_totalLiquidity_ASC', + Token0TotalLiquidityAscNullsFirst = 'token0_totalLiquidity_ASC_NULLS_FIRST', Token0TotalLiquidityDesc = 'token0_totalLiquidity_DESC', + Token0TotalLiquidityDescNullsLast = 'token0_totalLiquidity_DESC_NULLS_LAST', Token0TotalSupplyAsc = 'token0_totalSupply_ASC', + Token0TotalSupplyAscNullsFirst = 'token0_totalSupply_ASC_NULLS_FIRST', Token0TotalSupplyDesc = 'token0_totalSupply_DESC', + Token0TotalSupplyDescNullsLast = 'token0_totalSupply_DESC_NULLS_LAST', Token0TradeVolumeUsdAsc = 'token0_tradeVolumeUSD_ASC', + Token0TradeVolumeUsdAscNullsFirst = 'token0_tradeVolumeUSD_ASC_NULLS_FIRST', Token0TradeVolumeUsdDesc = 'token0_tradeVolumeUSD_DESC', + Token0TradeVolumeUsdDescNullsLast = 'token0_tradeVolumeUSD_DESC_NULLS_LAST', Token0TradeVolumeAsc = 'token0_tradeVolume_ASC', + Token0TradeVolumeAscNullsFirst = 'token0_tradeVolume_ASC_NULLS_FIRST', Token0TradeVolumeDesc = 'token0_tradeVolume_DESC', + Token0TradeVolumeDescNullsLast = 'token0_tradeVolume_DESC_NULLS_LAST', Token0TxCountAsc = 'token0_txCount_ASC', + Token0TxCountAscNullsFirst = 'token0_txCount_ASC_NULLS_FIRST', Token0TxCountDesc = 'token0_txCount_DESC', + Token0TxCountDescNullsLast = 'token0_txCount_DESC_NULLS_LAST', Token0UntrackedVolumeUsdAsc = 'token0_untrackedVolumeUSD_ASC', + Token0UntrackedVolumeUsdAscNullsFirst = 'token0_untrackedVolumeUSD_ASC_NULLS_FIRST', Token0UntrackedVolumeUsdDesc = 'token0_untrackedVolumeUSD_DESC', + Token0UntrackedVolumeUsdDescNullsLast = 'token0_untrackedVolumeUSD_DESC_NULLS_LAST', Token1DecimalsAsc = 'token1_decimals_ASC', + Token1DecimalsAscNullsFirst = 'token1_decimals_ASC_NULLS_FIRST', Token1DecimalsDesc = 'token1_decimals_DESC', + Token1DecimalsDescNullsLast = 'token1_decimals_DESC_NULLS_LAST', Token1DerivedEthAsc = 'token1_derivedETH_ASC', + Token1DerivedEthAscNullsFirst = 'token1_derivedETH_ASC_NULLS_FIRST', Token1DerivedEthDesc = 'token1_derivedETH_DESC', + Token1DerivedEthDescNullsLast = 'token1_derivedETH_DESC_NULLS_LAST', Token1IdAsc = 'token1_id_ASC', + Token1IdAscNullsFirst = 'token1_id_ASC_NULLS_FIRST', Token1IdDesc = 'token1_id_DESC', + Token1IdDescNullsLast = 'token1_id_DESC_NULLS_LAST', Token1NameAsc = 'token1_name_ASC', + Token1NameAscNullsFirst = 'token1_name_ASC_NULLS_FIRST', Token1NameDesc = 'token1_name_DESC', + Token1NameDescNullsLast = 'token1_name_DESC_NULLS_LAST', Token1SymbolAsc = 'token1_symbol_ASC', + Token1SymbolAscNullsFirst = 'token1_symbol_ASC_NULLS_FIRST', Token1SymbolDesc = 'token1_symbol_DESC', + Token1SymbolDescNullsLast = 'token1_symbol_DESC_NULLS_LAST', Token1TotalLiquidityAsc = 'token1_totalLiquidity_ASC', + Token1TotalLiquidityAscNullsFirst = 'token1_totalLiquidity_ASC_NULLS_FIRST', Token1TotalLiquidityDesc = 'token1_totalLiquidity_DESC', + Token1TotalLiquidityDescNullsLast = 'token1_totalLiquidity_DESC_NULLS_LAST', Token1TotalSupplyAsc = 'token1_totalSupply_ASC', + Token1TotalSupplyAscNullsFirst = 'token1_totalSupply_ASC_NULLS_FIRST', Token1TotalSupplyDesc = 'token1_totalSupply_DESC', + Token1TotalSupplyDescNullsLast = 'token1_totalSupply_DESC_NULLS_LAST', Token1TradeVolumeUsdAsc = 'token1_tradeVolumeUSD_ASC', + Token1TradeVolumeUsdAscNullsFirst = 'token1_tradeVolumeUSD_ASC_NULLS_FIRST', Token1TradeVolumeUsdDesc = 'token1_tradeVolumeUSD_DESC', + Token1TradeVolumeUsdDescNullsLast = 'token1_tradeVolumeUSD_DESC_NULLS_LAST', Token1TradeVolumeAsc = 'token1_tradeVolume_ASC', + Token1TradeVolumeAscNullsFirst = 'token1_tradeVolume_ASC_NULLS_FIRST', Token1TradeVolumeDesc = 'token1_tradeVolume_DESC', + Token1TradeVolumeDescNullsLast = 'token1_tradeVolume_DESC_NULLS_LAST', Token1TxCountAsc = 'token1_txCount_ASC', + Token1TxCountAscNullsFirst = 'token1_txCount_ASC_NULLS_FIRST', Token1TxCountDesc = 'token1_txCount_DESC', + Token1TxCountDescNullsLast = 'token1_txCount_DESC_NULLS_LAST', Token1UntrackedVolumeUsdAsc = 'token1_untrackedVolumeUSD_ASC', + Token1UntrackedVolumeUsdAscNullsFirst = 'token1_untrackedVolumeUSD_ASC_NULLS_FIRST', Token1UntrackedVolumeUsdDesc = 'token1_untrackedVolumeUSD_DESC', + Token1UntrackedVolumeUsdDescNullsLast = 'token1_untrackedVolumeUSD_DESC_NULLS_LAST', TotalSupplyAsc = 'totalSupply_ASC', - TotalSupplyDesc = 'totalSupply_DESC' + TotalSupplyAscNullsFirst = 'totalSupply_ASC_NULLS_FIRST', + TotalSupplyDesc = 'totalSupply_DESC', + TotalSupplyDescNullsLast = 'totalSupply_DESC_NULLS_LAST' } export type PairDayDataWhereInput = { @@ -2628,59 +4302,113 @@ export type PairHourDataEdge = { export enum PairHourDataOrderByInput { HourStartUnixAsc = 'hourStartUnix_ASC', + HourStartUnixAscNullsFirst = 'hourStartUnix_ASC_NULLS_FIRST', HourStartUnixDesc = 'hourStartUnix_DESC', + HourStartUnixDescNullsLast = 'hourStartUnix_DESC_NULLS_LAST', HourlyTxnsAsc = 'hourlyTxns_ASC', + HourlyTxnsAscNullsFirst = 'hourlyTxns_ASC_NULLS_FIRST', HourlyTxnsDesc = 'hourlyTxns_DESC', + HourlyTxnsDescNullsLast = 'hourlyTxns_DESC_NULLS_LAST', HourlyVolumeToken0Asc = 'hourlyVolumeToken0_ASC', + HourlyVolumeToken0AscNullsFirst = 'hourlyVolumeToken0_ASC_NULLS_FIRST', HourlyVolumeToken0Desc = 'hourlyVolumeToken0_DESC', + HourlyVolumeToken0DescNullsLast = 'hourlyVolumeToken0_DESC_NULLS_LAST', HourlyVolumeToken1Asc = 'hourlyVolumeToken1_ASC', + HourlyVolumeToken1AscNullsFirst = 'hourlyVolumeToken1_ASC_NULLS_FIRST', HourlyVolumeToken1Desc = 'hourlyVolumeToken1_DESC', + HourlyVolumeToken1DescNullsLast = 'hourlyVolumeToken1_DESC_NULLS_LAST', HourlyVolumeUsdAsc = 'hourlyVolumeUSD_ASC', + HourlyVolumeUsdAscNullsFirst = 'hourlyVolumeUSD_ASC_NULLS_FIRST', HourlyVolumeUsdDesc = 'hourlyVolumeUSD_DESC', + HourlyVolumeUsdDescNullsLast = 'hourlyVolumeUSD_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', PairCreatedAtBlockNumberAsc = 'pair_createdAtBlockNumber_ASC', + PairCreatedAtBlockNumberAscNullsFirst = 'pair_createdAtBlockNumber_ASC_NULLS_FIRST', PairCreatedAtBlockNumberDesc = 'pair_createdAtBlockNumber_DESC', + PairCreatedAtBlockNumberDescNullsLast = 'pair_createdAtBlockNumber_DESC_NULLS_LAST', PairCreatedAtTimestampAsc = 'pair_createdAtTimestamp_ASC', + PairCreatedAtTimestampAscNullsFirst = 'pair_createdAtTimestamp_ASC_NULLS_FIRST', PairCreatedAtTimestampDesc = 'pair_createdAtTimestamp_DESC', + PairCreatedAtTimestampDescNullsLast = 'pair_createdAtTimestamp_DESC_NULLS_LAST', PairIdAsc = 'pair_id_ASC', + PairIdAscNullsFirst = 'pair_id_ASC_NULLS_FIRST', PairIdDesc = 'pair_id_DESC', + PairIdDescNullsLast = 'pair_id_DESC_NULLS_LAST', PairLiquidityProviderCountAsc = 'pair_liquidityProviderCount_ASC', + PairLiquidityProviderCountAscNullsFirst = 'pair_liquidityProviderCount_ASC_NULLS_FIRST', PairLiquidityProviderCountDesc = 'pair_liquidityProviderCount_DESC', + PairLiquidityProviderCountDescNullsLast = 'pair_liquidityProviderCount_DESC_NULLS_LAST', PairReserve0Asc = 'pair_reserve0_ASC', + PairReserve0AscNullsFirst = 'pair_reserve0_ASC_NULLS_FIRST', PairReserve0Desc = 'pair_reserve0_DESC', + PairReserve0DescNullsLast = 'pair_reserve0_DESC_NULLS_LAST', PairReserve1Asc = 'pair_reserve1_ASC', + PairReserve1AscNullsFirst = 'pair_reserve1_ASC_NULLS_FIRST', PairReserve1Desc = 'pair_reserve1_DESC', + PairReserve1DescNullsLast = 'pair_reserve1_DESC_NULLS_LAST', PairReserveEthAsc = 'pair_reserveETH_ASC', + PairReserveEthAscNullsFirst = 'pair_reserveETH_ASC_NULLS_FIRST', PairReserveEthDesc = 'pair_reserveETH_DESC', + PairReserveEthDescNullsLast = 'pair_reserveETH_DESC_NULLS_LAST', PairReserveUsdAsc = 'pair_reserveUSD_ASC', + PairReserveUsdAscNullsFirst = 'pair_reserveUSD_ASC_NULLS_FIRST', PairReserveUsdDesc = 'pair_reserveUSD_DESC', + PairReserveUsdDescNullsLast = 'pair_reserveUSD_DESC_NULLS_LAST', PairToken0PriceAsc = 'pair_token0Price_ASC', + PairToken0PriceAscNullsFirst = 'pair_token0Price_ASC_NULLS_FIRST', PairToken0PriceDesc = 'pair_token0Price_DESC', + PairToken0PriceDescNullsLast = 'pair_token0Price_DESC_NULLS_LAST', PairToken1PriceAsc = 'pair_token1Price_ASC', + PairToken1PriceAscNullsFirst = 'pair_token1Price_ASC_NULLS_FIRST', PairToken1PriceDesc = 'pair_token1Price_DESC', + PairToken1PriceDescNullsLast = 'pair_token1Price_DESC_NULLS_LAST', PairTotalSupplyAsc = 'pair_totalSupply_ASC', + PairTotalSupplyAscNullsFirst = 'pair_totalSupply_ASC_NULLS_FIRST', PairTotalSupplyDesc = 'pair_totalSupply_DESC', + PairTotalSupplyDescNullsLast = 'pair_totalSupply_DESC_NULLS_LAST', PairTrackedReserveEthAsc = 'pair_trackedReserveETH_ASC', + PairTrackedReserveEthAscNullsFirst = 'pair_trackedReserveETH_ASC_NULLS_FIRST', PairTrackedReserveEthDesc = 'pair_trackedReserveETH_DESC', + PairTrackedReserveEthDescNullsLast = 'pair_trackedReserveETH_DESC_NULLS_LAST', PairTxCountAsc = 'pair_txCount_ASC', + PairTxCountAscNullsFirst = 'pair_txCount_ASC_NULLS_FIRST', PairTxCountDesc = 'pair_txCount_DESC', + PairTxCountDescNullsLast = 'pair_txCount_DESC_NULLS_LAST', PairUntrackedVolumeUsdAsc = 'pair_untrackedVolumeUSD_ASC', + PairUntrackedVolumeUsdAscNullsFirst = 'pair_untrackedVolumeUSD_ASC_NULLS_FIRST', PairUntrackedVolumeUsdDesc = 'pair_untrackedVolumeUSD_DESC', + PairUntrackedVolumeUsdDescNullsLast = 'pair_untrackedVolumeUSD_DESC_NULLS_LAST', PairVolumeToken0Asc = 'pair_volumeToken0_ASC', + PairVolumeToken0AscNullsFirst = 'pair_volumeToken0_ASC_NULLS_FIRST', PairVolumeToken0Desc = 'pair_volumeToken0_DESC', + PairVolumeToken0DescNullsLast = 'pair_volumeToken0_DESC_NULLS_LAST', PairVolumeToken1Asc = 'pair_volumeToken1_ASC', + PairVolumeToken1AscNullsFirst = 'pair_volumeToken1_ASC_NULLS_FIRST', PairVolumeToken1Desc = 'pair_volumeToken1_DESC', + PairVolumeToken1DescNullsLast = 'pair_volumeToken1_DESC_NULLS_LAST', PairVolumeUsdAsc = 'pair_volumeUSD_ASC', + PairVolumeUsdAscNullsFirst = 'pair_volumeUSD_ASC_NULLS_FIRST', PairVolumeUsdDesc = 'pair_volumeUSD_DESC', + PairVolumeUsdDescNullsLast = 'pair_volumeUSD_DESC_NULLS_LAST', Reserve0Asc = 'reserve0_ASC', + Reserve0AscNullsFirst = 'reserve0_ASC_NULLS_FIRST', Reserve0Desc = 'reserve0_DESC', + Reserve0DescNullsLast = 'reserve0_DESC_NULLS_LAST', Reserve1Asc = 'reserve1_ASC', + Reserve1AscNullsFirst = 'reserve1_ASC_NULLS_FIRST', Reserve1Desc = 'reserve1_DESC', + Reserve1DescNullsLast = 'reserve1_DESC_NULLS_LAST', ReserveUsdAsc = 'reserveUSD_ASC', + ReserveUsdAscNullsFirst = 'reserveUSD_ASC_NULLS_FIRST', ReserveUsdDesc = 'reserveUSD_DESC', + ReserveUsdDescNullsLast = 'reserveUSD_DESC_NULLS_LAST', TotalSupplyAsc = 'totalSupply_ASC', - TotalSupplyDesc = 'totalSupply_DESC' + TotalSupplyAscNullsFirst = 'totalSupply_ASC_NULLS_FIRST', + TotalSupplyDesc = 'totalSupply_DESC', + TotalSupplyDescNullsLast = 'totalSupply_DESC_NULLS_LAST' } export type PairHourDataWhereInput = { @@ -2846,83 +4574,161 @@ export type PairHourDataWhereInput = { export enum PairOrderByInput { CreatedAtBlockNumberAsc = 'createdAtBlockNumber_ASC', + CreatedAtBlockNumberAscNullsFirst = 'createdAtBlockNumber_ASC_NULLS_FIRST', CreatedAtBlockNumberDesc = 'createdAtBlockNumber_DESC', + CreatedAtBlockNumberDescNullsLast = 'createdAtBlockNumber_DESC_NULLS_LAST', CreatedAtTimestampAsc = 'createdAtTimestamp_ASC', + CreatedAtTimestampAscNullsFirst = 'createdAtTimestamp_ASC_NULLS_FIRST', CreatedAtTimestampDesc = 'createdAtTimestamp_DESC', + CreatedAtTimestampDescNullsLast = 'createdAtTimestamp_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiquidityProviderCountAsc = 'liquidityProviderCount_ASC', + LiquidityProviderCountAscNullsFirst = 'liquidityProviderCount_ASC_NULLS_FIRST', LiquidityProviderCountDesc = 'liquidityProviderCount_DESC', + LiquidityProviderCountDescNullsLast = 'liquidityProviderCount_DESC_NULLS_LAST', Reserve0Asc = 'reserve0_ASC', + Reserve0AscNullsFirst = 'reserve0_ASC_NULLS_FIRST', Reserve0Desc = 'reserve0_DESC', + Reserve0DescNullsLast = 'reserve0_DESC_NULLS_LAST', Reserve1Asc = 'reserve1_ASC', + Reserve1AscNullsFirst = 'reserve1_ASC_NULLS_FIRST', Reserve1Desc = 'reserve1_DESC', + Reserve1DescNullsLast = 'reserve1_DESC_NULLS_LAST', ReserveEthAsc = 'reserveETH_ASC', + ReserveEthAscNullsFirst = 'reserveETH_ASC_NULLS_FIRST', ReserveEthDesc = 'reserveETH_DESC', + ReserveEthDescNullsLast = 'reserveETH_DESC_NULLS_LAST', ReserveUsdAsc = 'reserveUSD_ASC', + ReserveUsdAscNullsFirst = 'reserveUSD_ASC_NULLS_FIRST', ReserveUsdDesc = 'reserveUSD_DESC', + ReserveUsdDescNullsLast = 'reserveUSD_DESC_NULLS_LAST', Token0PriceAsc = 'token0Price_ASC', + Token0PriceAscNullsFirst = 'token0Price_ASC_NULLS_FIRST', Token0PriceDesc = 'token0Price_DESC', + Token0PriceDescNullsLast = 'token0Price_DESC_NULLS_LAST', Token0DecimalsAsc = 'token0_decimals_ASC', + Token0DecimalsAscNullsFirst = 'token0_decimals_ASC_NULLS_FIRST', Token0DecimalsDesc = 'token0_decimals_DESC', + Token0DecimalsDescNullsLast = 'token0_decimals_DESC_NULLS_LAST', Token0DerivedEthAsc = 'token0_derivedETH_ASC', + Token0DerivedEthAscNullsFirst = 'token0_derivedETH_ASC_NULLS_FIRST', Token0DerivedEthDesc = 'token0_derivedETH_DESC', + Token0DerivedEthDescNullsLast = 'token0_derivedETH_DESC_NULLS_LAST', Token0IdAsc = 'token0_id_ASC', + Token0IdAscNullsFirst = 'token0_id_ASC_NULLS_FIRST', Token0IdDesc = 'token0_id_DESC', + Token0IdDescNullsLast = 'token0_id_DESC_NULLS_LAST', Token0NameAsc = 'token0_name_ASC', + Token0NameAscNullsFirst = 'token0_name_ASC_NULLS_FIRST', Token0NameDesc = 'token0_name_DESC', + Token0NameDescNullsLast = 'token0_name_DESC_NULLS_LAST', Token0SymbolAsc = 'token0_symbol_ASC', + Token0SymbolAscNullsFirst = 'token0_symbol_ASC_NULLS_FIRST', Token0SymbolDesc = 'token0_symbol_DESC', + Token0SymbolDescNullsLast = 'token0_symbol_DESC_NULLS_LAST', Token0TotalLiquidityAsc = 'token0_totalLiquidity_ASC', + Token0TotalLiquidityAscNullsFirst = 'token0_totalLiquidity_ASC_NULLS_FIRST', Token0TotalLiquidityDesc = 'token0_totalLiquidity_DESC', + Token0TotalLiquidityDescNullsLast = 'token0_totalLiquidity_DESC_NULLS_LAST', Token0TotalSupplyAsc = 'token0_totalSupply_ASC', + Token0TotalSupplyAscNullsFirst = 'token0_totalSupply_ASC_NULLS_FIRST', Token0TotalSupplyDesc = 'token0_totalSupply_DESC', + Token0TotalSupplyDescNullsLast = 'token0_totalSupply_DESC_NULLS_LAST', Token0TradeVolumeUsdAsc = 'token0_tradeVolumeUSD_ASC', + Token0TradeVolumeUsdAscNullsFirst = 'token0_tradeVolumeUSD_ASC_NULLS_FIRST', Token0TradeVolumeUsdDesc = 'token0_tradeVolumeUSD_DESC', + Token0TradeVolumeUsdDescNullsLast = 'token0_tradeVolumeUSD_DESC_NULLS_LAST', Token0TradeVolumeAsc = 'token0_tradeVolume_ASC', + Token0TradeVolumeAscNullsFirst = 'token0_tradeVolume_ASC_NULLS_FIRST', Token0TradeVolumeDesc = 'token0_tradeVolume_DESC', + Token0TradeVolumeDescNullsLast = 'token0_tradeVolume_DESC_NULLS_LAST', Token0TxCountAsc = 'token0_txCount_ASC', + Token0TxCountAscNullsFirst = 'token0_txCount_ASC_NULLS_FIRST', Token0TxCountDesc = 'token0_txCount_DESC', + Token0TxCountDescNullsLast = 'token0_txCount_DESC_NULLS_LAST', Token0UntrackedVolumeUsdAsc = 'token0_untrackedVolumeUSD_ASC', + Token0UntrackedVolumeUsdAscNullsFirst = 'token0_untrackedVolumeUSD_ASC_NULLS_FIRST', Token0UntrackedVolumeUsdDesc = 'token0_untrackedVolumeUSD_DESC', + Token0UntrackedVolumeUsdDescNullsLast = 'token0_untrackedVolumeUSD_DESC_NULLS_LAST', Token1PriceAsc = 'token1Price_ASC', + Token1PriceAscNullsFirst = 'token1Price_ASC_NULLS_FIRST', Token1PriceDesc = 'token1Price_DESC', + Token1PriceDescNullsLast = 'token1Price_DESC_NULLS_LAST', Token1DecimalsAsc = 'token1_decimals_ASC', + Token1DecimalsAscNullsFirst = 'token1_decimals_ASC_NULLS_FIRST', Token1DecimalsDesc = 'token1_decimals_DESC', + Token1DecimalsDescNullsLast = 'token1_decimals_DESC_NULLS_LAST', Token1DerivedEthAsc = 'token1_derivedETH_ASC', + Token1DerivedEthAscNullsFirst = 'token1_derivedETH_ASC_NULLS_FIRST', Token1DerivedEthDesc = 'token1_derivedETH_DESC', + Token1DerivedEthDescNullsLast = 'token1_derivedETH_DESC_NULLS_LAST', Token1IdAsc = 'token1_id_ASC', + Token1IdAscNullsFirst = 'token1_id_ASC_NULLS_FIRST', Token1IdDesc = 'token1_id_DESC', + Token1IdDescNullsLast = 'token1_id_DESC_NULLS_LAST', Token1NameAsc = 'token1_name_ASC', + Token1NameAscNullsFirst = 'token1_name_ASC_NULLS_FIRST', Token1NameDesc = 'token1_name_DESC', + Token1NameDescNullsLast = 'token1_name_DESC_NULLS_LAST', Token1SymbolAsc = 'token1_symbol_ASC', + Token1SymbolAscNullsFirst = 'token1_symbol_ASC_NULLS_FIRST', Token1SymbolDesc = 'token1_symbol_DESC', + Token1SymbolDescNullsLast = 'token1_symbol_DESC_NULLS_LAST', Token1TotalLiquidityAsc = 'token1_totalLiquidity_ASC', + Token1TotalLiquidityAscNullsFirst = 'token1_totalLiquidity_ASC_NULLS_FIRST', Token1TotalLiquidityDesc = 'token1_totalLiquidity_DESC', + Token1TotalLiquidityDescNullsLast = 'token1_totalLiquidity_DESC_NULLS_LAST', Token1TotalSupplyAsc = 'token1_totalSupply_ASC', + Token1TotalSupplyAscNullsFirst = 'token1_totalSupply_ASC_NULLS_FIRST', Token1TotalSupplyDesc = 'token1_totalSupply_DESC', + Token1TotalSupplyDescNullsLast = 'token1_totalSupply_DESC_NULLS_LAST', Token1TradeVolumeUsdAsc = 'token1_tradeVolumeUSD_ASC', + Token1TradeVolumeUsdAscNullsFirst = 'token1_tradeVolumeUSD_ASC_NULLS_FIRST', Token1TradeVolumeUsdDesc = 'token1_tradeVolumeUSD_DESC', + Token1TradeVolumeUsdDescNullsLast = 'token1_tradeVolumeUSD_DESC_NULLS_LAST', Token1TradeVolumeAsc = 'token1_tradeVolume_ASC', + Token1TradeVolumeAscNullsFirst = 'token1_tradeVolume_ASC_NULLS_FIRST', Token1TradeVolumeDesc = 'token1_tradeVolume_DESC', + Token1TradeVolumeDescNullsLast = 'token1_tradeVolume_DESC_NULLS_LAST', Token1TxCountAsc = 'token1_txCount_ASC', + Token1TxCountAscNullsFirst = 'token1_txCount_ASC_NULLS_FIRST', Token1TxCountDesc = 'token1_txCount_DESC', + Token1TxCountDescNullsLast = 'token1_txCount_DESC_NULLS_LAST', Token1UntrackedVolumeUsdAsc = 'token1_untrackedVolumeUSD_ASC', + Token1UntrackedVolumeUsdAscNullsFirst = 'token1_untrackedVolumeUSD_ASC_NULLS_FIRST', Token1UntrackedVolumeUsdDesc = 'token1_untrackedVolumeUSD_DESC', + Token1UntrackedVolumeUsdDescNullsLast = 'token1_untrackedVolumeUSD_DESC_NULLS_LAST', TotalSupplyAsc = 'totalSupply_ASC', + TotalSupplyAscNullsFirst = 'totalSupply_ASC_NULLS_FIRST', TotalSupplyDesc = 'totalSupply_DESC', + TotalSupplyDescNullsLast = 'totalSupply_DESC_NULLS_LAST', TrackedReserveEthAsc = 'trackedReserveETH_ASC', + TrackedReserveEthAscNullsFirst = 'trackedReserveETH_ASC_NULLS_FIRST', TrackedReserveEthDesc = 'trackedReserveETH_DESC', + TrackedReserveEthDescNullsLast = 'trackedReserveETH_DESC_NULLS_LAST', TxCountAsc = 'txCount_ASC', + TxCountAscNullsFirst = 'txCount_ASC_NULLS_FIRST', TxCountDesc = 'txCount_DESC', + TxCountDescNullsLast = 'txCount_DESC_NULLS_LAST', UntrackedVolumeUsdAsc = 'untrackedVolumeUSD_ASC', + UntrackedVolumeUsdAscNullsFirst = 'untrackedVolumeUSD_ASC_NULLS_FIRST', UntrackedVolumeUsdDesc = 'untrackedVolumeUSD_DESC', + UntrackedVolumeUsdDescNullsLast = 'untrackedVolumeUSD_DESC_NULLS_LAST', VolumeToken0Asc = 'volumeToken0_ASC', + VolumeToken0AscNullsFirst = 'volumeToken0_ASC_NULLS_FIRST', VolumeToken0Desc = 'volumeToken0_DESC', + VolumeToken0DescNullsLast = 'volumeToken0_DESC_NULLS_LAST', VolumeToken1Asc = 'volumeToken1_ASC', + VolumeToken1AscNullsFirst = 'volumeToken1_ASC_NULLS_FIRST', VolumeToken1Desc = 'volumeToken1_DESC', + VolumeToken1DescNullsLast = 'volumeToken1_DESC_NULLS_LAST', VolumeUsdAsc = 'volumeUSD_ASC', - VolumeUsdDesc = 'volumeUSD_DESC' + VolumeUsdAscNullsFirst = 'volumeUSD_ASC_NULLS_FIRST', + VolumeUsdDesc = 'volumeUSD_DESC', + VolumeUsdDescNullsLast = 'volumeUSD_DESC_NULLS_LAST' } export type PairWhereInput = { @@ -3229,6 +5035,11 @@ export type Query = { backstopPoolByUniqueInput?: Maybe; backstopPools: Array; backstopPoolsConnection: BackstopPoolsConnection; + blockById?: Maybe; + /** @deprecated Use blockById */ + blockByUniqueInput?: Maybe; + blocks: Array; + blocksConnection: BlocksConnection; bundleById?: Maybe; /** @deprecated Use bundleById */ bundleByUniqueInput?: Maybe; @@ -3239,6 +5050,21 @@ export type Query = { burnByUniqueInput?: Maybe; burns: Array; burnsConnection: BurnsConnection; + callById?: Maybe; + /** @deprecated Use callById */ + callByUniqueInput?: Maybe; + calls: Array; + callsConnection: CallsConnection; + eventById?: Maybe; + /** @deprecated Use eventById */ + eventByUniqueInput?: Maybe; + events: Array; + eventsConnection: EventsConnection; + extrinsicById?: Maybe; + /** @deprecated Use extrinsicById */ + extrinsicByUniqueInput?: Maybe; + extrinsics: Array; + extrinsicsConnection: ExtrinsicsConnection; factories: Array; factoriesConnection: FactoriesConnection; factoryById?: Maybe; @@ -3259,6 +5085,11 @@ export type Query = { incentiveByUniqueInput?: Maybe; incentives: Array; incentivesConnection: IncentivesConnection; + itemsCounterById?: Maybe; + /** @deprecated Use itemsCounterById */ + itemsCounterByUniqueInput?: Maybe; + itemsCounters: Array; + itemsCountersConnection: ItemsCountersConnection; liquidityPositionById?: Maybe; /** @deprecated Use liquidityPositionById */ liquidityPositionByUniqueInput?: Maybe; @@ -3459,6 +5290,32 @@ export type QueryBackstopPoolsConnectionArgs = { }; +export type QueryBlockByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type QueryBlockByUniqueInputArgs = { + where: WhereIdInput; +}; + + +export type QueryBlocksArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type QueryBlocksConnectionArgs = { + after?: InputMaybe; + first?: InputMaybe; + orderBy: Array; + where?: InputMaybe; +}; + + export type QueryBundleByIdArgs = { id: Scalars['String']['input']; }; @@ -3511,6 +5368,84 @@ export type QueryBurnsConnectionArgs = { }; +export type QueryCallByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type QueryCallByUniqueInputArgs = { + where: WhereIdInput; +}; + + +export type QueryCallsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type QueryCallsConnectionArgs = { + after?: InputMaybe; + first?: InputMaybe; + orderBy: Array; + where?: InputMaybe; +}; + + +export type QueryEventByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type QueryEventByUniqueInputArgs = { + where: WhereIdInput; +}; + + +export type QueryEventsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type QueryEventsConnectionArgs = { + after?: InputMaybe; + first?: InputMaybe; + orderBy: Array; + where?: InputMaybe; +}; + + +export type QueryExtrinsicByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type QueryExtrinsicByUniqueInputArgs = { + where: WhereIdInput; +}; + + +export type QueryExtrinsicsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type QueryExtrinsicsConnectionArgs = { + after?: InputMaybe; + first?: InputMaybe; + orderBy: Array; + where?: InputMaybe; +}; + + export type QueryFactoriesArgs = { limit?: InputMaybe; offset?: InputMaybe; @@ -3615,6 +5550,32 @@ export type QueryIncentivesConnectionArgs = { }; +export type QueryItemsCounterByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type QueryItemsCounterByUniqueInputArgs = { + where: WhereIdInput; +}; + + +export type QueryItemsCountersArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type QueryItemsCountersConnectionArgs = { + after?: InputMaybe; + first?: InputMaybe; + orderBy: Array; + where?: InputMaybe; +}; + + export type QueryLiquidityPositionByIdArgs = { id: Scalars['String']['input']; }; @@ -4530,9 +6491,13 @@ export type RouterEdge = { export enum RouterOrderByInput { IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', PausedAsc = 'paused_ASC', - PausedDesc = 'paused_DESC' + PausedAscNullsFirst = 'paused_ASC_NULLS_FIRST', + PausedDesc = 'paused_DESC', + PausedDescNullsLast = 'paused_DESC_NULLS_LAST' } export type RouterWhereInput = { @@ -4636,23 +6601,41 @@ export type SingleTokenLockDayDataEdge = { export enum SingleTokenLockDayDataOrderByInput { DateAsc = 'date_ASC', + DateAscNullsFirst = 'date_ASC_NULLS_FIRST', DateDesc = 'date_DESC', + DateDescNullsLast = 'date_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', SingleTokenLockIdAsc = 'singleTokenLock_id_ASC', + SingleTokenLockIdAscNullsFirst = 'singleTokenLock_id_ASC_NULLS_FIRST', SingleTokenLockIdDesc = 'singleTokenLock_id_DESC', + SingleTokenLockIdDescNullsLast = 'singleTokenLock_id_DESC_NULLS_LAST', SingleTokenLockTotalLiquidityEthAsc = 'singleTokenLock_totalLiquidityETH_ASC', + SingleTokenLockTotalLiquidityEthAscNullsFirst = 'singleTokenLock_totalLiquidityETH_ASC_NULLS_FIRST', SingleTokenLockTotalLiquidityEthDesc = 'singleTokenLock_totalLiquidityETH_DESC', + SingleTokenLockTotalLiquidityEthDescNullsLast = 'singleTokenLock_totalLiquidityETH_DESC_NULLS_LAST', SingleTokenLockTotalLiquidityUsdAsc = 'singleTokenLock_totalLiquidityUSD_ASC', + SingleTokenLockTotalLiquidityUsdAscNullsFirst = 'singleTokenLock_totalLiquidityUSD_ASC_NULLS_FIRST', SingleTokenLockTotalLiquidityUsdDesc = 'singleTokenLock_totalLiquidityUSD_DESC', + SingleTokenLockTotalLiquidityUsdDescNullsLast = 'singleTokenLock_totalLiquidityUSD_DESC_NULLS_LAST', SingleTokenLockTotalLiquidityAsc = 'singleTokenLock_totalLiquidity_ASC', + SingleTokenLockTotalLiquidityAscNullsFirst = 'singleTokenLock_totalLiquidity_ASC_NULLS_FIRST', SingleTokenLockTotalLiquidityDesc = 'singleTokenLock_totalLiquidity_DESC', + SingleTokenLockTotalLiquidityDescNullsLast = 'singleTokenLock_totalLiquidity_DESC_NULLS_LAST', TotalLiquidityEthAsc = 'totalLiquidityETH_ASC', + TotalLiquidityEthAscNullsFirst = 'totalLiquidityETH_ASC_NULLS_FIRST', TotalLiquidityEthDesc = 'totalLiquidityETH_DESC', + TotalLiquidityEthDescNullsLast = 'totalLiquidityETH_DESC_NULLS_LAST', TotalLiquidityUsdAsc = 'totalLiquidityUSD_ASC', + TotalLiquidityUsdAscNullsFirst = 'totalLiquidityUSD_ASC_NULLS_FIRST', TotalLiquidityUsdDesc = 'totalLiquidityUSD_DESC', + TotalLiquidityUsdDescNullsLast = 'totalLiquidityUSD_DESC_NULLS_LAST', TotalLiquidityAsc = 'totalLiquidity_ASC', - TotalLiquidityDesc = 'totalLiquidity_DESC' + TotalLiquidityAscNullsFirst = 'totalLiquidity_ASC_NULLS_FIRST', + TotalLiquidityDesc = 'totalLiquidity_DESC', + TotalLiquidityDescNullsLast = 'totalLiquidity_DESC_NULLS_LAST' } export type SingleTokenLockDayDataWhereInput = { @@ -4770,23 +6753,41 @@ export type SingleTokenLockHourDataEdge = { export enum SingleTokenLockHourDataOrderByInput { HourStartUnixAsc = 'hourStartUnix_ASC', + HourStartUnixAscNullsFirst = 'hourStartUnix_ASC_NULLS_FIRST', HourStartUnixDesc = 'hourStartUnix_DESC', + HourStartUnixDescNullsLast = 'hourStartUnix_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', SingleTokenLockIdAsc = 'singleTokenLock_id_ASC', + SingleTokenLockIdAscNullsFirst = 'singleTokenLock_id_ASC_NULLS_FIRST', SingleTokenLockIdDesc = 'singleTokenLock_id_DESC', + SingleTokenLockIdDescNullsLast = 'singleTokenLock_id_DESC_NULLS_LAST', SingleTokenLockTotalLiquidityEthAsc = 'singleTokenLock_totalLiquidityETH_ASC', + SingleTokenLockTotalLiquidityEthAscNullsFirst = 'singleTokenLock_totalLiquidityETH_ASC_NULLS_FIRST', SingleTokenLockTotalLiquidityEthDesc = 'singleTokenLock_totalLiquidityETH_DESC', + SingleTokenLockTotalLiquidityEthDescNullsLast = 'singleTokenLock_totalLiquidityETH_DESC_NULLS_LAST', SingleTokenLockTotalLiquidityUsdAsc = 'singleTokenLock_totalLiquidityUSD_ASC', + SingleTokenLockTotalLiquidityUsdAscNullsFirst = 'singleTokenLock_totalLiquidityUSD_ASC_NULLS_FIRST', SingleTokenLockTotalLiquidityUsdDesc = 'singleTokenLock_totalLiquidityUSD_DESC', + SingleTokenLockTotalLiquidityUsdDescNullsLast = 'singleTokenLock_totalLiquidityUSD_DESC_NULLS_LAST', SingleTokenLockTotalLiquidityAsc = 'singleTokenLock_totalLiquidity_ASC', + SingleTokenLockTotalLiquidityAscNullsFirst = 'singleTokenLock_totalLiquidity_ASC_NULLS_FIRST', SingleTokenLockTotalLiquidityDesc = 'singleTokenLock_totalLiquidity_DESC', + SingleTokenLockTotalLiquidityDescNullsLast = 'singleTokenLock_totalLiquidity_DESC_NULLS_LAST', TotalLiquidityEthAsc = 'totalLiquidityETH_ASC', + TotalLiquidityEthAscNullsFirst = 'totalLiquidityETH_ASC_NULLS_FIRST', TotalLiquidityEthDesc = 'totalLiquidityETH_DESC', + TotalLiquidityEthDescNullsLast = 'totalLiquidityETH_DESC_NULLS_LAST', TotalLiquidityUsdAsc = 'totalLiquidityUSD_ASC', + TotalLiquidityUsdAscNullsFirst = 'totalLiquidityUSD_ASC_NULLS_FIRST', TotalLiquidityUsdDesc = 'totalLiquidityUSD_DESC', + TotalLiquidityUsdDescNullsLast = 'totalLiquidityUSD_DESC_NULLS_LAST', TotalLiquidityAsc = 'totalLiquidity_ASC', - TotalLiquidityDesc = 'totalLiquidity_DESC' + TotalLiquidityAscNullsFirst = 'totalLiquidity_ASC_NULLS_FIRST', + TotalLiquidityDesc = 'totalLiquidity_DESC', + TotalLiquidityDescNullsLast = 'totalLiquidity_DESC_NULLS_LAST' } export type SingleTokenLockHourDataWhereInput = { @@ -4875,35 +6876,65 @@ export type SingleTokenLockHourDataWhereInput = { export enum SingleTokenLockOrderByInput { IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', TokenDecimalsAsc = 'token_decimals_ASC', + TokenDecimalsAscNullsFirst = 'token_decimals_ASC_NULLS_FIRST', TokenDecimalsDesc = 'token_decimals_DESC', + TokenDecimalsDescNullsLast = 'token_decimals_DESC_NULLS_LAST', TokenDerivedEthAsc = 'token_derivedETH_ASC', + TokenDerivedEthAscNullsFirst = 'token_derivedETH_ASC_NULLS_FIRST', TokenDerivedEthDesc = 'token_derivedETH_DESC', + TokenDerivedEthDescNullsLast = 'token_derivedETH_DESC_NULLS_LAST', TokenIdAsc = 'token_id_ASC', + TokenIdAscNullsFirst = 'token_id_ASC_NULLS_FIRST', TokenIdDesc = 'token_id_DESC', + TokenIdDescNullsLast = 'token_id_DESC_NULLS_LAST', TokenNameAsc = 'token_name_ASC', + TokenNameAscNullsFirst = 'token_name_ASC_NULLS_FIRST', TokenNameDesc = 'token_name_DESC', + TokenNameDescNullsLast = 'token_name_DESC_NULLS_LAST', TokenSymbolAsc = 'token_symbol_ASC', + TokenSymbolAscNullsFirst = 'token_symbol_ASC_NULLS_FIRST', TokenSymbolDesc = 'token_symbol_DESC', + TokenSymbolDescNullsLast = 'token_symbol_DESC_NULLS_LAST', TokenTotalLiquidityAsc = 'token_totalLiquidity_ASC', + TokenTotalLiquidityAscNullsFirst = 'token_totalLiquidity_ASC_NULLS_FIRST', TokenTotalLiquidityDesc = 'token_totalLiquidity_DESC', + TokenTotalLiquidityDescNullsLast = 'token_totalLiquidity_DESC_NULLS_LAST', TokenTotalSupplyAsc = 'token_totalSupply_ASC', + TokenTotalSupplyAscNullsFirst = 'token_totalSupply_ASC_NULLS_FIRST', TokenTotalSupplyDesc = 'token_totalSupply_DESC', + TokenTotalSupplyDescNullsLast = 'token_totalSupply_DESC_NULLS_LAST', TokenTradeVolumeUsdAsc = 'token_tradeVolumeUSD_ASC', + TokenTradeVolumeUsdAscNullsFirst = 'token_tradeVolumeUSD_ASC_NULLS_FIRST', TokenTradeVolumeUsdDesc = 'token_tradeVolumeUSD_DESC', + TokenTradeVolumeUsdDescNullsLast = 'token_tradeVolumeUSD_DESC_NULLS_LAST', TokenTradeVolumeAsc = 'token_tradeVolume_ASC', + TokenTradeVolumeAscNullsFirst = 'token_tradeVolume_ASC_NULLS_FIRST', TokenTradeVolumeDesc = 'token_tradeVolume_DESC', + TokenTradeVolumeDescNullsLast = 'token_tradeVolume_DESC_NULLS_LAST', TokenTxCountAsc = 'token_txCount_ASC', + TokenTxCountAscNullsFirst = 'token_txCount_ASC_NULLS_FIRST', TokenTxCountDesc = 'token_txCount_DESC', + TokenTxCountDescNullsLast = 'token_txCount_DESC_NULLS_LAST', TokenUntrackedVolumeUsdAsc = 'token_untrackedVolumeUSD_ASC', + TokenUntrackedVolumeUsdAscNullsFirst = 'token_untrackedVolumeUSD_ASC_NULLS_FIRST', TokenUntrackedVolumeUsdDesc = 'token_untrackedVolumeUSD_DESC', + TokenUntrackedVolumeUsdDescNullsLast = 'token_untrackedVolumeUSD_DESC_NULLS_LAST', TotalLiquidityEthAsc = 'totalLiquidityETH_ASC', + TotalLiquidityEthAscNullsFirst = 'totalLiquidityETH_ASC_NULLS_FIRST', TotalLiquidityEthDesc = 'totalLiquidityETH_DESC', + TotalLiquidityEthDescNullsLast = 'totalLiquidityETH_DESC_NULLS_LAST', TotalLiquidityUsdAsc = 'totalLiquidityUSD_ASC', + TotalLiquidityUsdAscNullsFirst = 'totalLiquidityUSD_ASC_NULLS_FIRST', TotalLiquidityUsdDesc = 'totalLiquidityUSD_DESC', + TotalLiquidityUsdDescNullsLast = 'totalLiquidityUSD_DESC_NULLS_LAST', TotalLiquidityAsc = 'totalLiquidity_ASC', - TotalLiquidityDesc = 'totalLiquidity_DESC' + TotalLiquidityAscNullsFirst = 'totalLiquidity_ASC_NULLS_FIRST', + TotalLiquidityDesc = 'totalLiquidity_DESC', + TotalLiquidityDescNullsLast = 'totalLiquidity_DESC_NULLS_LAST' } export type SingleTokenLockWhereInput = { @@ -5026,13 +7057,21 @@ export type StableDayDataEdge = { export enum StableDayDataOrderByInput { DailyVolumeUsdAsc = 'dailyVolumeUSD_ASC', + DailyVolumeUsdAscNullsFirst = 'dailyVolumeUSD_ASC_NULLS_FIRST', DailyVolumeUsdDesc = 'dailyVolumeUSD_DESC', + DailyVolumeUsdDescNullsLast = 'dailyVolumeUSD_DESC_NULLS_LAST', DateAsc = 'date_ASC', + DateAscNullsFirst = 'date_ASC_NULLS_FIRST', DateDesc = 'date_DESC', + DateDescNullsLast = 'date_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', TvlUsdAsc = 'tvlUSD_ASC', - TvlUsdDesc = 'tvlUSD_DESC' + TvlUsdAscNullsFirst = 'tvlUSD_ASC_NULLS_FIRST', + TvlUsdDesc = 'tvlUSD_DESC', + TvlUsdDescNullsLast = 'tvlUSD_DESC_NULLS_LAST' } export type StableDayDataWhereInput = { @@ -5201,37 +7240,69 @@ export type StableSwapDayDataEdge = { export enum StableSwapDayDataOrderByInput { DailyVolumeUsdAsc = 'dailyVolumeUSD_ASC', + DailyVolumeUsdAscNullsFirst = 'dailyVolumeUSD_ASC_NULLS_FIRST', DailyVolumeUsdDesc = 'dailyVolumeUSD_DESC', + DailyVolumeUsdDescNullsLast = 'dailyVolumeUSD_DESC_NULLS_LAST', DateAsc = 'date_ASC', + DateAscNullsFirst = 'date_ASC_NULLS_FIRST', DateDesc = 'date_DESC', + DateDescNullsLast = 'date_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', StableSwapAAsc = 'stableSwap_a_ASC', + StableSwapAAscNullsFirst = 'stableSwap_a_ASC_NULLS_FIRST', StableSwapADesc = 'stableSwap_a_DESC', + StableSwapADescNullsLast = 'stableSwap_a_DESC_NULLS_LAST', StableSwapAddressAsc = 'stableSwap_address_ASC', + StableSwapAddressAscNullsFirst = 'stableSwap_address_ASC_NULLS_FIRST', StableSwapAddressDesc = 'stableSwap_address_DESC', + StableSwapAddressDescNullsLast = 'stableSwap_address_DESC_NULLS_LAST', StableSwapAdminFeeAsc = 'stableSwap_adminFee_ASC', + StableSwapAdminFeeAscNullsFirst = 'stableSwap_adminFee_ASC_NULLS_FIRST', StableSwapAdminFeeDesc = 'stableSwap_adminFee_DESC', + StableSwapAdminFeeDescNullsLast = 'stableSwap_adminFee_DESC_NULLS_LAST', StableSwapBaseSwapAddressAsc = 'stableSwap_baseSwapAddress_ASC', + StableSwapBaseSwapAddressAscNullsFirst = 'stableSwap_baseSwapAddress_ASC_NULLS_FIRST', StableSwapBaseSwapAddressDesc = 'stableSwap_baseSwapAddress_DESC', + StableSwapBaseSwapAddressDescNullsLast = 'stableSwap_baseSwapAddress_DESC_NULLS_LAST', StableSwapIdAsc = 'stableSwap_id_ASC', + StableSwapIdAscNullsFirst = 'stableSwap_id_ASC_NULLS_FIRST', StableSwapIdDesc = 'stableSwap_id_DESC', + StableSwapIdDescNullsLast = 'stableSwap_id_DESC_NULLS_LAST', StableSwapLpTokenAsc = 'stableSwap_lpToken_ASC', + StableSwapLpTokenAscNullsFirst = 'stableSwap_lpToken_ASC_NULLS_FIRST', StableSwapLpTokenDesc = 'stableSwap_lpToken_DESC', + StableSwapLpTokenDescNullsLast = 'stableSwap_lpToken_DESC_NULLS_LAST', StableSwapLpTotalSupplyAsc = 'stableSwap_lpTotalSupply_ASC', + StableSwapLpTotalSupplyAscNullsFirst = 'stableSwap_lpTotalSupply_ASC_NULLS_FIRST', StableSwapLpTotalSupplyDesc = 'stableSwap_lpTotalSupply_DESC', + StableSwapLpTotalSupplyDescNullsLast = 'stableSwap_lpTotalSupply_DESC_NULLS_LAST', StableSwapNumTokensAsc = 'stableSwap_numTokens_ASC', + StableSwapNumTokensAscNullsFirst = 'stableSwap_numTokens_ASC_NULLS_FIRST', StableSwapNumTokensDesc = 'stableSwap_numTokens_DESC', + StableSwapNumTokensDescNullsLast = 'stableSwap_numTokens_DESC_NULLS_LAST', StableSwapSwapFeeAsc = 'stableSwap_swapFee_ASC', + StableSwapSwapFeeAscNullsFirst = 'stableSwap_swapFee_ASC_NULLS_FIRST', StableSwapSwapFeeDesc = 'stableSwap_swapFee_DESC', + StableSwapSwapFeeDescNullsLast = 'stableSwap_swapFee_DESC_NULLS_LAST', StableSwapTvlUsdAsc = 'stableSwap_tvlUSD_ASC', + StableSwapTvlUsdAscNullsFirst = 'stableSwap_tvlUSD_ASC_NULLS_FIRST', StableSwapTvlUsdDesc = 'stableSwap_tvlUSD_DESC', + StableSwapTvlUsdDescNullsLast = 'stableSwap_tvlUSD_DESC_NULLS_LAST', StableSwapVirtualPriceAsc = 'stableSwap_virtualPrice_ASC', + StableSwapVirtualPriceAscNullsFirst = 'stableSwap_virtualPrice_ASC_NULLS_FIRST', StableSwapVirtualPriceDesc = 'stableSwap_virtualPrice_DESC', + StableSwapVirtualPriceDescNullsLast = 'stableSwap_virtualPrice_DESC_NULLS_LAST', StableSwapVolumeUsdAsc = 'stableSwap_volumeUSD_ASC', + StableSwapVolumeUsdAscNullsFirst = 'stableSwap_volumeUSD_ASC_NULLS_FIRST', StableSwapVolumeUsdDesc = 'stableSwap_volumeUSD_DESC', + StableSwapVolumeUsdDescNullsLast = 'stableSwap_volumeUSD_DESC_NULLS_LAST', TvlUsdAsc = 'tvlUSD_ASC', - TvlUsdDesc = 'tvlUSD_DESC' + TvlUsdAscNullsFirst = 'tvlUSD_ASC_NULLS_FIRST', + TvlUsdDesc = 'tvlUSD_DESC', + TvlUsdDescNullsLast = 'tvlUSD_DESC_NULLS_LAST' } export type StableSwapDayDataWhereInput = { @@ -5458,65 +7529,125 @@ export type StableSwapEventEdge = { export enum StableSwapEventOrderByInput { BlockAsc = 'block_ASC', + BlockAscNullsFirst = 'block_ASC_NULLS_FIRST', BlockDesc = 'block_DESC', + BlockDescNullsLast = 'block_DESC_NULLS_LAST', DataAdminFeeAsc = 'data_adminFee_ASC', + DataAdminFeeAscNullsFirst = 'data_adminFee_ASC_NULLS_FIRST', DataAdminFeeDesc = 'data_adminFee_DESC', + DataAdminFeeDescNullsLast = 'data_adminFee_DESC_NULLS_LAST', DataCallerAsc = 'data_caller_ASC', + DataCallerAscNullsFirst = 'data_caller_ASC_NULLS_FIRST', DataCallerDesc = 'data_caller_DESC', + DataCallerDescNullsLast = 'data_caller_DESC_NULLS_LAST', DataCurrentAAsc = 'data_currentA_ASC', + DataCurrentAAscNullsFirst = 'data_currentA_ASC_NULLS_FIRST', DataCurrentADesc = 'data_currentA_DESC', + DataCurrentADescNullsLast = 'data_currentA_DESC_NULLS_LAST', DataFutureTimeAsc = 'data_futureTime_ASC', + DataFutureTimeAscNullsFirst = 'data_futureTime_ASC_NULLS_FIRST', DataFutureTimeDesc = 'data_futureTime_DESC', + DataFutureTimeDescNullsLast = 'data_futureTime_DESC_NULLS_LAST', DataInitialTimeAsc = 'data_initialTime_ASC', + DataInitialTimeAscNullsFirst = 'data_initialTime_ASC_NULLS_FIRST', DataInitialTimeDesc = 'data_initialTime_DESC', + DataInitialTimeDescNullsLast = 'data_initialTime_DESC_NULLS_LAST', DataInvariantAsc = 'data_invariant_ASC', + DataInvariantAscNullsFirst = 'data_invariant_ASC_NULLS_FIRST', DataInvariantDesc = 'data_invariant_DESC', + DataInvariantDescNullsLast = 'data_invariant_DESC_NULLS_LAST', DataIsTypeOfAsc = 'data_isTypeOf_ASC', + DataIsTypeOfAscNullsFirst = 'data_isTypeOf_ASC_NULLS_FIRST', DataIsTypeOfDesc = 'data_isTypeOf_DESC', + DataIsTypeOfDescNullsLast = 'data_isTypeOf_DESC_NULLS_LAST', DataLpTokenSupplyAsc = 'data_lpTokenSupply_ASC', + DataLpTokenSupplyAscNullsFirst = 'data_lpTokenSupply_ASC_NULLS_FIRST', DataLpTokenSupplyDesc = 'data_lpTokenSupply_DESC', + DataLpTokenSupplyDescNullsLast = 'data_lpTokenSupply_DESC_NULLS_LAST', DataNewAAsc = 'data_newA_ASC', + DataNewAAscNullsFirst = 'data_newA_ASC_NULLS_FIRST', DataNewADesc = 'data_newA_DESC', + DataNewADescNullsLast = 'data_newA_DESC_NULLS_LAST', DataOldAAsc = 'data_oldA_ASC', + DataOldAAscNullsFirst = 'data_oldA_ASC_NULLS_FIRST', DataOldADesc = 'data_oldA_DESC', + DataOldADescNullsLast = 'data_oldA_DESC_NULLS_LAST', DataProviderAsc = 'data_provider_ASC', + DataProviderAscNullsFirst = 'data_provider_ASC_NULLS_FIRST', DataProviderDesc = 'data_provider_DESC', + DataProviderDescNullsLast = 'data_provider_DESC_NULLS_LAST', DataReceiverAsc = 'data_receiver_ASC', + DataReceiverAscNullsFirst = 'data_receiver_ASC_NULLS_FIRST', DataReceiverDesc = 'data_receiver_DESC', + DataReceiverDescNullsLast = 'data_receiver_DESC_NULLS_LAST', DataSwapFeeAsc = 'data_swapFee_ASC', + DataSwapFeeAscNullsFirst = 'data_swapFee_ASC_NULLS_FIRST', DataSwapFeeDesc = 'data_swapFee_DESC', + DataSwapFeeDescNullsLast = 'data_swapFee_DESC_NULLS_LAST', DataTimeAsc = 'data_time_ASC', + DataTimeAscNullsFirst = 'data_time_ASC_NULLS_FIRST', DataTimeDesc = 'data_time_DESC', + DataTimeDescNullsLast = 'data_time_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', StableSwapAAsc = 'stableSwap_a_ASC', + StableSwapAAscNullsFirst = 'stableSwap_a_ASC_NULLS_FIRST', StableSwapADesc = 'stableSwap_a_DESC', + StableSwapADescNullsLast = 'stableSwap_a_DESC_NULLS_LAST', StableSwapAddressAsc = 'stableSwap_address_ASC', + StableSwapAddressAscNullsFirst = 'stableSwap_address_ASC_NULLS_FIRST', StableSwapAddressDesc = 'stableSwap_address_DESC', + StableSwapAddressDescNullsLast = 'stableSwap_address_DESC_NULLS_LAST', StableSwapAdminFeeAsc = 'stableSwap_adminFee_ASC', + StableSwapAdminFeeAscNullsFirst = 'stableSwap_adminFee_ASC_NULLS_FIRST', StableSwapAdminFeeDesc = 'stableSwap_adminFee_DESC', + StableSwapAdminFeeDescNullsLast = 'stableSwap_adminFee_DESC_NULLS_LAST', StableSwapBaseSwapAddressAsc = 'stableSwap_baseSwapAddress_ASC', + StableSwapBaseSwapAddressAscNullsFirst = 'stableSwap_baseSwapAddress_ASC_NULLS_FIRST', StableSwapBaseSwapAddressDesc = 'stableSwap_baseSwapAddress_DESC', + StableSwapBaseSwapAddressDescNullsLast = 'stableSwap_baseSwapAddress_DESC_NULLS_LAST', StableSwapIdAsc = 'stableSwap_id_ASC', + StableSwapIdAscNullsFirst = 'stableSwap_id_ASC_NULLS_FIRST', StableSwapIdDesc = 'stableSwap_id_DESC', + StableSwapIdDescNullsLast = 'stableSwap_id_DESC_NULLS_LAST', StableSwapLpTokenAsc = 'stableSwap_lpToken_ASC', + StableSwapLpTokenAscNullsFirst = 'stableSwap_lpToken_ASC_NULLS_FIRST', StableSwapLpTokenDesc = 'stableSwap_lpToken_DESC', + StableSwapLpTokenDescNullsLast = 'stableSwap_lpToken_DESC_NULLS_LAST', StableSwapLpTotalSupplyAsc = 'stableSwap_lpTotalSupply_ASC', + StableSwapLpTotalSupplyAscNullsFirst = 'stableSwap_lpTotalSupply_ASC_NULLS_FIRST', StableSwapLpTotalSupplyDesc = 'stableSwap_lpTotalSupply_DESC', + StableSwapLpTotalSupplyDescNullsLast = 'stableSwap_lpTotalSupply_DESC_NULLS_LAST', StableSwapNumTokensAsc = 'stableSwap_numTokens_ASC', + StableSwapNumTokensAscNullsFirst = 'stableSwap_numTokens_ASC_NULLS_FIRST', StableSwapNumTokensDesc = 'stableSwap_numTokens_DESC', + StableSwapNumTokensDescNullsLast = 'stableSwap_numTokens_DESC_NULLS_LAST', StableSwapSwapFeeAsc = 'stableSwap_swapFee_ASC', + StableSwapSwapFeeAscNullsFirst = 'stableSwap_swapFee_ASC_NULLS_FIRST', StableSwapSwapFeeDesc = 'stableSwap_swapFee_DESC', + StableSwapSwapFeeDescNullsLast = 'stableSwap_swapFee_DESC_NULLS_LAST', StableSwapTvlUsdAsc = 'stableSwap_tvlUSD_ASC', + StableSwapTvlUsdAscNullsFirst = 'stableSwap_tvlUSD_ASC_NULLS_FIRST', StableSwapTvlUsdDesc = 'stableSwap_tvlUSD_DESC', + StableSwapTvlUsdDescNullsLast = 'stableSwap_tvlUSD_DESC_NULLS_LAST', StableSwapVirtualPriceAsc = 'stableSwap_virtualPrice_ASC', + StableSwapVirtualPriceAscNullsFirst = 'stableSwap_virtualPrice_ASC_NULLS_FIRST', StableSwapVirtualPriceDesc = 'stableSwap_virtualPrice_DESC', + StableSwapVirtualPriceDescNullsLast = 'stableSwap_virtualPrice_DESC_NULLS_LAST', StableSwapVolumeUsdAsc = 'stableSwap_volumeUSD_ASC', + StableSwapVolumeUsdAscNullsFirst = 'stableSwap_volumeUSD_ASC_NULLS_FIRST', StableSwapVolumeUsdDesc = 'stableSwap_volumeUSD_DESC', + StableSwapVolumeUsdDescNullsLast = 'stableSwap_volumeUSD_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', TransactionAsc = 'transaction_ASC', - TransactionDesc = 'transaction_DESC' + TransactionAscNullsFirst = 'transaction_ASC_NULLS_FIRST', + TransactionDesc = 'transaction_DESC', + TransactionDescNullsLast = 'transaction_DESC_NULLS_LAST' } export type StableSwapEventWhereInput = { @@ -5652,49 +7783,93 @@ export type StableSwapExchangeEdge = { export enum StableSwapExchangeOrderByInput { BlockAsc = 'block_ASC', + BlockAscNullsFirst = 'block_ASC_NULLS_FIRST', BlockDesc = 'block_DESC', + BlockDescNullsLast = 'block_DESC_NULLS_LAST', DataBoughtIdAsc = 'data_boughtId_ASC', + DataBoughtIdAscNullsFirst = 'data_boughtId_ASC_NULLS_FIRST', DataBoughtIdDesc = 'data_boughtId_DESC', + DataBoughtIdDescNullsLast = 'data_boughtId_DESC_NULLS_LAST', DataBuyerAsc = 'data_buyer_ASC', + DataBuyerAscNullsFirst = 'data_buyer_ASC_NULLS_FIRST', DataBuyerDesc = 'data_buyer_DESC', + DataBuyerDescNullsLast = 'data_buyer_DESC_NULLS_LAST', DataIsTypeOfAsc = 'data_isTypeOf_ASC', + DataIsTypeOfAscNullsFirst = 'data_isTypeOf_ASC_NULLS_FIRST', DataIsTypeOfDesc = 'data_isTypeOf_DESC', + DataIsTypeOfDescNullsLast = 'data_isTypeOf_DESC_NULLS_LAST', DataSoldIdAsc = 'data_soldId_ASC', + DataSoldIdAscNullsFirst = 'data_soldId_ASC_NULLS_FIRST', DataSoldIdDesc = 'data_soldId_DESC', + DataSoldIdDescNullsLast = 'data_soldId_DESC_NULLS_LAST', DataTokensBoughtAsc = 'data_tokensBought_ASC', + DataTokensBoughtAscNullsFirst = 'data_tokensBought_ASC_NULLS_FIRST', DataTokensBoughtDesc = 'data_tokensBought_DESC', + DataTokensBoughtDescNullsLast = 'data_tokensBought_DESC_NULLS_LAST', DataTokensSoldAsc = 'data_tokensSold_ASC', + DataTokensSoldAscNullsFirst = 'data_tokensSold_ASC_NULLS_FIRST', DataTokensSoldDesc = 'data_tokensSold_DESC', + DataTokensSoldDescNullsLast = 'data_tokensSold_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', StableSwapAAsc = 'stableSwap_a_ASC', + StableSwapAAscNullsFirst = 'stableSwap_a_ASC_NULLS_FIRST', StableSwapADesc = 'stableSwap_a_DESC', + StableSwapADescNullsLast = 'stableSwap_a_DESC_NULLS_LAST', StableSwapAddressAsc = 'stableSwap_address_ASC', + StableSwapAddressAscNullsFirst = 'stableSwap_address_ASC_NULLS_FIRST', StableSwapAddressDesc = 'stableSwap_address_DESC', + StableSwapAddressDescNullsLast = 'stableSwap_address_DESC_NULLS_LAST', StableSwapAdminFeeAsc = 'stableSwap_adminFee_ASC', + StableSwapAdminFeeAscNullsFirst = 'stableSwap_adminFee_ASC_NULLS_FIRST', StableSwapAdminFeeDesc = 'stableSwap_adminFee_DESC', + StableSwapAdminFeeDescNullsLast = 'stableSwap_adminFee_DESC_NULLS_LAST', StableSwapBaseSwapAddressAsc = 'stableSwap_baseSwapAddress_ASC', + StableSwapBaseSwapAddressAscNullsFirst = 'stableSwap_baseSwapAddress_ASC_NULLS_FIRST', StableSwapBaseSwapAddressDesc = 'stableSwap_baseSwapAddress_DESC', + StableSwapBaseSwapAddressDescNullsLast = 'stableSwap_baseSwapAddress_DESC_NULLS_LAST', StableSwapIdAsc = 'stableSwap_id_ASC', + StableSwapIdAscNullsFirst = 'stableSwap_id_ASC_NULLS_FIRST', StableSwapIdDesc = 'stableSwap_id_DESC', + StableSwapIdDescNullsLast = 'stableSwap_id_DESC_NULLS_LAST', StableSwapLpTokenAsc = 'stableSwap_lpToken_ASC', + StableSwapLpTokenAscNullsFirst = 'stableSwap_lpToken_ASC_NULLS_FIRST', StableSwapLpTokenDesc = 'stableSwap_lpToken_DESC', + StableSwapLpTokenDescNullsLast = 'stableSwap_lpToken_DESC_NULLS_LAST', StableSwapLpTotalSupplyAsc = 'stableSwap_lpTotalSupply_ASC', + StableSwapLpTotalSupplyAscNullsFirst = 'stableSwap_lpTotalSupply_ASC_NULLS_FIRST', StableSwapLpTotalSupplyDesc = 'stableSwap_lpTotalSupply_DESC', + StableSwapLpTotalSupplyDescNullsLast = 'stableSwap_lpTotalSupply_DESC_NULLS_LAST', StableSwapNumTokensAsc = 'stableSwap_numTokens_ASC', + StableSwapNumTokensAscNullsFirst = 'stableSwap_numTokens_ASC_NULLS_FIRST', StableSwapNumTokensDesc = 'stableSwap_numTokens_DESC', + StableSwapNumTokensDescNullsLast = 'stableSwap_numTokens_DESC_NULLS_LAST', StableSwapSwapFeeAsc = 'stableSwap_swapFee_ASC', + StableSwapSwapFeeAscNullsFirst = 'stableSwap_swapFee_ASC_NULLS_FIRST', StableSwapSwapFeeDesc = 'stableSwap_swapFee_DESC', + StableSwapSwapFeeDescNullsLast = 'stableSwap_swapFee_DESC_NULLS_LAST', StableSwapTvlUsdAsc = 'stableSwap_tvlUSD_ASC', + StableSwapTvlUsdAscNullsFirst = 'stableSwap_tvlUSD_ASC_NULLS_FIRST', StableSwapTvlUsdDesc = 'stableSwap_tvlUSD_DESC', + StableSwapTvlUsdDescNullsLast = 'stableSwap_tvlUSD_DESC_NULLS_LAST', StableSwapVirtualPriceAsc = 'stableSwap_virtualPrice_ASC', + StableSwapVirtualPriceAscNullsFirst = 'stableSwap_virtualPrice_ASC_NULLS_FIRST', StableSwapVirtualPriceDesc = 'stableSwap_virtualPrice_DESC', + StableSwapVirtualPriceDescNullsLast = 'stableSwap_virtualPrice_DESC_NULLS_LAST', StableSwapVolumeUsdAsc = 'stableSwap_volumeUSD_ASC', + StableSwapVolumeUsdAscNullsFirst = 'stableSwap_volumeUSD_ASC_NULLS_FIRST', StableSwapVolumeUsdDesc = 'stableSwap_volumeUSD_DESC', + StableSwapVolumeUsdDescNullsLast = 'stableSwap_volumeUSD_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', TransactionAsc = 'transaction_ASC', - TransactionDesc = 'transaction_DESC' + TransactionAscNullsFirst = 'transaction_ASC_NULLS_FIRST', + TransactionDesc = 'transaction_DESC', + TransactionDescNullsLast = 'transaction_DESC_NULLS_LAST' } export type StableSwapExchangeWhereInput = { @@ -5782,37 +7957,69 @@ export type StableSwapHourDataEdge = { export enum StableSwapHourDataOrderByInput { HourStartUnixAsc = 'hourStartUnix_ASC', + HourStartUnixAscNullsFirst = 'hourStartUnix_ASC_NULLS_FIRST', HourStartUnixDesc = 'hourStartUnix_DESC', + HourStartUnixDescNullsLast = 'hourStartUnix_DESC_NULLS_LAST', HourlyVolumeUsdAsc = 'hourlyVolumeUSD_ASC', + HourlyVolumeUsdAscNullsFirst = 'hourlyVolumeUSD_ASC_NULLS_FIRST', HourlyVolumeUsdDesc = 'hourlyVolumeUSD_DESC', + HourlyVolumeUsdDescNullsLast = 'hourlyVolumeUSD_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', StableSwapAAsc = 'stableSwap_a_ASC', + StableSwapAAscNullsFirst = 'stableSwap_a_ASC_NULLS_FIRST', StableSwapADesc = 'stableSwap_a_DESC', + StableSwapADescNullsLast = 'stableSwap_a_DESC_NULLS_LAST', StableSwapAddressAsc = 'stableSwap_address_ASC', + StableSwapAddressAscNullsFirst = 'stableSwap_address_ASC_NULLS_FIRST', StableSwapAddressDesc = 'stableSwap_address_DESC', + StableSwapAddressDescNullsLast = 'stableSwap_address_DESC_NULLS_LAST', StableSwapAdminFeeAsc = 'stableSwap_adminFee_ASC', + StableSwapAdminFeeAscNullsFirst = 'stableSwap_adminFee_ASC_NULLS_FIRST', StableSwapAdminFeeDesc = 'stableSwap_adminFee_DESC', + StableSwapAdminFeeDescNullsLast = 'stableSwap_adminFee_DESC_NULLS_LAST', StableSwapBaseSwapAddressAsc = 'stableSwap_baseSwapAddress_ASC', + StableSwapBaseSwapAddressAscNullsFirst = 'stableSwap_baseSwapAddress_ASC_NULLS_FIRST', StableSwapBaseSwapAddressDesc = 'stableSwap_baseSwapAddress_DESC', + StableSwapBaseSwapAddressDescNullsLast = 'stableSwap_baseSwapAddress_DESC_NULLS_LAST', StableSwapIdAsc = 'stableSwap_id_ASC', + StableSwapIdAscNullsFirst = 'stableSwap_id_ASC_NULLS_FIRST', StableSwapIdDesc = 'stableSwap_id_DESC', + StableSwapIdDescNullsLast = 'stableSwap_id_DESC_NULLS_LAST', StableSwapLpTokenAsc = 'stableSwap_lpToken_ASC', + StableSwapLpTokenAscNullsFirst = 'stableSwap_lpToken_ASC_NULLS_FIRST', StableSwapLpTokenDesc = 'stableSwap_lpToken_DESC', + StableSwapLpTokenDescNullsLast = 'stableSwap_lpToken_DESC_NULLS_LAST', StableSwapLpTotalSupplyAsc = 'stableSwap_lpTotalSupply_ASC', + StableSwapLpTotalSupplyAscNullsFirst = 'stableSwap_lpTotalSupply_ASC_NULLS_FIRST', StableSwapLpTotalSupplyDesc = 'stableSwap_lpTotalSupply_DESC', + StableSwapLpTotalSupplyDescNullsLast = 'stableSwap_lpTotalSupply_DESC_NULLS_LAST', StableSwapNumTokensAsc = 'stableSwap_numTokens_ASC', + StableSwapNumTokensAscNullsFirst = 'stableSwap_numTokens_ASC_NULLS_FIRST', StableSwapNumTokensDesc = 'stableSwap_numTokens_DESC', + StableSwapNumTokensDescNullsLast = 'stableSwap_numTokens_DESC_NULLS_LAST', StableSwapSwapFeeAsc = 'stableSwap_swapFee_ASC', + StableSwapSwapFeeAscNullsFirst = 'stableSwap_swapFee_ASC_NULLS_FIRST', StableSwapSwapFeeDesc = 'stableSwap_swapFee_DESC', + StableSwapSwapFeeDescNullsLast = 'stableSwap_swapFee_DESC_NULLS_LAST', StableSwapTvlUsdAsc = 'stableSwap_tvlUSD_ASC', + StableSwapTvlUsdAscNullsFirst = 'stableSwap_tvlUSD_ASC_NULLS_FIRST', StableSwapTvlUsdDesc = 'stableSwap_tvlUSD_DESC', + StableSwapTvlUsdDescNullsLast = 'stableSwap_tvlUSD_DESC_NULLS_LAST', StableSwapVirtualPriceAsc = 'stableSwap_virtualPrice_ASC', + StableSwapVirtualPriceAscNullsFirst = 'stableSwap_virtualPrice_ASC_NULLS_FIRST', StableSwapVirtualPriceDesc = 'stableSwap_virtualPrice_DESC', + StableSwapVirtualPriceDescNullsLast = 'stableSwap_virtualPrice_DESC_NULLS_LAST', StableSwapVolumeUsdAsc = 'stableSwap_volumeUSD_ASC', + StableSwapVolumeUsdAscNullsFirst = 'stableSwap_volumeUSD_ASC_NULLS_FIRST', StableSwapVolumeUsdDesc = 'stableSwap_volumeUSD_DESC', + StableSwapVolumeUsdDescNullsLast = 'stableSwap_volumeUSD_DESC_NULLS_LAST', TvlUsdAsc = 'tvlUSD_ASC', - TvlUsdDesc = 'tvlUSD_DESC' + TvlUsdAscNullsFirst = 'tvlUSD_ASC_NULLS_FIRST', + TvlUsdDesc = 'tvlUSD_DESC', + TvlUsdDescNullsLast = 'tvlUSD_DESC_NULLS_LAST' } export type StableSwapHourDataWhereInput = { @@ -5910,15 +8117,25 @@ export type StableSwapInfoEdge = { export enum StableSwapInfoOrderByInput { IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', PoolCountAsc = 'poolCount_ASC', + PoolCountAscNullsFirst = 'poolCount_ASC_NULLS_FIRST', PoolCountDesc = 'poolCount_DESC', + PoolCountDescNullsLast = 'poolCount_DESC_NULLS_LAST', TotalTvlUsdAsc = 'totalTvlUSD_ASC', + TotalTvlUsdAscNullsFirst = 'totalTvlUSD_ASC_NULLS_FIRST', TotalTvlUsdDesc = 'totalTvlUSD_DESC', + TotalTvlUsdDescNullsLast = 'totalTvlUSD_DESC_NULLS_LAST', TotalVolumeUsdAsc = 'totalVolumeUSD_ASC', + TotalVolumeUsdAscNullsFirst = 'totalVolumeUSD_ASC_NULLS_FIRST', TotalVolumeUsdDesc = 'totalVolumeUSD_DESC', + TotalVolumeUsdDescNullsLast = 'totalVolumeUSD_DESC_NULLS_LAST', TxCountAsc = 'txCount_ASC', - TxCountDesc = 'txCount_DESC' + TxCountAscNullsFirst = 'txCount_ASC_NULLS_FIRST', + TxCountDesc = 'txCount_DESC', + TxCountDescNullsLast = 'txCount_DESC_NULLS_LAST' } export type StableSwapInfoWhereInput = { @@ -6021,37 +8238,69 @@ export type StableSwapLiquidityPositionEdge = { export enum StableSwapLiquidityPositionOrderByInput { IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiquidityTokenBalanceAsc = 'liquidityTokenBalance_ASC', + LiquidityTokenBalanceAscNullsFirst = 'liquidityTokenBalance_ASC_NULLS_FIRST', LiquidityTokenBalanceDesc = 'liquidityTokenBalance_DESC', + LiquidityTokenBalanceDescNullsLast = 'liquidityTokenBalance_DESC_NULLS_LAST', StableSwapAAsc = 'stableSwap_a_ASC', + StableSwapAAscNullsFirst = 'stableSwap_a_ASC_NULLS_FIRST', StableSwapADesc = 'stableSwap_a_DESC', + StableSwapADescNullsLast = 'stableSwap_a_DESC_NULLS_LAST', StableSwapAddressAsc = 'stableSwap_address_ASC', + StableSwapAddressAscNullsFirst = 'stableSwap_address_ASC_NULLS_FIRST', StableSwapAddressDesc = 'stableSwap_address_DESC', + StableSwapAddressDescNullsLast = 'stableSwap_address_DESC_NULLS_LAST', StableSwapAdminFeeAsc = 'stableSwap_adminFee_ASC', + StableSwapAdminFeeAscNullsFirst = 'stableSwap_adminFee_ASC_NULLS_FIRST', StableSwapAdminFeeDesc = 'stableSwap_adminFee_DESC', + StableSwapAdminFeeDescNullsLast = 'stableSwap_adminFee_DESC_NULLS_LAST', StableSwapBaseSwapAddressAsc = 'stableSwap_baseSwapAddress_ASC', + StableSwapBaseSwapAddressAscNullsFirst = 'stableSwap_baseSwapAddress_ASC_NULLS_FIRST', StableSwapBaseSwapAddressDesc = 'stableSwap_baseSwapAddress_DESC', + StableSwapBaseSwapAddressDescNullsLast = 'stableSwap_baseSwapAddress_DESC_NULLS_LAST', StableSwapIdAsc = 'stableSwap_id_ASC', + StableSwapIdAscNullsFirst = 'stableSwap_id_ASC_NULLS_FIRST', StableSwapIdDesc = 'stableSwap_id_DESC', + StableSwapIdDescNullsLast = 'stableSwap_id_DESC_NULLS_LAST', StableSwapLpTokenAsc = 'stableSwap_lpToken_ASC', + StableSwapLpTokenAscNullsFirst = 'stableSwap_lpToken_ASC_NULLS_FIRST', StableSwapLpTokenDesc = 'stableSwap_lpToken_DESC', + StableSwapLpTokenDescNullsLast = 'stableSwap_lpToken_DESC_NULLS_LAST', StableSwapLpTotalSupplyAsc = 'stableSwap_lpTotalSupply_ASC', + StableSwapLpTotalSupplyAscNullsFirst = 'stableSwap_lpTotalSupply_ASC_NULLS_FIRST', StableSwapLpTotalSupplyDesc = 'stableSwap_lpTotalSupply_DESC', + StableSwapLpTotalSupplyDescNullsLast = 'stableSwap_lpTotalSupply_DESC_NULLS_LAST', StableSwapNumTokensAsc = 'stableSwap_numTokens_ASC', + StableSwapNumTokensAscNullsFirst = 'stableSwap_numTokens_ASC_NULLS_FIRST', StableSwapNumTokensDesc = 'stableSwap_numTokens_DESC', + StableSwapNumTokensDescNullsLast = 'stableSwap_numTokens_DESC_NULLS_LAST', StableSwapSwapFeeAsc = 'stableSwap_swapFee_ASC', + StableSwapSwapFeeAscNullsFirst = 'stableSwap_swapFee_ASC_NULLS_FIRST', StableSwapSwapFeeDesc = 'stableSwap_swapFee_DESC', + StableSwapSwapFeeDescNullsLast = 'stableSwap_swapFee_DESC_NULLS_LAST', StableSwapTvlUsdAsc = 'stableSwap_tvlUSD_ASC', + StableSwapTvlUsdAscNullsFirst = 'stableSwap_tvlUSD_ASC_NULLS_FIRST', StableSwapTvlUsdDesc = 'stableSwap_tvlUSD_DESC', + StableSwapTvlUsdDescNullsLast = 'stableSwap_tvlUSD_DESC_NULLS_LAST', StableSwapVirtualPriceAsc = 'stableSwap_virtualPrice_ASC', + StableSwapVirtualPriceAscNullsFirst = 'stableSwap_virtualPrice_ASC_NULLS_FIRST', StableSwapVirtualPriceDesc = 'stableSwap_virtualPrice_DESC', + StableSwapVirtualPriceDescNullsLast = 'stableSwap_virtualPrice_DESC_NULLS_LAST', StableSwapVolumeUsdAsc = 'stableSwap_volumeUSD_ASC', + StableSwapVolumeUsdAscNullsFirst = 'stableSwap_volumeUSD_ASC_NULLS_FIRST', StableSwapVolumeUsdDesc = 'stableSwap_volumeUSD_DESC', + StableSwapVolumeUsdDescNullsLast = 'stableSwap_volumeUSD_DESC_NULLS_LAST', UserIdAsc = 'user_id_ASC', + UserIdAscNullsFirst = 'user_id_ASC_NULLS_FIRST', UserIdDesc = 'user_id_DESC', + UserIdDescNullsLast = 'user_id_DESC_NULLS_LAST', UserUsdSwappedAsc = 'user_usdSwapped_ASC', - UserUsdSwappedDesc = 'user_usdSwapped_DESC' + UserUsdSwappedAscNullsFirst = 'user_usdSwapped_ASC_NULLS_FIRST', + UserUsdSwappedDesc = 'user_usdSwapped_DESC', + UserUsdSwappedDescNullsLast = 'user_usdSwapped_DESC_NULLS_LAST' } export type StableSwapLiquidityPositionWhereInput = { @@ -6112,39 +8361,73 @@ export type StableSwapNewFeeEventData = { export enum StableSwapOrderByInput { AAsc = 'a_ASC', + AAscNullsFirst = 'a_ASC_NULLS_FIRST', ADesc = 'a_DESC', + ADescNullsLast = 'a_DESC_NULLS_LAST', AddressAsc = 'address_ASC', + AddressAscNullsFirst = 'address_ASC_NULLS_FIRST', AddressDesc = 'address_DESC', + AddressDescNullsLast = 'address_DESC_NULLS_LAST', AdminFeeAsc = 'adminFee_ASC', + AdminFeeAscNullsFirst = 'adminFee_ASC_NULLS_FIRST', AdminFeeDesc = 'adminFee_DESC', + AdminFeeDescNullsLast = 'adminFee_DESC_NULLS_LAST', BaseSwapAddressAsc = 'baseSwapAddress_ASC', + BaseSwapAddressAscNullsFirst = 'baseSwapAddress_ASC_NULLS_FIRST', BaseSwapAddressDesc = 'baseSwapAddress_DESC', + BaseSwapAddressDescNullsLast = 'baseSwapAddress_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LpTokenAsc = 'lpToken_ASC', + LpTokenAscNullsFirst = 'lpToken_ASC_NULLS_FIRST', LpTokenDesc = 'lpToken_DESC', + LpTokenDescNullsLast = 'lpToken_DESC_NULLS_LAST', LpTotalSupplyAsc = 'lpTotalSupply_ASC', + LpTotalSupplyAscNullsFirst = 'lpTotalSupply_ASC_NULLS_FIRST', LpTotalSupplyDesc = 'lpTotalSupply_DESC', + LpTotalSupplyDescNullsLast = 'lpTotalSupply_DESC_NULLS_LAST', NumTokensAsc = 'numTokens_ASC', + NumTokensAscNullsFirst = 'numTokens_ASC_NULLS_FIRST', NumTokensDesc = 'numTokens_DESC', + NumTokensDescNullsLast = 'numTokens_DESC_NULLS_LAST', StableSwapInfoIdAsc = 'stableSwapInfo_id_ASC', + StableSwapInfoIdAscNullsFirst = 'stableSwapInfo_id_ASC_NULLS_FIRST', StableSwapInfoIdDesc = 'stableSwapInfo_id_DESC', + StableSwapInfoIdDescNullsLast = 'stableSwapInfo_id_DESC_NULLS_LAST', StableSwapInfoPoolCountAsc = 'stableSwapInfo_poolCount_ASC', + StableSwapInfoPoolCountAscNullsFirst = 'stableSwapInfo_poolCount_ASC_NULLS_FIRST', StableSwapInfoPoolCountDesc = 'stableSwapInfo_poolCount_DESC', + StableSwapInfoPoolCountDescNullsLast = 'stableSwapInfo_poolCount_DESC_NULLS_LAST', StableSwapInfoTotalTvlUsdAsc = 'stableSwapInfo_totalTvlUSD_ASC', + StableSwapInfoTotalTvlUsdAscNullsFirst = 'stableSwapInfo_totalTvlUSD_ASC_NULLS_FIRST', StableSwapInfoTotalTvlUsdDesc = 'stableSwapInfo_totalTvlUSD_DESC', + StableSwapInfoTotalTvlUsdDescNullsLast = 'stableSwapInfo_totalTvlUSD_DESC_NULLS_LAST', StableSwapInfoTotalVolumeUsdAsc = 'stableSwapInfo_totalVolumeUSD_ASC', + StableSwapInfoTotalVolumeUsdAscNullsFirst = 'stableSwapInfo_totalVolumeUSD_ASC_NULLS_FIRST', StableSwapInfoTotalVolumeUsdDesc = 'stableSwapInfo_totalVolumeUSD_DESC', + StableSwapInfoTotalVolumeUsdDescNullsLast = 'stableSwapInfo_totalVolumeUSD_DESC_NULLS_LAST', StableSwapInfoTxCountAsc = 'stableSwapInfo_txCount_ASC', + StableSwapInfoTxCountAscNullsFirst = 'stableSwapInfo_txCount_ASC_NULLS_FIRST', StableSwapInfoTxCountDesc = 'stableSwapInfo_txCount_DESC', + StableSwapInfoTxCountDescNullsLast = 'stableSwapInfo_txCount_DESC_NULLS_LAST', SwapFeeAsc = 'swapFee_ASC', + SwapFeeAscNullsFirst = 'swapFee_ASC_NULLS_FIRST', SwapFeeDesc = 'swapFee_DESC', + SwapFeeDescNullsLast = 'swapFee_DESC_NULLS_LAST', TvlUsdAsc = 'tvlUSD_ASC', + TvlUsdAscNullsFirst = 'tvlUSD_ASC_NULLS_FIRST', TvlUsdDesc = 'tvlUSD_DESC', + TvlUsdDescNullsLast = 'tvlUSD_DESC_NULLS_LAST', VirtualPriceAsc = 'virtualPrice_ASC', + VirtualPriceAscNullsFirst = 'virtualPrice_ASC_NULLS_FIRST', VirtualPriceDesc = 'virtualPrice_DESC', + VirtualPriceDescNullsLast = 'virtualPrice_DESC_NULLS_LAST', VolumeUsdAsc = 'volumeUSD_ASC', - VolumeUsdDesc = 'volumeUSD_DESC' + VolumeUsdAscNullsFirst = 'volumeUSD_ASC_NULLS_FIRST', + VolumeUsdDesc = 'volumeUSD_DESC', + VolumeUsdDescNullsLast = 'volumeUSD_DESC_NULLS_LAST' } export type StableSwapRampAEventData = { @@ -6412,31 +8695,57 @@ export type StakePositionEdge = { export enum StakePositionOrderByInput { FarmCreatedAtBlockAsc = 'farm_createdAtBlock_ASC', + FarmCreatedAtBlockAscNullsFirst = 'farm_createdAtBlock_ASC_NULLS_FIRST', FarmCreatedAtBlockDesc = 'farm_createdAtBlock_DESC', + FarmCreatedAtBlockDescNullsLast = 'farm_createdAtBlock_DESC_NULLS_LAST', FarmCreatedAtTimestampAsc = 'farm_createdAtTimestamp_ASC', + FarmCreatedAtTimestampAscNullsFirst = 'farm_createdAtTimestamp_ASC_NULLS_FIRST', FarmCreatedAtTimestampDesc = 'farm_createdAtTimestamp_DESC', + FarmCreatedAtTimestampDescNullsLast = 'farm_createdAtTimestamp_DESC_NULLS_LAST', FarmIdAsc = 'farm_id_ASC', + FarmIdAscNullsFirst = 'farm_id_ASC_NULLS_FIRST', FarmIdDesc = 'farm_id_DESC', + FarmIdDescNullsLast = 'farm_id_DESC_NULLS_LAST', FarmLiquidityStakedAsc = 'farm_liquidityStaked_ASC', + FarmLiquidityStakedAscNullsFirst = 'farm_liquidityStaked_ASC_NULLS_FIRST', FarmLiquidityStakedDesc = 'farm_liquidityStaked_DESC', + FarmLiquidityStakedDescNullsLast = 'farm_liquidityStaked_DESC_NULLS_LAST', FarmPidAsc = 'farm_pid_ASC', + FarmPidAscNullsFirst = 'farm_pid_ASC_NULLS_FIRST', FarmPidDesc = 'farm_pid_DESC', + FarmPidDescNullsLast = 'farm_pid_DESC_NULLS_LAST', FarmRewardUsdPerDayAsc = 'farm_rewardUSDPerDay_ASC', + FarmRewardUsdPerDayAscNullsFirst = 'farm_rewardUSDPerDay_ASC_NULLS_FIRST', FarmRewardUsdPerDayDesc = 'farm_rewardUSDPerDay_DESC', + FarmRewardUsdPerDayDescNullsLast = 'farm_rewardUSDPerDay_DESC_NULLS_LAST', FarmStakeAprAsc = 'farm_stakeApr_ASC', + FarmStakeAprAscNullsFirst = 'farm_stakeApr_ASC_NULLS_FIRST', FarmStakeAprDesc = 'farm_stakeApr_DESC', + FarmStakeAprDescNullsLast = 'farm_stakeApr_DESC_NULLS_LAST', FarmStakeTokenAsc = 'farm_stakeToken_ASC', + FarmStakeTokenAscNullsFirst = 'farm_stakeToken_ASC_NULLS_FIRST', FarmStakeTokenDesc = 'farm_stakeToken_DESC', + FarmStakeTokenDescNullsLast = 'farm_stakeToken_DESC_NULLS_LAST', FarmStakedUsdAsc = 'farm_stakedUSD_ASC', + FarmStakedUsdAscNullsFirst = 'farm_stakedUSD_ASC_NULLS_FIRST', FarmStakedUsdDesc = 'farm_stakedUSD_DESC', + FarmStakedUsdDescNullsLast = 'farm_stakedUSD_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiquidityStakedBalanceAsc = 'liquidityStakedBalance_ASC', + LiquidityStakedBalanceAscNullsFirst = 'liquidityStakedBalance_ASC_NULLS_FIRST', LiquidityStakedBalanceDesc = 'liquidityStakedBalance_DESC', + LiquidityStakedBalanceDescNullsLast = 'liquidityStakedBalance_DESC_NULLS_LAST', UserIdAsc = 'user_id_ASC', + UserIdAscNullsFirst = 'user_id_ASC_NULLS_FIRST', UserIdDesc = 'user_id_DESC', + UserIdDescNullsLast = 'user_id_DESC_NULLS_LAST', UserUsdSwappedAsc = 'user_usdSwapped_ASC', - UserUsdSwappedDesc = 'user_usdSwapped_DESC' + UserUsdSwappedAscNullsFirst = 'user_usdSwapped_ASC_NULLS_FIRST', + UserUsdSwappedDesc = 'user_usdSwapped_DESC', + UserUsdSwappedDescNullsLast = 'user_usdSwapped_DESC_NULLS_LAST' } export type StakePositionWhereInput = { @@ -6485,10 +8794,18 @@ export type Subscription = { __typename?: 'Subscription'; backstopPoolById?: Maybe; backstopPools: Array; + blockById?: Maybe; + blocks: Array; bundleById?: Maybe; bundles: Array; burnById?: Maybe; burns: Array; + callById?: Maybe; + calls: Array; + eventById?: Maybe; + events: Array; + extrinsicById?: Maybe; + extrinsics: Array; factories: Array; factoryById?: Maybe; factoryDayData: Array; @@ -6497,6 +8814,8 @@ export type Subscription = { farms: Array; incentiveById?: Maybe; incentives: Array; + itemsCounterById?: Maybe; + itemsCounters: Array; liquidityPositionById?: Maybe; liquidityPositionSnapshotById?: Maybe; liquidityPositionSnapshots: Array; @@ -6581,6 +8900,19 @@ export type SubscriptionBackstopPoolsArgs = { }; +export type SubscriptionBlockByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type SubscriptionBlocksArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + export type SubscriptionBundleByIdArgs = { id: Scalars['String']['input']; }; @@ -6607,6 +8939,45 @@ export type SubscriptionBurnsArgs = { }; +export type SubscriptionCallByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type SubscriptionCallsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type SubscriptionEventByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type SubscriptionEventsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type SubscriptionExtrinsicByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type SubscriptionExtrinsicsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + export type SubscriptionFactoriesArgs = { limit?: InputMaybe; offset?: InputMaybe; @@ -6659,6 +9030,19 @@ export type SubscriptionIncentivesArgs = { }; +export type SubscriptionItemsCounterByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type SubscriptionItemsCountersArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + export type SubscriptionLiquidityPositionByIdArgs = { id: Scalars['String']['input']; }; @@ -7125,67 +9509,129 @@ export type SwapEdge = { export enum SwapOrderByInput { Amount0InAsc = 'amount0In_ASC', + Amount0InAscNullsFirst = 'amount0In_ASC_NULLS_FIRST', Amount0InDesc = 'amount0In_DESC', + Amount0InDescNullsLast = 'amount0In_DESC_NULLS_LAST', Amount0OutAsc = 'amount0Out_ASC', + Amount0OutAscNullsFirst = 'amount0Out_ASC_NULLS_FIRST', Amount0OutDesc = 'amount0Out_DESC', + Amount0OutDescNullsLast = 'amount0Out_DESC_NULLS_LAST', Amount1InAsc = 'amount1In_ASC', + Amount1InAscNullsFirst = 'amount1In_ASC_NULLS_FIRST', Amount1InDesc = 'amount1In_DESC', + Amount1InDescNullsLast = 'amount1In_DESC_NULLS_LAST', Amount1OutAsc = 'amount1Out_ASC', + Amount1OutAscNullsFirst = 'amount1Out_ASC_NULLS_FIRST', Amount1OutDesc = 'amount1Out_DESC', + Amount1OutDescNullsLast = 'amount1Out_DESC_NULLS_LAST', AmountUsdAsc = 'amountUSD_ASC', + AmountUsdAscNullsFirst = 'amountUSD_ASC_NULLS_FIRST', AmountUsdDesc = 'amountUSD_DESC', + AmountUsdDescNullsLast = 'amountUSD_DESC_NULLS_LAST', FromAsc = 'from_ASC', + FromAscNullsFirst = 'from_ASC_NULLS_FIRST', FromDesc = 'from_DESC', + FromDescNullsLast = 'from_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LogIndexAsc = 'logIndex_ASC', + LogIndexAscNullsFirst = 'logIndex_ASC_NULLS_FIRST', LogIndexDesc = 'logIndex_DESC', + LogIndexDescNullsLast = 'logIndex_DESC_NULLS_LAST', PairCreatedAtBlockNumberAsc = 'pair_createdAtBlockNumber_ASC', + PairCreatedAtBlockNumberAscNullsFirst = 'pair_createdAtBlockNumber_ASC_NULLS_FIRST', PairCreatedAtBlockNumberDesc = 'pair_createdAtBlockNumber_DESC', + PairCreatedAtBlockNumberDescNullsLast = 'pair_createdAtBlockNumber_DESC_NULLS_LAST', PairCreatedAtTimestampAsc = 'pair_createdAtTimestamp_ASC', + PairCreatedAtTimestampAscNullsFirst = 'pair_createdAtTimestamp_ASC_NULLS_FIRST', PairCreatedAtTimestampDesc = 'pair_createdAtTimestamp_DESC', + PairCreatedAtTimestampDescNullsLast = 'pair_createdAtTimestamp_DESC_NULLS_LAST', PairIdAsc = 'pair_id_ASC', + PairIdAscNullsFirst = 'pair_id_ASC_NULLS_FIRST', PairIdDesc = 'pair_id_DESC', + PairIdDescNullsLast = 'pair_id_DESC_NULLS_LAST', PairLiquidityProviderCountAsc = 'pair_liquidityProviderCount_ASC', + PairLiquidityProviderCountAscNullsFirst = 'pair_liquidityProviderCount_ASC_NULLS_FIRST', PairLiquidityProviderCountDesc = 'pair_liquidityProviderCount_DESC', + PairLiquidityProviderCountDescNullsLast = 'pair_liquidityProviderCount_DESC_NULLS_LAST', PairReserve0Asc = 'pair_reserve0_ASC', + PairReserve0AscNullsFirst = 'pair_reserve0_ASC_NULLS_FIRST', PairReserve0Desc = 'pair_reserve0_DESC', + PairReserve0DescNullsLast = 'pair_reserve0_DESC_NULLS_LAST', PairReserve1Asc = 'pair_reserve1_ASC', + PairReserve1AscNullsFirst = 'pair_reserve1_ASC_NULLS_FIRST', PairReserve1Desc = 'pair_reserve1_DESC', + PairReserve1DescNullsLast = 'pair_reserve1_DESC_NULLS_LAST', PairReserveEthAsc = 'pair_reserveETH_ASC', + PairReserveEthAscNullsFirst = 'pair_reserveETH_ASC_NULLS_FIRST', PairReserveEthDesc = 'pair_reserveETH_DESC', + PairReserveEthDescNullsLast = 'pair_reserveETH_DESC_NULLS_LAST', PairReserveUsdAsc = 'pair_reserveUSD_ASC', + PairReserveUsdAscNullsFirst = 'pair_reserveUSD_ASC_NULLS_FIRST', PairReserveUsdDesc = 'pair_reserveUSD_DESC', + PairReserveUsdDescNullsLast = 'pair_reserveUSD_DESC_NULLS_LAST', PairToken0PriceAsc = 'pair_token0Price_ASC', + PairToken0PriceAscNullsFirst = 'pair_token0Price_ASC_NULLS_FIRST', PairToken0PriceDesc = 'pair_token0Price_DESC', + PairToken0PriceDescNullsLast = 'pair_token0Price_DESC_NULLS_LAST', PairToken1PriceAsc = 'pair_token1Price_ASC', + PairToken1PriceAscNullsFirst = 'pair_token1Price_ASC_NULLS_FIRST', PairToken1PriceDesc = 'pair_token1Price_DESC', + PairToken1PriceDescNullsLast = 'pair_token1Price_DESC_NULLS_LAST', PairTotalSupplyAsc = 'pair_totalSupply_ASC', + PairTotalSupplyAscNullsFirst = 'pair_totalSupply_ASC_NULLS_FIRST', PairTotalSupplyDesc = 'pair_totalSupply_DESC', + PairTotalSupplyDescNullsLast = 'pair_totalSupply_DESC_NULLS_LAST', PairTrackedReserveEthAsc = 'pair_trackedReserveETH_ASC', + PairTrackedReserveEthAscNullsFirst = 'pair_trackedReserveETH_ASC_NULLS_FIRST', PairTrackedReserveEthDesc = 'pair_trackedReserveETH_DESC', + PairTrackedReserveEthDescNullsLast = 'pair_trackedReserveETH_DESC_NULLS_LAST', PairTxCountAsc = 'pair_txCount_ASC', + PairTxCountAscNullsFirst = 'pair_txCount_ASC_NULLS_FIRST', PairTxCountDesc = 'pair_txCount_DESC', + PairTxCountDescNullsLast = 'pair_txCount_DESC_NULLS_LAST', PairUntrackedVolumeUsdAsc = 'pair_untrackedVolumeUSD_ASC', + PairUntrackedVolumeUsdAscNullsFirst = 'pair_untrackedVolumeUSD_ASC_NULLS_FIRST', PairUntrackedVolumeUsdDesc = 'pair_untrackedVolumeUSD_DESC', + PairUntrackedVolumeUsdDescNullsLast = 'pair_untrackedVolumeUSD_DESC_NULLS_LAST', PairVolumeToken0Asc = 'pair_volumeToken0_ASC', + PairVolumeToken0AscNullsFirst = 'pair_volumeToken0_ASC_NULLS_FIRST', PairVolumeToken0Desc = 'pair_volumeToken0_DESC', + PairVolumeToken0DescNullsLast = 'pair_volumeToken0_DESC_NULLS_LAST', PairVolumeToken1Asc = 'pair_volumeToken1_ASC', + PairVolumeToken1AscNullsFirst = 'pair_volumeToken1_ASC_NULLS_FIRST', PairVolumeToken1Desc = 'pair_volumeToken1_DESC', + PairVolumeToken1DescNullsLast = 'pair_volumeToken1_DESC_NULLS_LAST', PairVolumeUsdAsc = 'pair_volumeUSD_ASC', + PairVolumeUsdAscNullsFirst = 'pair_volumeUSD_ASC_NULLS_FIRST', PairVolumeUsdDesc = 'pair_volumeUSD_DESC', + PairVolumeUsdDescNullsLast = 'pair_volumeUSD_DESC_NULLS_LAST', SenderAsc = 'sender_ASC', + SenderAscNullsFirst = 'sender_ASC_NULLS_FIRST', SenderDesc = 'sender_DESC', + SenderDescNullsLast = 'sender_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', ToAsc = 'to_ASC', + ToAscNullsFirst = 'to_ASC_NULLS_FIRST', ToDesc = 'to_DESC', + ToDescNullsLast = 'to_DESC_NULLS_LAST', TransactionBlockNumberAsc = 'transaction_blockNumber_ASC', + TransactionBlockNumberAscNullsFirst = 'transaction_blockNumber_ASC_NULLS_FIRST', TransactionBlockNumberDesc = 'transaction_blockNumber_DESC', + TransactionBlockNumberDescNullsLast = 'transaction_blockNumber_DESC_NULLS_LAST', TransactionIdAsc = 'transaction_id_ASC', + TransactionIdAscNullsFirst = 'transaction_id_ASC_NULLS_FIRST', TransactionIdDesc = 'transaction_id_DESC', + TransactionIdDescNullsLast = 'transaction_id_DESC_NULLS_LAST', TransactionTimestampAsc = 'transaction_timestamp_ASC', - TransactionTimestampDesc = 'transaction_timestamp_DESC' + TransactionTimestampAscNullsFirst = 'transaction_timestamp_ASC_NULLS_FIRST', + TransactionTimestampDesc = 'transaction_timestamp_DESC', + TransactionTimestampDescNullsLast = 'transaction_timestamp_DESC_NULLS_LAST' } export type SwapPool = { @@ -7208,37 +9654,69 @@ export type SwapPoolEdge = { export enum SwapPoolOrderByInput { BackstopIdAsc = 'backstop_id_ASC', + BackstopIdAscNullsFirst = 'backstop_id_ASC_NULLS_FIRST', BackstopIdDesc = 'backstop_id_DESC', + BackstopIdDescNullsLast = 'backstop_id_DESC_NULLS_LAST', BackstopLiabilitiesAsc = 'backstop_liabilities_ASC', + BackstopLiabilitiesAscNullsFirst = 'backstop_liabilities_ASC_NULLS_FIRST', BackstopLiabilitiesDesc = 'backstop_liabilities_DESC', + BackstopLiabilitiesDescNullsLast = 'backstop_liabilities_DESC_NULLS_LAST', BackstopPausedAsc = 'backstop_paused_ASC', + BackstopPausedAscNullsFirst = 'backstop_paused_ASC_NULLS_FIRST', BackstopPausedDesc = 'backstop_paused_DESC', + BackstopPausedDescNullsLast = 'backstop_paused_DESC_NULLS_LAST', BackstopReservesAsc = 'backstop_reserves_ASC', + BackstopReservesAscNullsFirst = 'backstop_reserves_ASC_NULLS_FIRST', BackstopReservesDesc = 'backstop_reserves_DESC', + BackstopReservesDescNullsLast = 'backstop_reserves_DESC_NULLS_LAST', BackstopTotalSupplyAsc = 'backstop_totalSupply_ASC', + BackstopTotalSupplyAscNullsFirst = 'backstop_totalSupply_ASC_NULLS_FIRST', BackstopTotalSupplyDesc = 'backstop_totalSupply_DESC', + BackstopTotalSupplyDescNullsLast = 'backstop_totalSupply_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', LiabilitiesAsc = 'liabilities_ASC', + LiabilitiesAscNullsFirst = 'liabilities_ASC_NULLS_FIRST', LiabilitiesDesc = 'liabilities_DESC', + LiabilitiesDescNullsLast = 'liabilities_DESC_NULLS_LAST', PausedAsc = 'paused_ASC', + PausedAscNullsFirst = 'paused_ASC_NULLS_FIRST', PausedDesc = 'paused_DESC', + PausedDescNullsLast = 'paused_DESC_NULLS_LAST', ReservesAsc = 'reserves_ASC', + ReservesAscNullsFirst = 'reserves_ASC_NULLS_FIRST', ReservesDesc = 'reserves_DESC', + ReservesDescNullsLast = 'reserves_DESC_NULLS_LAST', RouterIdAsc = 'router_id_ASC', + RouterIdAscNullsFirst = 'router_id_ASC_NULLS_FIRST', RouterIdDesc = 'router_id_DESC', + RouterIdDescNullsLast = 'router_id_DESC_NULLS_LAST', RouterPausedAsc = 'router_paused_ASC', + RouterPausedAscNullsFirst = 'router_paused_ASC_NULLS_FIRST', RouterPausedDesc = 'router_paused_DESC', + RouterPausedDescNullsLast = 'router_paused_DESC_NULLS_LAST', TokenDecimalsAsc = 'token_decimals_ASC', + TokenDecimalsAscNullsFirst = 'token_decimals_ASC_NULLS_FIRST', TokenDecimalsDesc = 'token_decimals_DESC', + TokenDecimalsDescNullsLast = 'token_decimals_DESC_NULLS_LAST', TokenIdAsc = 'token_id_ASC', + TokenIdAscNullsFirst = 'token_id_ASC_NULLS_FIRST', TokenIdDesc = 'token_id_DESC', + TokenIdDescNullsLast = 'token_id_DESC_NULLS_LAST', TokenNameAsc = 'token_name_ASC', + TokenNameAscNullsFirst = 'token_name_ASC_NULLS_FIRST', TokenNameDesc = 'token_name_DESC', + TokenNameDescNullsLast = 'token_name_DESC_NULLS_LAST', TokenSymbolAsc = 'token_symbol_ASC', + TokenSymbolAscNullsFirst = 'token_symbol_ASC_NULLS_FIRST', TokenSymbolDesc = 'token_symbol_DESC', + TokenSymbolDescNullsLast = 'token_symbol_DESC_NULLS_LAST', TotalSupplyAsc = 'totalSupply_ASC', - TotalSupplyDesc = 'totalSupply_DESC' + TotalSupplyAscNullsFirst = 'totalSupply_ASC_NULLS_FIRST', + TotalSupplyDesc = 'totalSupply_DESC', + TotalSupplyDescNullsLast = 'totalSupply_DESC_NULLS_LAST' } export type SwapPoolWhereInput = { @@ -7588,47 +10066,89 @@ export type TokenDayDataEdge = { export enum TokenDayDataOrderByInput { DailyTxnsAsc = 'dailyTxns_ASC', + DailyTxnsAscNullsFirst = 'dailyTxns_ASC_NULLS_FIRST', DailyTxnsDesc = 'dailyTxns_DESC', + DailyTxnsDescNullsLast = 'dailyTxns_DESC_NULLS_LAST', DailyVolumeEthAsc = 'dailyVolumeETH_ASC', + DailyVolumeEthAscNullsFirst = 'dailyVolumeETH_ASC_NULLS_FIRST', DailyVolumeEthDesc = 'dailyVolumeETH_DESC', + DailyVolumeEthDescNullsLast = 'dailyVolumeETH_DESC_NULLS_LAST', DailyVolumeTokenAsc = 'dailyVolumeToken_ASC', + DailyVolumeTokenAscNullsFirst = 'dailyVolumeToken_ASC_NULLS_FIRST', DailyVolumeTokenDesc = 'dailyVolumeToken_DESC', + DailyVolumeTokenDescNullsLast = 'dailyVolumeToken_DESC_NULLS_LAST', DailyVolumeUsdAsc = 'dailyVolumeUSD_ASC', + DailyVolumeUsdAscNullsFirst = 'dailyVolumeUSD_ASC_NULLS_FIRST', DailyVolumeUsdDesc = 'dailyVolumeUSD_DESC', + DailyVolumeUsdDescNullsLast = 'dailyVolumeUSD_DESC_NULLS_LAST', DateAsc = 'date_ASC', + DateAscNullsFirst = 'date_ASC_NULLS_FIRST', DateDesc = 'date_DESC', + DateDescNullsLast = 'date_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', PriceUsdAsc = 'priceUSD_ASC', + PriceUsdAscNullsFirst = 'priceUSD_ASC_NULLS_FIRST', PriceUsdDesc = 'priceUSD_DESC', + PriceUsdDescNullsLast = 'priceUSD_DESC_NULLS_LAST', TokenDecimalsAsc = 'token_decimals_ASC', + TokenDecimalsAscNullsFirst = 'token_decimals_ASC_NULLS_FIRST', TokenDecimalsDesc = 'token_decimals_DESC', + TokenDecimalsDescNullsLast = 'token_decimals_DESC_NULLS_LAST', TokenDerivedEthAsc = 'token_derivedETH_ASC', + TokenDerivedEthAscNullsFirst = 'token_derivedETH_ASC_NULLS_FIRST', TokenDerivedEthDesc = 'token_derivedETH_DESC', + TokenDerivedEthDescNullsLast = 'token_derivedETH_DESC_NULLS_LAST', TokenIdAsc = 'token_id_ASC', + TokenIdAscNullsFirst = 'token_id_ASC_NULLS_FIRST', TokenIdDesc = 'token_id_DESC', + TokenIdDescNullsLast = 'token_id_DESC_NULLS_LAST', TokenNameAsc = 'token_name_ASC', + TokenNameAscNullsFirst = 'token_name_ASC_NULLS_FIRST', TokenNameDesc = 'token_name_DESC', + TokenNameDescNullsLast = 'token_name_DESC_NULLS_LAST', TokenSymbolAsc = 'token_symbol_ASC', + TokenSymbolAscNullsFirst = 'token_symbol_ASC_NULLS_FIRST', TokenSymbolDesc = 'token_symbol_DESC', + TokenSymbolDescNullsLast = 'token_symbol_DESC_NULLS_LAST', TokenTotalLiquidityAsc = 'token_totalLiquidity_ASC', + TokenTotalLiquidityAscNullsFirst = 'token_totalLiquidity_ASC_NULLS_FIRST', TokenTotalLiquidityDesc = 'token_totalLiquidity_DESC', + TokenTotalLiquidityDescNullsLast = 'token_totalLiquidity_DESC_NULLS_LAST', TokenTotalSupplyAsc = 'token_totalSupply_ASC', + TokenTotalSupplyAscNullsFirst = 'token_totalSupply_ASC_NULLS_FIRST', TokenTotalSupplyDesc = 'token_totalSupply_DESC', + TokenTotalSupplyDescNullsLast = 'token_totalSupply_DESC_NULLS_LAST', TokenTradeVolumeUsdAsc = 'token_tradeVolumeUSD_ASC', + TokenTradeVolumeUsdAscNullsFirst = 'token_tradeVolumeUSD_ASC_NULLS_FIRST', TokenTradeVolumeUsdDesc = 'token_tradeVolumeUSD_DESC', + TokenTradeVolumeUsdDescNullsLast = 'token_tradeVolumeUSD_DESC_NULLS_LAST', TokenTradeVolumeAsc = 'token_tradeVolume_ASC', + TokenTradeVolumeAscNullsFirst = 'token_tradeVolume_ASC_NULLS_FIRST', TokenTradeVolumeDesc = 'token_tradeVolume_DESC', + TokenTradeVolumeDescNullsLast = 'token_tradeVolume_DESC_NULLS_LAST', TokenTxCountAsc = 'token_txCount_ASC', + TokenTxCountAscNullsFirst = 'token_txCount_ASC_NULLS_FIRST', TokenTxCountDesc = 'token_txCount_DESC', + TokenTxCountDescNullsLast = 'token_txCount_DESC_NULLS_LAST', TokenUntrackedVolumeUsdAsc = 'token_untrackedVolumeUSD_ASC', + TokenUntrackedVolumeUsdAscNullsFirst = 'token_untrackedVolumeUSD_ASC_NULLS_FIRST', TokenUntrackedVolumeUsdDesc = 'token_untrackedVolumeUSD_DESC', + TokenUntrackedVolumeUsdDescNullsLast = 'token_untrackedVolumeUSD_DESC_NULLS_LAST', TotalLiquidityEthAsc = 'totalLiquidityETH_ASC', + TotalLiquidityEthAscNullsFirst = 'totalLiquidityETH_ASC_NULLS_FIRST', TotalLiquidityEthDesc = 'totalLiquidityETH_DESC', + TotalLiquidityEthDescNullsLast = 'totalLiquidityETH_DESC_NULLS_LAST', TotalLiquidityTokenAsc = 'totalLiquidityToken_ASC', + TotalLiquidityTokenAscNullsFirst = 'totalLiquidityToken_ASC_NULLS_FIRST', TotalLiquidityTokenDesc = 'totalLiquidityToken_DESC', + TotalLiquidityTokenDescNullsLast = 'totalLiquidityToken_DESC_NULLS_LAST', TotalLiquidityUsdAsc = 'totalLiquidityUSD_ASC', - TotalLiquidityUsdDesc = 'totalLiquidityUSD_DESC' + TotalLiquidityUsdAscNullsFirst = 'totalLiquidityUSD_ASC_NULLS_FIRST', + TotalLiquidityUsdDesc = 'totalLiquidityUSD_DESC', + TotalLiquidityUsdDescNullsLast = 'totalLiquidityUSD_DESC_NULLS_LAST' } export type TokenDayDataWhereInput = { @@ -7811,19 +10331,33 @@ export type TokenDepositEdge = { export enum TokenDepositOrderByInput { AmountAsc = 'amount_ASC', + AmountAscNullsFirst = 'amount_ASC_NULLS_FIRST', AmountDesc = 'amount_DESC', + AmountDescNullsLast = 'amount_DESC_NULLS_LAST', BlockNumberAsc = 'blockNumber_ASC', + BlockNumberAscNullsFirst = 'blockNumber_ASC_NULLS_FIRST', BlockNumberDesc = 'blockNumber_DESC', + BlockNumberDescNullsLast = 'blockNumber_DESC_NULLS_LAST', CurrencyIdAsc = 'currencyId_ASC', + CurrencyIdAscNullsFirst = 'currencyId_ASC_NULLS_FIRST', CurrencyIdDesc = 'currencyId_DESC', + CurrencyIdDescNullsLast = 'currencyId_DESC_NULLS_LAST', ExtrinsicHashAsc = 'extrinsicHash_ASC', + ExtrinsicHashAscNullsFirst = 'extrinsicHash_ASC_NULLS_FIRST', ExtrinsicHashDesc = 'extrinsicHash_DESC', + ExtrinsicHashDescNullsLast = 'extrinsicHash_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', WhoAsc = 'who_ASC', - WhoDesc = 'who_DESC' + WhoAscNullsFirst = 'who_ASC_NULLS_FIRST', + WhoDesc = 'who_DESC', + WhoDescNullsLast = 'who_DESC_NULLS_LAST' } export type TokenDepositWhereInput = { @@ -7941,27 +10475,49 @@ export type TokenEdge = { export enum TokenOrderByInput { DecimalsAsc = 'decimals_ASC', + DecimalsAscNullsFirst = 'decimals_ASC_NULLS_FIRST', DecimalsDesc = 'decimals_DESC', + DecimalsDescNullsLast = 'decimals_DESC_NULLS_LAST', DerivedEthAsc = 'derivedETH_ASC', + DerivedEthAscNullsFirst = 'derivedETH_ASC_NULLS_FIRST', DerivedEthDesc = 'derivedETH_DESC', + DerivedEthDescNullsLast = 'derivedETH_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', NameAsc = 'name_ASC', + NameAscNullsFirst = 'name_ASC_NULLS_FIRST', NameDesc = 'name_DESC', + NameDescNullsLast = 'name_DESC_NULLS_LAST', SymbolAsc = 'symbol_ASC', + SymbolAscNullsFirst = 'symbol_ASC_NULLS_FIRST', SymbolDesc = 'symbol_DESC', + SymbolDescNullsLast = 'symbol_DESC_NULLS_LAST', TotalLiquidityAsc = 'totalLiquidity_ASC', + TotalLiquidityAscNullsFirst = 'totalLiquidity_ASC_NULLS_FIRST', TotalLiquidityDesc = 'totalLiquidity_DESC', + TotalLiquidityDescNullsLast = 'totalLiquidity_DESC_NULLS_LAST', TotalSupplyAsc = 'totalSupply_ASC', + TotalSupplyAscNullsFirst = 'totalSupply_ASC_NULLS_FIRST', TotalSupplyDesc = 'totalSupply_DESC', + TotalSupplyDescNullsLast = 'totalSupply_DESC_NULLS_LAST', TradeVolumeUsdAsc = 'tradeVolumeUSD_ASC', + TradeVolumeUsdAscNullsFirst = 'tradeVolumeUSD_ASC_NULLS_FIRST', TradeVolumeUsdDesc = 'tradeVolumeUSD_DESC', + TradeVolumeUsdDescNullsLast = 'tradeVolumeUSD_DESC_NULLS_LAST', TradeVolumeAsc = 'tradeVolume_ASC', + TradeVolumeAscNullsFirst = 'tradeVolume_ASC_NULLS_FIRST', TradeVolumeDesc = 'tradeVolume_DESC', + TradeVolumeDescNullsLast = 'tradeVolume_DESC_NULLS_LAST', TxCountAsc = 'txCount_ASC', + TxCountAscNullsFirst = 'txCount_ASC_NULLS_FIRST', TxCountDesc = 'txCount_DESC', + TxCountDescNullsLast = 'txCount_DESC_NULLS_LAST', UntrackedVolumeUsdAsc = 'untrackedVolumeUSD_ASC', - UntrackedVolumeUsdDesc = 'untrackedVolumeUSD_DESC' + UntrackedVolumeUsdAscNullsFirst = 'untrackedVolumeUSD_ASC_NULLS_FIRST', + UntrackedVolumeUsdDesc = 'untrackedVolumeUSD_DESC', + UntrackedVolumeUsdDescNullsLast = 'untrackedVolumeUSD_DESC_NULLS_LAST' } export type TokenTransfer = { @@ -7972,6 +10528,7 @@ export type TokenTransfer = { extrinsicHash?: Maybe; from: Scalars['String']['output']; id: Scalars['String']['output']; + remark?: Maybe; timestamp: Scalars['DateTime']['output']; to: Scalars['String']['output']; }; @@ -7984,21 +10541,41 @@ export type TokenTransferEdge = { export enum TokenTransferOrderByInput { AmountAsc = 'amount_ASC', + AmountAscNullsFirst = 'amount_ASC_NULLS_FIRST', AmountDesc = 'amount_DESC', + AmountDescNullsLast = 'amount_DESC_NULLS_LAST', BlockNumberAsc = 'blockNumber_ASC', + BlockNumberAscNullsFirst = 'blockNumber_ASC_NULLS_FIRST', BlockNumberDesc = 'blockNumber_DESC', + BlockNumberDescNullsLast = 'blockNumber_DESC_NULLS_LAST', CurrencyIdAsc = 'currencyId_ASC', + CurrencyIdAscNullsFirst = 'currencyId_ASC_NULLS_FIRST', CurrencyIdDesc = 'currencyId_DESC', + CurrencyIdDescNullsLast = 'currencyId_DESC_NULLS_LAST', ExtrinsicHashAsc = 'extrinsicHash_ASC', + ExtrinsicHashAscNullsFirst = 'extrinsicHash_ASC_NULLS_FIRST', ExtrinsicHashDesc = 'extrinsicHash_DESC', + ExtrinsicHashDescNullsLast = 'extrinsicHash_DESC_NULLS_LAST', FromAsc = 'from_ASC', + FromAscNullsFirst = 'from_ASC_NULLS_FIRST', FromDesc = 'from_DESC', + FromDescNullsLast = 'from_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', + RemarkAsc = 'remark_ASC', + RemarkAscNullsFirst = 'remark_ASC_NULLS_FIRST', + RemarkDesc = 'remark_DESC', + RemarkDescNullsLast = 'remark_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', ToAsc = 'to_ASC', - ToDesc = 'to_DESC' + ToAscNullsFirst = 'to_ASC_NULLS_FIRST', + ToDesc = 'to_DESC', + ToDescNullsLast = 'to_DESC_NULLS_LAST' } export type TokenTransferWhereInput = { @@ -8090,6 +10667,23 @@ export type TokenTransferWhereInput = { id_not_in?: InputMaybe>; id_not_startsWith?: InputMaybe; id_startsWith?: InputMaybe; + remark_contains?: InputMaybe; + remark_containsInsensitive?: InputMaybe; + remark_endsWith?: InputMaybe; + remark_eq?: InputMaybe; + remark_gt?: InputMaybe; + remark_gte?: InputMaybe; + remark_in?: InputMaybe>; + remark_isNull?: InputMaybe; + remark_lt?: InputMaybe; + remark_lte?: InputMaybe; + remark_not_contains?: InputMaybe; + remark_not_containsInsensitive?: InputMaybe; + remark_not_endsWith?: InputMaybe; + remark_not_eq?: InputMaybe; + remark_not_in?: InputMaybe>; + remark_not_startsWith?: InputMaybe; + remark_startsWith?: InputMaybe; timestamp_eq?: InputMaybe; timestamp_gt?: InputMaybe; timestamp_gte?: InputMaybe; @@ -8335,19 +10929,33 @@ export type TokenWithdrawnEdge = { export enum TokenWithdrawnOrderByInput { AmountAsc = 'amount_ASC', + AmountAscNullsFirst = 'amount_ASC_NULLS_FIRST', AmountDesc = 'amount_DESC', + AmountDescNullsLast = 'amount_DESC_NULLS_LAST', BlockNumberAsc = 'blockNumber_ASC', + BlockNumberAscNullsFirst = 'blockNumber_ASC_NULLS_FIRST', BlockNumberDesc = 'blockNumber_DESC', + BlockNumberDescNullsLast = 'blockNumber_DESC_NULLS_LAST', CurrencyIdAsc = 'currencyId_ASC', + CurrencyIdAscNullsFirst = 'currencyId_ASC_NULLS_FIRST', CurrencyIdDesc = 'currencyId_DESC', + CurrencyIdDescNullsLast = 'currencyId_DESC_NULLS_LAST', ExtrinsicHashAsc = 'extrinsicHash_ASC', + ExtrinsicHashAscNullsFirst = 'extrinsicHash_ASC_NULLS_FIRST', ExtrinsicHashDesc = 'extrinsicHash_DESC', + ExtrinsicHashDescNullsLast = 'extrinsicHash_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', WhoAsc = 'who_ASC', - WhoDesc = 'who_DESC' + WhoAscNullsFirst = 'who_ASC_NULLS_FIRST', + WhoDesc = 'who_DESC', + WhoDescNullsLast = 'who_DESC_NULLS_LAST' } export type TokenWithdrawnWhereInput = { @@ -8482,11 +11090,17 @@ export type TransactionEdge = { export enum TransactionOrderByInput { BlockNumberAsc = 'blockNumber_ASC', + BlockNumberAscNullsFirst = 'blockNumber_ASC_NULLS_FIRST', BlockNumberDesc = 'blockNumber_DESC', + BlockNumberDescNullsLast = 'blockNumber_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', - TimestampDesc = 'timestamp_DESC' + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', + TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST' } export type TransactionWhereInput = { @@ -8556,6 +11170,7 @@ export type Transfer = { fee: Scalars['BigInt']['output']; from: Scalars['String']['output']; id: Scalars['String']['output']; + remark?: Maybe; timestamp: Scalars['DateTime']['output']; to: Scalars['String']['output']; }; @@ -8568,21 +11183,41 @@ export type TransferEdge = { export enum TransferOrderByInput { AmountAsc = 'amount_ASC', + AmountAscNullsFirst = 'amount_ASC_NULLS_FIRST', AmountDesc = 'amount_DESC', + AmountDescNullsLast = 'amount_DESC_NULLS_LAST', BlockNumberAsc = 'blockNumber_ASC', + BlockNumberAscNullsFirst = 'blockNumber_ASC_NULLS_FIRST', BlockNumberDesc = 'blockNumber_DESC', + BlockNumberDescNullsLast = 'blockNumber_DESC_NULLS_LAST', ExtrinsicHashAsc = 'extrinsicHash_ASC', + ExtrinsicHashAscNullsFirst = 'extrinsicHash_ASC_NULLS_FIRST', ExtrinsicHashDesc = 'extrinsicHash_DESC', + ExtrinsicHashDescNullsLast = 'extrinsicHash_DESC_NULLS_LAST', FeeAsc = 'fee_ASC', + FeeAscNullsFirst = 'fee_ASC_NULLS_FIRST', FeeDesc = 'fee_DESC', + FeeDescNullsLast = 'fee_DESC_NULLS_LAST', FromAsc = 'from_ASC', + FromAscNullsFirst = 'from_ASC_NULLS_FIRST', FromDesc = 'from_DESC', + FromDescNullsLast = 'from_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', + RemarkAsc = 'remark_ASC', + RemarkAscNullsFirst = 'remark_ASC_NULLS_FIRST', + RemarkDesc = 'remark_DESC', + RemarkDescNullsLast = 'remark_DESC_NULLS_LAST', TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST', ToAsc = 'to_ASC', - ToDesc = 'to_DESC' + ToAscNullsFirst = 'to_ASC_NULLS_FIRST', + ToDesc = 'to_DESC', + ToDescNullsLast = 'to_DESC_NULLS_LAST' } export type TransferWhereInput = { @@ -8666,6 +11301,23 @@ export type TransferWhereInput = { id_not_in?: InputMaybe>; id_not_startsWith?: InputMaybe; id_startsWith?: InputMaybe; + remark_contains?: InputMaybe; + remark_containsInsensitive?: InputMaybe; + remark_endsWith?: InputMaybe; + remark_eq?: InputMaybe; + remark_gt?: InputMaybe; + remark_gte?: InputMaybe; + remark_in?: InputMaybe>; + remark_isNull?: InputMaybe; + remark_lt?: InputMaybe; + remark_lte?: InputMaybe; + remark_not_contains?: InputMaybe; + remark_not_containsInsensitive?: InputMaybe; + remark_not_endsWith?: InputMaybe; + remark_not_eq?: InputMaybe; + remark_not_in?: InputMaybe>; + remark_not_startsWith?: InputMaybe; + remark_startsWith?: InputMaybe; timestamp_eq?: InputMaybe; timestamp_gt?: InputMaybe; timestamp_gte?: InputMaybe; @@ -8743,9 +11395,13 @@ export type UserEdge = { export enum UserOrderByInput { IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', UsdSwappedAsc = 'usdSwapped_ASC', - UsdSwappedDesc = 'usdSwapped_DESC' + UsdSwappedAscNullsFirst = 'usdSwapped_ASC_NULLS_FIRST', + UsdSwappedDesc = 'usdSwapped_DESC', + UsdSwappedDescNullsLast = 'usdSwapped_DESC_NULLS_LAST' } export type UserWhereInput = { @@ -8822,11 +11478,17 @@ export type ZlkInfoEdge = { export enum ZlkInfoOrderByInput { BurnAsc = 'burn_ASC', + BurnAscNullsFirst = 'burn_ASC_NULLS_FIRST', BurnDesc = 'burn_DESC', + BurnDescNullsLast = 'burn_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', UpdatedDateAsc = 'updatedDate_ASC', - UpdatedDateDesc = 'updatedDate_DESC' + UpdatedDateAscNullsFirst = 'updatedDate_ASC_NULLS_FIRST', + UpdatedDateDesc = 'updatedDate_DESC', + UpdatedDateDescNullsLast = 'updatedDate_DESC_NULLS_LAST' } export type ZlkInfoWhereInput = { @@ -8894,41 +11556,77 @@ export type ZenlinkDayInfoEdge = { export enum ZenlinkDayInfoOrderByInput { DailyVolumeUsdAsc = 'dailyVolumeUSD_ASC', + DailyVolumeUsdAscNullsFirst = 'dailyVolumeUSD_ASC_NULLS_FIRST', DailyVolumeUsdDesc = 'dailyVolumeUSD_DESC', + DailyVolumeUsdDescNullsLast = 'dailyVolumeUSD_DESC_NULLS_LAST', DateAsc = 'date_ASC', + DateAscNullsFirst = 'date_ASC_NULLS_FIRST', DateDesc = 'date_DESC', + DateDescNullsLast = 'date_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', StableInfoDailyVolumeUsdAsc = 'stableInfo_dailyVolumeUSD_ASC', + StableInfoDailyVolumeUsdAscNullsFirst = 'stableInfo_dailyVolumeUSD_ASC_NULLS_FIRST', StableInfoDailyVolumeUsdDesc = 'stableInfo_dailyVolumeUSD_DESC', + StableInfoDailyVolumeUsdDescNullsLast = 'stableInfo_dailyVolumeUSD_DESC_NULLS_LAST', StableInfoDateAsc = 'stableInfo_date_ASC', + StableInfoDateAscNullsFirst = 'stableInfo_date_ASC_NULLS_FIRST', StableInfoDateDesc = 'stableInfo_date_DESC', + StableInfoDateDescNullsLast = 'stableInfo_date_DESC_NULLS_LAST', StableInfoIdAsc = 'stableInfo_id_ASC', + StableInfoIdAscNullsFirst = 'stableInfo_id_ASC_NULLS_FIRST', StableInfoIdDesc = 'stableInfo_id_DESC', + StableInfoIdDescNullsLast = 'stableInfo_id_DESC_NULLS_LAST', StableInfoTvlUsdAsc = 'stableInfo_tvlUSD_ASC', + StableInfoTvlUsdAscNullsFirst = 'stableInfo_tvlUSD_ASC_NULLS_FIRST', StableInfoTvlUsdDesc = 'stableInfo_tvlUSD_DESC', + StableInfoTvlUsdDescNullsLast = 'stableInfo_tvlUSD_DESC_NULLS_LAST', StandardInfoDailyVolumeEthAsc = 'standardInfo_dailyVolumeETH_ASC', + StandardInfoDailyVolumeEthAscNullsFirst = 'standardInfo_dailyVolumeETH_ASC_NULLS_FIRST', StandardInfoDailyVolumeEthDesc = 'standardInfo_dailyVolumeETH_DESC', + StandardInfoDailyVolumeEthDescNullsLast = 'standardInfo_dailyVolumeETH_DESC_NULLS_LAST', StandardInfoDailyVolumeUsdAsc = 'standardInfo_dailyVolumeUSD_ASC', + StandardInfoDailyVolumeUsdAscNullsFirst = 'standardInfo_dailyVolumeUSD_ASC_NULLS_FIRST', StandardInfoDailyVolumeUsdDesc = 'standardInfo_dailyVolumeUSD_DESC', + StandardInfoDailyVolumeUsdDescNullsLast = 'standardInfo_dailyVolumeUSD_DESC_NULLS_LAST', StandardInfoDailyVolumeUntrackedAsc = 'standardInfo_dailyVolumeUntracked_ASC', + StandardInfoDailyVolumeUntrackedAscNullsFirst = 'standardInfo_dailyVolumeUntracked_ASC_NULLS_FIRST', StandardInfoDailyVolumeUntrackedDesc = 'standardInfo_dailyVolumeUntracked_DESC', + StandardInfoDailyVolumeUntrackedDescNullsLast = 'standardInfo_dailyVolumeUntracked_DESC_NULLS_LAST', StandardInfoDateAsc = 'standardInfo_date_ASC', + StandardInfoDateAscNullsFirst = 'standardInfo_date_ASC_NULLS_FIRST', StandardInfoDateDesc = 'standardInfo_date_DESC', + StandardInfoDateDescNullsLast = 'standardInfo_date_DESC_NULLS_LAST', StandardInfoIdAsc = 'standardInfo_id_ASC', + StandardInfoIdAscNullsFirst = 'standardInfo_id_ASC_NULLS_FIRST', StandardInfoIdDesc = 'standardInfo_id_DESC', + StandardInfoIdDescNullsLast = 'standardInfo_id_DESC_NULLS_LAST', StandardInfoTotalLiquidityEthAsc = 'standardInfo_totalLiquidityETH_ASC', + StandardInfoTotalLiquidityEthAscNullsFirst = 'standardInfo_totalLiquidityETH_ASC_NULLS_FIRST', StandardInfoTotalLiquidityEthDesc = 'standardInfo_totalLiquidityETH_DESC', + StandardInfoTotalLiquidityEthDescNullsLast = 'standardInfo_totalLiquidityETH_DESC_NULLS_LAST', StandardInfoTotalLiquidityUsdAsc = 'standardInfo_totalLiquidityUSD_ASC', + StandardInfoTotalLiquidityUsdAscNullsFirst = 'standardInfo_totalLiquidityUSD_ASC_NULLS_FIRST', StandardInfoTotalLiquidityUsdDesc = 'standardInfo_totalLiquidityUSD_DESC', + StandardInfoTotalLiquidityUsdDescNullsLast = 'standardInfo_totalLiquidityUSD_DESC_NULLS_LAST', StandardInfoTotalVolumeEthAsc = 'standardInfo_totalVolumeETH_ASC', + StandardInfoTotalVolumeEthAscNullsFirst = 'standardInfo_totalVolumeETH_ASC_NULLS_FIRST', StandardInfoTotalVolumeEthDesc = 'standardInfo_totalVolumeETH_DESC', + StandardInfoTotalVolumeEthDescNullsLast = 'standardInfo_totalVolumeETH_DESC_NULLS_LAST', StandardInfoTotalVolumeUsdAsc = 'standardInfo_totalVolumeUSD_ASC', + StandardInfoTotalVolumeUsdAscNullsFirst = 'standardInfo_totalVolumeUSD_ASC_NULLS_FIRST', StandardInfoTotalVolumeUsdDesc = 'standardInfo_totalVolumeUSD_DESC', + StandardInfoTotalVolumeUsdDescNullsLast = 'standardInfo_totalVolumeUSD_DESC_NULLS_LAST', StandardInfoTxCountAsc = 'standardInfo_txCount_ASC', + StandardInfoTxCountAscNullsFirst = 'standardInfo_txCount_ASC_NULLS_FIRST', StandardInfoTxCountDesc = 'standardInfo_txCount_DESC', + StandardInfoTxCountDescNullsLast = 'standardInfo_txCount_DESC_NULLS_LAST', TvlUsdAsc = 'tvlUSD_ASC', - TvlUsdDesc = 'tvlUSD_DESC' + TvlUsdAscNullsFirst = 'tvlUSD_ASC_NULLS_FIRST', + TvlUsdDesc = 'tvlUSD_DESC', + TvlUsdDescNullsLast = 'tvlUSD_DESC_NULLS_LAST' } export type ZenlinkDayInfoWhereInput = { @@ -9028,41 +11726,77 @@ export type ZenlinkInfoEdge = { export enum ZenlinkInfoOrderByInput { FactoryIdAsc = 'factory_id_ASC', + FactoryIdAscNullsFirst = 'factory_id_ASC_NULLS_FIRST', FactoryIdDesc = 'factory_id_DESC', + FactoryIdDescNullsLast = 'factory_id_DESC_NULLS_LAST', FactoryPairCountAsc = 'factory_pairCount_ASC', + FactoryPairCountAscNullsFirst = 'factory_pairCount_ASC_NULLS_FIRST', FactoryPairCountDesc = 'factory_pairCount_DESC', + FactoryPairCountDescNullsLast = 'factory_pairCount_DESC_NULLS_LAST', FactoryTotalLiquidityEthAsc = 'factory_totalLiquidityETH_ASC', + FactoryTotalLiquidityEthAscNullsFirst = 'factory_totalLiquidityETH_ASC_NULLS_FIRST', FactoryTotalLiquidityEthDesc = 'factory_totalLiquidityETH_DESC', + FactoryTotalLiquidityEthDescNullsLast = 'factory_totalLiquidityETH_DESC_NULLS_LAST', FactoryTotalLiquidityUsdAsc = 'factory_totalLiquidityUSD_ASC', + FactoryTotalLiquidityUsdAscNullsFirst = 'factory_totalLiquidityUSD_ASC_NULLS_FIRST', FactoryTotalLiquidityUsdDesc = 'factory_totalLiquidityUSD_DESC', + FactoryTotalLiquidityUsdDescNullsLast = 'factory_totalLiquidityUSD_DESC_NULLS_LAST', FactoryTotalVolumeEthAsc = 'factory_totalVolumeETH_ASC', + FactoryTotalVolumeEthAscNullsFirst = 'factory_totalVolumeETH_ASC_NULLS_FIRST', FactoryTotalVolumeEthDesc = 'factory_totalVolumeETH_DESC', + FactoryTotalVolumeEthDescNullsLast = 'factory_totalVolumeETH_DESC_NULLS_LAST', FactoryTotalVolumeUsdAsc = 'factory_totalVolumeUSD_ASC', + FactoryTotalVolumeUsdAscNullsFirst = 'factory_totalVolumeUSD_ASC_NULLS_FIRST', FactoryTotalVolumeUsdDesc = 'factory_totalVolumeUSD_DESC', + FactoryTotalVolumeUsdDescNullsLast = 'factory_totalVolumeUSD_DESC_NULLS_LAST', FactoryTxCountAsc = 'factory_txCount_ASC', + FactoryTxCountAscNullsFirst = 'factory_txCount_ASC_NULLS_FIRST', FactoryTxCountDesc = 'factory_txCount_DESC', + FactoryTxCountDescNullsLast = 'factory_txCount_DESC_NULLS_LAST', FactoryUntrackedVolumeUsdAsc = 'factory_untrackedVolumeUSD_ASC', + FactoryUntrackedVolumeUsdAscNullsFirst = 'factory_untrackedVolumeUSD_ASC_NULLS_FIRST', FactoryUntrackedVolumeUsdDesc = 'factory_untrackedVolumeUSD_DESC', + FactoryUntrackedVolumeUsdDescNullsLast = 'factory_untrackedVolumeUSD_DESC_NULLS_LAST', IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', StableSwapInfoIdAsc = 'stableSwapInfo_id_ASC', + StableSwapInfoIdAscNullsFirst = 'stableSwapInfo_id_ASC_NULLS_FIRST', StableSwapInfoIdDesc = 'stableSwapInfo_id_DESC', + StableSwapInfoIdDescNullsLast = 'stableSwapInfo_id_DESC_NULLS_LAST', StableSwapInfoPoolCountAsc = 'stableSwapInfo_poolCount_ASC', + StableSwapInfoPoolCountAscNullsFirst = 'stableSwapInfo_poolCount_ASC_NULLS_FIRST', StableSwapInfoPoolCountDesc = 'stableSwapInfo_poolCount_DESC', + StableSwapInfoPoolCountDescNullsLast = 'stableSwapInfo_poolCount_DESC_NULLS_LAST', StableSwapInfoTotalTvlUsdAsc = 'stableSwapInfo_totalTvlUSD_ASC', + StableSwapInfoTotalTvlUsdAscNullsFirst = 'stableSwapInfo_totalTvlUSD_ASC_NULLS_FIRST', StableSwapInfoTotalTvlUsdDesc = 'stableSwapInfo_totalTvlUSD_DESC', + StableSwapInfoTotalTvlUsdDescNullsLast = 'stableSwapInfo_totalTvlUSD_DESC_NULLS_LAST', StableSwapInfoTotalVolumeUsdAsc = 'stableSwapInfo_totalVolumeUSD_ASC', + StableSwapInfoTotalVolumeUsdAscNullsFirst = 'stableSwapInfo_totalVolumeUSD_ASC_NULLS_FIRST', StableSwapInfoTotalVolumeUsdDesc = 'stableSwapInfo_totalVolumeUSD_DESC', + StableSwapInfoTotalVolumeUsdDescNullsLast = 'stableSwapInfo_totalVolumeUSD_DESC_NULLS_LAST', StableSwapInfoTxCountAsc = 'stableSwapInfo_txCount_ASC', + StableSwapInfoTxCountAscNullsFirst = 'stableSwapInfo_txCount_ASC_NULLS_FIRST', StableSwapInfoTxCountDesc = 'stableSwapInfo_txCount_DESC', + StableSwapInfoTxCountDescNullsLast = 'stableSwapInfo_txCount_DESC_NULLS_LAST', TotalTvlUsdAsc = 'totalTvlUSD_ASC', + TotalTvlUsdAscNullsFirst = 'totalTvlUSD_ASC_NULLS_FIRST', TotalTvlUsdDesc = 'totalTvlUSD_DESC', + TotalTvlUsdDescNullsLast = 'totalTvlUSD_DESC_NULLS_LAST', TotalVolumeUsdAsc = 'totalVolumeUSD_ASC', + TotalVolumeUsdAscNullsFirst = 'totalVolumeUSD_ASC_NULLS_FIRST', TotalVolumeUsdDesc = 'totalVolumeUSD_DESC', + TotalVolumeUsdDescNullsLast = 'totalVolumeUSD_DESC_NULLS_LAST', TxCountAsc = 'txCount_ASC', + TxCountAscNullsFirst = 'txCount_ASC_NULLS_FIRST', TxCountDesc = 'txCount_DESC', + TxCountDescNullsLast = 'txCount_DESC_NULLS_LAST', UpdatedDateAsc = 'updatedDate_ASC', - UpdatedDateDesc = 'updatedDate_DESC' + UpdatedDateAscNullsFirst = 'updatedDate_ASC_NULLS_FIRST', + UpdatedDateDesc = 'updatedDate_DESC', + UpdatedDateDescNullsLast = 'updatedDate_DESC_NULLS_LAST' } export type ZenlinkInfoWhereInput = { @@ -9157,23 +11891,29 @@ export type GetBackstopPoolQueryVariables = Exact<{ export type GetBackstopPoolQuery = { __typename?: 'Query', backstopPoolById?: { __typename?: 'BackstopPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any, token: { __typename?: 'NablaToken', decimals: number, id: string, name: string, symbol: string }, router: { __typename?: 'Router', id: string, swapPools: Array<{ __typename?: 'SwapPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any, token: { __typename?: 'NablaToken', decimals: number, id: string, name: string, symbol: string } }> } } | null }; -export type GetBackstopPoolsQueryVariables = Exact<{ [key: string]: never; }>; +export type GetBackstopPoolsQueryVariables = Exact<{ + ids?: InputMaybe | Scalars['String']['input']>; +}>; export type GetBackstopPoolsQuery = { __typename?: 'Query', backstopPools: Array<{ __typename?: 'BackstopPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any, token: { __typename?: 'NablaToken', id: string, decimals: number, name: string, symbol: string }, router: { __typename?: 'Router', id: string, swapPools: Array<{ __typename?: 'SwapPool', id: string }> } }> }; -export type GetSwapPoolsQueryVariables = Exact<{ [key: string]: never; }>; +export type GetSwapPoolsQueryVariables = Exact<{ + ids?: InputMaybe | Scalars['String']['input']>; +}>; export type GetSwapPoolsQuery = { __typename?: 'Query', swapPools: Array<{ __typename?: 'SwapPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any, token: { __typename?: 'NablaToken', id: string, name: string, symbol: string, decimals: number }, router: { __typename?: 'Router', id: string, paused: boolean }, backstop: { __typename?: 'BackstopPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any } }> }; -export type GetTokensQueryVariables = Exact<{ [key: string]: never; }>; +export type GetTokensQueryVariables = Exact<{ + ids?: InputMaybe | Scalars['String']['input']>; +}>; export type GetTokensQuery = { __typename?: 'Query', nablaTokens: Array<{ __typename?: 'NablaToken', id: string, name: string, symbol: string, decimals: number }> }; export const GetBackstopPoolDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getBackstopPool"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"id"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"backstopPoolById"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"id"},"value":{"kind":"Variable","name":{"kind":"Name","value":"id"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}},{"kind":"Field","name":{"kind":"Name","value":"router"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"router_isNull"},"value":{"kind":"BooleanValue","value":false}},{"kind":"ObjectField","name":{"kind":"Name","value":"paused_not_eq"},"value":{"kind":"BooleanValue","value":true}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]}}]} as unknown as DocumentNode; -export const GetBackstopPoolsDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getBackstopPools"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"backstopPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"paused_eq"},"value":{"kind":"BooleanValue","value":false}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}},{"kind":"Field","name":{"kind":"Name","value":"router"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"router_isNull"},"value":{"kind":"BooleanValue","value":false}},{"kind":"ObjectField","name":{"kind":"Name","value":"paused_not_eq"},"value":{"kind":"BooleanValue","value":true}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]}}]} as unknown as DocumentNode; -export const GetSwapPoolsDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getSwapPools"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"paused_eq"},"value":{"kind":"BooleanValue","value":false}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}}]}},{"kind":"Field","name":{"kind":"Name","value":"router"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}}]}},{"kind":"Field","name":{"kind":"Name","value":"backstop"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}}]}}]}}]}}]} as unknown as DocumentNode; -export const GetTokensDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getTokens"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"nablaTokens"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}}]}}]}}]} as unknown as DocumentNode; \ No newline at end of file +export const GetBackstopPoolsDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getBackstopPools"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"ids"}},"type":{"kind":"ListType","type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"backstopPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"paused_eq"},"value":{"kind":"BooleanValue","value":false}},{"kind":"ObjectField","name":{"kind":"Name","value":"id_in"},"value":{"kind":"Variable","name":{"kind":"Name","value":"ids"}}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}},{"kind":"Field","name":{"kind":"Name","value":"router"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"router_isNull"},"value":{"kind":"BooleanValue","value":false}},{"kind":"ObjectField","name":{"kind":"Name","value":"paused_not_eq"},"value":{"kind":"BooleanValue","value":true}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]}}]} as unknown as DocumentNode; +export const GetSwapPoolsDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getSwapPools"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"ids"}},"type":{"kind":"ListType","type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"paused_eq"},"value":{"kind":"BooleanValue","value":false}},{"kind":"ObjectField","name":{"kind":"Name","value":"id_in"},"value":{"kind":"Variable","name":{"kind":"Name","value":"ids"}}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}}]}},{"kind":"Field","name":{"kind":"Name","value":"router"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}}]}},{"kind":"Field","name":{"kind":"Name","value":"backstop"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}}]}}]}}]}}]} as unknown as DocumentNode; +export const GetTokensDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getTokens"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"ids"}},"type":{"kind":"ListType","type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"nablaTokens"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"id_in"},"value":{"kind":"Variable","name":{"kind":"Name","value":"ids"}}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}}]}}]}}]} as unknown as DocumentNode; \ No newline at end of file diff --git a/src/config/apps/nabla.ts b/src/config/apps/nabla.ts index 900ce289..6dcaab81 100644 --- a/src/config/apps/nabla.ts +++ b/src/config/apps/nabla.ts @@ -9,6 +9,9 @@ export type NablaConfig = AppConfigBase & router: string; oracle: string; curve: string; + assets: string[]; + swapPools: string[]; + backstopPools: string[]; } > >; @@ -20,8 +23,19 @@ export const nablaConfig: NablaConfig = { indexerUrl: 'https://squid.subsquid.io/foucoco-squid/graphql', // TODO: if these addresses change we will need to fetch them from the indexer - router: '6nHNN8GfwaUcSvp7QhRJZtXY5yQLBeVz3J2RCx395ma9MbeV', - oracle: '6guy27fyEZpKyBwWfysB6X2N3RDgrVertCaZ4ont8FPqdD9C', - curve: '6mxUgPWk76RzqnUnEryZkFNZ3tqqdtwyrXmaWwMJ2n311cZE', + router: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', + curve: '6mwEn6oJpMLfkBB3PwDWvdvv8XystGsnHwE2Jm6JUmTtbfmW', + oracle: '6mRAW3J7FhfW9cK4pQN2gLUohBvejvXagTMaG57mm79MMukh', + assets: [ + '6iFkBQJ1C5rKeAc3Np6xAZBM9WfNuukLyjJffELK9HGkDjoa', + '6h4VmXd5MHBTyJbem7f68xsi7otXvqLUiKf8SdRH9n2nuYaP', + '6nbACDpR3WCCy7qcTBb5MQZjpZZJCLzQ3g9sBH3RqXgWx4T4', + ], + swapPools: [ + '6knNBRZ6L6KDdS9JxBUN92ffUdNGHnA4MiFFNbVfbYkKZSUv', + '6hCd2N5PVhHEoRwg5Db1Ja11sdwNKEmsRd24i76CV2NmdH46', + '6nSUPH1Zubuipt1Knit352hkNEMKdSobaYGsZyo271mFd6fp', + ], + backstopPools: ['6m6SUHd1XRpboq3GMsL73RigXCfz9iKZGWjoAzMnJJ9dJNgs'], }, }; diff --git a/src/hooks/nabla/useBackstopPools.ts b/src/hooks/nabla/useBackstopPools.ts index c3b9167a..40ccb94e 100644 --- a/src/hooks/nabla/useBackstopPools.ts +++ b/src/hooks/nabla/useBackstopPools.ts @@ -9,11 +9,14 @@ import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; export type UseBackstopPoolsProps = UseQueryOptions; export const useBackstopPools = (options?: UseBackstopPoolsProps) => { - const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!indexerUrl && options?.enabled !== false; + const { indexerUrl, backstopPools } = useGetAppDataByTenant('nabla').data || {}; + const enabled = !!indexerUrl && !!backstopPools && options?.enabled !== false; return useQuery( enabled ? [cacheKeys.backstopPools, indexerUrl] : emptyCacheKey, - enabled ? async () => (await request(indexerUrl, getBackstopPools))?.backstopPools as BackstopPool[] : emptyFn, + enabled + ? async () => + (await request(indexerUrl, getBackstopPools, { ids: backstopPools }))?.backstopPools as BackstopPool[] + : emptyFn, { ...inactiveOptions['1m'], refetchInterval: 30000, @@ -24,8 +27,8 @@ export const useBackstopPools = (options?: UseBackstopPoolsProps) => { }; export const getBackstopPools = graphql(` - query getBackstopPools { - backstopPools(where: { paused_eq: false }) { + query getBackstopPools($ids: [String!]) { + backstopPools(where: { paused_eq: false, id_in: $ids }) { id liabilities paused diff --git a/src/hooks/nabla/useSwapPools.ts b/src/hooks/nabla/useSwapPools.ts index e5c70cdf..14095fb0 100644 --- a/src/hooks/nabla/useSwapPools.ts +++ b/src/hooks/nabla/useSwapPools.ts @@ -9,11 +9,13 @@ import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; export type UseSwapPoolsProps = UseQueryOptions; export const useSwapPools = (options?: UseSwapPoolsProps) => { - const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!indexerUrl && options?.enabled !== false; + const { indexerUrl, swapPools } = useGetAppDataByTenant('nabla').data || {}; + const enabled = !!indexerUrl && !!swapPools && options?.enabled !== false; return useQuery( enabled ? [cacheKeys.swapPools, indexerUrl] : emptyCacheKey, - enabled ? async () => (await request(indexerUrl, getSwapPools))?.swapPools as SwapPool[] : emptyFn, + enabled + ? async () => (await request(indexerUrl, getSwapPools, { ids: swapPools }))?.swapPools as SwapPool[] + : emptyFn, { ...inactiveOptions['1m'], refetchInterval: 30000, @@ -24,8 +26,8 @@ export const useSwapPools = (options?: UseSwapPoolsProps) => { }; export const getSwapPools = graphql(` - query getSwapPools { - swapPools(where: { paused_eq: false }) { + query getSwapPools($ids: [String!]) { + swapPools(where: { paused_eq: false, id_in: $ids }) { id liabilities paused diff --git a/src/hooks/nabla/useTokens.ts b/src/hooks/nabla/useTokens.ts index ca171500..bff9339c 100644 --- a/src/hooks/nabla/useTokens.ts +++ b/src/hooks/nabla/useTokens.ts @@ -2,7 +2,7 @@ import { useQuery } from '@tanstack/react-query'; import request from 'graphql-request'; import { graphql } from '../../../gql/gql'; import { Token } from '../../../gql/graphql'; -import { QueryOptions, cacheKeys, inactiveOptions } from '../../constants/cache'; +import { cacheKeys, inactiveOptions, QueryOptions } from '../../constants/cache'; import { emptyCacheKey, emptyFn } from '../../helpers/general'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; @@ -12,13 +12,13 @@ export type TokensData = { }; export const useTokens = (options?: QueryOptions) => { - const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!indexerUrl && options?.enabled !== false; + const { indexerUrl, assets } = useGetAppDataByTenant('nabla').data || {}; + const enabled = !!indexerUrl && options?.enabled !== false && !!assets; return useQuery( enabled ? [cacheKeys.tokens, indexerUrl] : emptyCacheKey, enabled ? async () => { - const response = (await request(indexerUrl, getTokens))?.nablaTokens as Token[]; + const response = (await request(indexerUrl, getTokens, { ids: assets }))?.nablaTokens as Token[]; return response?.reduce( (acc, curr) => { acc.tokensMap[curr.id] = curr; @@ -39,8 +39,8 @@ export const useTokens = (options?: QueryOptions) => { }; const getTokens = graphql(` - query getTokens { - nablaTokens { + query getTokens($ids: [String!]) { + nablaTokens(where: { id_in: $ids }) { id name symbol diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index 32fff783..62e2237b 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -96,5 +96,6 @@ export const useContractWrite = >({ }); }; const mutation = useMutation(submit, rest); + console.log(mutation.data); return { ...mutation, data: transaction, isReady }; }; diff --git a/src/shared/useTokenApproval.ts b/src/shared/useTokenApproval.ts index ce3509e3..79db9649 100644 --- a/src/shared/useTokenApproval.ts +++ b/src/shared/useTokenApproval.ts @@ -59,10 +59,9 @@ export const useTokenApproval = ({ address: token, method: 'approve', args: [spender, approveMax ? maxInt : amountBI.toString()], - options: (api) => ({ - gasLimit: api.createType('WeightV2', gasDefaults), - storageDepositLimit: null, - }), + options: { + gas: gasDefaults, + }, onError: (err) => { setPending(false); if (onError) onError(err); diff --git a/vite.config.ts b/vite.config.ts index aaf8091b..044ac873 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -47,6 +47,7 @@ export default defineConfig({ optimizeDeps: { exclude: [], esbuildOptions: { + target: 'esnext', // Node.js global to browser globalThis define: { global: 'globalThis', @@ -62,6 +63,7 @@ export default defineConfig({ }, }, build: { + target: ['esnext'], rollupOptions: { plugins: [ // Enable rollup polyfills plugin From 1b529dd51a4cbdb02436eeb1737723c2ba112a61 Mon Sep 17 00:00:00 2001 From: Nejc Date: Thu, 28 Dec 2023 16:56:07 +0100 Subject: [PATCH 04/58] refactor: use mock data --- src/hooks/nabla/mock.ts | 102 ++++++++++++++++++++++++++++ src/hooks/nabla/useBackstopPool.ts | 5 +- src/hooks/nabla/useBackstopPools.ts | 4 +- src/hooks/nabla/useSwapPools.ts | 5 +- src/hooks/nabla/useTokens.ts | 4 +- src/shared/useContractWrite.ts | 8 +-- 6 files changed, 120 insertions(+), 8 deletions(-) create mode 100644 src/hooks/nabla/mock.ts diff --git a/src/hooks/nabla/mock.ts b/src/hooks/nabla/mock.ts new file mode 100644 index 00000000..0856cd09 --- /dev/null +++ b/src/hooks/nabla/mock.ts @@ -0,0 +1,102 @@ +import { BackstopPool, NablaToken, SwapPool } from '../../../gql/graphql'; + +const common = { + decimals: 18, + derivedETH: '', + pairBase: [], + pairDayDataBase: [], + pairDayDataQuote: [], + pairQuote: [], + tokenDayData: [], + totalLiquidity: '1000000000', + totalSupply: '10000000000', + tradeVolume: '500000000', + tradeVolumeUSD: '500000000', + txCount: 1000, + untrackedVolumeUSD: '', +}; +export const mockTokens: NablaToken[] = [ + { + id: '6iFkBQJ1C5rKeAc3Np6xAZBM9WfNuukLyjJffELK9HGkDjoa', + name: 'Mock USD', + symbol: 'mUSD', + ...common, + }, + { + id: '6h4VmXd5MHBTyJbem7f68xsi7otXvqLUiKf8SdRH9n2nuYaP', + name: 'Mock EUR', + symbol: 'mEUR', + ...common, + }, + { + id: '6nbACDpR3WCCy7qcTBb5MQZjpZZJCLzQ3g9sBH3RqXgWx4T4', + name: 'Mock ETH', + symbol: 'mETH', + ...common, + }, +]; + +export const mockBackstopPools: BackstopPool[] = [ + { + id: '6m6SUHd1XRpboq3GMsL73RigXCfz9iKZGWjoAzMnJJ9dJNgs', + token: mockTokens[0], + liabilities: '1200000000', + paused: false, + reserves: '1400000000', + router: { + id: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', + backstopPools: [], + paused: false, + swapPools: [], + }, + ...common, + }, +]; + +export const mockSwapPools: SwapPool[] = [ + { + id: '6nSUPH1Zubuipt1Knit352hkNEMKdSobaYGsZyo271mFd6fp', + token: mockTokens[0], + liabilities: '1200000000', + paused: false, + reserves: '1400000000', + router: { + id: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', + backstopPools: [], + paused: false, + swapPools: [], + }, + backstop: mockBackstopPools[0], + ...common, + }, + { + id: '6knNBRZ6L6KDdS9JxBUN92ffUdNGHnA4MiFFNbVfbYkKZSUv', + token: mockTokens[1], + liabilities: '1200000000', + paused: false, + reserves: '1400000000', + router: { + id: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', + backstopPools: [], + paused: false, + swapPools: [], + }, + backstop: mockBackstopPools[0], + ...common, + }, + { + id: '6hCd2N5PVhHEoRwg5Db1Ja11sdwNKEmsRd24i76CV2NmdH46', + token: mockTokens[2], + liabilities: '1200000000', + paused: false, + reserves: '1400000000', + router: { + id: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', + backstopPools: [], + paused: false, + swapPools: [], + }, + backstop: mockBackstopPools[0], + ...common, + }, +]; diff --git a/src/hooks/nabla/useBackstopPool.ts b/src/hooks/nabla/useBackstopPool.ts index 1233ba43..48aac045 100644 --- a/src/hooks/nabla/useBackstopPool.ts +++ b/src/hooks/nabla/useBackstopPool.ts @@ -5,6 +5,7 @@ import { BackstopPool } from '../../../gql/graphql'; import { cacheKeys, inactiveOptions } from '../../constants/cache'; import { emptyCacheKey, emptyFn } from '../../helpers/general'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; +import { mockBackstopPools } from './mock'; export type UseBackstopPoolProps = UseQueryOptions; @@ -14,7 +15,9 @@ export const useBackstopPool = (id: string, options?: UseBackstopPoolProps) => { return useQuery( enabled ? [cacheKeys.backstopPools, id, indexerUrl] : emptyCacheKey, enabled - ? async () => (await request(indexerUrl, getBackstopPool, { id }))?.backstopPoolById as BackstopPool + ? async () => + (mockBackstopPools[0] || // TODO: temporary solution + (await request(indexerUrl, getBackstopPool, { id }))?.backstopPoolById) as BackstopPool : emptyFn, { ...inactiveOptions['1m'], diff --git a/src/hooks/nabla/useBackstopPools.ts b/src/hooks/nabla/useBackstopPools.ts index 40ccb94e..ae0c3a2c 100644 --- a/src/hooks/nabla/useBackstopPools.ts +++ b/src/hooks/nabla/useBackstopPools.ts @@ -5,6 +5,7 @@ import { BackstopPool } from '../../../gql/graphql'; import { cacheKeys, inactiveOptions } from '../../constants/cache'; import { emptyCacheKey, emptyFn } from '../../helpers/general'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; +import { mockBackstopPools } from './mock'; export type UseBackstopPoolsProps = UseQueryOptions; @@ -15,7 +16,8 @@ export const useBackstopPools = (options?: UseBackstopPoolsProps) => { enabled ? [cacheKeys.backstopPools, indexerUrl] : emptyCacheKey, enabled ? async () => - (await request(indexerUrl, getBackstopPools, { ids: backstopPools }))?.backstopPools as BackstopPool[] + (mockBackstopPools || // TODO: temporary solution + (await request(indexerUrl, getBackstopPools, { ids: backstopPools }))?.backstopPools) as BackstopPool[] : emptyFn, { ...inactiveOptions['1m'], diff --git a/src/hooks/nabla/useSwapPools.ts b/src/hooks/nabla/useSwapPools.ts index 14095fb0..570e6a05 100644 --- a/src/hooks/nabla/useSwapPools.ts +++ b/src/hooks/nabla/useSwapPools.ts @@ -5,6 +5,7 @@ import { SwapPool } from '../../../gql/graphql'; import { cacheKeys, inactiveOptions } from '../../constants/cache'; import { emptyCacheKey, emptyFn } from '../../helpers/general'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; +import { mockSwapPools } from './mock'; export type UseSwapPoolsProps = UseQueryOptions; @@ -14,7 +15,9 @@ export const useSwapPools = (options?: UseSwapPoolsProps) => { return useQuery( enabled ? [cacheKeys.swapPools, indexerUrl] : emptyCacheKey, enabled - ? async () => (await request(indexerUrl, getSwapPools, { ids: swapPools }))?.swapPools as SwapPool[] + ? async () => + // TODO: temporary solution + (mockSwapPools || (await request(indexerUrl, getSwapPools, { ids: swapPools }))?.swapPools) as SwapPool[] : emptyFn, { ...inactiveOptions['1m'], diff --git a/src/hooks/nabla/useTokens.ts b/src/hooks/nabla/useTokens.ts index bff9339c..48ce9079 100644 --- a/src/hooks/nabla/useTokens.ts +++ b/src/hooks/nabla/useTokens.ts @@ -5,6 +5,7 @@ import { Token } from '../../../gql/graphql'; import { cacheKeys, inactiveOptions, QueryOptions } from '../../constants/cache'; import { emptyCacheKey, emptyFn } from '../../helpers/general'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; +import { mockTokens } from './mock'; export type TokensData = { tokensMap: Record; @@ -18,7 +19,8 @@ export const useTokens = (options?: QueryOptions) => { enabled ? [cacheKeys.tokens, indexerUrl] : emptyCacheKey, enabled ? async () => { - const response = (await request(indexerUrl, getTokens, { ids: assets }))?.nablaTokens as Token[]; + const response = (mockTokens || // TODO: temporary solution + (await request(indexerUrl, getTokens, { ids: assets }))?.nablaTokens) as Token[]; return response?.reduce( (acc, curr) => { acc.tokensMap[curr.id] = curr; diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index 62e2237b..395d833c 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -82,13 +82,13 @@ export const useContractWrite = >({ return messageCall({ abi: abi as Abi, api, - callerAddress: address, - contractDeploymentAddress: '', + callerAddress: walletAddress, + contractDeploymentAddress: address, getSigner: () => Promise.resolve({ type: 'signer', address: walletAddress, - signer: signer, + signer, }), messageName: method, messageArguments: fnArgs, @@ -96,6 +96,6 @@ export const useContractWrite = >({ }); }; const mutation = useMutation(submit, rest); - console.log(mutation.data); + console.log('test', mutation.data); return { ...mutation, data: transaction, isReady }; }; From 11eb4d9094dedbac5ae8486a8e94ddf4f82aaace Mon Sep 17 00:00:00 2001 From: Nejc Date: Thu, 28 Dec 2023 19:20:08 +0100 Subject: [PATCH 05/58] feat: updated abi files --- src/contracts/nabla/AmberCurve.ts | 1 - src/contracts/nabla/BackstopPool.ts | 635 ++++++++++++----------- src/contracts/nabla/ChainlinkAdapter.ts | 280 ---------- src/contracts/nabla/ERC20Wrapper.ts | 654 ++++++++++++++++++++++++ src/contracts/nabla/MockERC20.ts | 542 -------------------- src/contracts/nabla/NablaCurve.ts | 438 ++++++++++++++++ src/contracts/nabla/PriceOracle.ts | 19 +- src/contracts/nabla/Router.ts | 231 +++++++-- src/contracts/nabla/SwapPool.ts | 651 +++++++++++++++-------- src/pages/nabla/dev/index.tsx | 4 +- src/shared/useContractBalance.ts | 4 +- src/shared/useContractWrite.ts | 44 +- src/shared/useTokenAllowance.ts | 4 +- src/shared/useTokenApproval.ts | 4 +- tailwind.config.cjs | 2 +- 15 files changed, 2102 insertions(+), 1411 deletions(-) delete mode 100644 src/contracts/nabla/ChainlinkAdapter.ts create mode 100644 src/contracts/nabla/ERC20Wrapper.ts delete mode 100644 src/contracts/nabla/MockERC20.ts create mode 100644 src/contracts/nabla/NablaCurve.ts diff --git a/src/contracts/nabla/AmberCurve.ts b/src/contracts/nabla/AmberCurve.ts index 88efb68b..ae47800f 100644 --- a/src/contracts/nabla/AmberCurve.ts +++ b/src/contracts/nabla/AmberCurve.ts @@ -9,7 +9,6 @@ export const amberCurveAbi = { compiler: 'solang 0.3.0', hash: '0x19a93fa817d5199daa422e1fb71b05f8be5e9e06c458845c1631b440ba050222', language: 'Solidity 0.3.0', - wasm: '0x0061736d0100000001390860047f7f7f7f017f60027f7f0060017f017f60047f7e7e7f0060097e7e7e7e7e7e7e7e7f017f60057e7e7e7e7f017f60037f7f7f00600000027406057365616c320b7365745f73746f726167650000057365616c310b6765745f73746f726167650000057365616c300b7365616c5f72657475726e0006057365616c3005696e7075740001057365616c301176616c75655f7472616e73666572726564000103656e76066d656d6f727902011010030d0c0202000303000004050504070608017f01418080040b071102066465706c6f7900100463616c6c00100ae4d3010c7b01047f2000220141086a10062202200136020420022001360200200241086a210002402001450d00200141016b2001410771220304400340200041003a0000200041016a2100200141016b2101200341016b22030d000b0b4107490d00034020004200370000200041086a2100200141086b22010d000b0b20020b950101047f41808004210103400240200128020c0d00200128020822022000490d002002200041076a41787122026b220441184f0440200120026a41106a22002001280200220336020020030440200320003602040b2000200441106b3602082000410036020c2000200136020420012000360200200120023602080b2001410136020c200141106a0f0b200128020021010c000b000b8303020c7f027e2003411f752003712107200341027420006a41046b210520032104027f03402007200441004c0d011a200441016b21042005280200200541046b2105450d000b200441016a0b2108200341027420016a41046b21052003210402400340200441004c0d01200441016b21042005280200200541046b2105450d000b200441016a21070b200341004c044041000f0b41012003410174220b200b41014c1b210e200141046b210f410021014101210c4100210603402009200120074e6a21090240200620062007486a2206200a200120084e6a220a4d0440420021110c010b2006200a6b210d200020094102746a2104200f20064102746a210542002111034020114280808080107c201120102010200535020020043502007e7c2210561b2111200441046a2104200541046b2105200d41016b220d0d000b0b0240024020012003480440200220014102746a20103e02000c010b20104200520d010b200141016a2201200b48210c201042208820118421102001200e470d010b0b200c0b5001017e02402003450d00200341c00071044020012003413f71ad862102420021010c010b20022003ad220486200141c00020036bad88842102200120048621010b20002002370308200020013703000b5001017e02402003450d00200341c00071044020022003413f71ad882101420021020c010b200241c00020036bad8620012003ad220488842101200220048821020b20002002370308200020013703000bb51102197e047f230041f0006b221d2400200041186a2903002106200041106a2903002108200041086a29030021072000290300210a027f02402001290300220f420156200141086a290300220c420052200c501b200141106a2903002210420052200141186a290300220b420052200b5022201b200b201084501b4504404101200fa741016b0d021a200242003703102002420037030820024200370300200241186a4200370300200320083703102003200a37030020032007370308200341186a20063703000c010b20082010852204200a200f85842006200b8522052007200c858484500440200242003703102002420037030820024200370300200241186a420037030020034200370310200341186a420037030020034201370300200342003703080c010b2008200a84200620078484504101200a200f5a2007200c5a2007200c511b200820105a2006200b5a2006200b511b2004200584501b1b04402002200a3703002002200737030820022008370310200241186a200637030020034200370310200341186a420037030020034200370300200342003703080c010b41c0012100027f02402006220450221f450d004180012100200822044200520d0041c0002100200722044200520d0041002200200a2204500d011a0b2000411f413f20044280808080105422001b220141106b20012004422086200420001b220442808080808080c0005422001b220141086b20012004421086200420001b2204428080808080808080015422001b220141046b20012004420886200420001b2204428080808080808080105422001b220141026b20012004420486200420001b2204428080808080808080c0005422001b6a2004420286200420001b423f87a7417f736a0b210041c0012101200b2104201d41306a200f200c4180012000027f02402020450d004180012101201022044200520d0041c0002101200c22044200520d0041002201200f2204500d011a0b2001411f413f20044280808080105422011b221e41106b201e2004422086200420011b220442808080808080c0005422011b221e41086b201e2004421086200420011b2204428080808080808080015422011b221e41046b201e2004420886200420011b2204428080808080808080105422011b221e41026b201e2004420486200420011b2204428080808080808080c0005422011b6a2004420286200420011b423f87a7417f736a0b6b22006b1009201d41e0006a2010200b20001008201d41406b200f200c20004180016b1008201d41d0006a200f200c20001008201d41e8006a290300201d41386a29030084201d41c8006a290300200041800149221e1b201d290360201d29033084201d290340201e1b2109201d41d8006a290300210d201d290350211141c001210120062104027f0240201f450d004180012101200822044200520d0041c0002101200722044200520d0041002201200a2204500d011a0b2001411f413f20044280808080105422011b221f41106b201f2004422086200420011b220442808080808080c0005422011b221f41086b201f2004421086200420011b2204428080808080808080015422011b221f41046b201f2004420886200420011b2204428080808080808080105422011b221f41026b201f2004420486200420011b2204428080808080808080c0005422011b6a2004420286200420011b423f87a7417f736a0b2101200b20001b21042009201020001b210e200d4200201e1b210d20114200201e1b211141c0012100200b2105201d41106a420142002001027f02402020450d004180012100201022054200520d0041c0002100200c22054200520d0041002200200f2205500d011a0b2000411f413f20054280808080105422001b221e41106b201e2005422086200520001b220542808080808080c0005422001b221e41086b201e2005421086200520001b2205428080808080808080015422001b221e41046b201e2005420886200520001b2205428080808080808080105422001b221e41026b201e2005420486200520001b2205428080808080808080c0005422001b6a2005420286200520001b423f87a7417f736a0b6b22004180016b1008201d4201420041800120006b1009201d41206a4201420020001008200e200a2011542007200d542007200d511b2008200e54200420065620042006511b2008200e85200420068584501b221ead2209882004420186201e413f73ad221286842105200d4201862012862011200988842111201d290300201d29031020004180014922011b420020001b2213200988201d41086a290300201d41186a29030020011b420020001b2214420186201286842117201d41286a290300420020011b2215420186201286201d290320420020011b200988842112200e420186201e417f73413f71ad221686200d20098884210e2013420186201686201520098884210d20042009882104201420098821094200211342002114420021154200211603404200200e200a2011542007200e542007200e511b2005200856200420065620042006511b2005200885200420068584501b22001b21184200201120001b211a4200200420001b211b20084200200520001b22195421014200200920001b20168421164200201720001b20158421154200200d20001b20148421144200201220001b2013842113200d423f862012420188842112200e423f8620114201888421112017423f86200d42018884210d2005423f86200e42018884210e2009423f8620174201888421172004423f8620054201888421052009420188210920044201882104200820197d2219200a201a542200200720185420072018511bad221c7d2108200a201a7d220a200f5a200720187d2000ad7d2207200c5a2007200c511b200820105a2006201b7d2001ad7d2019201c54ad7d2206200b5a2006200b511b20082010852006200b8584501b0d000b200320133703002003201437030820032015370310200341186a201637030020022008370310200241186a20063703002002200a370300200220073703080b41000b201d41f0006a24000b8f0402037e047f20002c001f2209410048044020004200200029030022057d370300200041086a220742002007290300220420054200522207ad7c7d370300200041106a22084200200829030022057d2206200720044200522004501bad22047d370300200041186a220742002004200656ad20072903002005420052ad7c7c7d3703000b20012c001f2208410048044020014200200129030022057d370300200141086a220742002007290300220420054200522207ad7c7d370300200141106a220a4200200a29030022057d2206200720044200522004501bad22047d370300200141186a220742002004200656ad20072903002005420052ad7c7c7d3703000b4101210702402000200120022003100a0d002008200973410048044020034200200329030022057d370300200341086a220042002000290300220420054200522200ad7c7d370300200341106a22014200200129030022057d2206200020044200522004501bad22047d370300200341186a220042002004200656ad20002903002005420052ad7c7c7d3703000b41002107200941004e0d0020024200200229030022057d370300200241086a220042002000290300220420054200522200ad7c7d370300200241106a22014200200129030022057d2206200020044200522004501bad22047d370300200241186a220042002004200656ad20002903002005420052ad7c7c7d3703000b20070bc20402057f067e230041e0016b22092400200941386a4200420020067d220e2004420052220c20054200522005501bad221054ad20072006420052ad7c7c7d20072007420053220a1b370300200941186a4200420020027d22112000420052220d20014200522001501bad220f54ad20032002420052ad7c7c7d20032003420053220b1b3703002009420020047d2004200a1b3703202009420020007d2000200b1b3703002009200e20107d2006200a1b370330200942002005200cad7c7d2005200a1b37032820092011200f7d2002200b1b370310200942002001200dad7c7d2001200b1b37030802402009200941206a200941406b410810074200200941d8006a290300220f200941d0006a2903002210420052ad7c420020107d221220092903402211420052220c200941c8006a290300220e420052200e501bad221354ad7c7d200f200a200b73220a1b220f200320078585423f88502000200284200120038484502004200684200520078484507272457245044020094198016a4200370300200941f8006a200f37030020094200370390012009420037038801200942808090bbbad6adf00d370380012009420020117d2011200a1b37036020094200200e200cad7c7d200e200a1b3703682009201220137d2010200a1b370370200941e0006a20094180016a200941a0016a200941c0016a100b450d01000b000b200820092903c001370300200841186a200941d8016a2903003703002008200941d0016a2903003703102008200941c8016a290300370308200941e0016a240041000ba10302037f037e230041e0016b22052400200541386a4200420020027d22082000420052220720014200522001501bad220954ad20032002420052ad7c7c7d2003200342005322061b220a370300200541186a200a3703002005420020007d200020061b220a3703202005200a3703002005200820097d200220061b22083703302005420020012007ad7c7d200120061b2209370328200520083703102005200937030802402005200541206a200541406b41081007200541d8006a2903002208423f8850200020028420012003848450724572450440200541d0006a2903002100200541c8006a29030021012005290340210220054198016a4200370300200541f8006a200837030020054200370390012005420037038801200542808090bbbad6adf00d37038001200520023703602005200137036820052000370370200541e0006a20054180016a200541a0016a200541c0016a100b450d01000b000b200420052903c001370300200441186a200541d8016a2903003703002004200541d0016a2903003703102004200541c8016a290300370308200541e0016a240041000bc31702047f0e7e230041b0086b22052400024002400240024002400240024002400240200020028420012003848450450440200541206b220622082400027e2002200384500440200021092002210a2003210e20010c010b428001210b2002210920030b210c027e200c200e84200a84500440200b210d200e0c010b200b42407d220d200b5422072007ad2212420054200b200d581bad2213420054ad2110200c2109200a210c200e210a42000b21110240200c42208620094220888422142011422086200a42208884220b84200a422086200c42208884220f2011422088220e848450044020092114200c210f200a210b2011210e200d210920122115201321160c010b20102013200d42207c2209200d54220720122007ad7c22152012542009200d5a1bad7c2216201354ad7c21100b0240200f4230862014421088842212200e423086200b42108884220c84200b423086200f42108884220a200e4210882211848450044020142112200f210a200b210c200e21112009210d20152113201621150c010b20102016200942107c220d200954220720152007ad7c22132015542009200d581bad7c2215201654ad7c21100b0240200a42388620124208888422142011423886200c42088884220b84200c423886200a42088884220f2011420888220e848450044020122114200a210f200c210b2011210e200d2109201321162015210d0c010b20102015200d42087c2209200d54220720132007ad7c22162013542009200d5a1bad7c220d201554ad7c21100b0240200f423c862014420488842212200e423c86200b42048884220c84200b423c86200f42048884220a200e4204882211848450044020142112200f210a200b210c200e21112009210b20162114200d21090c010b2010200d200942047c220b200954220720162007ad7c22142016542009200b581bad7c2209200d54ad7c21100b0240200a423e8620124202888422132011423e86200c42028884220f84200c423e86200a42028884220e2011420288220d848450044020122113200a210e200c210f2011210d200b210c2014210a2009210b0c010b20102009200b42027c220c200b54220720142007ad7c220a201454200b200c581bad7c220b200954ad7c21100b0240200e423f86201342018884200d423f86200f4201888484200f423f86200d200e844201888484500440200c210f200a210e200b210c0c010b2010200b200c42017c220f200c542207200a2007ad7c220e200a54200c200f581bad7c220c200b54ad7c21100b2006200f3703002006200e3703082006200c370310200641186a2010370300200541106a420142002006290300420188a722064180016b100820054201420041800120066b1009200541206a4201420020061008200541c8006a2003370300200541e8006a200541086a290300200541186a29030020064180014922071b420020061b220b3703002005200037033020052001370338200520023703402005200541286a290300420020071b220c37035820052005290320420020071b220937035020052005290300200529031020071b420020061b220a370360200541306a200541d0006a200541f0006a20054190016a100a0d01200541c8016a2003370300200541e8016a200a200a200541a0016a2903007c220a56ad200b200541a8016a2903007c7c200a200a20092005290390017c220b20095422062006ad200c20054198016a2903007c7c2209200c542009200c511bad7c220a56ad7c220e420188220d370300200520003703b001200520013703b801200520023703c00120052009423f86200b42018884220b3703d0012005200a423f86200942018884220c3703d8012005200e423f86200a4201888422093703e001200541b0016a200541d0016a200541f0016a20054190026a100a0d02200541c8026a2003370300200541e8026a2009200541a0026a2903007c220a200954ad200d200541a8026a2903007c7c200a200a200b200b2005290390027c220b5622062006ad200c20054198026a2903007c7c2209200c542009200c511bad7c220a56ad7c220e420188220d370300200520003703b002200520013703b802200520023703c00220052009423f86200b42018884220b3703d0022005200a423f86200942018884220c3703d8022005200e423f86200a4201888422093703e002200541b0026a200541d0026a200541f0026a20054190036a100a0d03200541c8036a2003370300200541e8036a2009200541a0036a2903007c220a200954ad200d200541a8036a2903007c7c200a200a200b200b2005290390037c220b5622062006ad200c20054198036a2903007c7c2209200c542009200c511bad7c220a56ad7c220e420188220d370300200520003703b003200520013703b803200520023703c00320052009423f86200b42018884220b3703d0032005200a423f86200942018884220c3703d8032005200e423f86200a4201888422093703e003200541b0036a200541d0036a200541f0036a20054190046a100a0d04200541c8046a2003370300200541e8046a2009200541a0046a2903007c220a200954ad200d200541a8046a2903007c7c200a200a200b200b2005290390047c220b5622062006ad200c20054198046a2903007c7c2209200c542009200c511bad7c220a56ad7c220e420188220d370300200520003703b004200520013703b804200520023703c00420052009423f86200b42018884220b3703d0042005200a423f86200942018884220c3703d8042005200e423f86200a4201888422093703e004200541b0046a200541d0046a200541f0046a20054190056a100a0d05200541c8056a2003370300200541e8056a2009200541a0056a2903007c220a200954ad200d200541a8056a2903007c7c200a200a200b200b2005290390057c220b5622062006ad200c20054198056a2903007c7c2209200c542009200c511bad7c220a56ad7c220e420188220d370300200520003703b005200520013703b805200520023703c00520052009423f86200b42018884220b3703d0052005200a423f86200942018884220c3703d8052005200e423f86200a4201888422093703e005200541b0056a200541d0056a200541f0056a20054190066a100a0d06200541c8066a2003370300200541e8066a2009200541a0066a2903007c220a200954ad200d200541a8066a2903007c7c200a200a200b200b2005290390067c220b5622062006ad200c20054198066a2903007c7c2209200c542009200c511bad7c220a56ad7c220e420188220d370300200520003703b006200520013703b806200520023703c00620052009423f86200b42018884220b3703d0062005200a423f86200942018884220c3703d8062005200e423f86200a4201888422093703e006200541b0066a200541d0066a200541f0066a20054190076a100a0d07200541c8076a2003370300200541e8076a2009200541a0076a2903007c2203200954ad200d200541a8076a2903007c7c2003200b2005290390077c220a200b5422062006ad200c20054198076a2903007c7c2209200c542009200c511bad7c220c200354ad7c220b4201882203370300200520003703b007200520013703b807200520023703c00720052009423f86200a42018884220a3703d0072005200c423f8620094201888422013703d8072005200b423f86200c4201888422023703e007200541b0076a200541d0076a200541f0076a20054190086a100a0d08200529039008210b20054198086a290300210c200541a0086a2903002109200541a8086a2903002100200841206b220624000240200a200b5a2001200c5a2001200c511b200220095a200020035820002003511b2002200985200020038584501b4504402006200a3703002006200137030820062002370310200641186a20033703000c010b2006200b3703002006200c37030820062009370310200641186a20003703000b0c090b200442003703102004420037030820044200370300200441186a4200370300200541b0086a240041000f0b000b000b000b000b000b000b000b000b20042006290300370300200441186a200641186a2903003703002004200641106a2903003703102004200641086a290300370308200541b0086a240041000b9c0f02047f067e230041e0016b2209240002400240024002400240024002400240024002400240027e0240027e02402000200284200120038484500440200941206b220a2400200a41186a4200370300200a4200370310200a4200370308200a420137030041084120360200200a4120411041081001450d01420021074200210642000c020b200941206b220a2400200941386a4200370300200941186a20033703002009420037033020094200370328200942808090bbbad6adf00d3703202009200237031020092001370308200920003703002009200941206a200941406b410810070d04200941d8006a2903002100200941d0006a2903002101200941c8006a29030021022009290340210320094198016a2007370300200941f8006a2000370300200920043703800120092003370360200920053703880120092002370368200920063703900120092001370370200941e0006a20094180016a200941a0016a200941c0016a100a0d05200a20092903c001370300200a41186a220b200941d8016a290300370300200a200941d0016a290300370310200a200941c8016a290300370308200b2903002101200a41106a2903002110200a41086a2903002102200a290300210f200a41206b220a240042002103200a41186a4200370300200a4200370310200a4200370308200a420137030041084120360200200a4120411041081001450d0242000c030b41202903002106411829030021074110290300210d41282903000b2105200a41206b220a2400200941b8016a200337030020094198016a2005370300200920023703b001200920013703a801200920003703a001200920063703900120092007370388012009200d3703800120094180016a200941a0016a200941c0016a410810070d0420092903c0012100200a4200370310200a4200370308200a41186a220b4200370300200a200042808090bbbad6adf00d803703000c050b4128290300210e4120290300210d4110290300210341182903000b2100200a41206b220a2400200941b8016a200737030020094198016a200e370300200920063703b001200920053703a801200920043703a0012009200d370390012009200037038801200920033703800120094180016a200941a0016a200941c0016a410810070d0420092903c0012100200a4200370310200a4200370308200a41186a4200370300200a200042808090bbbad6adf00d80370300200120012001201042017d2200201054ad7c20002000200f42808090bbbad6adf00d7d2204200f54220b2002200bad7c42017d220320025420022003511bad7c220056ad7c42017d220585834200530d05200a41186a2903002106200a41106a2903002107200a41086a290300210d200a290300210e200a41206b220a24002004200320002005200a100d220b0d0a200a41186a2903002100200a41106a2903002103200a41086a2903002104200a2903002105200a41206b220a2400027e0240200e200d200720062005200420032000200a100c220b450440200a41186a2903002100200a41106a2903002106200a41086a2903002103200a2903002107200a41206b220a2400200a41186a4200370300200a4200370310200a4200370308200a420237030041084120360200200a4120411041081001450d014200210d4200210e4200210542000c020b0c0c0b412829030021054120290300210e4118290300210d41102903000b21042001200585427f852001200e20107c220e201054ad200120057c7c200e2004200f7c2210200f54220b200bad2002200d7c7c220420025420022004511bad7c220d200e54ad7c220e85834200530d08200a41206b220a2400200941386a4200370300200941186a4200420020067d22012007420052220c20034200522003501bad220254ad20002006420052ad7c7c7d20002000420053220b1b3703002009420037033020094200370328200942808090bbbad6adf00d3703202009200120027d2006200b1b370310200942002003200cad7c7d2003200b1b3703082009420020077d2007200b1b3703002009200941206a200941406b4108100720004200200941d8006a290300220f200941d0006a2903002202420052ad7c420020027d221120092903402205420052220c200941c8006a29030022014200522001501bad221254ad7c7d200f200b1b220f85423f88a7200620078420002003848442005271720d0620094198016a200e370300200941f8006a200f37030020092010370380012009420020057d2005200b1b3703602009200437038801200942002001200cad7c7d2001200b1b3703682009200d370390012009201120127d2002200b1b370370200941e0006a20094180016a200941a0016a200941c0016a100b0d07200a20092903c001370300200a41186a200941d8016a290300370300200a200941d0016a290300370310200a200941c8016a2903003703080c090b000b000b000b2008200a290300370300200841186a200b2903003703002008200a41106a2903003703102008200a41086a290300370308200941e0016a240041000f0b000b000b000b000b000b2008200a290300370300200841186a200a41186a2903003703002008200a41106a2903003703102008200a41086a290300370308200941e0016a240041000f0b200941e0016a2400200b0b94890102097f317e230041206b22032400418080044100360200418480044100360200418c80044100360200418880043f00411074419080046b3602004108418080023602004110410810034104410828020022003602002003411036020c200341106a2003410c6a10042003290310210b200341186a2903002112230041206b220624000240024002400240024002400240024002400240024002400240200041034d0d004100411028020022033602000240024002400240024002400240024002400240024002400240024002400240024020034197d98daa7e4c0440200341cfe1afb579460d01200341c7a3bfb67a460d04200341e2f8f0c57b470d12200b201284500d06000b20034198eaea98054c044020034198d98daa7e460d0320034184d58bfc00470d12200b201284500d07000b20034199eaea9805460d01200341fa88cad806470d11200b201284500d04000b200b2012844200520d18200641106b2203240041e00010062100200641186a2202420037030041084120360200200642003703102006420037030820064200370300027e2006412041104108100104404200210b42000c010b412829030021114118290300210b4110290300210e41202903000b21122000200e3703002000200b37030820002012370310200041186a2011370300410841203602004200210b20024200370300200642003703102006420137030020064200370308027e2006412041104108100104404200210e4200211142000c010b4128290300210a412029030021114118290300210e41102903000b2112200041286a200e370300200041206a2012370300200041306a2011370300200041386a200a37030041084120360200200641186a4200370300200642003703102006420237030020064200370308027e2006412041104108100104404200210e4200211142000c010b412829030021114120290300210e4110290300210b41182903000b211220032000360200200041c8006a2012370300200041406b200b370300200041d0006a200e370300200041d8006a20113703002003280200210341e000100541086a2201210241e00021000340200220032d00003a0000200220032d00013a0001200220032d00023a0002200220032d00033a0003200220032d00043a0004200220032d00053a0005200220032d00063a0006200220032d00073a0007200241086a2102200341086a2103200041086b22000d000b4100200141e00010020c1a0b2000200041046b2203490d10200341c0004f0440200341c0004d0d0a000b000b200b2012844200520d152000200041046b2203490d042003418001490d0520034180014d0d0c000b200b2012844200520d132000200041046b2203490d05200341c000490d06200341c0004d0d0c000b2000200041046b2203490d0e20034180014f044020034180014d0d08000b000b2000200041046b2203490d0e20034180014f044020034180014d0d08000b000b2000200041046b2203490d0e20034180014f044020034180014d0d08000b000b000b000b000b000b027f41142903002112411c290300210b4124290300210e412c29030021114134290300210a413c290300210941c400290300211041cc00290300211423004180026b22002400200041d8006a4200370300200041386a42003703002000420037035020004200370348200042808090bbbad6adf00d3703402000420037033020004200370328200042808090bbbad6adf00d3703200240024002400240200041206a200041406b200041e0006a41081007200041f8006a290300220f423f88a772450440200041f0006a290300210d200041e8006a290300211a2000290360211d200041b8016a201437030020004198016a200f3703002000200a3703a0012000201d37038001200020093703a8012000201a37038801200020103703b0012000200d3703900120004180016a200041a0016a200041c0016a200041e0016a100b0d01200041186a2202200041f8016a290300370300200020002903e0013703002000200041f0016a2903003703102000200041e8016a290300370308200041106a290300220f2000290300220d42808090bbbad6adf00d7c221a200d542203200041086a290300221d2003ad7c2222201d54200d201a581b2203ad7c220d200f5422012002290300221d2001ad7c2217201d54200d200f5a1b200320031b0d03200041206b22032400201a2022200d201720004180016a100e2202450440200041d8016a4200370300200041b8016a20004198016a29030037030020002000290380013703a001200042003703d001200042003703c8012000428094ebdc033703c001200020004190016a2903003703b001200020004188016a2903003703a801200041a0016a200041c0016a200041e0016a410810070d03200041f8016a290300210f200041f0016a290300210d200041e8016a290300211a200320002903e0013703002003201a3703082003200d370310200341186a200f3703000c050b2002450d0420004180026a240020020c050b000b000b000b000b200341106a290300220f2003290300220d42808090bbbad6adf00d7c221a200d542202200341086a290300221d2002ad7c2222201d54200d201a581b2202ad7c220d200f542201200341186a290300221d2001ad7c2217201d54200d200f5a1b200220021b0440000b200341206b22032400200041d8016a2017370300200041b8016a20143703002000200d3703d001200020223703c8012000201a3703c001200020103703b001200020093703a8012000200a3703a0010240200041a0016a200041c0016a200041e0016a4108100745044020002903e001210f2003420037031020034200370308200341186a220242003703002003200f42808090bbbad6adf00d80370300201220032903007c221d20125422012001ad200b200341086a2903007c7c221a200b54200b201a511b2201200e200341106a2903007c220d2001ad7c220f200e54200d200f56ad200d200e54ad201120022903007c7c7c220d201154200d2011511b200e200f85200d20118584501b450d01000b000b41e00010062202200b37030820022012370300200241d0006a200f370300200241c8006a201a370300200241406b2204201d370300200241306a2010370300200241286a2009370300200241206a2205200a3703002002200e370310200241d8006a200d370300200241386a2014370300200241186a2011370300200341206b22032400200341186a22014200370300200342003703102003420037030820034200370300200341202002412010001a20014200370300200342003703102003420037030820034201370300200341202005412010001a20014200370300200342003703102003420037030820034202370300200341202004412010001a20004180026a240041000b450d0a200641206a24000c110b412c290300212241242903002124411c2903002114411429030021234134290300210e41cc00290300211a41c400290300211d413c290300211141d400290300212c41ec00290300211241e400290300211b41dc00290300212541f400290300210c418c012903002126418401290300211f41fc00290300210b200641206b22032400027f230041c0086b22002400027e02402023202c7d221c202356201420257d2023202c542202ad7d222320145620142023511b2024201b7d22162002201420255420142025511bad22147d2229202456202220127d201b202456ad7d2014201656ad7d221620225620162022511b2024202985201620228584501b450440200041206b22022400200241186a42003703002002420037031020024200370308200242023703004108412036020020024120411041081001450d0142000c020b000b4128290300210a411829030021104110290300210941202903000b2114027e0240200c202c7c222c200c5422012001ad200b20257c7c2224200b54200b2024511b2201201b201f7c220b2001ad7c2222201f54200b202256ad200b201f54ad201220267c7c7c220b202654200b2026511b201f202285200b20268584501b450440200241206b22022400200241186a42003703002002420037031020024200370308200242013703004108412036020020024120411041081001450d0142000c020b000b4128290300210f412029030021174118290300210d41102903000b211f02400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200a427f85200a200a2014200942808090bbbad6adf00d7c2212200954220120102001ad7c222520105420092012581bad7c221b201454ad7c222685834200590440200241206b22012400201f200d2017200f200920102014200a2001100c22020d1a200141186a290300210c200141106a2903002120200141086a290300211320012903002115200141206b220122042400201c2023202920162001100d22020d1b200041186a4200370300200041386a4200420020207d22182015420052220520134200522013501bad221954ad200c2020420052ad7c7c7d200c200c42005322021b3703002000420037031020004200370308200042043703002000420020132005ad7c7d201320021b3703282000420020157d201520021b3703202000201820197d202020021b370330200141186a2903002128200141106a2903002127200141086a290300212b2001290300212a2000200041206a200041406b41081007200c4200200041d8006a2903002219200041d0006a290300221e420052ad7c4200201e7d222d200029034022214200522205200041c8006a29030022184200522018501bad222e54ad7c7d201920021b221985423f88a72015202084200c2013848442005271720d01200041f8006a420037030020004198016a4200420020177d220c201f4200522207200d420052200d501bad221354ad200f2017420052ad7c7c7d200f200f42005322011b37030020004200370370200042003703682000420437036020004200200d2007ad7c7d200d20011b3703880120004200201f7d201f20011b370380012000200c20137d201720011b37039001200041e0006a20004180016a200041a0016a41081007200f4200200041b8016a2903002215200041b0016a2903002213420052ad7c420020137d222f20002903a00122204200522207200041a8016a290300220c420052200c501bad223054ad7c7d201520011b221585423f88a72017201f84200d200f848442005271720d022015201985427f852019202d202e7d201e20021b221e202f20307d201320011b7c2213201e54ad201520197c7c20132013420020217d202120021b2215420020207d202020011b7c222020155422082008ad420020182005ad7c7d201820021b22154200200c2007ad7c7d200c20011b7c7c220c201554200c2015511bad7c221556ad7c221385834200530d032013201320132015201542017d221856ad7c20182020202042808090bbbad6adf00d7d2215562202200c2002ad7c42017d2220200c54200c2020511bad7c220c201854ad7c42017d221885834200530d04200441206b2201240020152020200c2018202a202b202720282001100c22020d1a200141186a290300220c4200200c200141106a2903002213420052ad7c420020137d222f200129030022304200522204200141086a29030022284200522028501bad223154ad7c7d2220834200530d05200141206b22012400201c202320292016201f200d2017200f2001100c22020d1a200141186a290300210c200141106a2903002113200141086a29030021152001290300200141206b2201240020152013200c200e2011201d201a2001100c22020d1c200041d8016a4200370300200041f8016a4200200141186a290300220c200141106a2903002215420052ad7c420020157d2219200129030022184200522205200141086a29030022134200522013501bad221e54ad7c7d200c200c42005322021b370300200042003703d001200042003703c801200042083703c0012000420020187d201820021b3703e0012000420020132005ad7c7d201320021b3703e80120002019201e7d201520021b3703f001200041c0016a200041e0016a20004180026a41081007200c420020004198026a290300222720004190026a290300221e420052ad7c4200201e7d222b2000290380022221420052220520004188026a29030022194200522019501bad222a54ad7c7d202720021b222785423f88a72015201884200c2013848442005271720d06200141206b22012400420020217d202120021b420020192005ad7c7d201920021b202b202a7d201e20021b202720122025201b20262001100c22020d1b200141186a2903002115200141106a2903002127200141086a29030021182001290300212b200141206b22012400201c202320292016200920102014200a2001100c22020d1a200141186a290300210c200141106a2903002113200141086a29030021192001290300200141206b2201240020192013200c200e2011201d201a2001100c22020d1c200041b8026a4200370300200041d8026a4200200141186a290300220c200141106a2903002219420052ad7c420020197d22212001290300221e4200522205200141086a29030022134200522013501bad222a54ad7c7d200c200c42005322021b370300200042003703b002200042003703a802200042023703a00220004200201e7d201e20021b3703c0022000420020132005ad7c7d201320021b3703c80220002021202a7d201920021b3703d002200041a0026a200041c0026a200041e0026a41081007200c4200200041f8026a290300222e200041f0026a290300222a420052ad7c4200202a7d223220002903e002222d4200522205200041e8026a29030022214200522021501bad223354ad7c7d202e20021b222e85423f88a72019201e84200c2013848442005271720d072015202e85427f8520152027203220337d202a20021b7c220c202754ad2015202e7c7c200c202b4200202d7d202d20021b7c2219202b5422072007ad2018420020212005ad7c7d202120021b7c7c221320185420132018511bad7c2218200c54ad7c220c85834200530d08200c202085427f8520202018202f20317d221e7c2215201e54ad200c20207c7c2015420020307d220c20197c2221200c5422022002ad2013420020282004ad7c7d22187c7c220c201854200c2018511bad7c2228201554ad7c221585834200530d09200141206b22012400201c202320292016202c20242022200b2001100c22020d1d20004198036a4200370300200041b8036a4200200141186a2903002213200141106a2903002218420052ad7c420020187d221e200129030022194200522204200141086a29030022204200522020501bad222754ad7c7d2013201342005322021b3703002000420037039003200042003703880320004202370380032000420020197d201920021b3703a0032000420020202004ad7c7d202020021b3703a8032000201e20277d201820021b3703b00320004180036a200041a0036a200041c0036a4108100720134200200041d8036a290300222a200041d0036a2903002227420052ad7c420020277d222d20002903c003222b4200522204200041c8036a290300221e420052201e501bad222e54ad7c7d202a20021b222a85423f88a7201820198420132020848442005271720d0a200141206b220124004200202b7d202b20021b4200201e2004ad7c7d201e20021b202d202e7d202720021b202a20122025201b20262001100c22020d1b2015200141186a290300221385427f8520152028200141106a2903007c2220202854ad201320157c7c2020202120012903007c221920215422022002ad200c200141086a2903007c7c2213200c54200c2013511bad7c2218202054ad7c220c85834200530d0c200141206b2202240020004198086a201a370300200041f8076a201a3703002000201d3703900820002011370388082000200e370380082000201d3703f007200020113703e8072000200e3703e007200041e0076a20004180086a200041a0086a410810070d0b20002903a00821202002420037031020024200370308200241186a220142003703002002202042808090bbbad6adf00d8037030020012903002120200241106a2903002115200241086a290300211e20022903002121200241206b22012400201f200d2017200f2021201e201520202001100c22020d1a200141186a290300210f200141106a290300210d200141086a29030021172001290300200141206b220124002017200d200f20122025201b20262001100c22020d1d200041f8036a420037030020004198046a4200200141186a290300220f200141106a2903002217420052ad7c420020177d22202001290300221f4200522204200141086a290300220d420052200d501bad221554ad7c7d200f200f42005322021b370300200042003703f003200042003703e803200042043703e00320004200201f7d201f20021b3703800420004200200d2004ad7c7d200d20021b370388042000202020157d201720021b37039004200041e0036a20004180046a200041a0046a41081007200f4200200041b8046a2903002221200041b0046a2903002215420052ad7c420020157d222820002903a004221e4200522204200041a8046a29030022204200522020501bad222754ad7c7d202120021b222185423f88a72017201f84200d200f848442005271720d0d200c202185200c200c20217d2018202820277d201520021b220f54ad7d2018200f7d222e20194200201e7d201e20021b222f5422052013420020202004ad7c7d202020021b221e542013201e511bad223054ad7d222085834200530d0e200141206b22012400200920102014200a2001100d22020d1a200141186a2903002131200141106a2903002132200141086a29030021332001290300200141206b2202240020004198086a201a370300200041f8076a201a3703002000201d3703900820002011370388082000200e370380082000201d3703f007200020113703e8072000200e3703e007200041e0076a20004180086a200041a0086a410810070d0f20002903a008210f2002420037031020024200370308200241186a220142003703002002200f42808090bbbad6adf00d803703002001290300210c200241106a2903002121200241086a290300211520022903002128200241206b22012400200e2011201d201a202c20242022200b2001100c22020d1a200141186a290300210f200141106a2903002117200141086a290300210d2001290300211f200141206b22012400202c20242022200b2001100d22020d1b200041d8046a4200370300200041f8046a4200420020177d2218201f4200522204200d420052200d501bad222754ad200f2017420052ad7c7c7d200f200f42005322021b370300200042003703d004200042003703c804200042023703c00420004200200d2004ad7c7d200d20021b3703e80420004200201f7d201f20021b3703e0042000201820277d201720021b3703f004200141186a2903002127200141106a2903002135200141086a290300213620012903002137200041c0046a200041e0046a20004180056a41081007200f420020004198056a290300222d20004190056a290300222b420052ad7c4200202b7d2238200029038005222a420052220420004188056a29030022184200522018501bad223954ad7c7d202d20021b222d85423f88a72017201f84200d200f848442005271720d10200c202d85427f85200c2021203820397d202b20021b7c220d202154ad200c202d7c7c200d20284200202a7d202a20021b7c221720285422072007ad2015420020182004ad7c7d201820021b7c7c220f201554200f2015511bad7c221f200d54ad7c220d85834200530d11200d202785427f85200d201f201f20357c220c56ad200d20277c7c200c2017201720377c221f5622022002ad200f20367c7c2217200f54200f2017511bad7c220f200c54ad7c220c85834200530d12200141206b22012400203320322031201f2017200f200c2001100c22020d1d2020200141186a290300220f85427f852020202e20307d2217200141106a2903007c220d201754ad200f20207c7c200d2019202f7d220f20012903007c2215200f5422022002ad2013201e7d2005ad7d2217200141086a2903007c7c220f201754200f2017511bad7c2218200d54ad7c221785834200530d13200041b8056a4200370300200041d8056a4200420020147d220d2009420052220420104200522010501bad221f54ad200a2014420052ad7c7c7d200a200a42005322021b370300200042003703b005200042003703a805200042023703a0052000420020102004ad7c7d201020021b3703c8052000420020097d200920021b3703c0052000200d201f7d201420021b3703d005200041a0056a200041c0056a200041e0056a41081007200a4200200041f8056a290300220d200041f0056a2903002213420052ad7c420020137d221920002903e005220c4200522204200041e8056a290300221f420052201f501bad221e54ad7c7d200d20021b220d85423f88a72009201484200a2010848442005271720d14200141206b220124004200200c7d200c20021b220c4200201f2004ad7c7d201f20021b22202019201e7d201320021b2219200d200e2011201d201a2001100c22020d1b200141186a290300211f200141106a2903002113200141086a290300211e2001290300200141206b22012400201e2013201f202c20242022200b2001100c22020d1a200141186a290300211f200141106a290300211e200141086a290300211320012903002121200141206b22012400202c20242022200b2001100d22020d1a200d427f85200d200d2019200c42808090bbbad6adf00d7c2228200c542202202020202002ad7c222756200c2028581bad7c220c201954ad7c222085834200530d15200141186a290300210d200141106a2903002119200141086a290300212b2001290300200141206b22012400202b2019200d20282027200c20202001100c22020d1a201f200141186a290300220c85427f85201f201e200141106a2903007c220d201e54ad200c201f7c7c200d202120012903007c222020215422022002ad2013200141086a2903007c7c220c201354200c2013511bad7c2213200d54ad7c220d85834200530d16200d201785427f852017201320187c221f201854ad200d20177c7c201f201f201520207c221320155422022002ad200c200f7c7c220d200f54200d200f511bad7c221f56ad7c220c85834200530d17200141206b22012400200920102014200a200e2011201d201a2001100c22020d1a200141186a2903002111200141106a290300210f200141086a290300210e2001290300211a200141206b22012400200920102014200a202c20242022200b2001100c22020d1a200141186a290300210a200141106a2903002114200141086a290300211d20012903002117200141206b220124002013200d201f200c200041c0076a100e220245044020004198086a4200370300200041f8076a200041d8076a290300370300200020002903c0073703e007200042003703900820004200370388082000428094ebdc03370380082000200041d0076a2903003703f0072000200041c8076a2903003703e807200041e0076a20004180086a200041a0086a410810070d19200041b8086a2903002109200041b0086a2903002110200041a8086a290300210d200120002903a0083703002001200d37030820012010370310200141186a20093703000c1a0b2002450d190c1a0b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b02400240024002404200420020297d2210201c420052220220234200522023501bad220d54ad20162029420052ad7c7c7d22092011852009200920117d2010200d7d2211200f54ad7d2011200f7d220f4200201c7d220d201a542204420020232002ad7c7d2210200e54200e2010511bad222354ad7d221185834200590440200a201185427f8520112014200f20237d22147c2209201454ad200a20117c7c20092009200d201a7d220a20177c2214200a5422022002ad2010200e7d2004ad7d220a201d7c7c220e200a54200a200e511bad7c220956ad7c220a85834200530d01200a200b85427f85200a2009200920227c221056ad200a200b7c7c201020142014202c7c220b5622022002ad200e20247c7c2211200e54200e2011511bad7c220e201054ad7c220985834200530d022009200141186a290300220a85427f852009200e200e200141106a2903007c221056ad2009200a7c7c20102010200b200b20012903007c220b5622022002ad2011200141086a2903007c7c220e201154200e2011511bad7c220a56ad7c221185834200530d0320004198066a4200370300200041b8066a42004200201b7d22092012420052220220254200522025501bad221054ad2026201b420052ad7c7c7d2026202642005322041b3703002000420037039006200042003703880620004202370380062000420020252002ad7c7d202520041b3703a8062000420020127d201220041b3703a0062000200920107d201b20041b3703b00620004180066a200041a0066a200041c0066a4108100720264200200041d8066a290300220f200041d0066a2903002210420052ad7c420020107d221a20002903c00622144200522205200041c8066a29030022094200522009501bad221d54ad7c7d200f20041b222285423f88a72012201b842025202684844200527172450d04000b000b000b000b000b200141206b2202240020004198076a4200370300200041f8066a42004200200a7d2212200b4200522207200e420052200e501bad220f54ad2011200a420052ad7c7c7d2011201142005322011b37030020004200370390072000420037038807200042808090bbbad6adf00d3703800720002012200f7d200a20011b3703f00620004200200e2007ad7c7d200e20011b3703e80620004200200b7d200b20011b3703e00602400240200041e0066a20004180076a200041a0076a4108100720114200200041b8076a2903002217200041b0076a290300220f420052ad7c4200200f7d222320002903a007220d4200522207200041a8076a29030022124200522012501bad222454ad7c7d201720011b221785423f88a7200a200b84200e201184844200527172450440200041f8076a2022370300200041d8076a20173703002000420020147d201420041b3703e00720004200200d7d200d20011b3703c0072000420020092005ad7c7d200920041b3703e8072000420020122007ad7c7d201220011b3703c8072000201a201d7d201020041b3703f0072000202320247d200f20011b3703d007200041c0076a200041e0076a20004180086a200041a0086a100b0d01200220002903a008370300200241186a200041b8086a2903003703002002200041b0086a2903003703102002200041a8086a2903003703080c020b000b000b20032002290300370300200341186a200241186a2903003703002003200241106a2903003703102003200241086a290300370308200041c0086a240041000c040b200041c0086a240020020c030b200041c0086a240020020c020b200041c0086a240020020c010b200041c0086a240020020b450d0d0c0f0b412c290300210a41242903002109411c2903002110411429030021144134290300210e41cc00290300211141c400290300210b413c290300211241d400290300212441ec00290300212641e400290300212541dc00290300212341f4002903002116418c01290300211b418401290300211c41fc00290300210c200641206b22032400027f230041c0066b22002400027e0240201420247d2220201456201020237d20142024542202ad7d222920105620102029511b200920257d22242002201020235420102023511bad22237d222c200956200a20267d2009202554ad7d2023202456ad7d221f200a56200a201f511b2009202c85200a201f8584501b450440200041206b22022400200241186a42003703002002420037031020024200370308200242013703004108412036020020024120411041081001450d0142000c020b000b4128290300210f411829030021174110290300212241202903000b2124200241206b22022400200241186a42003703002002420037031020024200370308200242023703004108412036020020024120411041081001047e4200054128290300211a4120290300210d4110290300211d41182903000b21250240024002400240024002400240024002400240024002400240024002400240024002400240201420167c222620145422012001ad200c20107c7c222320105420102023511b22012009201c7c22102001ad7c22142009542010201456ad2009201056ad200a201b7c7c7c2210200a54200a2010511b2009201485200a20108584501b450440200241206b22012400202220172024200f201d2025200d201a2001100c22020d12200141186a290300210a200141106a2903002109200141086a29030021162001290300200141206b2202240020004198066a2011370300200041f8056a20113703002000200b3703900620002012370388062000200e370380062000200b3703f005200020123703e8052000200e3703e005200041e0056a20004180066a200041a0066a410810070d0120002903a006211c2002420037031020024200370308200241186a220142003703002002201c42808090bbbad6adf00d803703002001290300211c200241106a290300210c200241086a290300211320022903002115200241206b2201240020162009200a20152013200c201c2001100c22020d13200041206a4200370300200041406b4200200141186a290300220a200141106a2903002216420052ad7c420020167d221c2001290300221b4200522204200141086a29030022094200522009501bad220c54ad7c7d200a200a42005322021b37030020004200370318200042003703102000420437030820004200201b7d201b20021b3703282000420020092004ad7c7d200920021b3703302000201c200c7d201620021b370338200041086a200041286a200041c8006a41081007200a4200200041e0006a2903002215200041d8006a290300220c420052ad7c4200200c7d2218200029034822134200522204200041d0006a290300221c420052201c501bad221954ad7c7d201520021b221585423f88a72016201b842009200a848442005271720d02201542002015201820197d200c20021b220a420052ad7c4200200a7d221e420020137d201320021b222142005222054200201c2004ad7c7d201c20021b22134200522013501bad222854ad7c7d2216834200530d03200141206b22012400202220172024200f201d2025200d201a2001100c22020d12200141186a290300210a200141106a2903002109200141086a290300211b2001290300200141206b22012400201b2009200a200e2012200b20112001100c22020d12200141186a290300210a200141106a2903002109200141086a290300211b2001290300200141206b22012400201b2009200a20262023201420102001100c22020d1320004180016a4200370300200041a0016a4200200141186a290300220a200141106a290300221b420052ad7c4200201b7d220c2001290300221c4200522204200141086a29030022094200522009501bad221554ad7c7d200a200a42005322021b37030020004200370378200042003703702000420437036820004200201c7d201c20021b370388012000420020092004ad7c7d200920021b370390012000200c20157d201b20021b37039801200041e8006a20004188016a200041a8016a41081007200a4200200041c0016a2903002219200041b8016a2903002215420052ad7c420020157d222720002903a80122184200522204200041b0016a290300220c420052200c501bad222b54ad7c7d201920021b221985423f88a7201b201c842009200a848442005271720d042016201985427f852016201e20287d220a2027202b7d201520021b7c2209200a54ad201620197c7c2009420020217d220a420020187d201820021b7c2215200a5422072007ad420020132005ad7c7d221b4200200c2004ad7c7d200c20021b7c7c220a201b54200a201b511bad7c2218200954ad7c221b85834200530d06200141206b2202240020004198066a2011370300200041f8056a20113703002000200b3703900620002012370388062000200e370380062000200b3703f005200020123703e8052000200e3703e005200041e0056a20004180066a200041a0066a410810070d0520002903a00621092002420037031020024200370308200241186a220142003703002002200942808090bbbad6adf00d8037030020012903002109200241106a2903002116200241086a290300211c2002290300210c200241206b22012400202220172024200f200c201c201620092001100c22020d13200041e0016a420037030020004180026a4200200141186a2903002209200141106a290300221c420052ad7c4200201c7d22132001290300220c4200522204200141086a29030022164200522016501bad221954ad7c7d2009200942005322021b370300200042003703d801200042003703d001200042043703c80120004200200c7d200c20021b3703e8012000420020162004ad7c7d201620021b3703f0012000201320197d201c20021b3703f801200041c8016a200041e8016a20004188026a4108100720094200200041a0026a290300222120004198026a2903002219420052ad7c420020197d2228200029038802221e420052220420004190026a29030022134200522013501bad222754ad7c7d202120021b222185423f88a7200c201c8420092016848442005271720d07201b202185201b201b20217d2018202820277d201920021b220954ad7d201820097d222820154200201e7d201e20021b2227542205200a420020132004ad7c7d201320021b221854200a2018511bad222b54ad7d221c85834200530d08200141206b22012400202220172024200f200e2012200b20112001100c22020d12200141186a2903002109200141106a2903002116200141086a290300211b2001290300200141206b22012400201b2016200920262023201420102001100c22020d13200041c0026a4200370300200041e0026a4200200141186a2903002209200141106a290300221b420052ad7c4200201b7d22132001290300220c4200522204200141086a29030022164200522016501bad221954ad7c7d2009200942005322021b370300200042003703b802200042003703b002200042043703a80220004200200c7d200c20021b3703c8022000420020162004ad7c7d201620021b3703d0022000201320197d201b20021b3703d802200041a8026a200041c8026a200041e8026a410810072009420020004180036a2903002221200041f8026a2903002219420052ad7c420020197d222a20002903e802221e4200522204200041f0026a29030022134200522013501bad222d54ad7c7d202120021b222185423f88a7200c201b8420092016848442005271720d09201c202185427f85201c2028202b7d2216202a202d7d201920021b7c2209201654ad201c20217c7c20092009201520277d22164200201e7d201e20021b7c221b20165422072007ad200a20187d2005ad7d2216420020132004ad7c7d201320021b7c7c220a201654200a2016511bad7c220c56ad7c221685834200530d0a200141206b22012400201d2025200d201a2001100d22020d12200141186a2903002109200141106a290300211c200141086a29030021132001290300200141206b2202240020004198066a2011370300200041f8056a20113703002000200b3703900620002012370388062000200e370380062000200b3703f005200020123703e8052000200e3703e005200041e0056a20004180066a200041a0066a410810070d0b20002903a00621182002420037031020024200370308200241186a220142003703002002201842808090bbbad6adf00d8037030020012903002118200241106a2903002119200241086a290300211e20022903002121200241206b220124002013201c20092021201e201920182001100c22020d122016200141186a290300220985427f852016200c200141106a2903007c221c200c54ad200920167c7c201c201b20012903007c2215201b5422022002ad200a200141086a2903007c7c2209200a542009200a511bad7c2218201c54ad7c221b85834200530d0c200141206b22012400201d2025200d201a200e2012200b20112001100c22020d12200141186a290300210a200141106a2903002116200141086a290300211c2001290300200141206b22012400201c2016200a20262023201420102001100c22020d13200041a0036a4200370300200041c0036a4200200141186a290300220a200141106a290300221c420052ad7c4200201c7d22132001290300220c4200522204200141086a29030022164200522016501bad221954ad7c7d200a200a42005322021b37030020004200370398032000420037039003200042023703880320004200200c7d200c20021b3703a8032000420020162004ad7c7d201620021b3703b0032000201320197d201c20021b3703b80320004188036a200041a8036a200041c8036a41081007200a4200200041e0036a2903002221200041d8036a2903002219420052ad7c420020197d222820002903c803221e4200522204200041d0036a29030022134200522013501bad222754ad7c7d202120021b222185423f88a7200c201c84200a2016848442005271720d0d201b202185427f85201b2018202820277d201920021b7c2216201854ad201b20217c7c2016201620154200201e7d201e20021b7c221c20155422052005ad2009420020132004ad7c7d201320021b7c7c220a2009542009200a511bad7c220c56ad7c220985834200530d0e200141206b2201240020262023201420102001100d22020d122009200141186a290300221b85427f852009200c200c200141106a2903007c221656ad2009201b7c7c20162016201c201c20012903007c221c5622022002ad200a200141086a2903007c7c221b200a54200a201b511bad7c220c56ad7c221685834200530d0f200141206b22012400202220172024200f200e2012200b20112001100c22020d12200141186a290300210a200141106a290300210f200141086a290300210920012903002122200141206b22012400201d2025200d201a200e2012200b20112001100c22020d12200141186a2903002117200141106a2903002124200141086a290300211120012903002125200141206b22012400201c201b200c2016200041c0056a100e220245044020004198066a4200370300200041f8056a200041d8056a290300370300200020002903c0053703e005200042003703900620004200370388062000428094ebdc03370380062000200041d0056a2903003703f0052000200041c8056a2903003703e805200041e0056a20004180066a200041a0066a410810070d11200041b8066a290300210e200041b0066a290300210b200041a8066a2903002112200120002903a006370300200120123703082001200b370310200141186a200e3703000c120b2002450d110c120b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b200141186a2903002116200141106a290300210c200141086a290300211320012903002115200141206b220222012400200241186a420037030020024200370310200242003703082002420137030041084120360200027e2002412041104108100104404200210b4200210e4200211242000c010b412829030021124120290300210e4118290300210b41102903000b210d20004180046a4200370300200041a0046a42004200200f7d221a2022420052220420094200522009501bad221d54ad200a200f420052ad7c7c7d200a200a42005322021b370300200042003703f803200042003703f003200042023703e8032000420020092004ad7c7d200920021b370390042000420020227d202220021b370388042000201a201d7d200f20021b3703980402400240024002400240024002400240200041e8036a20004188046a200041a8046a41081007200a4200200041c0046a290300221d200041b8046a290300221b420052ad7c4200201b7d221820002903a804221c4200522204200041b0046a290300221a420052201a501bad221954ad7c7d201d20021b221d85423f88a7200f2022842009200a848442005271724504402017201d85201d201d20177d201820197d201b20021b220a202454ad7d200a20247d220f4200201c7d201c20021b222220255422054200201a2004ad7c7d201a20021b220920115420092011511bad221a54ad7d220a85834200530d01200a201085427f85200a200f201a7d220f20147c2214200f54ad200a20107c7c20142014202220257d220f20267c2210200f5422022002ad200920117d2005ad7d220920237c7c221120095420092011511bad7c221456ad7c220985834200530d022009201685427f8520092014200c20147c220a56ad200920167c7c200a200a2010201020157c22145622022002ad201120137c7c221020115420102011511bad7c220f56ad7c220a85834200530d03200e200d42808090bbbad6adf00d7c2211200d542202200b2002ad7c200b54200d2011581b2202ad7c220b200e54220420122004ad7c201254200b200e5a1b200220021b0d04200020113703d004200042023703c804200041c8046a200041d0046a200041d8046a410210070d0520002903d804210e200141206b2202240020004198056a4200370300200041f8046a200a37030020004200370390052000420037038805200042808090bbbad6adf00d370380052000200f3703f004200020103703e804200020143703e004200041e0046a20004180056a200041a0056a410810070d06200041b8056a2903002111200041b0056a290300210b200041a8056a290300211220002903a005210a200041f8056a4200370300200041d8056a2011370300200042003703f005200042003703e8052000200e3703e0052000200a3703c005200020123703c8052000200b3703d005200041c0056a200041e0056a20004180066a200041a0066a100a0d07200220002903a006370300200241186a2201200041b8066a2903003703002002200041b0066a2903003703102002200041a8066a2903003703082002290300221120207d2209201156200241086a290300220e20297d20112020542204ad7d2212200e56200e2012511b200241106a2903002211202c7d220b2004200e202954200e2029511bad22107d220a2011562001290300220e201f7d2011202c54ad7d200b201054ad7d220b200e56200b200e511b200a201185200b200e8584501b450d08000b000b000b000b000b000b000b000b000b20032009370300200320123703082003200a370310200341186a200b370300200041c0066a240041000c020b200041c0066a240020020c010b200041c0066a240020020b450d0c0c0e0b412c290300210f4124290300210d411c290300210b411429030021094134290300212341cc00290300212441c4002903002125413c290300212641d400290300212241ec00290300211141e400290300211741dc00290300211a41f4002903002114418c012903002112418401290300210a41fc00290300210e200641206b22032400027f2300210202400240024002400240200920227d221d200956200b201a7d20092022542200ad7d2209200b562009200b511b200d20177d22292000200b201a54200b201a511bad220b7d2210200d56200f20117d200d201754ad7d200b202956ad7d220b200f56200b200f511b200d201085200b200f8584501b4504402014201d582009200e5a2009200e5122001b200a201058200b20125a200b2012511b200a201085200b20128584501b450d01201d20147d2229201d562009200e7d2014201d562201ad7d220f2009562009200f511b2010200a7d221d20012009200e5420001bad22097d220d201056200b20127d200a201056ad7d2009201d56ad7d2209200b562009200b511b200d2010852009200b8584501b0d02200241206b220024002029200f200d200920232026202520242000100f22010d03201420227c220920145422012001ad200e201a7c7c220b200e54200b200e511b2201200a20177c22102001ad7c220e200a54200e201054ad200a201056ad201120127c7c7c221120125420112012511b200a200e85201120128584501b0d0420092000290300220a7d2210200956200b200041086a29030022127d2009200a542201ad7d220a200b56200a200b511b200e200041106a29030022097d22142001200b201254200b2012511bad220b7d2212200e562011200041186a2903007d2009200e56ad7d200b201456ad7d220b201156200b2011511b200e201285200b20118584501b450d05000b000b000b000b2002240020010c020b000b200320103703002003200a37030820032012370310200341186a200b3703002002240041000b450d0b0c0d0b412c290300210d4124290300211a411c2903002110411429030021094134290300212341cc00290300211d41c4002903002122413c290300211441d400290300212441ec00290300211141e400290300212541dc00290300211741f4002903002112418c01290300210a418401290300210b41fc00290300210e200641206b22032400027f2300210202400240024002400240200920247d2226200956201020177d20092024542200ad7d220920105620092010511b201a20257d22292000201020175420102017511bad22107d220f201a56200d20117d201a202554ad7d2010202956ad7d2210200d56200d2010511b200f201a85200d20108584501b450440202620127d22292026562009200e7d20122026562200ad7d220d2009562009200d511b200f200b7d222620002009200e542009200e511bad22097d221a200f562010200a7d200b200f56ad7d2009202656ad7d220920105620092010511b200f201a85200920108584501b0d01202320127d22262023562014200e7d20122023562200ad7d220f201456200f2014511b2022200b7d22102000200e201456200e2014511bad22237d2214202256201d200a7d200b202256ad7d2010202354ad7d2210201d562010201d511b20142022852010201d8584501b0d02200241206b220024002029200d201a20092026200f201420102000100f22010d03201220247c220920125422012001ad200e20177c7c2212200e54200e2012511b2201200b20257c22102001ad7c220e200b54200e201054ad200b201056ad200a20117c7c7c2211200a54200a2011511b200b200e85200a20118584501b0d0420092000290300220a7d22102009562012200041086a290300220b7d2009200a542201ad7d220a201256200a2012511b200e200041106a29030022097d22142001200b201256200b2012511bad220b7d2212200e562011200041186a2903007d2009200e56ad7d200b201456ad7d220b201156200b2011511b200e201285200b20118584501b450d05000b000b000b000b2002240020010c020b000b200320103703002003200a37030820032012370310200341186a200b3703002002240041000b450d0a0c0c0b412c290300210e41242903002111411c290300210b41142903004134290300210a41cc00290300210941c4002903002110413c2903002114200641206b22032400200b2011200e200a2014201020092003100f450d090c0b0b000b000b000b000b000b41004100100541086a410010020c040b000b000b000b200341086a290300210e200341106a2903002111200341186a290300210b2003290300211241201005220041206a200b370300200041186a2011370300200041106a200e370300200041086a2200201237030041002000412010020b200641206a24000c010b200641206a24000b000b008e010970726f64756365727302086c616e6775616765010143000c70726f6365737365642d62790105636c616e676131352e302e34202868747470733a2f2f6769746875622e636f6d2f736f6c616e612d6c6162732f6c6c766d2d70726f6a6563742e676974203333633336323963616135396235396438663538353733366134613531393461613965393337376429', }, spec: { constructors: [ diff --git a/src/contracts/nabla/BackstopPool.ts b/src/contracts/nabla/BackstopPool.ts index ce602e92..221adcfe 100644 --- a/src/contracts/nabla/BackstopPool.ts +++ b/src/contracts/nabla/BackstopPool.ts @@ -7,10 +7,9 @@ export const backstopPoolAbi = { version: '0.0.1', }, source: { - compiler: 'solang 0.3.0', - hash: '0xea84980f2af6ef0afca162792e26bb46bad178bed27fb34b6558753e4075b0f6', - language: 'Solidity 0.3.0', - wasm: '0x0061736d0100000001a5031460027f7f0060047f7f7f7f017f60037f7f7f0060000060447f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7e7e7e7e017f60047f7e7e7f0060247f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7e7e7e7e017f6000017f60027f7f017f60047f7f7f7f0060087f7f7e7f7f7f7f7f017f60037f7f7f017f60017f017f60217f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60417f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60207f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60237f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60027e7f017f60297f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7e7e7e7e7e7e7e7e7f017f60037f7e7e000291020e057365616c310d636c6561725f73746f726167650008057365616c320b7365745f73746f726167650001057365616c300f686173685f6b656363616b5f3235360002057365616c310b6765745f73746f726167650001057365616c300663616c6c65720000057365616c300f686173685f626c616b65325f3235360002057365616c300d6465706f7369745f6576656e740009057365616c300762616c616e63650000057365616c31097365616c5f63616c6c000a057365616c3007616464726573730000057365616c300b7365616c5f72657475726e0002057365616c3005696e7075740000057365616c301176616c75655f7472616e73666572726564000003656e76066d656d6f727902011010031d1c020000020b0c0103010505010d0e04040607070f04101106121303030608017f01418080040b071102066465706c6f7900270463616c6c00280ab789061cb50101027f02402002450d00200241016b2002410771220304400340200020012d00003a0000200041016a2100200141016a2101200241016b2102200341016b22030d000b0b4107490d000340200020012d00003a0000200020012d00013a0001200020012d00023a0002200020012d00033a0003200020012d00043a0004200020012d00053a0005200020012d00063a0006200020012d00073a0007200041086a2100200141086a2101200241086b22020d000b0b0ba10101027f02402001450d00200141016b200141077122020440034020004200370300200041086a2100200141016b2101200241016b22020d000b0b4107490d00034020004200370300200041386a4200370300200041306a4200370300200041286a4200370300200041206a4200370300200041186a4200370300200041106a4200370300200041086a4200370300200041406b2100200141086b22010d000b0b0b930101037f4120210302404100450440200041206a21040c010b03402001200341016b220320006a22042d00003a0000200141016a2101200241016b22020d000b0b200441046b210203402001200241036a2d00003a00002001200241026a2d00003a00012001200241016a2d00003a0002200120022d00003a0003200241046b2102200141046a2101200341046b22030d000b0b9f0101037f200241016b024020024103712203450440200120026a21040c010b0340200241016b220220016a220420002d00003a0000200041016a2100200341016b22030d000b0b41034f0440200441046b21030340200341036a20002d00003a0000200341026a20002d00013a0000200341016a20002d00023a0000200320002d00033a0000200041046a2100200341046b2103200241046b22020d000b0b0bb60201037f200020016c220141086a10122204200036020420042000360200200441086a210002402002417f4704402001450d01200141016b2001410771220304400340200020022d00003a0000200041016a2100200241016a2102200141016b2101200341016b22030d000b0b4107490d010340200020022d00003a0000200020022d00013a0001200020022d00023a0002200020022d00033a0003200020022d00043a0004200020022d00053a0005200020022d00063a0006200020022d00073a0007200041086a2100200241086a2102200141086b22010d000b0c010b2001450d00200141016b2001410771220204400340200041003a0000200041016a2100200141016b2101200241016b22020d000b0b4107490d00034020004200370000200041086a2100200141086b22010d000b0b20040b950101047f41808004210103400240200128020c0d00200128020822022000490d002002200041076a41787122026b220441184f0440200120026a41106a22002001280200220336020020030440200320003602040b2000200441106b3602082000410036020c2000200136020420012000360200200120023602080b2001410136020c200141106a0f0b200128020021010c000b000b890301047f200120036a220441086a10122205200436020420052004360200200541086a210402402001450d00200141016b2001410771220604400340200420002d00003a0000200441016a2104200041016a2100200141016b2101200641016b22060d000b0b4107490d000340200420002d00003a0000200420002d00013a0001200420002d00023a0002200420002d00033a0003200420002d00043a0004200420002d00053a0005200420002d00063a0006200420002d00073a0007200441086a2104200041086a2100200141086b22010d000b0b02402003450d00200341016b2003410771220004400340200420022d00003a0000200441016a2104200241016a2102200341016b2103200041016b22000d000b0b4107490d000340200420022d00003a0000200420022d00013a0001200420022d00023a0002200420022d00033a0003200420022d00043a0004200420022d00053a0005200420022d00063a0006200420022d00073a0007200441086a2104200241086a2102200341086b22030d000b0b20050b2e00418080044100360200418480044100360200418c80044100360200418880043f00411074419080046b3602000b8303020c7f027e2003411f752003712107200341027420006a41046b210520032104027f03402007200441004c0d011a200441016b21042005280200200541046b2105450d000b200441016a0b2108200341027420016a41046b21052003210402400340200441004c0d01200441016b21042005280200200541046b2105450d000b200441016a21070b200341004c044041000f0b41012003410174220b200b41014c1b210e200141046b210f410021014101210c4100210603402009200120074e6a21090240200620062007486a2206200a200120084e6a220a4d0440420021110c010b2006200a6b210d200020094102746a2104200f20064102746a210542002111034020114280808080107c201120102010200535020020043502007e7c2210561b2111200441046a2104200541046b2105200d41016b220d0d000b0b0240024020012003480440200220014102746a20103e02000c010b20104200520d010b200141016a2201200b48210c201042208820118421102001200e470d010b0b200c0b5001017e02402003450d00200341c00071044020012003413f71ad862102420021010c010b20022003ad220486200141c00020036bad88842102200120048621010b20002002370308200020013703000b5001017e02402003450d00200341c00071044020022003413f71ad882101420021020c010b200241c00020036bad8620012003ad220488842101200220048821020b20002002370308200020013703000bb51102197e047f230041f0006b221d2400200041186a2903002106200041106a2903002108200041086a29030021072000290300210a027f02402001290300220f420156200141086a290300220c420052200c501b200141106a2903002210420052200141186a290300220b420052200b5022201b200b201084501b4504404101200fa741016b0d021a200242003703102002420037030820024200370300200241186a4200370300200320083703102003200a37030020032007370308200341186a20063703000c010b20082010852204200a200f85842006200b8522052007200c858484500440200242003703102002420037030820024200370300200241186a420037030020034200370310200341186a420037030020034201370300200342003703080c010b2008200a84200620078484504101200a200f5a2007200c5a2007200c511b200820105a2006200b5a2006200b511b2004200584501b1b04402002200a3703002002200737030820022008370310200241186a200637030020034200370310200341186a420037030020034200370300200342003703080c010b41c0012100027f02402006220450221f450d004180012100200822044200520d0041c0002100200722044200520d0041002200200a2204500d011a0b2000411f413f20044280808080105422001b220141106b20012004422086200420001b220442808080808080c0005422001b220141086b20012004421086200420001b2204428080808080808080015422001b220141046b20012004420886200420001b2204428080808080808080105422001b220141026b20012004420486200420001b2204428080808080808080c0005422001b6a2004420286200420001b423f87a7417f736a0b210041c0012101200b2104201d41306a200f200c4180012000027f02402020450d004180012101201022044200520d0041c0002101200c22044200520d0041002201200f2204500d011a0b2001411f413f20044280808080105422011b221e41106b201e2004422086200420011b220442808080808080c0005422011b221e41086b201e2004421086200420011b2204428080808080808080015422011b221e41046b201e2004420886200420011b2204428080808080808080105422011b221e41026b201e2004420486200420011b2204428080808080808080c0005422011b6a2004420286200420011b423f87a7417f736a0b6b22006b1017201d41e0006a2010200b20001016201d41406b200f200c20004180016b1016201d41d0006a200f200c20001016201d41e8006a290300201d41386a29030084201d41c8006a290300200041800149221e1b201d290360201d29033084201d290340201e1b2109201d41d8006a290300210d201d290350211141c001210120062104027f0240201f450d004180012101200822044200520d0041c0002101200722044200520d0041002201200a2204500d011a0b2001411f413f20044280808080105422011b221f41106b201f2004422086200420011b220442808080808080c0005422011b221f41086b201f2004421086200420011b2204428080808080808080015422011b221f41046b201f2004420886200420011b2204428080808080808080105422011b221f41026b201f2004420486200420011b2204428080808080808080c0005422011b6a2004420286200420011b423f87a7417f736a0b2101200b20001b21042009201020001b210e200d4200201e1b210d20114200201e1b211141c0012100200b2105201d41106a420142002001027f02402020450d004180012100201022054200520d0041c0002100200c22054200520d0041002200200f2205500d011a0b2000411f413f20054280808080105422001b221e41106b201e2005422086200520001b220542808080808080c0005422001b221e41086b201e2005421086200520001b2205428080808080808080015422001b221e41046b201e2005420886200520001b2205428080808080808080105422001b221e41026b201e2005420486200520001b2205428080808080808080c0005422001b6a2005420286200520001b423f87a7417f736a0b6b22004180016b1016201d4201420041800120006b1017201d41206a4201420020001016200e200a2011542007200d542007200d511b2008200e54200420065620042006511b2008200e85200420068584501b221ead2209882004420186201e413f73ad221286842105200d4201862012862011200988842111201d290300201d29031020004180014922011b420020001b2213200988201d41086a290300201d41186a29030020011b420020001b2214420186201286842117201d41286a290300420020011b2215420186201286201d290320420020011b200988842112200e420186201e417f73413f71ad221686200d20098884210e2013420186201686201520098884210d20042009882104201420098821094200211342002114420021154200211603404200200e200a2011542007200e542007200e511b2005200856200420065620042006511b2005200885200420068584501b22001b21184200201120001b211a4200200420001b211b20084200200520001b22195421014200200920001b20168421164200201720001b20158421154200200d20001b20148421144200201220001b2013842113200d423f862012420188842112200e423f8620114201888421112017423f86200d42018884210d2005423f86200e42018884210e2009423f8620174201888421172004423f8620054201888421052009420188210920044201882104200820197d2219200a201a542200200720185420072018511bad221c7d2108200a201a7d220a200f5a200720187d2000ad7d2207200c5a2007200c511b200820105a2006201b7d2001ad7d2019201c54ad7d2206200b5a2006200b511b20082010852006200b8584501b0d000b200320133703002003201437030820032015370310200341186a201637030020022008370310200241186a20063703002002200a370300200220073703080b41000b201d41f0006a24000b9d0402027f047e230041406a22222400202241406a22212400202141186a4200370300202142003703102021420037030820214203370300202141206a20003a0000202141216a20013a0000202141226a20023a0000202141236a20033a0000202141246a20043a0000202141256a20053a0000202141266a20063a0000202141276a20073a0000202141286a20083a0000202141296a20093a00002021412a6a200a3a00002021412b6a200b3a00002021412c6a200c3a00002021412d6a200d3a00002021412e6a200e3a00002021412f6a200f3a0000202141306a20103a0000202141316a20113a0000202141326a20123a0000202141336a20133a0000202141346a20143a0000202141356a20153a0000202141366a20163a0000202141376a20173a0000202141386a20183a0000202141396a20193a00002021413a6a201a3a00002021413b6a201b3a00002021413c6a201c3a00002021413d6a201d3a00002021413e6a201e3a00002021413f6a201f3a0000202141c000202241206a10024198054120360200202241186a202241386a2903003703002022202241306a2903003703102022202241286a29030037030820222022290320370300027e2022412041a0054198051003044042000c010b41b005290300212541a805290300212441a005290300212341b8052903000b2126202020233703002020202437030820202025370310202041186a2026370300202241406b240041000bc30702027f057e230041e0006b22422400204241406a22412400204141186a4200370300204142003703102041420037030820414204370300204141206a20003a0000204141216a20013a0000204141226a20023a0000204141236a20033a0000204141246a20043a0000204141256a20053a0000204141266a20063a0000204141276a20073a0000204141286a20083a0000204141296a20093a00002041412a6a200a3a00002041412b6a200b3a00002041412c6a200c3a00002041412d6a200d3a00002041412e6a200e3a00002041412f6a200f3a0000204141306a20103a0000204141316a20113a0000204141326a20123a0000204141336a20133a0000204141346a20143a0000204141356a20153a0000204141366a20163a0000204141376a20173a0000204141386a20183a0000204141396a20193a00002041413a6a201a3a00002041413b6a201b3a00002041413c6a201c3a00002041413d6a201d3a00002041413e6a201e3a00002041413f6a201f3a0000204141c000204241406b1002204241c8006a2903002147204241d0006a2903002143204241d8006a290300214420422903402145204141406a22002400200041186a2044370300200020433703102000204737030820002045370300200041206a20203a0000200041216a20213a0000200041226a20223a0000200041236a20233a0000200041246a20243a0000200041256a20253a0000200041266a20263a0000200041276a20273a0000200041286a20283a0000200041296a20293a00002000412a6a202a3a00002000412b6a202b3a00002000412c6a202c3a00002000412d6a202d3a00002000412e6a202e3a00002000412f6a202f3a0000200041306a20303a0000200041316a20313a0000200041326a20323a0000200041336a20333a0000200041346a20343a0000200041356a20353a0000200041366a20363a0000200041376a20373a0000200041386a20383a0000200041396a20393a00002000413a6a203a3a00002000413b6a203b3a00002000413c6a203c3a00002000413d6a203d3a00002000413e6a203e3a00002000413f6a203f3a0000200041c000204241206a10024198054120360200204241186a204241386a2903003703002042204241306a2903003703102042204241286a29030037030820422042290320370300027e2042412041a00541980510030440420021434200214442000c010b41b005290300214441a805290300214341a005290300214641b8052903000b2145204020463703002040204337030820402044370310204041186a2045370300204241e0006a240041000bf41602077f047e230041e0006b224421462044240002402000200172200272200372200472200572200672200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f7241ff017104402020202172202272202372202472202572202672202772202872202972202a72202b72202c72202d72202e72202f72203072203172203272203372203472203572203672203772203872203972203a72203b72203c72203d72203e72203f7241ff0171450d01204441406a22442400204441186a4200370300204442003703102044420037030820444204370300204441206a20003a0000204441216a20013a0000204441226a20023a0000204441236a20033a0000204441246a20043a0000204441256a20053a0000204441266a20063a0000204441276a20073a0000204441286a20083a0000204441296a20093a00002044412a6a200a3a00002044412b6a200b3a00002044412c6a200c3a00002044412d6a200d3a00002044412e6a200e3a00002044412f6a200f3a0000204441306a20103a0000204441316a20113a0000204441326a20123a0000204441336a20133a0000204441346a20143a0000204441356a20153a0000204441366a20163a0000204441376a20173a0000204441386a20183a0000204441396a20193a00002044413a6a201a3a00002044413b6a201b3a00002044413c6a201c3a00002044413d6a201d3a00002044413e6a201e3a00002044413f6a201f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214e204541406a22442400204441186a204e3703002044204d3703102044204c3703082044204b370300204441206a20203a0000204441216a20213a0000204441226a20223a0000204441236a20233a0000204441246a20243a0000204441256a20253a0000204441266a20263a0000204441276a20273a0000204441286a20283a0000204441296a20293a00002044412a6a202a3a00002044412b6a202b3a00002044412c6a202c3a00002044412d6a202d3a00002044412e6a202e3a00002044412f6a202f3a0000204441306a20303a0000204441316a20313a0000204441326a20323a0000204441336a20333a0000204441346a20343a0000204441356a20353a0000204441366a20363a0000204441376a20373a0000204441386a20383a0000204441396a20393a00002044413a6a203a3a00002044413b6a203b3a00002044413c6a203c3a00002044413d6a203d3a00002044413e6a203e3a00002044413f6a203f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214e204541206b224422452400204641186a2043370300204441186a204e3703002044204d3703102044204c3703082044204b370300204620423703102046204137030820462040370300204441202046412010011a41204101417f1011224441276a201f3a0000204441266a201e3a0000204441256a201d3a0000204441246a201c3a0000204441236a201b3a0000204441226a201a3a0000204441216a20193a0000204441206a20183a00002044411f6a20173a00002044411e6a20163a00002044411d6a20153a00002044411c6a20143a00002044411b6a20133a00002044411a6a20123a0000204441196a20113a0000204441186a20103a0000204441176a200f3a0000204441166a200e3a0000204441156a200d3a0000204441146a200c3a0000204441136a200b3a0000204441126a200a3a0000204441116a20093a0000204441106a20083a00002044410f6a20073a00002044410e6a20063a00002044410d6a20053a00002044410c6a20043a00002044410b6a20033a00002044410a6a20023a0000204441096a20013a0000204441086a224820003a000041e000411820482044280200410020441b10132248280200410020481b41204b044020482802002144204541206b224722452400204841086a22492044410020481b20471005204541206b22442245240020472044100f204641386a204441186a2903003703002046204441106a2903003703302046204441086a29030037032820462044290300370320204641206a2049412010100b41204101417f10112244410a6a20223a0000204441096a20213a0000204441086a224720203a00002044410b6a20233a00002044410c6a20243a00002044410d6a20253a00002044410e6a20263a00002044410f6a20273a0000204441106a20283a0000204441116a20293a0000204441126a202a3a0000204441136a202b3a0000204441146a202c3a0000204441156a202d3a0000204441166a202e3a0000204441176a202f3a0000204441186a20303a0000204441196a20313a00002044411a6a20323a00002044411b6a20333a00002044411c6a20343a00002044411d6a20353a00002044411e6a20363a00002044411f6a20373a0000204441206a20383a0000204441216a20393a0000204441226a203a3a0000204441236a203b3a0000204441246a203c3a0000204441256a203d3a0000204441266a203e3a0000204441276a203f3a0000418001411a20472044280200410020441b10132247280200410020471b41214f044020472802002144204541206b224922452400204741086a224a2044410020471b20491005204541206b22442245240020492044100f204641d8006a204441186a2903003703002046204441106a2903003703502046204441086a29030037034820462044290300370340204641406b204a412010100b41e1004101417f1011224441096a20003a0000204441086a224941013a00002044410a6a20013a00002044410b6a20023a00002044410c6a20033a00002044410d6a20043a00002044410e6a20053a00002044410f6a20063a0000204441106a20073a0000204441116a20083a0000204441126a20093a0000204441136a200a3a0000204441146a200b3a0000204441156a200c3a0000204441166a200d3a0000204441176a200e3a0000204441186a200f3a0000204441196a20103a00002044411a6a20113a00002044411b6a20123a00002044411c6a20133a00002044411d6a20143a00002044411e6a20153a00002044411f6a20163a0000204441206a20173a0000204441216a20183a0000204441226a20193a0000204441236a201a3a0000204441246a201b3a0000204441256a201c3a0000204441266a201d3a0000204441276a201e3a0000204441286a201f3a0000204441c8006a203f3a0000204441c7006a203e3a0000204441c6006a203d3a0000204441c5006a203c3a0000204441c4006a203b3a0000204441c3006a203a3a0000204441c2006a20393a0000204441c1006a20383a0000204441406b20373a00002044413f6a20363a00002044413e6a20353a00002044413d6a20343a00002044413c6a20333a00002044413b6a20323a00002044413a6a20313a0000204441396a20303a0000204441386a202f3a0000204441376a202e3a0000204441366a202d3a0000204441356a202c3a0000204441346a202b3a0000204441336a202a3a0000204441326a20293a0000204441316a20283a0000204441306a20273a00002044412f6a20263a00002044412e6a20253a00002044412d6a20243a00002044412c6a20233a00002044412b6a20223a00002044412a6a20213a0000204441296a20203a0000204441e1006a2043370300204441d9006a2042370300204441d1006a2041370300204441c9006a2040370300204541f0006b220024002000410c3a0000204541ef006b2201410c100e200141a0014120100d204541cf006b204841086a2048280200410020481b100d2045412f6b204741086a2047280200410020471b100d200041e10020492044280200410020441b1006204641e0006a240041000f0b000b000b832102077f087e23004180016b2244214620442400024002402000200172200272200372200472200572200672200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f7241ff017104402020202172202272202372202472202572202672202772202872202972202a72202b72202c72202d72202e72202f72203072203172203272203372203472203572203672203772203872203972203a72203b72203c72203d72203e72203f7241ff0171450d01027e204441406a22442400204441186a4200370300204442003703102044420037030820444203370300204441206a20003a0000204441216a20013a0000204441226a20023a0000204441236a20033a0000204441246a20043a0000204441256a20053a0000204441266a20063a0000204441276a20073a0000204441286a20083a0000204441296a20093a00002044412a6a200a3a00002044412b6a200b3a00002044412c6a200c3a00002044412d6a200d3a00002044412e6a200e3a00002044412f6a200f3a0000204441306a20103a0000204441316a20113a0000204441326a20123a0000204441336a20133a0000204441346a20143a0000204441356a20153a0000204441366a20163a0000204441376a20173a0000204441386a20183a0000204441396a20193a00002044413a6a201a3a00002044413b6a201b3a00002044413c6a201c3a00002044413d6a201d3a00002044413e6a201e3a00002044413f6a201f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214e204541206b22442400204441186a204e3703002044204d3703102044204c3703082044204b37030041980541203602002044412041a005419805100304404200214c4200214d42000c010b41b005290300214d41a805290300214c41a005290300214f41b8052903000b214b027e02402040204f5622482041204c562041204c511b22472042204d5622492043204b562043204b511b2042204d852043204b8584501b450440204441406a22442400204441186a4200370300204442003703102044420037030820444203370300204441206a20003a0000204441216a20013a0000204441226a20023a0000204441236a20033a0000204441246a20043a0000204441256a20053a0000204441266a20063a0000204441276a20073a0000204441286a20083a0000204441296a20093a00002044412a6a200a3a00002044412b6a200b3a00002044412c6a200c3a00002044412d6a200d3a00002044412e6a200e3a00002044412f6a200f3a0000204441306a20103a0000204441316a20113a0000204441326a20123a0000204441336a20133a0000204441346a20143a0000204441356a20153a0000204441366a20163a0000204441376a20173a0000204441386a20183a0000204441396a20193a00002044413a6a201a3a00002044413b6a201b3a00002044413c6a201c3a00002044413d6a201d3a00002044413e6a201e3a00002044413f6a201f3a0000204441206b22452400204441c000204510022045290300214e204541086a2903002150204541106a2903002151204541186a2903002152204541206b22442400204641186a204b20437d2049ad7d204d20427d224b2047ad224d54ad7d370300204441186a205237030020442051370310204420503703082044204e3703002046204b204d7d3703102046204c20417d2048ad7d3703082046204f20407d370300204441202046412010011a204441406a22442400204441186a4200370300204442003703102044420037030820444203370300204441206a20203a0000204441216a20213a0000204441226a20223a0000204441236a20233a0000204441246a20243a0000204441256a20253a0000204441266a20263a0000204441276a20273a0000204441286a20283a0000204441296a20293a00002044412a6a202a3a00002044412b6a202b3a00002044412c6a202c3a00002044412d6a202d3a00002044412e6a202e3a00002044412f6a202f3a0000204441306a20303a0000204441316a20313a0000204441326a20323a0000204441336a20333a0000204441346a20343a0000204441356a20353a0000204441366a20363a0000204441376a20373a0000204441386a20383a0000204441396a20393a00002044413a6a203a3a00002044413b6a203b3a00002044413c6a203c3a00002044413d6a203d3a00002044413e6a203e3a00002044413f6a203f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214f204541206b22442400204441186a204f3703002044204d3703102044204c3703082044204b37030041980541203602002044412041a0054198051003450d014200214c4200214d4200214f42000c020b000b41b805290300214f41b005290300214d41a005290300214c41a8052903000b214b204441406a22442400204441186a4200370300204442003703102044420037030820444203370300204441206a20203a0000204441216a20213a0000204441226a20223a0000204441236a20233a0000204441246a20243a0000204441256a20253a0000204441266a20263a0000204441276a20273a0000204441286a20283a0000204441296a20293a00002044412a6a202a3a00002044412b6a202b3a00002044412c6a202c3a00002044412d6a202d3a00002044412e6a202e3a00002044412f6a202f3a0000204441306a20303a0000204441316a20313a0000204441326a20323a0000204441336a20333a0000204441346a20343a0000204441356a20353a0000204441366a20363a0000204441376a20373a0000204441386a20383a0000204441396a20393a00002044413a6a203a3a00002044413b6a203b3a00002044413c6a203c3a00002044413d6a203d3a00002044413e6a203e3a00002044413f6a203f3a0000204441206b22452400204441c000204510022045290300214e204541086a2903002150204541106a2903002151204541186a2903002152204541206b224422452400204441186a205237030020442051370310204420503703082044204e37030020462040204c7c224e3703202046204c204e562248ad2041204b7c7c224c37032820462042204d7c224e2048204b204c56204b204c511bad7c224b370330204641386a204b204e54ad204d204e56ad2043204f7c7c7c37030020444120204641206a412010011a41204101417f1011224441276a201f3a0000204441266a201e3a0000204441256a201d3a0000204441246a201c3a0000204441236a201b3a0000204441226a201a3a0000204441216a20193a0000204441206a20183a00002044411f6a20173a00002044411e6a20163a00002044411d6a20153a00002044411c6a20143a00002044411b6a20133a00002044411a6a20123a0000204441196a20113a0000204441186a20103a0000204441176a200f3a0000204441166a200e3a0000204441156a200d3a0000204441146a200c3a0000204441136a200b3a0000204441126a200a3a0000204441116a20093a0000204441106a20083a00002044410f6a20073a00002044410e6a20063a00002044410d6a20053a00002044410c6a20043a00002044410b6a20033a00002044410a6a20023a0000204441096a20013a0000204441086a224820003a00004100411720482044280200410020441b10132248280200410020481b41214f044020482802002144204541206b224722452400204841086a22492044410020481b20471005204541206b22442245240020472044100f204641d8006a204441186a2903003703002046204441106a2903003703502046204441086a29030037034820462044290300370340204641406b2049412010100b41204101417f10112244410a6a20223a0000204441096a20213a0000204441086a224720203a00002044410b6a20233a00002044410c6a20243a00002044410d6a20253a00002044410e6a20263a00002044410f6a20273a0000204441106a20283a0000204441116a20293a0000204441126a202a3a0000204441136a202b3a0000204441146a202c3a0000204441156a202d3a0000204441166a202e3a0000204441176a202f3a0000204441186a20303a0000204441196a20313a00002044411a6a20323a00002044411b6a20333a00002044411c6a20343a00002044411d6a20353a00002044411e6a20363a00002044411f6a20373a0000204441206a20383a0000204441216a20393a0000204441226a203a3a0000204441236a203b3a0000204441246a203c3a0000204441256a203d3a0000204441266a203e3a0000204441276a203f3a00004120411520472044280200410020441b10132247280200410020471b41214f044020472802002144204541206b224922452400204741086a224a2044410020471b20491005204541206b22442245240020492044100f204641f8006a204441186a2903003703002046204441106a2903003703702046204441086a29030037036820462044290300370360204641e0006a204a412010100b41e1004101417f1011224441096a20003a0000204441086a224941003a00002044410a6a20013a00002044410b6a20023a00002044410c6a20033a00002044410d6a20043a00002044410e6a20053a00002044410f6a20063a0000204441106a20073a0000204441116a20083a0000204441126a20093a0000204441136a200a3a0000204441146a200b3a0000204441156a200c3a0000204441166a200d3a0000204441176a200e3a0000204441186a200f3a0000204441196a20103a00002044411a6a20113a00002044411b6a20123a00002044411c6a20133a00002044411d6a20143a00002044411e6a20153a00002044411f6a20163a0000204441206a20173a0000204441216a20183a0000204441226a20193a0000204441236a201a3a0000204441246a201b3a0000204441256a201c3a0000204441266a201d3a0000204441276a201e3a0000204441286a201f3a0000204441c8006a203f3a0000204441c7006a203e3a0000204441c6006a203d3a0000204441c5006a203c3a0000204441c4006a203b3a0000204441c3006a203a3a0000204441c2006a20393a0000204441c1006a20383a0000204441406b20373a00002044413f6a20363a00002044413e6a20353a00002044413d6a20343a00002044413c6a20333a00002044413b6a20323a00002044413a6a20313a0000204441396a20303a0000204441386a202f3a0000204441376a202e3a0000204441366a202d3a0000204441356a202c3a0000204441346a202b3a0000204441336a202a3a0000204441326a20293a0000204441316a20283a0000204441306a20273a00002044412f6a20263a00002044412e6a20253a00002044412d6a20243a00002044412c6a20233a00002044412b6a20223a00002044412a6a20213a0000204441296a20203a0000204441e1006a2043370300204441d9006a2042370300204441d1006a2041370300204441c9006a2040370300204541f0006b220024002000410c3a0000204541ef006b2201410c100e200141c0004120100d204541cf006b204841086a2048280200410020481b100d2045412f6b204741086a2047280200410020471b100d200041e10020492044280200410020441b10060c020b000b000b20464180016a240041000ba01502077f087e23004180016b222421262024240002402000200172200272200372200472200572200672200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f7241ff01710440027e202441406a22242400202441186a4200370300202442003703102024420037030820244203370300202441206a20003a0000202441216a20013a0000202441226a20023a0000202441236a20033a0000202441246a20043a0000202441256a20053a0000202441266a20063a0000202441276a20073a0000202441286a20083a0000202441296a20093a00002024412a6a200a3a00002024412b6a200b3a00002024412c6a200c3a00002024412d6a200d3a00002024412e6a200e3a00002024412f6a200f3a0000202441306a20103a0000202441316a20113a0000202441326a20123a0000202441336a20133a0000202441346a20143a0000202441356a20153a0000202441366a20163a0000202441376a20173a0000202441386a20183a0000202441396a20193a00002024413a6a201a3a00002024413b6a201b3a00002024413c6a201c3a00002024413d6a201d3a00002024413e6a201e3a00002024413f6a201f3a0000202441206b22252400202441c000202510022025290300212c202541086a290300212d202541106a290300212b202541186a290300212f202541206b22242400202441186a202f3703002024202b3703102024202d3703082024202c37030041980541203602002024412041a005419805100304404200212d4200212b42000c010b41b005290300212b41a805290300212d41a005290300212e41b8052903000b212c027e02402020202e5622282021202d562021202d511b22272022202b5622292023202c562023202c511b2022202b852023202c8584501b450440202441406a22242400202441186a4200370300202442003703102024420037030820244203370300202441206a20003a0000202441216a20013a0000202441226a20023a0000202441236a20033a0000202441246a20043a0000202441256a20053a0000202441266a20063a0000202441276a20073a0000202441286a20083a0000202441296a20093a00002024412a6a200a3a00002024412b6a200b3a00002024412c6a200c3a00002024412d6a200d3a00002024412e6a200e3a00002024412f6a200f3a0000202441306a20103a0000202441316a20113a0000202441326a20123a0000202441336a20133a0000202441346a20143a0000202441356a20153a0000202441366a20163a0000202441376a20173a0000202441386a20183a0000202441396a20193a00002024413a6a201a3a00002024413b6a201b3a00002024413c6a201c3a00002024413d6a201d3a00002024413e6a201e3a00002024413f6a201f3a0000202441206b22252400202441c000202510022025290300212f202541086a2903002130202541106a2903002131202541186a2903002132202541206b22242400202641186a202c20237d2029ad7d202b20227d222c2027ad222b54ad7d370300202441186a203237030020242031370310202420303703082024202f3703002026202c202b7d3703102026202d20217d2028ad7d3703082026202e20207d370300202441202026412010011a202441206b22242400202441186a420037030020244200370310202442003703082024420537030041980541203602002024412041a0054198051003450d014200212d4200212b4200212e42000c020b000b41b805290300212e41b005290300212b41a005290300212d41a8052903000b212c202441206b222422252400202441186a4200370300202442003703102024420037030820244205370300202641386a202e20237d2022202b56ad7d202b20227d222b2020202d5622282021202c562021202c511bad222e54ad7d3703002026202c20217d2028ad7d3703282026202d20207d3703202026202b202e7d37033020244120202641206a412010011a41204101417f1011222441136a200b3a0000202441126a200a3a0000202441116a20093a0000202441106a20083a00002024410f6a20073a00002024410e6a20063a00002024410d6a20053a00002024410c6a20043a00002024410b6a20033a00002024410a6a20023a0000202441096a20013a0000202441086a222820003a0000202441146a200c3a0000202441156a200d3a0000202441166a200e3a0000202441176a200f3a0000202441186a20103a0000202441196a20113a00002024411a6a20123a00002024411b6a20133a00002024411c6a20143a00002024411d6a20153a00002024411e6a20163a00002024411f6a20173a0000202441206a20183a0000202441216a20193a0000202441226a201a3a0000202441236a201b3a0000202441246a201c3a0000202441256a201d3a0000202441266a201e3a0000202441276a201f3a00004100411720282024280200410020241b10132228280200410020281b41214f044020282802002124202541206b222722252400202841086a22292024410020281b20271005202541206b22242225240020272024100f202641d8006a202441186a2903003703002026202441106a2903003703502026202441086a29030037034820262024290300370340202641406b2029412010100b41204101417f1011222441206a4200370000202441186a4200370000202441106a4200370000202441086a222742003700004120411520272024280200410020241b10132227280200410020271b41214f044020272802002124202541206b222922252400202741086a222a2024410020271b20291005202541206b22242225240020292024100f202641f8006a202441186a2903003703002026202441106a2903003703702026202441086a29030037036820262024290300370360202641e0006a202a412010100b41e1004101417f1011222441096a20003a0000202441086a222941003a00002024410a6a20013a00002024410b6a20023a00002024410c6a20033a00002024410d6a20043a00002024410e6a20053a00002024410f6a20063a0000202441106a20073a0000202441116a20083a0000202441126a20093a0000202441136a200a3a0000202441146a200b3a0000202441156a200c3a0000202441166a200d3a0000202441176a200e3a0000202441186a200f3a0000202441196a20103a00002024411a6a20113a00002024411b6a20123a00002024411c6a20133a00002024411d6a20143a00002024411e6a20153a00002024411f6a20163a0000202441206a20173a0000202441216a20183a0000202441226a20193a0000202441236a201a3a0000202441246a201b3a0000202441256a201c3a0000202441266a201d3a0000202441276a201e3a0000202441286a201f3a0000202441e1006a2023370300202441d9006a2022370300202441d1006a2021370300202441c9006a2020370300202441c1006a4200370000202441396a4200370000202441316a4200370000202441296a4200370000202541f0006b220024002000410c3a0000202541ef006b2201410c100e200141c0004120100d202541cf006b202841086a2028280200410020281b100d2025412f6b202741086a2027280200410020271b100d200041e10020292024280200410020241b10060c010b000b20264180016a240041000bdf0102027f047e230041406a220024004198054120360200200041186a4200370300200042003703102000420037030820004201370300027e2000412041a0054198051003044042000c010b41b005290300210441a805290300210341a005290300210241b8052903000b2105200242028520048420032005848450450440200041206b22012400200041386a4200370300200141186a420037030020014200370310200142003703082001420137030020004200370330200042003703282000420237032020014120200041206a412010011a200041406b240041000f0b000bb60a01227f230041406a220024004198054120360200200041386a4200370300200042003703302000420037032820004200370320200041206a412041a0054198051003210241a0052d0000210341a1052d0000210441a2052d0000210541a3052d0000210641a4052d0000210741a5052d0000210841a6052d0000210941a7052d0000210a41a8052d0000210b41a9052d0000210c41aa052d0000210d41ab052d0000210e41ac052d0000210f41ad052d0000211041ae052d0000211141af052d0000211241b0052d0000211341b1052d0000211441b2052d0000211541b3052d0000211641b4052d0000211741b5052d0000211841b6052d0000211941b7052d0000211a41b8052d0000211b41b9052d0000211c41ba052d0000211d41bb052d0000211e41bc052d0000211f41bd052d0000212041be052d000021212000410041bf052d000020021b3a001f20004100202120021b3a001e20004100202020021b3a001d20004100201f20021b3a001c20004100201e20021b3a001b20004100201d20021b3a001a20004100201c20021b3a001920004100201b20021b3a001820004100201a20021b3a001720004100201920021b3a001620004100201820021b3a001520004100201720021b3a001420004100201620021b3a001320004100201520021b3a001220004100201420021b3a001120004100201320021b3a001020004100201220021b3a000f20004100201120021b3a000e20004100201020021b3a000d20004100200f20021b3a000c20004100200e20021b3a000b20004100200d20021b3a000a20004100200c20021b3a000920004100200b20021b3a000820004100200a20021b3a000720004100200920021b3a000620004100200820021b3a000520004100200720021b3a000420004100200620021b3a000320004100200520021b3a000220004100200420021b3a000120004100200320021b3a000020002d001f210220002d001e210320002d001d210420002d001c210520002d001b210620002d001a210720002d0019210820002d0018210920002d0017210a20002d0016210b20002d0015210c20002d0014210d20002d0013210e20002d0012210f20002d0011211020002d0010211120002d000f211220002d000e211320002d000d211420002d000c211520002d000b211620002d000a211720002d0009211820002d0008211920002d0007211a20002d0006211b20002d0005211c20002d0004211d20002d0003211e20002d0002211f20002d0001212020002d00002121200041206b22012400419805412036020041a0054198051004200141a005290300370000200141a805290300370008200141b005290300370010200141b80529030037001802400240202120012d0000470d00202020012d0001470d00201f20012d0002470d00201e20012d0003470d00201d20012d0004470d00201c20012d0005470d00201b20012d0006470d00201a20012d0007470d00201920012d0008470d00201820012d0009470d00201720012d000a470d00201620012d000b470d00201520012d000c470d00201420012d000d470d00201320012d000e470d00201220012d000f470d00201120012d0010470d00201020012d0011470d00200f20012d0012470d00200e20012d0013470d00200d20012d0014470d00200c20012d0015470d00200b20012d0016470d00200a20012d0017470d00200920012d0018470d00200820012d0019470d00200720012d001a470d00200620012d001b470d00200520012d001c470d00200420012d001d470d00200320012d001e470d00200220012d001f460d010b000b200041406b240041000b881401277f230041a0016b2223240041980541203602002023222141d8006a4200370300202142003703502021420037034820214200370340202141406b412041a0054198051003212241a0052d0000212441a1052d0000212641a2052d0000212741a3052d0000212841a4052d0000212941a5052d0000212a41a6052d0000212b41a7052d0000212c41a8052d0000212d41a9052d0000212e41aa052d0000212f41ab052d0000213041ac052d0000213141ad052d0000213241ae052d0000213341af052d0000213441b0052d0000213541b1052d0000213641b2052d0000213741b3052d0000213841b4052d0000213941b5052d0000213a41b6052d0000213b41b7052d0000213c41b8052d0000213d41b9052d0000213e41ba052d0000213f41bb052d0000214041bc052d0000214141bd052d0000214241be052d0000214341bf052d000021442021201f3a001f2021201e3a001e2021201d3a001d2021201c3a001c2021201b3a001b2021201a3a001a202120193a0019202120183a0018202120173a0017202120163a0016202120153a0015202120143a0014202120133a0013202120123a0012202120113a0011202120103a00102021200f3a000f2021200e3a000e2021200d3a000d2021200c3a000c2021200b3a000b2021200a3a000a202120093a0009202120083a0008202120073a0007202120063a0006202120053a0005202120043a0004202120033a0003202120023a0002202120013a0001202120003a0000202141386a4200370300202142003703302021420037032820214200370320202141206a41202021412010011a41204101417f1011222041276a4100204420221b22443a0000202041266a4100204320221b22433a0000202041256a4100204220221b22423a0000202041246a4100204120221b22413a0000202041236a4100204020221b22403a0000202041226a4100203f20221b223f3a0000202041216a4100203e20221b223e3a0000202041206a4100203d20221b223d3a00002020411f6a4100203c20221b223c3a00002020411e6a4100203b20221b223b3a00002020411d6a4100203a20221b223a3a00002020411c6a4100203920221b22393a00002020411b6a4100203820221b22383a00002020411a6a4100203720221b22373a0000202041196a4100203620221b22363a0000202041186a4100203520221b22353a0000202041176a4100203420221b22343a0000202041166a4100203320221b22333a0000202041156a4100203220221b22323a0000202041146a4100203120221b22313a0000202041136a4100203020221b22303a0000202041126a4100202f20221b222f3a0000202041116a4100202e20221b222e3a0000202041106a4100202d20221b222d3a00002020410f6a4100202c20221b222c3a00002020410e6a4100202b20221b222b3a00002020410d6a4100202a20221b222a3a00002020410c6a4100202920221b22293a00002020410b6a4100202820221b22283a00002020410a6a4100202720221b22273a0000202041096a4100202620221b22263a0000202041086a22254100202420221b22453a000041c001412d20252020280200410020201b10132222280200410020221b41214f044020222802002124202341206b222022232400202241086a22252024410020221b20201005202341206b2223240020202023100f202141f8006a202341186a2903003703002021202341106a2903003703702021202341086a29030037036820212023290300370360202141e0006a2025412010100b41204101417f10112220410a6a20023a0000202041096a20013a0000202041086a222420003a00002020410b6a20033a00002020410c6a20043a00002020410d6a20053a00002020410e6a20063a00002020410f6a20073a0000202041106a20083a0000202041116a20093a0000202041126a200a3a0000202041136a200b3a0000202041146a200c3a0000202041156a200d3a0000202041166a200e3a0000202041176a200f3a0000202041186a20103a0000202041196a20113a00002020411a6a20123a00002020411b6a20133a00002020411c6a20143a00002020411d6a20153a00002020411e6a20163a00002020411f6a20173a0000202041206a20183a0000202041216a20193a0000202041226a201a3a0000202041236a201b3a0000202041246a201c3a0000202041256a201d3a0000202041266a201e3a0000202041276a201f3a000041f001412820242020280200410020201b10132224280200410020241b41214f044020242802002125202341206b222022232400202441086a22462025410020241b20201005202341206b2223240020202023100f20214198016a202341186a2903003703002021202341106a290300370390012021202341086a29030037038801202120232903003703800120214180016a2046412010100b41c1004101417f1011222041096a20453a0000202041086a222541043a00002020410a6a20263a00002020410b6a20273a00002020410c6a20283a00002020410d6a20293a00002020410e6a202a3a00002020410f6a202b3a0000202041106a202c3a0000202041116a202d3a0000202041126a202e3a0000202041136a202f3a0000202041146a20303a0000202041156a20313a0000202041166a20323a0000202041176a20333a0000202041186a20343a0000202041196a20353a00002020411a6a20363a00002020411b6a20373a00002020411c6a20383a00002020411d6a20393a00002020411e6a203a3a00002020411f6a203b3a0000202041206a203c3a0000202041216a203d3a0000202041226a203e3a0000202041236a203f3a0000202041246a20403a0000202041256a20413a0000202041266a20423a0000202041276a20433a0000202041286a20443a0000202041c8006a201f3a0000202041c7006a201e3a0000202041c6006a201d3a0000202041c5006a201c3a0000202041c4006a201b3a0000202041c3006a201a3a0000202041c2006a20193a0000202041c1006a20183a0000202041406b20173a00002020413f6a20163a00002020413e6a20153a00002020413d6a20143a00002020413c6a20133a00002020413b6a20123a00002020413a6a20113a0000202041396a20103a0000202041386a200f3a0000202041376a200e3a0000202041366a200d3a0000202041356a200c3a0000202041346a200b3a0000202041336a200a3a0000202041326a20093a0000202041316a20083a0000202041306a20073a00002020412f6a20063a00002020412e6a20053a00002020412d6a20043a00002020412c6a20033a00002020412b6a20023a00002020412a6a20013a0000202041296a20003a0000202341f0006b220024002000410c3a0000202341ef006b2201410c100e200141a0024120100d202341cf006b202241086a2022280200410020221b100d2023412f6b202441086a2024280200410020241b100d200041e10020252020280200410020201b1006202141a0016a240041000bd40401027f230041106b2245240041c4004101417f10112144204541bbb996c87a360208204541086a204441086a410410102044412b6a203f3a00002044412a6a203e3a0000204441296a203d3a0000204441286a203c3a0000204441276a203b3a0000204441266a203a3a0000204441256a20393a0000204441246a20383a0000204441236a20373a0000204441226a20363a0000204441216a20353a0000204441206a20343a00002044411f6a20333a00002044411e6a20323a00002044411d6a20313a00002044411c6a20303a00002044411b6a202f3a00002044411a6a202e3a0000204441196a202d3a0000204441186a202c3a0000204441176a202b3a0000204441166a202a3a0000204441156a20293a0000204441146a20283a0000204441136a20273a0000204441126a20263a0000204441116a20253a0000204441106a20243a00002044410f6a20233a00002044410e6a20223a00002044410d6a20213a00002044410c6a20203a0000204441c4006a20433703002044413c6a2042370300204441346a20413703002044412c6a2040370300024002400240024002402000200120022003200420052006200720082009200a200b200c200d200e200f2010201120122013201420152016201720182019201a201b201c201d201e201f20444120410141c00210112045410c6a102222010d0041002101204528020c2200280200410020001b450d002000280200410020001b2202450d01200241014b0d02200041086a2d0000410171450d030b2001450d03204541106a240020010f0b000b000b000b204541106a240041000be20802017f017e230041206b22232400419805411036020041a00541980510070240024002400240024041a00529030042005441a80529030022244200542024501b2024423f872224420054202450712024501b450440202320003a0000202320013a0001202320023a0002202320033a0003202320043a0004202320053a0005202320063a0006202320073a0007202320083a0008202320093a00092023200a3a000a2023200b3a000b2023200c3a000c2023200d3a000d2023200e3a000e2023200f3a000f202320103a0010202320113a0011202320123a0012202320133a0013202320143a0014202320153a0015202320163a0016202320173a0017202320183a0018202320193a00192023201a3a001a2023201b3a001b2023201c3a001c2023201d3a001d2023201e3a001e2023201f3a001f20202802002101202341106b2200220224002000420037030820004200370300419805418080023602004100202342002000202041086a2001410020201b41a0054198051008419805280200410141a00510112100200241106b220124000440024002400240024002400240024002400240024002400240024002402000280200410020001b044041012100410d410141e00210112201280200410020011b41ffffffff034b0d110240410d410141e00210112201280200410020011b413f4d0d0041042100410d410141e00210112201280200410020011b41ffff004b0d00410221000b20002000410d410141e00210112201280200410020011b6a22014b0d012001200141046a22004b0d0220004101417f1011220241086a41a0f38dc600360200410d410141e00210112200280200410020001b220041ffffffff034d0d05000b2021280200410020211b41ffffffff034b0d14027f41012021280200410020211b413f4d0d001a41042021280200410020211b41ffff004b0d001a41020b220020002021280200410020211b6a22004b0d022000200041046a22014b0d0320014101417f1011220241086a41a0f38dc6003602002021280200410020211b220041ffffffff034d0d05000b000b000b000b000b2000413f4b0d01200041ffffffff03712000470d022002410c6a2000410274360200410121010c0e0b2000413f4b0d02200041ffffffff03712000470d032002410c6a2000410274360200410121010c0c0b200041ffff004b0d03200041ffffffff03712000470d04410221012002410c6a20004102744101723602000c0c0b000b200041ffff004b0d03200041ffffffff03712000470d04410221012002410c6a20004102744101723602000c090b000b2000200041ffffffff03714604402002410c6a2000410274410272360200410421010c090b000b000b2000200041ffffffff03714604402002410c6a2000410274410272360200410421010c060b000b000b200120003602000c020b000b000b20222001280200360200202341206a240041000f0b200120026a410c6a202141086a2000100d000b200120026a410c6a410d410141e002101141086a2000100d000b000bd20302037f057e230041e0016b220224004198054120360200200241206a420037030020024200370318200242003703102002420a370308200241086a412041a005419805100345044041a00529030021050b200241206b220324004198054120360200200241d8016a4200370300200242003703d001200242003703c801200242053703c001027e200241c0016a412041a0054198051003044042000c010b41b005290300210741a805290300210641a005290300210841b8052903000b2109200320083703002003200637030820032007370310200341186a22042009370300200220003703282002200537033020042903002100200341106a2903002106200341086a2903002107200329030021050240200241286a200241306a200241386a4102101545044020022903382108200241d8006a4200370300200241f8006a2000370300200220053703602002420037035020024200370348200220083703402002200737036820022006370370200241406b200241e0006a20024180016a200241a0016a1018450d01000b000b200120022903a001370300200141186a200241b8016a2903003703002001200241b0016a2903003703102001200241a8016a290300370308200241e0016a240041000b8b0502027f047e230041206b222421252024240002402000200172200272200372200472200572200672200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f7241ff01710440202220238450202150202042b9175471710d01000b000b202441406a22242400202441186a4200370300202442003703102024420037030820244210370300202441206a20003a0000202441216a20013a0000202441226a20023a0000202441236a20033a0000202441246a20043a0000202441256a20053a0000202441266a20063a0000202441276a20073a0000202441286a20083a0000202441296a20093a00002024412a6a200a3a00002024412b6a200b3a00002024412c6a200c3a00002024412d6a200d3a00002024412e6a200e3a00002024412f6a200f3a0000202441306a20103a0000202441316a20113a0000202441326a20123a0000202441336a20133a0000202441346a20143a0000202441356a20153a0000202441366a20163a0000202441376a20173a0000202441386a20183a0000202441396a20193a00002024413a6a201a3a00002024413b6a201b3a00002024413c6a201c3a00002024413d6a201d3a00002024413e6a201e3a00002024413f6a201f3a0000202441206b22002400202441c0002000100220002903002126200041086a2903002127200041106a2903002128200041186a2903002129200041206b22002400202541186a2023370300200041186a2029370300200020283703102000202737030820002026370300202520223703102025202137030820252020370300200041202025412010011a202541206a240041000b821d02247f067e23004180066b222924004198054120360200202941306a420037030020294200370328202942003703202029420c370318202941186a412041a0054198051003212a41a0052d0000212f41a1052d0000213041a2052d0000213141a3052d0000213241a4052d0000213341a5052d0000213441a6052d0000213541a7052d0000213641a8052d0000213741a9052d0000213841aa052d0000213941ab052d0000213a41ac052d0000213b41ad052d0000213c41ae052d0000213d41af052d0000213e41b0052d0000213f41b1052d0000214041b2052d0000214141b3052d0000214241b4052d0000214341b5052d0000214441b6052d0000214541b7052d0000214641b8052d0000214741b9052d0000214841ba052d0000214941bb052d0000214a41bc052d0000214b41bd052d0000214c41be052d0000212b41bf052d0000212d41244101417f1011212c202941b2e0d8c00336023c2029413c6a202c41086a222e41041010202c412b6a201f3a0000202c412a6a201e3a0000202c41296a201d3a0000202c41286a201c3a0000202c41276a201b3a0000202c41266a201a3a0000202c41256a20193a0000202c41246a20183a0000202c41236a20173a0000202c41226a20163a0000202c41216a20153a0000202c41206a20143a0000202c411f6a20133a0000202c411e6a20123a0000202c411d6a20113a0000202c411c6a20103a0000202c411b6a200f3a0000202c411a6a200e3a0000202c41196a200d3a0000202c41186a200c3a0000202c41176a200b3a0000202c41166a200a3a0000202c41156a20093a0000202c41146a20083a0000202c41136a20073a0000202c41126a20063a0000202c41116a20053a0000202c41106a20043a0000202c410f6a20033a0000202c410e6a20023a0000202c410d6a20013a0000202c410c6a20003a000020294100202d202a1b3a005f20294100202b202a1b3a005e20294100204c202a1b3a005d20294100204b202a1b3a005c20294100204a202a1b3a005b202941002049202a1b3a005a202941002048202a1b3a0059202941002047202a1b3a0058202941002046202a1b3a0057202941002045202a1b3a0056202941002044202a1b3a0055202941002043202a1b3a0054202941002042202a1b3a0053202941002041202a1b3a0052202941002040202a1b3a005120294100203f202a1b3a005020294100203e202a1b3a004f20294100203d202a1b3a004e20294100203c202a1b3a004d20294100203b202a1b3a004c20294100203a202a1b3a004b202941002039202a1b3a004a202941002038202a1b3a0049202941002037202a1b3a0048202941002036202a1b3a0047202941002035202a1b3a0046202941002034202a1b3a0045202941002033202a1b3a0044202941002032202a1b3a0043202941002031202a1b3a0042202941002030202a1b3a004120294100202f202a1b3a0040202c280200212d4198054180800236020020294200370310202942003703080240024002400240024002400240024002400240024002400240024002404100202941406b4200202941086a202e202d4100202c1b41a0054198051008450440419805280200410141a0051011222d2802004100202d1b222d411f4d0d01419805280200410141a0051011212b202d41204b0d02202b41276a2d0000212f202b41266a2d00002130202b41256a2d00002131202b41246a2d00002132202b41236a2d00002133202b41226a2d00002134202b41216a2d00002135202b41206a2d00002136202b411f6a2d00002137202b411e6a2d00002138202b411d6a2d00002139202b411c6a2d0000213a202b411b6a2d0000213b202b411a6a2d0000213c202b41196a2d0000213d202b41186a2d0000213e202b41176a2d0000213f202b41166a2d00002140202b41156a2d00002141202b41146a2d00002142202b41136a2d00002143202b41126a2d00002144202b41116a2d00002145202b41106a2d00002146202b410f6a2d00002147202b410e6a2d00002148202b410d6a2d00002149202b410c6a2d0000214a202b410b6a2d0000214b202b410a6a2d0000214c202b41096a2d0000212e202b41086a2d0000212d41244101417f1011212a20294187dee59a7b360260202941e0006a202a41086a222b41041010202a410f6a20033a0000202a410e6a20023a0000202a410d6a20013a0000202a410c6a20003a0000202a41106a20043a0000202a41116a20053a0000202a41126a20063a0000202a41136a20073a0000202a41146a20083a0000202a41156a20093a0000202a41166a200a3a0000202a41176a200b3a0000202a41186a200c3a0000202a41196a200d3a0000202a411a6a200e3a0000202a411b6a200f3a0000202a411c6a20103a0000202a411d6a20113a0000202a411e6a20123a0000202a411f6a20133a0000202a41206a20143a0000202a41216a20153a0000202a41226a20163a0000202a41236a20173a0000202a41246a20183a0000202a41256a20193a0000202a41266a201a3a0000202a41276a201b3a0000202a41286a201c3a0000202a41296a201d3a0000202a412a6a201e3a0000202a412b6a201f3a00002029202f3a008301202920303a008201202920313a008101202920323a008001202920333a007f202920343a007e202920353a007d202920363a007c202920373a007b202920383a007a202920393a00792029203a3a00782029203b3a00772029203c3a00762029203d3a00752029203e3a00742029203f3a0073202920403a0072202920413a0071202920423a0070202920433a006f202920443a006e202920453a006d202920463a006c202920473a006b202920483a006a202920493a00692029204a3a00682029204b3a00672029204c3a00662029202e3a00652029202d3a0064202a280200212d202941106b222e2400202e4200370308202e4200370300419805418080023602004100202941e4006a4200202e202b202d4100202a1b41a00541980510080d03419805280200410141a0051011222d2802004100202d1b222d411f4d0d04419805280200410141a0051011212b202d41204b0d052024202684202520278484500d06202b41086a290300224f202b41186a290300225084202b41106a290300224e202b41206a29030022528484500d07202e41206b222d222e2400202d41186a4200370300202d4200370310202d4200370308202d420b3703004198054120360200202d412041a005419805100345044041a005290300214d0b41044101417f1011212b202941e7caf389033602840120294184016a202b41086a222d41041010202920033a008b01202920023a008a01202920013a008901202920003a008801202920043a008c01202920053a008d01202920063a008e01202920073a008f01202920083a009001202920093a0091012029200a3a0092012029200b3a0093012029200c3a0094012029200d3a0095012029200e3a0096012029200f3a009701202920103a009801202920113a009901202920123a009a01202920133a009b01202920143a009c01202920153a009d01202920163a009e01202920173a009f01202920183a00a001202920193a00a1012029201a3a00a2012029201b3a00a3012029201c3a00a4012029201d3a00a5012029201e3a00a6012029201f3a00a701202b2802002100202e41106b22012400200142003703082001420037030041980541808002360200410020294188016a42002001202d20004100202b1b41a00541980510080d08419805280200410141a00510112200280200410020001b2201450d09419805280200410141a0051011200141014b0d0a41086a2d0000202941e0016a2052370300202941c0016a20233703002029204f3703c801202920203703a8012029204e3703d001202920213703b001202920503703d801202920223703b801202941a8016a202941c8016a202941e8016a410810150d0b20294180026a2903002123202941f8016a2903002122202941f0016a290300212120292903e8012120202941c0026a2027370300202941a0026a2023370300202920243703a8022029202037038802202920253703b0022029202137039002202920263703b802202920223703980220294188026a202941a8026a202941c8026a202941e8026a10180d0c202920292903e802370388032029204d3703900320294188036a20294190036a20294198036a410210150d0d2029290398032152ad42ff0183214d42002127420a212620294190056a21014200212542002124420021234200212142002122420121514200214f420021504200214e02400340204da74101710440202941f8046a2024370300202941d8046a204e370300202920263703e004202920513703c004202920273703e8042029204f3703c804202920253703f004202920503703d004202941c0046a202941e0046a20294180056a410810150d112001290300215020294188056a290300214f202929038005215120294198056a290300214e0b2023423f86204d42018884224d2022423f862021420188842220842021423f862023420188842223202242018822228484500d01202941d8056a2024370300202941b8056a2024370300202920263703c005202920263703a005202920273703c805202920273703a805202920253703d005202920253703b005202941a0056a202941c0056a202941e0056a41081015202941f8056a2903002124202941f0056a2903002125202941e8056a290300212720292903e005212620202121450d000b000b202941b8036a204e370300202941d8036a4200370300202941f8036a204e370300202920513703a0032029204f3703a803202920503703b003202942003703d003202942003703c803202920523703c003202920513703e0032029204f3703e803202920503703f003202941c0036a202941e0036a20294180046a202941a0046a1018450d0f000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b202820292903a004370300202841186a202941b8046a2903003703002028202941b0046a2903003703102028202941a8046a29030037030820294180066a240041000bc5b70402a8017f1d7e230041406a220824000240024002400240024002400240024002400240027f0240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200041034d0d0041900541a0052802002205360200024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200541e3b1acc9004c0440200541a88bf0dc7b4c0440200541eac5aff3794c0440200541f1fb8fdf784c0440200541abe596bb78460d1a200541dfb49bcc78470d642001200284500d1c000b200541f2fb8fdf78460d0e200541c6cf86b479470d632001200284500d34000b20054188bc9d9d7b4c0440200541ebc5aff379460d13200541f1a0e1b07a470d632001200284500d0d000b20054189bc9d9d7b460d07200541dcaeeada7b470d622001200284500d0a000b200541a2f0caeb7d4c0440200541a3af89be7d4c0440200541a98bf0dc7b460d0720054198f492a17c470d632001200284500d3c000b200541a4af89be7d460d0920054198acb4e87d470d622001200284500d05000b200541edfcc56c4c0440200541a3f0caeb7d460d08200541a08795927f470d622001200284500d38000b200541eefcc56c460d1820054186fafb1e460d01200541caf1872e470d612001200284500d35000b200541f78faa87044c0440200541b5ebfeaa024c0440200541b7aabbf9004c0440200541e4b1acc900460d14200541ee9faaf300470d632001200284500d38000b200541b8aabbf900460d0f200541bed6ddb501470d62200041046b220620004b0d14200641e000490d1541c3052d0000210c41c2052d0000210941c1052d0000210b41c0052d0000212141bf052d0000211041be052d0000210d41bd052d0000212241bc052d0000212341bb052d0000210a41ba052d0000210e41b9052d0000210f41b8052d0000211141b7052d0000211241b6052d0000211341b5052d0000211441b4052d0000211541b3052d0000211641b2052d0000211741b1052d0000211841b0052d0000211941af052d0000211a41ae052d0000211b41ad052d0000211c41ac052d0000211d41ab052d0000211e41aa052d0000211f41a9052d0000212041a8052d0000212441a7052d0000212541a6052d0000212641a5052d0000212841a4052d0000212a41e3052d0000212b41e2052d0000212d41e1052d0000212941e0052d0000212741df052d0000212c41de052d0000212e41dd052d0000213041dc052d0000212f41db052d0000213641da052d0000213741d9052d0000213841d8052d0000213241d7052d0000213141d6052d0000213341d5052d0000213441d4052d0000213941d3052d0000213a41d2052d0000213b41d1052d0000213c41d0052d0000213d41cf052d0000213e41ce052d0000213f41cd052d0000214041cc052d0000214141cb052d0000214241ca052d0000214341c9052d0000214441c8052d0000214641c7052d0000214541c6052d0000213541c5052d0000214741c4052d000021484183062d0000214b4182062d0000214c4181062d000021494180062d0000214d41ff052d0000214a41fe052d0000214e41fd052d0000214f41fc052d0000215041fb052d0000215141fa052d0000215241f9052d0000215341f8052d0000215441f7052d0000215541f6052d0000215641f5052d0000215741f4052d0000215841f3052d0000215941f2052d0000215a41f1052d0000215b41f0052d0000215c41ef052d0000215d41ee052d0000215e41ed052d0000215f41ec052d0000216041eb052d0000216141ea052d0000216241e9052d0000216341e8052d0000216441e7052d0000216741e6052d0000216841e5052d0000216941e4052d0000216a4184062d000022004103710e034243442b0b200541d7ebd4af034c0440200541b6ebfeaa02460d16200541f0c08a8c03470d622001200284500d1c000b200541d8ebd4af03460d16200541ddc5b5f703470d612001200284500d1e000b200541cf9c8598054c0440200541cb89dcaa044c0440200541f88faa8704460d1120054195b1ef8c04470d622001200284500d03000b200541cc89dcaa04460d0f200541b9a0cd8c05470d612001200284500d23000b2005418ccbaede054c0440200541d09c859805460d1a200541b9a9f1be05470d612001200284500d0d000b2005418dcbaede05460d09200541b1f894bf06460d02200541c4b4f88107470d602001200284500d2e000b20012002844200520d7c200841106b2200240041980541808002360200200841386a42003703002008420037033020084200370328200842063703202000200841206a412041a0054198051003047f410005419805280200410141a00510110b36020020002802002205280200410020051b41ffffffff034d0d39000b200841106b2200240041980541808002360200200841386a42003703002008420037033020084200370328200842073703202000200841206a412041a0054198051003047f410005419805280200410141a00510110b36020020002802002205280200410020051b41ffffffff034d0d39000b20012002844200520d79200841106b22002400200041123a000020002d0000210541014101417f101141086a220020053a00000c80010b200841206b220524004198054120360200200841386a42003703002008420037033020084200370328200842053703200c80010b20012002844200520d762000200041046b2205490d16200541c000490d17200541c0004d0d37000b20012002844200520d742000200041046b2205490d18200541c000490d19200541c0004d0d37000b20012002844200520d722000200041046b2205490d19200541e000490d1a200541e0004d0d37000b20012002844200520d702000200041046b2205490d1b200541c000490d1c200541c0004d0d44000b200841106b220524004198054101360200200841386a42003703002008420037033020084200370328200842023703202005200841206a412041a0054198051003047f41000541a0052d00000b4101713a00000c770b20012002844200520d6d200841206b220524004198054120360200200841386a42003703002008420037033020084200370328200842003703200c7b0b0240101f22050d00410021054100210041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100102022030440200321000b2000450d00200021050b20050d81010c7b0b20012002844200520d6a2000200041046b2205490d1920054120490d1a200541204d0d33000b200841206b220524004198054120360200200841386a42003703002008420037033020084200370328200842093703200c770b20012002844200520d67200841206b220524004198054120360200200841386a42003703002008420037033020084200370328200842083703200c770b20012002844200520d652000200041046b2205490d1820054120490d19200541204d0d3e000b20012002844200520d63200841206b220524004198054120360200200841386a420037030020084200370330200842003703282008420c3703200c750b20012002844200520d61200841206b220524004198054120360200200841386a420037030020084200370330200842003703282008420d3703200c740b20012002844200520d5f200841206b220524004198054120360200200841386a420037030020084200370330200842003703282008420e3703200c720b000b000b20012002844200520d5b2000200041046b2205490d1520054120490d16200541204d0d39000b20012002844200520d592000200041046b2205490d1620054120490d17200541204d0d2d000b20012002844200520d572000200041046b2205490d18200541c000490d19200541c0004d0d2d000b20012002844200520d552000200041046b2205490d1a200541e000490d1b200541e0004d0d38000b200841206b220524004198054120360200200841386a420037030020084200370330200842003703282008420f3703200c6b0b20012002844200520d522000200041046b2205490d1d20054120490d1e200541204d0d39000b2000200041046b2205490d46200541204f0440200541204d0d2c000b000b000b000b2000200041046b2205490d44200541c0004f0440200541c0004d0d2b000b000b000b000b000b000b2000200041046b2205490d40200541c0004f0440200541c0004d0d29000b000b000b000b000b000b000b000b000b000b000b000b000b2000200041046b2205490d35200541c0004f0440200541c0004d0d21000b000b000b000b2000200041046b2205490d33200541c0004f0440200541c0004d0d14000b000b000b000b2000200041046b2205490d31200541e0004f0440200541e0004d0d1d000b000b200841206b22002400200041206b22052400027f230041d0006b220324004198054120360200200341206a420037030020034200370318200342003703102003420a370308200341086a412041a0054198051003047e42000541b00529030021ac0141a80529030021b00141a00529030021b40141b8052903000b2101200341206b220422072400200441186a420037030020044200370310200442003703082004420837030041980541203602002004412041a0054198051003210441a0052d0000210c41a1052d0000210941a2052d0000210b41a3052d0000212141a4052d0000211041a5052d0000210d41a6052d0000212241a7052d0000212341a8052d0000210a41a9052d0000210e41aa052d0000210f41ab052d0000211141ac052d0000211241ad052d0000211341ae052d0000211441af052d0000211541b0052d0000211641b1052d0000211741b2052d0000211841b3052d0000211941b4052d0000211a41b5052d0000211b41b6052d0000211c41b7052d0000211d41b8052d0000211e41b9052d0000211f41ba052d0000212041bb052d0000212441bc052d0000212541bd052d0000212641be052d0000212841bf052d0000212a41244101417f10112106200341b18482850736022c2003412c6a200641086a222b41041010419805412036020041a005419805100941a005290300210241a80529030021ae0141b00529030021ab01200641246a41b8052903003700002006411c6a20ab01370000200641146a20ae013700002006410c6a200237000020034100202a20041b3a004f20034100202820041b3a004e20034100202620041b3a004d20034100202520041b3a004c20034100202420041b3a004b20034100202020041b3a004a20034100201f20041b3a004920034100201e20041b3a004820034100201d20041b3a004720034100201c20041b3a004620034100201b20041b3a004520034100201a20041b3a004420034100201920041b3a004320034100201820041b3a004220034100201720041b3a004120034100201620041b3a004020034100201520041b3a003f20034100201420041b3a003e20034100201320041b3a003d20034100201220041b3a003c20034100201120041b3a003b20034100200f20041b3a003a20034100200e20041b3a003920034100200a20041b3a003820034100202320041b3a003720034100202220041b3a003620034100200d20041b3a003520034100201020041b3a003420034100202120041b3a003320034100200b20041b3a003220034100200920041b3a003120034100200c20041b3a00302006280200210c200741106b22042400200442003703082004420037030041980541808002360200024002404100200341306a42002004202b200c410020061b41a0054198051008450440419805280200410141a00510112204280200410020041b2206411f4d0d01419805280200410141a00510112104200641204b0d02200441206a2903002102200441186a29030021ae01200441106a29030021ab012000200441086a290300370300200020ab01370308200020ae01370310200041186a2002370300200520ac01370310200541186a2001370300200520b401370300200520b001370308200341d0006a240041000c030b000b000b000b0d560c510b2000200041046b2205490d30200541204f0440200541204d0d1c000b000b000b000b200841206b22052400027f230041e0016b220024004198054120360200200041c8006a4200370300200042003703402000420037033820004208370330200041306a412041a0054198051003210441a0052d0000212841a1052d0000212641a2052d0000212541a3052d0000212441a4052d0000212041a5052d0000211f41a6052d0000211e41a7052d0000211d41a8052d0000211c41a9052d0000211b41aa052d0000211a41ab052d0000211941ac052d0000211841ad052d0000211741ae052d0000211641af052d0000211541b0052d0000211441b1052d0000211341b2052d0000211241b3052d0000211141b4052d0000210f41b5052d0000210e41b6052d0000210a41b7052d0000212341b8052d0000212241b9052d0000210d41ba052d0000211041bb052d0000212141bc052d0000210b41bd052d0000210941be052d0000210c41bf052d00002107200041286a4200370300419805412036020020004200370320200042003703182000420c370310200041106a412041a0054198051003210641a0052d0000212a41a1052d0000212b41a2052d0000212d41a3052d0000212941a4052d0000212741a5052d0000212c41a6052d0000212e41a7052d0000213041a8052d0000212f41a9052d0000213641aa052d0000213741ab052d0000213841ac052d0000213241ad052d0000213141ae052d0000213341af052d0000213441b0052d0000213941b1052d0000213a41b2052d0000213b41b3052d0000213c41b4052d0000213d41b5052d0000213e41b6052d0000213f41b7052d0000214041b8052d0000214141b9052d0000214241ba052d0000214341bb052d0000214441bc052d0000214641bd052d0000214541be052d0000213541bf052d0000214741244101417f10112103200041b2e0d8c003360250200041d0006a200341086a2248410410102003412b6a4100200720041b22073a00002003412a6a4100200c20041b220c3a0000200341296a4100200920041b22093a0000200341286a4100200b20041b220b3a0000200341276a4100202120041b22213a0000200341266a4100201020041b22103a0000200341256a4100200d20041b220d3a0000200341246a4100202220041b22223a0000200341236a4100202320041b22233a0000200341226a4100200a20041b220a3a0000200341216a4100200e20041b220e3a0000200341206a4100200f20041b220f3a00002003411f6a4100201120041b22113a00002003411e6a4100201220041b22123a00002003411d6a4100201320041b22133a00002003411c6a4100201420041b22143a00002003411b6a4100201520041b22153a00002003411a6a4100201620041b22163a0000200341196a4100201720041b22173a0000200341186a4100201820041b22183a0000200341176a4100201920041b22193a0000200341166a4100201a20041b221a3a0000200341156a4100201b20041b221b3a0000200341146a4100201c20041b221c3a0000200341136a4100201d20041b221d3a0000200341126a4100201e20041b221e3a0000200341116a4100201f20041b221f3a0000200341106a4100202020041b22203a00002003410f6a4100202420041b22243a00002003410e6a4100202520041b22253a00002003410d6a4100202620041b22263a00002003410c6a4100202820041b22283a000020004100204720061b3a007320004100203520061b3a007220004100204520061b3a007120004100204620061b3a007020004100204420061b3a006f20004100204320061b3a006e20004100204220061b3a006d20004100204120061b3a006c20004100204020061b3a006b20004100203f20061b3a006a20004100203e20061b3a006920004100203d20061b3a006820004100203c20061b3a006720004100203b20061b3a006620004100203a20061b3a006520004100203920061b3a006420004100203420061b3a006320004100203320061b3a006220004100203120061b3a006120004100203220061b3a006020004100203820061b3a005f20004100203720061b3a005e20004100203620061b3a005d20004100202f20061b3a005c20004100203020061b3a005b20004100202e20061b3a005a20004100202c20061b3a005920004100202720061b3a005820004100202920061b3a005720004100202d20061b3a005620004100202b20061b3a005520004100202a20061b3a00542003280200210441980541808002360200200042003703082000420037030002400240024002400240024002400240024002400240024002400240024002400240024002404100200041d4006a4200200020482004410020031b41a0054198051008450440419805280200410141a00510112203280200410020031b2204411f4d0d01419805280200410141a00510112103200441204b0d02200341276a2d00002104200341266a2d00002106200341256a2d0000212a200341246a2d0000212b200341236a2d0000212d200341226a2d00002129200341216a2d00002127200341206a2d0000212c2003411f6a2d0000212e2003411e6a2d000021302003411d6a2d0000212f2003411c6a2d000021362003411b6a2d000021372003411a6a2d00002138200341196a2d00002132200341186a2d00002131200341176a2d00002133200341166a2d00002134200341156a2d00002139200341146a2d0000213a200341136a2d0000213b200341126a2d0000213c200341116a2d0000213d200341106a2d0000213e2003410f6a2d0000213f2003410e6a2d000021402003410d6a2d000021412003410c6a2d000021422003410b6a2d000021432003410a6a2d00002144200341096a2d00002146200341086a2d0000214541244101417f1011210320004187dee59a7b360274200041f4006a200341086a2235410410102003410f6a20243a00002003410e6a20253a00002003410d6a20263a00002003410c6a20283a0000200341106a20203a0000200341116a201f3a0000200341126a201e3a0000200341136a201d3a0000200341146a201c3a0000200341156a201b3a0000200341166a201a3a0000200341176a20193a0000200341186a20183a0000200341196a20173a00002003411a6a20163a00002003411b6a20153a00002003411c6a20143a00002003411d6a20133a00002003411e6a20123a00002003411f6a20113a0000200341206a200f3a0000200341216a200e3a0000200341226a200a3a0000200341236a20233a0000200341246a20223a0000200341256a200d3a0000200341266a20103a0000200341276a20213a0000200341286a200b3a0000200341296a20093a00002003412a6a200c3a00002003412b6a20073a0000200020043a009701200020063a0096012000202a3a0095012000202b3a0094012000202d3a009301200020293a009201200020273a0091012000202c3a0090012000202e3a008f01200020303a008e012000202f3a008d01200020363a008c01200020373a008b01200020383a008a01200020323a008901200020313a008801200020333a008701200020343a008601200020393a0085012000203a3a0084012000203b3a0083012000203c3a0082012000203d3a0081012000203e3a0080012000203f3a007f200020403a007e200020413a007d200020423a007c200020433a007b200020443a007a200020463a0079200020453a007820032802002106200041106b220424002004420037030820044200370300419805418080023602004100200041f8006a4200200420352006410020031b41a00541980510080d03419805280200410141a00510112203280200410020031b2206411f4d0d04419805280200410141a00510112103200641204b0d05200341206a29030021b701200341186a29030021b901200341106a29030021b601200341086a29030021ba0141244101417f10112103200041b1848285073602980120004198016a200341086a220641041010419805412036020041a005419805100941a005290300210141a805290300210241b00529030021ab01200341246a41b8052903003700002003411c6a20ab01370000200341146a20023700002003410c6a20013700002000201d3a00a3012000201e3a00a2012000201f3a00a101200020203a00a001200020243a009f01200020253a009e01200020263a009d01200020283a009c012000201c3a00a4012000201b3a00a5012000201a3a00a601200020193a00a701200020183a00a801200020173a00a901200020163a00aa01200020153a00ab01200020143a00ac01200020133a00ad01200020123a00ae01200020113a00af012000200f3a00b0012000200e3a00b1012000200a3a00b201200020233a00b301200020223a00b4012000200d3a00b501200020103a00b601200020213a00b7012000200b3a00b801200020093a00b9012000200c3a00ba01200020073a00bb0120032802002107200441106b2204240020044200370308200442003703004198054180800236020041002000419c016a4200200420062007410020031b41a00541980510080d06419805280200410141a00510112203280200410020031b2203411f4d0d07419805280200410141a00510112107200341204b0d08200741206a2903002101200441206b22032206240020014200530d09200741186a2903002102200741106a29030021ab012003200741086a290300370300200320ab0137030820032002370310200341186a2204200137030020b90120ba018420b60120b7018484500d0a20042903002101200341106a29030021b501200341086a29030021ad01200329030021b401024003400240200641206b22032400420021ab01200341186a420037030020034200370310200342003703082003420f3703004198054120360200027e2003412041a00541980510030440420021b101420021b30142000c010b41b80529030021b30141b00529030021b10141a00529030021ab0141a8052903000b2102024020ab0120ac0158200220af0158200220af01511b20ae0120b1015a20b00120b3015a20b00120b301511b20ae0120b1018520b00120b3018584501b22044504402004450d01000b420021af01027e20b40142005220ad0142005220ad01501b20b50142005220014200552001501b200120b50184501b450440420021b001420021ac0142000c010b200341206b2203240020014200530d10200320b401370300200320ad01370308200320b501370310200341186a22042001370300200429030021ac01200341106a29030021b001200329030021af01200341086a2903000b2101200520af0137030020052001370308200520b001370310200541186a20ac013703000c170b200341206b220322062400200320ac0142cba3aeadf7999885177c22023703004198054120360200200320af01200220ac01542204ad7c4290c6e394d983bda0197c2202370308200320ae0142bda89192cdcbb4f6367c22ab012004200220af0154200220af01511bad7c2202370310200341186a200220ab0154ad20b00120ab0120ae0154ad7c7c42d19ed8fc8880b0c4f9007c3703002003412041a0054198051003210341a0052d0000210741a1052d0000210c41a2052d0000210941a3052d0000210b41a4052d0000212141a5052d0000211041a6052d0000210d41a7052d0000212241a8052d0000212341a9052d0000210a41aa052d0000210e41ab052d0000210f41ac052d0000211141ad052d0000211241ae052d0000211341af052d0000211441b0052d0000211541b1052d0000211641b2052d0000211741b3052d0000211841b4052d0000211941b5052d0000211a41b6052d0000211b41b7052d0000211c41b8052d0000211d41b9052d0000211e41ba052d0000211f41bb052d0000212041bc052d0000212441bd052d0000212541be052d0000212641bf052d0000212841044101417f101121042000418fdcd4c6033602bc01200041bc016a200441086a222a4104101020004100202820031b22283a00df0120004100202620031b22263a00de0120004100202520031b22253a00dd0120004100202420031b22243a00dc0120004100202020031b22203a00db0120004100201f20031b221f3a00da0120004100201e20031b221e3a00d90120004100201d20031b221d3a00d80120004100201c20031b221c3a00d70120004100201b20031b221b3a00d60120004100201a20031b221a3a00d50120004100201920031b22193a00d40120004100201820031b22183a00d30120004100201720031b22173a00d20120004100201620031b22163a00d10120004100201520031b22153a00d00120004100201420031b22143a00cf0120004100201320031b22133a00ce0120004100201220031b22123a00cd0120004100201120031b22113a00cc0120004100200f20031b220f3a00cb0120004100200e20031b220e3a00ca0120004100200a20031b220a3a00c90120004100202320031b22233a00c80120004100202220031b22223a00c70120004100200d20031b220d3a00c60120004100201020031b22103a00c50120004100202120031b22213a00c40120004100200b20031b220b3a00c30120004100200920031b22093a00c20120004100200c20031b220c3a00c10120004100200720031b22073a00c0012004280200212b200641106b2203220624002003420037030820034200370300419805418080023602004100200041c0016a42002003202a202b410020041b41a00541980510080d13419805280200410141a00510112203280200410020031b2204411f4d0440000b419805280200410141a00510112103200441204b0d150240200341276a2d0000222a200341086a2d0000222b2003410a6a2d0000222d200341096a2d0000222972722003410c6a2d000022272003410b6a2d0000222c722003410e6a2d0000222e2003410d6a2d00002230727272200341106a2d0000222f2003410f6a2d0000223672200341126a2d00002237200341116a2d000022387272200341146a2d00002232200341136a2d0000223172200341166a2d00002233200341156a2d0000223472727272200341186a2d00002239200341176a2d0000223a722003411a6a2d0000223b200341196a2d0000223c72722003411c6a2d0000223d2003411b6a2d0000223e722003411e6a2d0000223f2003411d6a2d00002240727272200341206a2d000022412003411f6a2d0000224272200341226a2d00002243200341216a2d000022447272200341246a2d00002246200341236a2d0000224572200341266a2d00002235200341256a2d00002247727272727272450d00200641206b22042400230041406a2203240041044101417f101121062003418ed4bdf47e36021c2003411c6a200641086a224841041010200320283a003f200320263a003e200320253a003d200320243a003c200320203a003b2003201f3a003a2003201e3a00392003201d3a00382003201c3a00372003201b3a00362003201a3a0035200320193a0034200320183a0033200320173a0032200320163a0031200320153a0030200320143a002f200320133a002e200320123a002d200320113a002c2003200f3a002b2003200e3a002a2003200a3a0029200320233a0028200320223a00272003200d3a0026200320103a0025200320213a00242003200b3a0023200320093a00222003200c3a0021200320073a002020062802002107419805418080023602002003420037031020034200370308024002400240024002404100200341206a4200200341086a20482007410020061b41a0054198051008450440419805280200410141a00510112206280200410020061b220c413f4d0d01419805280200410141a0051011220641206a2903002102200641186a29030021ab01200641106a29030021b101200641086a29030021b301419805280200410141a00510112107200c41c0004b0d02200341206b2206240020024200530d03200741406b29030021b201200741386a29030021b801200741306a29030021bb01200741286a29030021bd01200620b301370300200620b101370308200620ab01370310200641186a220c2002370300200641206b2207240020b2014200530d04200c2903002102200641106a29030021b101200641086a29030021ab01200629030021b301200720bd01370300200720bb01370308200720b801370310200741186a220620b2013703002002200629030022b201852002200220b2017d20b101200741106a29030022b20154ad7d20b10120b2017d22b10120b301200729030022b80154220620ab01200741086a29030022b2015420ab0120b201511bad22bb0154ad7d22bd0185834200590d05000b000b000b000b000b000b200420b30120b8017d370300200420ab0120b2017d2006ad7d370308200420b10120bb017d370310200441186a220620bd01370300200341406b2400200441106a29030021ab01200441086a29030021b201200429030021b1010240200629030022b301420053220645044020ab0121020c010b420020ab017d22b80120b101420052220320b20142005220b201501bad22bb017d2102420020b80120bb0154ad20b30120ab01420052ad7c7c7d21b301420020b1017d21b101420020b2012003ad7c7d21b2010b200441206b2203240020b3014200530d10200320b101370300200320b20137030820032002370310200341186a220420b30137030020042903002102200341106a29030021ab01200341086a29030021b201200329030021b101200341206b22032400202b2029202d202c20272030202e2036202f203820372031203220342033203a2039203c203b203e203d2040203f20422041204420432045204620472035202a20b10120b20120ab01200220ba0120b60120b90120b7012003102522040d11200341186a2903002102200341106a29030021ab01200341086a29030021b201200329030021b10120060440200341206b22032206240020024200530d13200320b101370300200320b201370308200320ab01370310200341186a22042002370300200120042903002202852001200120027d20b501200341106a290300220254ad7d20b50120027d22b20120b401200329030022b10154220420ad01200341086a29030022ab015420ab0120ad01511bad22b50154ad7d220285834200530d0220b20120b5017d21b50120ad0120ab017d2004ad7d21ad0120b40120b1017d21b401200221010c010b200341206b22032206240020024200530d13200320b101370300200320b201370308200320ab01370310200341186a2204200237030020012004290300220285427f85200120b501200341106a2903007c22ab0120b50154ad200120027c7c20ab0120b40120b40120032903007c22b4015622042004ad20ad01200341086a2903007c7c220220ad0154200220ad01511bad7c22b50120ab0154ad7c22ab0185834200530d03200221ad0120ab0121010b20ae0120ac0142017c220220ac0154220320af0120af012003ad7c22af0156200220ac015a1b2203ad7c22ab0120ae0154220420b00120b0012004ad7c22b0015620ab0120ae015a1b200320031b0d14200221ac0120ab0121ae010c010b0b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b200041e0016a240020040c060b000b000b000b000b000b200041e0016a240041000b450d450c520b027f41012005280200410020051b413f4d0d001a41042005280200410020051b41ffff004b0d001a41020b220020002005280200410020051b6a22034b0d1920034101417f101121062005280200410020051b220341ffffffff034d0d1b000b027f41012005280200410020051b413f4d0d001a41042005280200410020051b41ffff004b0d001a41020b220020002005280200410020051b6a22034b0d1920034101417f101121062005280200410020051b220341ffffffff034d0d1b000b41c3052d0000210541c2052d0000210341c1052d0000210441c0052d0000210641bf052d0000210741be052d0000210c41bd052d0000210941bc052d0000210b41bb052d0000212141ba052d0000211041b9052d0000210d41b8052d0000212241b7052d0000212341b6052d0000210a41b5052d0000210e41b4052d0000210f41b3052d0000211141b2052d0000211241b1052d0000211341b0052d0000211441af052d0000211541ae052d0000211641ad052d0000211741ac052d0000211841ab052d0000211941aa052d0000211a41a9052d0000211b41a8052d0000211c41a7052d0000211d41a6052d0000211e41a5052d0000211f41a4052d0000212041c405290300210141dc05290300210241d40529030021ae0141cc0529030021ab01200841106b22002400419805412036020041a0054198051004200841b80529030022ac01370018200841b00529030022ad01370010200841a80529030022af01370008200841a00529030022b00137000020b001a720082d000120082d000220082d000320082d000420082d000520082d000620082d000720af01a720082d000920082d000a20082d000b20082d000c20082d000d20082d000e20082d000f20ad01a720082d001120082d001220082d001320082d001420082d001520082d001620082d001720ac01a720082d001920082d001a20082d001b20082d001c20082d001d20082d001e20082d001f2020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c20072006200420032005200120ab0120ae012002101c22050d0a200041013a00000c440b41c3052d0000210541c2052d0000210341c1052d0000210441c0052d0000210641bf052d0000210741be052d0000210c41bd052d0000210941bc052d0000210b41bb052d0000212141ba052d0000211041b9052d0000210d41b8052d0000212241b7052d0000212341b6052d0000210a41b5052d0000210e41b4052d0000210f41b3052d0000211141b2052d0000211241b1052d0000211341b0052d0000211441af052d0000211541ae052d0000211641ad052d0000211741ac052d0000211841ab052d0000211941aa052d0000211a41a9052d0000211b41a8052d0000211c41a7052d0000211d41a6052d0000211e41a5052d0000211f41a4052d0000212041c405290300210141dc05290300210241d40529030021ae0141cc0529030021ab01200841106b22002400419805412036020041a0054198051004200841b80529030022ac01370018200841b00529030022ad01370010200841a80529030022af01370008200841a00529030022b00137000020b001a720082d000120082d000220082d000320082d000420082d000520082d000620082d000720af01a720082d000920082d000a20082d000b20082d000c20082d000d20082d000e20082d000f20ad01a720082d001120082d001220082d001320082d001420082d001520082d001620082d001720ac01a720082d001920082d001a20082d001b20082d001c20082d001d20082d001e20082d001f2020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c20072006200420032005200120ab0120ae012002101b22050d0b200041013a00000c430b41c3052d0000210041c2052d0000210341c1052d0000210441c0052d0000210641bf052d0000210741be052d0000210c41bd052d0000210941bc052d0000210b41bb052d0000212141ba052d0000211041b9052d0000210d41b8052d0000212241b7052d0000212341b6052d0000210a41b5052d0000210e41b4052d0000210f41b3052d0000211141b2052d0000211241b1052d0000211341b0052d0000211441af052d0000211541ae052d0000211641ad052d0000211741ac052d0000211841ab052d0000211941aa052d0000211a41a9052d0000211b41a8052d0000211c41a7052d0000211d41a6052d0000211e41a5052d0000211f41a4052d0000212041e3052d0000212541e2052d0000212641e1052d0000212841e0052d0000212a41df052d0000212b41de052d0000212d41dd052d0000212941dc052d0000212741db052d0000212c41da052d0000212e41d9052d0000213041d8052d0000212f41d7052d0000213641d6052d0000213741d5052d0000213841d4052d0000213241d3052d0000213141d2052d0000213341d1052d0000213441d0052d0000213941cf052d0000213a41ce052d0000213b41cd052d0000213c41cc052d0000213d41cb052d0000213e41ca052d0000213f41c9052d0000214041c8052d0000214141c7052d0000214241c6052d0000214341c5052d0000214441c4052d0000214641e40529030021ab0141fc05290300210141f405290300210241ec0529030021ae01200841106b22242400419805412036020041a0054198051004200841b80529030022ac01370018200841b00529030022ad01370010200841a80529030022af01370008200841a00529030022b00137000002402020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c2007200620042003200020b001a7224520082d0001223520082d0002224720082d0003224820082d0004224b20082d0005224c20082d0006224920082d0007224d20af01a7224a20082d0009224e20082d000a224f20082d000b225020082d000c225120082d000d225220082d000e225320082d000f225420ad01a7225520082d0011225620082d0012225720082d0013225820082d0014225920082d0015225a20082d0016225b20082d0017225c20ac01a7225d20082d0019225e20082d001a225f20082d001b226020082d001c226120082d001d226220082d001e226320082d001f2264200841206a101a22050d00200829032022b001200841306a29030022ac0183200841286a29030022ad01200841386a29030022af018383427f52044020ab0120b0015820ad0120ae015a20ad0120ae015122051b200220ac0158200120af0158200120af01511b200220ac0185200120af018584501b450d2c2020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c200720062004200320002045203520472048204b204c2049204d204a204e204f2050205120522053205420552056205720582059205a205b205c205d205e205f2060206120622063206420b00120ab017d20ad0120ae017d20ab0120b001562245ad7d20ac0120027d22b001204520ad0120ae015420051bad22ad017d20af0120017d200220ac0156ad7d20ad0120b00156ad7d101b22050d010b410021050b20050d0b2020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c20072006200420032000204620442043204220412040203f203e203d203c203b203a20392034203320312032203820372036202f2030202e202c20272029202d202b202a20282026202520ab0120ae0120022001101c2200047f200005202441013a000041000b0d4d0c2c0b41c3052d0000210341c2052d0000210441c1052d0000210641c0052d0000210741bf052d0000210c41be052d0000210941bd052d0000210b41bc052d0000212141bb052d0000211041ba052d0000210d41b9052d0000212241b8052d0000212341b7052d0000210a41b6052d0000210e41b5052d0000210f41b4052d0000211141b3052d0000211241b2052d0000211341b1052d0000211441b0052d0000211541af052d0000211641ae052d0000211741ad052d0000211841ac052d0000211941ab052d0000211a41aa052d0000211b41a9052d0000211c41a8052d0000211d41a7052d0000211e41a6052d0000211f41a5052d0000212041a4052d000021240240101f22050d0020032020202472201f72201e72201d72201c72201b72201a72201972201872201772201672201572201472201372201272201172200f72200e72200a72202372202272200d72201072202172200b72200972200c7220077220067220047272450d29410021054100210020242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c2007200620042003102022030440200321000b2000450d00200021050b20050d4c0c460b20004102762100410121040c290b410221044184062f010041027621000c280b4184062802004102762100410421040c270b41bc05290300210141b405290300210241ac0529030021ae0141a40529030021ab01101f2200047f200005200841186a4200370300200841386a2001370300200820ab01370320200820ae013703282008420037031020084200370308200842093703002008200237033020084120200841206a412010011a41000b0d480c420b41c3052d0000210441c2052d0000210741c1052d0000210c41c0052d0000210941bf052d0000210b41be052d0000212141bd052d0000211041bc052d0000210d41bb052d0000212241ba052d0000212341b9052d0000210a41b8052d0000210e41b7052d0000210f41b6052d0000211141b5052d0000211241b4052d0000211341b3052d0000211441b2052d0000211541b1052d0000211641b0052d0000211741af052d0000211841ae052d0000211941ad052d0000211a41ac052d0000211b41ab052d0000211c41aa052d0000211d41a9052d0000211e41a8052d0000211f41a7052d0000212041a6052d0000212441a5052d0000212541a4052d0000212641c40529030021b50141dc0529030021b40141d40529030021b70141cc0529030021b9010240101f22050d00027f230041d0006b22062100200624000240024002400240024002400240027e0340200641206b22052400200541186a420037030020054200370310200542003703082005420f3703004198054120360200027e2005412041a0054198051003044042002102420021b101420021b20142000c010b41b00529030021b20141a80529030021b10141a005290300210241b8052903000b21010240027e0240200220ab015820ac0120b1015a20ac0120b101511b20ae0120b2015a200120af0158200120af01511b20ae0120b20185200120af018584501b450440200541206b2205240042002102200541186a420037030020054200370310200542003703082005420f37030041980541203602002005412041a0054198051003450d01420021b101420021b20142000c020b200541206b22052400200541186a420037030020054200370310200542003703082005420f37030041980541203602002005412041a0054198051003450d02420021ae01420021ac0142000c040b41b00529030021b20141a80529030021b10141a005290300210241b8052903000b2101200220ab015620ac0120b1015420ac0120b101511b20ae0120b20154200120af0156200120af01511b20ae0120b20185200120af018584501b450d06200541206b22052400200541186a420037030020054200370310200542003703082005420f370300200541206b22032400200541202003100220032903002102200341086a2903002101200341186a29030021b201200341106a29030021ad01200341206b22052206240020052002200220ab017c22b001562203ad200120ac017c7c2202370308200520b0013703004198054120360200200520ad0120ae017c22b0012003200120025620012002511bad7c2201370310200541186a200120b00154ad20ad0120b00156ad20af0120b2017c7c7c3703002005412041a00541980510032105410041a0052d000020051b41ff0171202646410041a1052d000020051b41ff017120254671410041a2052d000020051b41ff017120244671410041a3052d000020051b41ff017120204671201f410041a4052d000020051b41ff01714671201e410041a5052d000020051b41ff01714671201d410041a6052d000020051b41ff01714671410041a7052d000020051b41ff0171201c4671201b410041a8052d000020051b41ff01714671201a410041a9052d000020051b41ff017146712019410041aa052d000020051b41ff017146712018410041ab052d000020051b41ff017146712017410041ac052d000020051b41ff017146712016410041ad052d000020051b41ff017146712015410041ae052d000020051b41ff01714671410041af052d000020051b41ff0171201446712013410041b0052d000020051b41ff017146712012410041b1052d000020051b41ff017146712011410041b2052d000020051b41ff01714671200f410041b3052d000020051b41ff01714671200e410041b4052d000020051b41ff01714671200a410041b5052d000020051b41ff017146712023410041b6052d000020051b41ff01714671410041b7052d000020051b41ff017120224671200d410041b8052d000020051b41ff017146712010410041b9052d000020051b41ff017146712021410041ba052d000020051b41ff01714671200b410041bb052d000020051b41ff017146712009410041bc052d000020051b41ff01714671200c410041bd052d000020051b41ff017146712007410041be052d000020051b41ff01714671410041bf052d000020051b41ff0171200446710d0320ae0120ab0142017c220120ab0154220520ac0120ac012005ad7c22ac0156200120ab015a1b2205ad7c220220ae0154220320af0120af012003ad7c22af0156200220ae015a1b200520051b0d05200121ab01200221ae010c010b0b41b80529030021b30141b00529030021ac0141a80529030021ae0141a0052903000b2101200541206b22052400200541186a420037030020054200370310200542003703082005420f370300200541206b220324002005412020031002200341186a29030021b001200341106a29030021ab01200341086a2903002102200329030021ad01200341206b220322052400200541206b22052400200520233a00162005200a3a00152005200e3a00142005200f3a0013200520113a0012200520123a0011200520133a0010200520143a000f200520153a000e200520163a000d200520173a000c200520183a000b200520193a000a2005201a3a00092005201b3a00082005201c3a00072005201d3a00062005201e3a00052005201f3a0004200520203a0003200520243a0002200520253a0001200520263a0000200520223a00172005200d3a0018200520103a0019200520213a001a2005200b3a001b200520093a001c2005200c3a001d200520073a001e200520043a001f200341186a20ab0120ab0120ac017c22af0156ad20b00120b3017c7c20af0120ad01200120ad017c22b0015622062006ad200220ae017c7c22ab01200254200220ab01511bad7c220220af0154ad7c37030020032002370310200320ab01370308200320b001370300200341202005412010011a200541206b22052400200541186a420037030020054200370310200542003703082005420f3703002000200142017c2202370308200020ae0120012002562203ad7c22ab01370310200020ac01200320ab0120ae015420012002581bad7c2201370318200041206a20b301200120ac0154ad7c37030020054120200041086a412010011a200541406a22052400200541186a4200370300200542003703102005420037030820054211370300200541206a20263a0000200541216a20253a0000200541226a20243a0000200541236a20203a0000200541246a201f3a0000200541256a201e3a0000200541266a201d3a0000200541276a201c3a0000200541286a201b3a0000200541296a201a3a00002005412a6a20193a00002005412b6a20183a00002005412c6a20173a00002005412d6a20163a00002005412e6a20153a00002005412f6a20143a0000200541306a20133a0000200541316a20123a0000200541326a20113a0000200541336a200f3a0000200541346a200e3a0000200541356a200a3a0000200541366a20233a0000200541376a20223a0000200541386a200d3a0000200541396a20103a00002005413a6a20213a00002005413b6a200b3a00002005413c6a20093a00002005413d6a200c3a00002005413e6a20073a00002005413f6a20043a0000200541206b22032400200541c0002003100220032903002101200341086a2903002102200341106a29030021ae01200341186a29030021ab01200341206b220522032400200541186a20ab01370300200520ae013703102005200237030820052001370300200041013a002b200541202000412b6a410110011a2026202520242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c2007200420b50120b90120b70120b401102422050d0441044101417f1011210520004197b0a8ef0736022c2000412c6a200541086a220641041010200020203a0033200020243a0032200020253a0031200020263a00302000201f3a00342000201e3a00352000201d3a00362000201c3a00372000201b3a00382000201a3a0039200020193a003a200020183a003b200020173a003c200020163a003d200020153a003e200020143a003f200020133a0040200020123a0041200020113a00422000200f3a00432000200e3a00442000200a3a0045200020233a0046200020223a00472000200d3a0048200020103a0049200020213a004a2000200b3a004b200020093a004c2000200c3a004d200020073a004e200020043a004f20052802002104200341106b220324002003420037030820034200370300419805418080023602004100200041306a4200200320062004410020051b41a00541980510080d05419805280200410141a00510112205280200410020051b220341204f0440419805280200410141a00510112105200341204d0d02000b000b000b200541276a2d00002103200541266a2d00002104200541256a2d00002106200541246a2d00002107200541236a2d0000210c200541226a2d00002109200541216a2d0000210b200541206a2d000021212005411f6a2d000021102005411e6a2d0000210d2005411d6a2d000021222005411c6a2d000021232005411b6a2d0000210a2005411a6a2d0000210e200541196a2d0000210f200541186a2d00002111200541176a2d00002112200541166a2d00002113200541156a2d00002114200541146a2d00002115200541136a2d00002116200541126a2d00002117200541116a2d00002118200541106a2d000021192005410f6a2d0000211a2005410e6a2d0000211b2005410d6a2d0000211c2005410c6a2d0000211d2005410b6a2d0000211e2005410a6a2d0000211f200541096a2d00002120200541086a2d00002105419805412036020041a00541980510090240200541a0052d0000470d00202041a1052d0000470d00201f41a2052d0000470d00201e41a3052d0000470d00201d41a4052d0000470d00201c41a5052d0000470d00201b41a6052d0000470d00201a41a7052d0000470d00201941a8052d0000470d00201841a9052d0000470d00201741aa052d0000470d00201641ab052d0000470d00201541ac052d0000470d00201441ad052d0000470d00201341ae052d0000470d00201241af052d0000470d00201141b0052d0000470d00200f41b1052d0000470d00200e41b2052d0000470d00200a41b3052d0000470d00202341b4052d0000470d00202241b5052d0000470d00200d41b6052d0000470d00201041b7052d0000470d00202141b8052d0000470d00200b41b9052d0000470d00200941ba052d0000470d00200c41bb052d0000470d00200741bc052d0000470d00200641bd052d0000470d00200441be052d0000470d00200341bf052d0000460d050b000b000b000b200041d0006a240020050c020b000b200041d0006a240041000b22050d00410021050b20050d470c410b41c3052d0000210341c2052d0000210441c1052d0000210641c0052d0000210741bf052d0000210c41be052d0000210941bd052d0000210b41bc052d0000212141bb052d0000211041ba052d0000210d41b9052d0000212241b8052d0000212341b7052d0000210a41b6052d0000210e41b5052d0000210f41b4052d0000211141b3052d0000211241b2052d0000211341b1052d0000211441b0052d0000211541af052d0000211641ae052d0000211741ad052d0000211841ac052d0000211941ab052d0000211a41aa052d0000211b41a9052d0000211c41a8052d0000211d41a7052d0000211e41a6052d0000211f41a5052d0000212041a4052d0000212441c405290300210141dc05290300210241d40529030021ae0141cc0529030021ab010240101f22050d00410021054100210020242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c2007200620042003200120ab0120ae012002102422030440200321000b2000450d00200021050b20050d460c400b41c3052d0000210041c2052d0000210341c1052d0000210441c0052d0000210641bf052d0000210741be052d0000210c41bd052d0000210941bc052d0000210b41bb052d0000212141ba052d0000211041b9052d0000210d41b8052d0000212241b7052d0000212341b6052d0000210a41b5052d0000210e41b4052d0000210f41b3052d0000211141b2052d0000211241b1052d0000211341b0052d0000211441af052d0000211541ae052d0000211641ad052d0000211741ac052d0000211841ab052d0000211941aa052d0000211a41a9052d0000211b41a8052d0000211c41a7052d0000211d41a6052d0000211e41a5052d0000211f41a4052d0000200841206b22052400201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c2007200620042003200020051019450d380c450b2005450d390c440b41c3052d0000210041c2052d0000210341c1052d0000210441c0052d0000210641bf052d0000210741be052d0000210c41bd052d0000210941bc052d0000210b41bb052d0000212141ba052d0000211041b9052d0000210d41b8052d0000212241b7052d0000212341b6052d0000210a41b5052d0000210e41b4052d0000210f41b3052d0000211141b2052d0000211241b1052d0000211341b0052d0000211441af052d0000211541ae052d0000211641ad052d0000211741ac052d0000211841ab052d0000211941aa052d0000211a41a9052d0000211b41a8052d0000211c41a7052d0000211d41a6052d0000211e41a5052d0000211f41a4052d000041e3052d0000212441e2052d0000212541e1052d0000212641e0052d0000212841df052d0000212a41de052d0000212b41dd052d0000212d41dc052d0000212941db052d0000212741da052d0000212c41d9052d0000212e41d8052d0000213041d7052d0000212f41d6052d0000213641d5052d0000213741d4052d0000213841d3052d0000213241d2052d0000213141d1052d0000213341d0052d0000213441cf052d0000213941ce052d0000213a41cd052d0000213b41cc052d0000213c41cb052d0000213d41ca052d0000213e41c9052d0000213f41c8052d0000214041c7052d0000214141c6052d0000214241c5052d0000214341c4052d00002144200841206b22052400201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c2007200620042003200020442043204220412040203f203e203d203c203b203a20392034203320312032203820372036202f2030202e202c20272029202d202b202a20282026202520242005101a450d360c430b2005450d370c420b2005450d200c410b41c3052d0000210441c2052d0000210641c1052d0000210741c0052d0000210c41bf052d0000210941be052d0000210b41bd052d0000212141bc052d0000211041bb052d0000210d41ba052d0000212241b9052d0000212341b8052d0000210a41b7052d0000210e41b6052d0000210f41b5052d0000211141b4052d0000211241b3052d0000211341b2052d0000211441b1052d0000211541b0052d0000211641af052d0000211741ae052d0000211841ad052d0000211941ac052d0000211a41ab052d0000211b41aa052d0000211c41a9052d0000211d41a8052d0000211e41a7052d0000211f41a6052d0000212041a5052d0000212441a4052d0000212541c405290300210141dc0529030021ab0141d405290300210241cc0529030021ae01200841106b22052400027f230041206b22002400419805412036020041a0054198051004200041a005290300370000200041a805290300370008200041b005290300370010200041b80529030037001820002d001f212620002d001e212820002d001d212a20002d001c212b20002d001b212d20002d001a212920002d0019212720002d0018212c20002d0017212e20002d0016213020002d0015212f20002d0014213620002d0013213720002d0012213820002d0011213220002d0010213120002d000f213320002d000e213420002d000d213920002d000c213a20002d000b213b20002d000a213c20002d0009213d20002d0008213e20002d0007213f20002d0006214020002d0005214120002d0004214220002d0003214320002d0002214420002d0001214620002d00002145200041206b22032400024002402045204620442043204220412040203f203e203d203c203b203a20392034203320312032203820372036202f2030202e202c20272029202d202b202a20282026202520242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c2007200620042003101a22354504402001200329030022ac017c22ad0120ac015422352035ad20ae01200341086a29030022017c7c22ac01200154200120ac01511b2235200341106a290300220120027c22ae012035ad7c2202200154200220ae0154ad200120ae0156ad200341186a29030022ae0120ab017c7c7c22ab0120ae015420ab0120ae01511b200120028520ab0120ae018584501b0d012045204620442043204220412040203f203e203d203c203b203a20392034203320312032203820372036202f2030202e202c20272029202d202b202a20282026202520242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c20072006200420ad0120ac01200220ab01101b2203450d02200041206a240020030c030b200041206a240020350c020b000b200541013a0000200041206a240041000b450d340c400b41c3052d0000210441c2052d0000210641c1052d0000210741c0052d0000210c41bf052d0000210941be052d0000210b41bd052d0000212141bc052d0000211041bb052d0000210d41ba052d0000212241b9052d0000212341b8052d0000210a41b7052d0000210e41b6052d0000210f41b5052d0000211141b4052d0000211241b3052d0000211341b2052d0000211441b1052d0000211541b0052d0000211641af052d0000211741ae052d0000211841ad052d0000211941ac052d0000211a41ab052d0000211b41aa052d0000211c41a9052d0000211d41a8052d0000211e41a7052d0000211f41a6052d0000212041a5052d0000212441a4052d0000212541c40529030021ab0141dc05290300210141d405290300210241cc0529030021ae01200841106b22052400027f230041206b22002400419805412036020041a0054198051004200041a005290300370000200041a805290300370008200041b005290300370010200041b80529030037001820002d001f212620002d001e212820002d001d212a20002d001c212b20002d001b212d20002d001a212920002d0019212720002d0018212c20002d0017212e20002d0016213020002d0015212f20002d0014213620002d0013213720002d0012213820002d0011213220002d0010213120002d000f213320002d000e213420002d000d213920002d000c213a20002d000b213b20002d000a213c20002d0009213d20002d0008213e20002d0007213f20002d0006214020002d0005214120002d0004214220002d0003214320002d0002214420002d0001214620002d00002145200041206b22032400024002402045204620442043204220412040203f203e203d203c203b203a20392034203320312032203820372036202f2030202e202c20272029202d202b202a20282026202520242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c2007200620042003101a2235450440200329030022b00120ab015a200341086a29030022ac0120ae015a20ac0120ae015122351b200341106a29030022ad0120025a200341186a29030022af0120015a200120af01511b200220ad0185200120af018584501b450d012045204620442043204220412040203f203e203d203c203b203a20392034203320312032203820372036202f2030202e202c20272029202d202b202a20282026202520242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d20102021200b2009200c20072006200420b00120ab017d20ac0120ae017d20ab0120b001562203ad7d20ad0120027d22ab01200320ac0120ae015420351bad22ae017d20af0120017d200220ad0156ad7d20ab0120ae0154ad7d101b2203450d02200041206a240020030c030b200041206a240020350c020b000b200541013a0000200041206a240041000b450d330c3f0b41bc052903001a41b4052903001a41ac052903001a41a405290300200841206b2205240020051023450d310c3e0b41bc05290300210141b40529030021ae0141ac05290300210241a40529030021af01200841206b22002400200041206b22052400027f230041306b220b24004198054101360200200b41286a4200370300200b4200370320200b4200370318200b4202370310200b200b41106a412041a0054198051003047f41000541a0052d00000b41017122033a000f02402003450440200b41206b22212400202141206b22222400027f230041406a220c240002400240101e2203450440200c41206b22102400201041206b22232400027f23004180016b22072400230041f0006b220324000240024002400240024002400240024020014200590440200341206a22042001370300200320af0137030820032002370310200320ae01370318200429030021b001200341186a29030021b501200341106a29030021b201200329030821b701200341206b220422092400200441186a420037030020044200370310200442003703082004420837030041980541203602002004412041a0054198051003210441a0052d0000210d41a1052d0000210a41a2052d0000210e41a3052d0000210f41a4052d0000211141a5052d0000211241a6052d0000211341a7052d0000211441a8052d0000211541a9052d0000211641aa052d0000211741ab052d0000211841ac052d0000211941ad052d0000211a41ae052d0000211b41af052d0000211c41b0052d0000211d41b1052d0000211e41b2052d0000211f41b3052d0000212041b4052d0000212441b5052d0000212541b6052d0000212641b7052d0000212841b8052d0000212a41b9052d0000212b41ba052d0000212d41bb052d0000212941bc052d0000212741bd052d0000212c41be052d0000212e41bf052d0000213041244101417f10112106200341b184828507360228200341286a200641086a222f41041010419805412036020041a005419805100941a00529030021b30141a80529030021b40141b00529030021b901200641246a41b8052903003700002006411c6a20b901370000200641146a20b4013700002006410c6a20b30137000020034100203020041b3a004b20034100202e20041b3a004a20034100202c20041b3a004920034100202720041b3a004820034100202920041b3a004720034100202d20041b3a004620034100202b20041b3a004520034100202a20041b3a004420034100202820041b3a004320034100202620041b3a004220034100202520041b3a004120034100202420041b3a004020034100202020041b3a003f20034100201f20041b3a003e20034100201e20041b3a003d20034100201d20041b3a003c20034100201c20041b3a003b20034100201b20041b3a003a20034100201a20041b3a003920034100201920041b3a003820034100201820041b3a003720034100201720041b3a003620034100201620041b3a003520034100201520041b3a003420034100201420041b3a003320034100201320041b3a003220034100201220041b3a003120034100201120041b3a003020034100200f20041b3a002f20034100200e20041b3a002e20034100200a20041b3a002d20034100200d20041b3a002c2006280200210d200941106b22042209240020044200370308200442003703004198054180800236020041002003412c6a42002004202f200d410020061b41a00541980510080d01419805280200410141a00510112204280200410020041b2206411f4d0d02419805280200410141a00510112104200641204b0d03200441206a29030021b901200441186a29030021b601200441106a29030021ba01200441086a29030021b801200941206b22042400420021b301200441186a420037030020044200370310200442003703082004420a3703004198054120360200027e2004412041a00541980510030440420021b40142000c010b41b80529030021b10141b00529030021ad0141a80529030021b40141a0052903000b21bb01200441206b22042400200441186a420037030020044200370310200442003703082004420e37030041980541203602002004412041a0054198051003047e42000541b80529030021ac0141b00529030021ab0141a00529030021b30141a8052903000b21bc01200441206b220422092400200441186a420037030020044200370310200442003703082004420d37030041980541203602002004412041a0054198051003210441a0052d0000210d41a1052d0000210a41a2052d0000210e41a3052d0000210f41a4052d0000211141a5052d0000211241a6052d0000211341a7052d0000211441a8052d0000211541a9052d0000211641aa052d0000211741ab052d0000211841ac052d0000211941ad052d0000211a41ae052d0000211b41af052d0000211c41b0052d0000211d41b1052d0000211e41b2052d0000211f41b3052d0000212041b4052d0000212441b5052d0000212541b6052d0000212641b7052d0000212841b8052d0000212a41b9052d0000212b41ba052d0000212d41bb052d0000212941bc052d0000212741bd052d0000212c41be052d0000212e41bf052d000021304184014101417f10112106200341eba490d40736024c200341cc006a200641086a222f4104101020064184016a2001370300200641fc006a20ae01370300200641f4006a2002370300200641ec006a20af01370300200641e4006a20ac01370300200641dc006a20ab01370300200641d4006a20bc01370300200641cc006a20b301370300200641c4006a20b1013703002006413c6a20ad01370300200641346a20b4013703002006412c6a20bb01370300200641246a20b9013703002006411c6a20b601370300200641146a20ba013703002006410c6a20b80137030020034100203020041b3a006f20034100202e20041b3a006e20034100202c20041b3a006d20034100202720041b3a006c20034100202920041b3a006b20034100202d20041b3a006a20034100202b20041b3a006920034100202a20041b3a006820034100202820041b3a006720034100202620041b3a006620034100202520041b3a006520034100202420041b3a006420034100202020041b3a006320034100201f20041b3a006220034100201e20041b3a006120034100201d20041b3a006020034100201c20041b3a005f20034100201b20041b3a005e20034100201a20041b3a005d20034100201920041b3a005c20034100201820041b3a005b20034100201720041b3a005a20034100201620041b3a005920034100201520041b3a005820034100201420041b3a005720034100201320041b3a005620034100201220041b3a005520034100201120041b3a005420034100200f20041b3a005320034100200e20041b3a005220034100200a20041b3a005120034100200d20041b3a00502006280200210d200941106b220424002004420037030820044200370300419805418080023602004100200341d0006a42002004202f200d410020061b41a00541980510080d04419805280200410141a00510112206280200410020061b2209411f4d0d05419805280200410141a00510112106200941204b0d06200641206a29030021ab01200441206b2204240020ab014200530d07200641186a29030021ac01200641106a29030021ad012004200641086a290300370300200420ad01370308200420ac01370310200441186a220620ab0137030020b001200629030022ab018520b00120b00120ab017d20b501200441106a29030022ab0154ad7d20b50120ab017d22ac0120b701200429030022ad0154220620b201200441086a29030022ab015420ab0120b201511bad22b10154ad7d22b50185834200590d08000b000b000b000b000b000b000b000b000b200720b70120ad017d370300200720b20120ab017d2006ad7d370308200720ac0120b1017d370310200741186a220420b501370300200341f0006a24004198054120360200200429030021b201200741106a29030021b101200741086a29030021b001200729030021b50141a005419805100441bf052d0000211141be052d0000211241bd052d0000211341bc052d0000211441bb052d0000211541ba052d0000211641b9052d0000211741b8052d0000211841b7052d0000211941b6052d0000211a41b5052d0000211b41b4052d0000211c41b3052d0000211d41b2052d0000211e41b1052d0000211f41b0052d0000212041af052d0000212441ae052d0000212541ad052d0000212641ac052d0000212841ab052d0000212a41aa052d0000212b41a9052d0000212d41a8052d0000212941a7052d0000212741a6052d0000212c41a5052d0000212e41a4052d0000213041a3052d0000212f41a2052d0000213641a1052d0000213741a0052d00002138200741206b220d240002400240027f200221ad0120ae0121ab01200121ac01200741e0006a2109420021b701420021b301420021b401230041d0026b220324004198054120360200200341c8026a4200370300200342003703c002200342003703b802200342053703b002200341206a2204200341b0026a412041a0054198051003047e42000541b00529030021b30141a80529030021b70141a00529030021b40141b8052903000b370300200320b401370308200320b701370310200320b301370318024002400240024002400240024002402009200329030822b301200341186a29030022b40184200341106a29030022b701200429030022b901848450047e20af0105200341206b2204220a2400200441186a420037030020044200370310200442003703082004420837030041980541203602002004412041a0054198051003210441a0052d0000210e41a1052d0000210f41a2052d0000213241a3052d0000213141a4052d0000213341a5052d0000213441a6052d0000213941a7052d0000213a41a8052d0000213b41a9052d0000213c41aa052d0000213d41ab052d0000213e41ac052d0000213f41ad052d0000214041ae052d0000214141af052d0000214241b0052d0000214341b1052d0000214441b2052d0000214641b3052d0000214541b4052d0000213541b5052d0000214741b6052d0000214841b7052d0000214b41b8052d0000214c41b9052d0000214941ba052d0000214d41bb052d0000214a41bc052d0000214e41bd052d0000214f41be052d0000215041bf052d0000215141244101417f10112106200341b18482850736022c2003412c6a200641086a225241041010419805412036020041a005419805100941a00529030021b60141a80529030021ba0141b00529030021b801200641246a41b8052903003700002006411c6a20b801370000200641146a20ba013700002006410c6a20b60137000020034100205120041b3a004f20034100205020041b3a004e20034100204f20041b3a004d20034100204e20041b3a004c20034100204a20041b3a004b20034100204d20041b3a004a20034100204920041b3a004920034100204c20041b3a004820034100204b20041b3a004720034100204820041b3a004620034100204720041b3a004520034100203520041b3a004420034100204520041b3a004320034100204620041b3a004220034100204420041b3a004120034100204320041b3a004020034100204220041b3a003f20034100204120041b3a003e20034100204020041b3a003d20034100203f20041b3a003c20034100203e20041b3a003b20034100203d20041b3a003a20034100203c20041b3a003920034100203b20041b3a003820034100203a20041b3a003720034100203920041b3a003620034100203420041b3a003520034100203320041b3a003420034100203120041b3a003320034100203220041b3a003220034100200f20041b3a003120034100200e20041b3a00302006280200210e200a41106b220424002004420037030820044200370300419805418080023602004100200341306a420020042052200e410020061b41a00541980510080d01419805280200410141a00510112206280200410020061b220a411f4d0d02419805280200410141a00510112106200a41204b0d03200641206a29030021b601200641186a29030021ba01200641106a29030021b801200641086a29030021bb0120034188016a20b901370300200341e8006a20ac01370300200320b301370370200320af01370350200320b701370378200320ad01370358200320b40137038001200320ab01370360200341d0006a200341f0006a20034190016a410810150d04200341a8016a29030021ab01200341a0016a29030021ac0120034198016a29030021ad0120032903900121b301200341e8016a20b601370300200341c8016a20ab01370300200320bb013703d001200320b3013703b001200320b8013703d801200320ad013703b801200320ba013703e001200320ac013703c001200341b0016a200341d0016a200341f0016a20034190026a10180d06200341a8026a29030021ab01200441206b2204240020ab014200530d05200341a0026a29030021ac0120034198026a29030021ad012004200329039002370300200420ad01370308200420ac01370310200441186a220620ab01370300200629030022ab0120b2018520ab0120ab0120b2017d200441106a29030022ac0120b10154ad7d20ac0120b1017d22b301200429030022b40120b501542206200441086a29030022ac0120b0015420ac0120b001511bad22b70154ad7d22ad0185834200530d08200441206b2204240020ad014200530d07200420b40120b5017d370300200420ac0120b0017d2006ad7d370308200420b30120b7017d370310200441186a220620ad01370300200629030021ac01200441106a29030021ab01200441086a29030021ad0120042903000b370300200920ad01370308200920ab01370310200941186a20ac01370300200341d0026a240041000c080b000b000b000b000b000b000b000b000b2203450440027f200729036021b301200741e8006a29030021b401200741f0006a29030021b701200741f8006a29030021b901420021ab01420021ad01420021bc01230041e0006b220324004198054120360200200341306a4200370300200342003703282003420037032020034208370318200341186a412041a0054198051003210441a0052d0000210941a1052d0000210a41a2052d0000210e41a3052d0000210f41a4052d0000213241a5052d0000213141a6052d0000213341a7052d0000213441a8052d0000213941a9052d0000213a41aa052d0000213b41ab052d0000213c41ac052d0000213d41ad052d0000213e41ae052d0000213f41af052d0000214041b0052d0000214141b1052d0000214241b2052d0000214341b3052d0000214441b4052d0000214641b5052d0000214541b6052d0000213541b7052d0000214741b8052d0000214841b9052d0000214b41ba052d0000214c41bb052d0000214941bc052d0000214d41bd052d0000214a41be052d0000214e41bf052d0000214f41244101417f10112106200341b18482850736023c2003413c6a200641086a225041041010419805412036020041a005419805100941a00529030021ac0141a80529030021b60141b00529030021ba01200641246a41b8052903003700002006411c6a20ba01370000200641146a20b6013700002006410c6a20ac0137000020034100204f20041b3a005f20034100204e20041b3a005e20034100204a20041b3a005d20034100204d20041b3a005c20034100204920041b3a005b20034100204c20041b3a005a20034100204b20041b3a005920034100204820041b3a005820034100204720041b3a005720034100203520041b3a005620034100204520041b3a005520034100204620041b3a005420034100204420041b3a005320034100204320041b3a005220034100204220041b3a005120034100204120041b3a005020034100204020041b3a004f20034100203f20041b3a004e20034100203e20041b3a004d20034100203d20041b3a004c20034100203c20041b3a004b20034100203b20041b3a004a20034100203a20041b3a004920034100203920041b3a004820034100203420041b3a004720034100203320041b3a004620034100203120041b3a004520034100203220041b3a004420034100200f20041b3a004320034100200e20041b3a004220034100200a20041b3a004120034100200920041b3a004020062802002104419805418080023602002003420037031020034200370308024002400240024002404100200341406b4200200341086a20502004410020061b41a0054198051008450440419805280200410141a00510112204280200410020041b2206411f4d0d01419805280200410141a00510112104200641204b0d02200441206a29030021b601200441186a29030021ba01200441106a29030021ac01200441086a29030021b801200341206b22042400200441186a420037030020044200370310200442003703082004420937030041980541203602002004412041a0054198051003047e42000541b80529030021ab0141a80529030021ad0141a00529030021bc0141b0052903000b21be0120b80120af0120b8017c22bf015622042004ad200220ac017c7c22bb0120ac015420ac0120bb01511b220420ae0120ba017c22ac012004ad7c22b80120ba015420ac0120b80156ad20ac0120ba0154ad200120b6017c7c7c22ac0120b6015420ac0120b601511b20b80120ba018520ac0120b6018584501b0d0320bc0120bf015a20ad0120bb015a20ad0120bb01511b20b80120be015820ab0120ac015a20ab0120ac01511b20b80120be018520ab0120ac018584501b450d04027f420021ac01420021ab01420021b601230041306b2204210920042400027e024020b30120b7018420b40120b901848450450440200441206b22042400200441186a420037030020044200370310200442003703082004420a37030041980541203602002004412041a0054198051003450d0142000c020b000b41b80529030021ac0141a80529030021ab0141a00529030021b60141b0052903000b21ad01200441206b22042400024002400240024002400240024020014200590440200420af0137030020042002370308200420ae01370310200441186a22062001370300200629030022ba0120b2018520ba0120ba0120b2017d200441106a29030022b80120b10154ad7d20b80120b1017d22bc01200429030022be0120b501542206200441086a29030022b80120b0015420b00120b801511bad22bf0154ad7d22bb0185834200530d02200441206b2204240020bb014200530d01200420be0120b5017d370300200420b80120b0017d2006ad7d370308200420bc0120bf017d370310200441186a220620bb0137030020b60120042903007c22b80120b60154220a200aad20ab01200441086a2903007c7c22ba0120ab015420ab0120ba01511b220a20ad01200441106a2903007c22b601200aad7c22ab0120ad015420ab0120b60154ad20ad0120b60156ad20ac0120062903007c7c7c22b60120ac015420ac0120b601511b20ab0120ad018520ac0120b6018584501b0d03200441206b22322400200941206a20b601370300203241186a420037030020324200370310203242003703082032420a370300200920ab01370318200920ba01370310200920b80137030820324120200941086a412010011a420021ad01420021ab01420021ac0123004180016b2204210620042400024020112037203872203672202f72203072202e72202c72202772202972202d72202b72202a72202872202672202572202472202072201f72201e72201d72201c72201b72201a72201972201872201772201672201572201472201372201272720440027e200441206b22042400200441186a4200370300200442003703102004420037030820044205370300419805412036020042002004412041a00541980510030d001a41b80529030021ac0141a80529030021ab0141a00529030021ad0141b0052903000b21b601027e024020ad0120b3017c22b80120ad0154220a200aad20ab0120b4017c7c22ba0120ab015420ab0120ba01511b220a20b60120b7017c22ad01200aad7c22ab0120b6015420ab0120ad0154ad20ad0120b60154ad20ac0120b9017c7c7c22ad0120ac015420ac0120ad01511b20ab0120b6018520ac0120ad018584501b450440200441206b22042400200641186a20ad01370300200441186a4200370300200442003703102004420037030820044205370300200620ab01370310200620ba01370308200620b801370300200441202006412010011a200441406a22042400200441186a4200370300200442003703102004420037030820044203370300200441206a20383a0000200441216a20373a0000200441226a20363a0000200441236a202f3a0000200441246a20303a0000200441256a202e3a0000200441266a202c3a0000200441276a20273a0000200441286a20293a0000200441296a202d3a00002004412a6a202b3a00002004412b6a202a3a00002004412c6a20283a00002004412d6a20263a00002004412e6a20253a00002004412f6a20243a0000200441306a20203a0000200441316a201f3a0000200441326a201e3a0000200441336a201d3a0000200441346a201c3a0000200441356a201b3a0000200441366a201a3a0000200441376a20193a0000200441386a20183a0000200441396a20173a00002004413a6a20163a00002004413b6a20153a00002004413c6a20143a00002004413d6a20133a00002004413e6a20123a00002004413f6a20113a0000200441206b220a2400200441c000200a1002200a29030021ab01200a41086a29030021ac01200a41106a29030021ad01200a41186a29030021b601200a41206b22042400200441186a20b601370300200420ad01370310200420ac01370308200420ab0137030041980541203602002004412041a0054198051003450d01420021ac01420021ab01420021ad0142000c020b000b41b80529030021ad0141b00529030021ab0141a00529030021ac0141a8052903000b21b601200441406a22042400200441186a4200370300200442003703102004420037030820044203370300200441206a20383a0000200441216a20373a0000200441226a20363a0000200441236a202f3a0000200441246a20303a0000200441256a202e3a0000200441266a202c3a0000200441276a20273a0000200441286a20293a0000200441296a202d3a00002004412a6a202b3a00002004412b6a202a3a00002004412c6a20283a00002004412d6a20263a00002004412e6a20253a00002004412f6a20243a0000200441306a20203a0000200441316a201f3a0000200441326a201e3a0000200441336a201d3a0000200441346a201c3a0000200441356a201b3a0000200441366a201a3a0000200441376a20193a0000200441386a20183a0000200441396a20173a00002004413a6a20163a00002004413b6a20153a00002004413c6a20143a00002004413d6a20133a00002004413e6a20123a00002004413f6a20113a0000200441206b220a2400200441c000200a1002200a29030021ba01200a41086a29030021b801200a41106a29030021bb01200a41186a29030021bc01200a41206b2204220a2400200441186a20bc01370300200420bb01370310200420b801370308200420ba01370300200620ac0120b3017c22ba01370320200620ac0120ba0156220ead20b40120b6017c7c22ac01370328200620ab0120b7017c22ba01200e20ac0120b6015420ac0120b601511bad7c22ac01370330200641386a20ac0120ba0154ad20ab0120ba0156ad20ad0120b9017c7c7c37030020044120200641206a412010011a41204101417f1011220441206a4200370000200441186a4200370000200441106a4200370000200441086a220e420037000041004117200e2004280200410020041b1013220e2802004100200e1b41214f0440200e2802002104200a41206b220f220a2400200e41086a223120044100200e1b200f1005200a41206b2204220a2400200f2004100f200641d8006a200441186a2903003703002006200441106a2903003703502006200441086a29030037034820062004290300370340200641406b2031412010100b41204101417f10112204410a6a20363a0000200441096a20373a0000200441086a220f20383a00002004410b6a202f3a00002004410c6a20303a00002004410d6a202e3a00002004410e6a202c3a00002004410f6a20273a0000200441106a20293a0000200441116a202d3a0000200441126a202b3a0000200441136a202a3a0000200441146a20283a0000200441156a20263a0000200441166a20253a0000200441176a20243a0000200441186a20203a0000200441196a201f3a00002004411a6a201e3a00002004411b6a201d3a00002004411c6a201c3a00002004411d6a201b3a00002004411e6a201a3a00002004411f6a20193a0000200441206a20183a0000200441216a20173a0000200441226a20163a0000200441236a20153a0000200441246a20143a0000200441256a20133a0000200441266a20123a0000200441276a20113a000041204115200f2004280200410020041b1013220f2802004100200f1b41214f0440200f2802002104200a41206b2231220a2400200f41086a223320044100200f1b20311005200a41206b2204220a240020312004100f200641f8006a200441186a2903003703002006200441106a2903003703702006200441086a29030037036820062004290300370360200641e0006a2033412010100b41e1004101417f1011220441086a22334200370000200441106a4200370000200441186a4200370000200441206a4200370000200441286a41003a0000200441296a20383a00002004412a6a20373a00002004412b6a20363a00002004412c6a202f3a00002004412d6a20303a00002004412e6a202e3a00002004412f6a202c3a0000200441306a20273a0000200441316a20293a0000200441326a202d3a0000200441336a202b3a0000200441346a202a3a0000200441356a20283a0000200441366a20263a0000200441376a20253a0000200441386a20243a0000200441396a20203a00002004413a6a201f3a00002004413b6a201e3a00002004413c6a201d3a00002004413d6a201c3a00002004413e6a201b3a00002004413f6a201a3a0000200441406b20193a0000200441c1006a20183a0000200441c2006a20173a0000200441c3006a20163a0000200441c4006a20153a0000200441c5006a20143a0000200441c6006a20133a0000200441c7006a20123a0000200441c8006a20113a0000200441e1006a20b901370300200441d9006a20b701370300200441d1006a20b401370300200441c9006a20b301370300200a41f0006b223124002031410c3a0000200a41ef006b2234410c100e203441c0004120100d200a41cf006b200e41086a200e2802004100200e1b100d200a412f6b200f41086a200f2802004100200f1b100d203141e10020332004280200410020041b10060c010b000b20064180016a2400203241206b22042400200441186a420037030020044200370310200442003703082004420837030041980541203602002004412041a0054198051003210641a0052d0000210a41a1052d0000210e41a2052d0000210f41a3052d0000213241a4052d0000213141a5052d0000213341a6052d0000213441a7052d0000213941a8052d0000213a41a9052d0000213b41aa052d0000213c41ab052d0000213d41ac052d0000213e41ad052d0000213f41ae052d0000214041af052d0000214141b0052d0000214241b1052d0000214341b2052d0000214441b3052d0000214641b4052d0000214541b5052d0000213541b6052d0000214741b7052d0000214841b8052d0000214b41b9052d0000214c41ba052d0000214941bb052d0000214d41bc052d0000214a41bd052d0000214e41be052d0000214f41bf052d00002150419805412036020041a005419805100941a00529030021ab0141a80529030021ac0141b00529030021ad0141b80529030021b60141e4004101417f10112104200941dde5e19d02360228200941286a200441086a410410102004411a6a20253a0000200441196a20263a0000200441186a20283a0000200441176a202a3a0000200441166a202b3a0000200441156a202d3a0000200441146a20293a0000200441136a20273a0000200441126a202c3a0000200441116a202e3a0000200441106a20303a00002004410f6a202f3a00002004410e6a20363a00002004410d6a20373a00002004410c6a20383a00002004411b6a20243a00002004411c6a20203a00002004411d6a201f3a00002004411e6a201e3a00002004411f6a201d3a0000200441206a201c3a0000200441216a201b3a0000200441226a201a3a0000200441236a20193a0000200441246a20183a0000200441256a20173a0000200441266a20163a0000200441276a20153a0000200441286a20143a0000200441296a20133a00002004412a6a20123a00002004412b6a20113a0000200441e4006a2001370300200441dc006a20ae01370300200441d4006a2002370300200441cc006a20af01370300200441c4006a20b6013700002004413c6a20ad01370000200441346a20ac013700002004412c6a20ab013700004100200a20061b4100200e20061b4100200f20061b4100203220061b4100203120061b4100203320061b4100203420061b4100203920061b4100203a20061b4100203b20061b4100203c20061b4100203d20061b4100203e20061b4100203f20061b4100204020061b4100204120061b4100204220061b4100204320061b4100204420061b4100204620061b4100204520061b4100203520061b4100204720061b4100204820061b4100204b20061b4100204c20061b4100204920061b4100204d20061b4100204a20061b4100204e20061b4100204f20061b4100205020061b20044120410141c00210112009412c6a10222204450440200928022c2204280200410020041b04402004280200410020041b2206450d06200641014b0d07200441086a2d0000410171450d080b410021040b2004450440410021040b2004450d07200941306a240020040c080b000b000b000b000b000b000b000b200941306a240041000b2204450d05200341e0006a240020040c060b000b000b000b000b000b200341e0006a240041000b2203450440200d20b301370300200d20b401370308200d20b701370310200d41186a20b901370300410021030b20030d010c020b2003450d010b20074180016a240020030c010b200d41186a29030021ab01200d41106a29030021ac01200d41086a29030021ad01200d29030021b301200d41206b22032400200341186a420037030020034200370310200342003703082003420e37030041980541203602002003412041a0054198051003047e42000541b00529030021bd0141a80529030021c00141a00529030021c10141b8052903000b21b401200341206b2203240002400240024020b4014200590440200320c101370300200320c001370308200320bd01370310200341186a220420b401370300200429030022b40120b20185427f8520b401200341106a29030022b90120b1017c22b70120b90154ad20b20120b4017c7c20b701200329030022b90120b5017c22ba0120b9015422042004ad200341086a29030022b90120b0017c7c22b60120b9015420b60120b901511bad7c22b90120b70154ad7c22b70185834200530d02200341206b2203240020b7014200530d01200320ba01370300200320b601370308200320b901370310200341186a220420b701370300200341086a29030021b401200341106a29030021b701200429030021b901200329030021b601200341206b220322062400200741386a20b901370300200341186a420037030020034200370310200342003703082003420e370300200720b701370330200720b401370328200720b60137032020034120200741206a412010011a419805412036020041a005419805100441a0052d0000210d41a1052d0000210a41a2052d0000210e41a3052d0000210f41a4052d0000211141a5052d0000211241a6052d0000211341a7052d0000211441a8052d0000211541a9052d0000211641aa052d0000211741ab052d0000211841ac052d0000211941ad052d0000211a41ae052d0000211b41af052d0000211c41b0052d0000211d41b1052d0000211e41b2052d0000211f41b3052d0000212041b4052d0000212441b5052d0000212541b6052d0000212641b7052d0000212841b8052d0000212a41b9052d0000212b41ba052d0000212d41bb052d0000212941bc052d0000212741bd052d0000212c41be052d0000212e41bf052d0000213041204101417f1011220341276a20303a0000200341266a202e3a0000200341256a202c3a0000200341246a20273a0000200341236a20293a0000200341226a202d3a0000200341216a202b3a0000200341206a202a3a00002003411f6a20283a00002003411e6a20263a00002003411d6a20253a00002003411c6a20243a00002003411b6a20203a00002003411a6a201f3a0000200341196a201e3a0000200341186a201d3a0000200341176a201c3a0000200341166a201b3a0000200341156a201a3a0000200341146a20193a0000200341136a20183a0000200341126a20173a0000200341116a20163a0000200341106a20153a00002003410f6a20143a00002003410e6a20133a00002003410d6a20123a00002003410c6a20113a00002003410b6a200f3a00002003410a6a200e3a0000200341096a200a3a0000200341086a2204200d3a000041f002411c20042003280200410020031b10132204280200410020041b41204b044020042802002103200641206b220922062400200441086a222f2003410020041b20091005200641206b22032206240020092003100f200741d8006a200341186a2903003703002007200341106a2903003703502007200341086a29030037034820072003290300370340200741406b202f412010100b41e1004101417f1011220941086a222f41053a0000202f41016a2203200a3a00012003200d3a00002003200e3a00022003200f3a0003200320113a0004200320123a0005200320133a0006200320143a0007200320153a0008200320163a0009200320173a000a200320183a000b200320193a000c2003201a3a000d2003201b3a000e2003201c3a000f2003201d3a00102003201e3a00112003201f3a0012200320203a0013200320243a0014200320253a0015200320263a0016200320283a00172003202a3a00182003202b3a00192003202d3a001a200320293a001b200320273a001c2003202c3a001d2003202e3a001e200320303a001f202f41216a220320ad01370308200320b301370300200320ac01370310200341186a20ab013703000c030b000b000b000b200941c9006a22032002370308200320af01370300200320ae01370310200341186a2001370300200641d0006b22032400200341083a0000200641cf006b220d4108100e200d4190034120100d2006412f6b200441086a2004280200410020041b100d200341c100200941086a2009280200410020091b1006201041186a20ab01370300201020ac01370310201020ad01370308201020b301370300202320b101370310202341186a20b201370300202320b501370300202320b00137030820074180016a240041000b22030d01202341186a2903002101202341106a2903002102202341086a29030021ae01201041186a29030021ab01201041106a29030021ac01201041086a29030021ad01202329030021af01201029030021b001200c41386a4200370300200c41186a4200370300200c4200370330200c4200370328200c4201370320200c4200370310200c4200370308200c4201370300200c4120200c41206a412010011a0c020b200c41406b240020030c020b200c41406b240020030c010b202120b001370300202120ad01370308202120ac01370310202141186a20ab0137030020222002370310202241186a2001370300202220af01370300202220ae01370308200c41406b240041000b2203450d01200b41306a240020030c020b000b20002021290300370300200041186a202141186a2903003703002000202141106a2903003703102000202141086a2903003703082005202241106a290300370310200541186a202241186a290300370300200520222903003703002005202241086a290300370308200b41306a240041000b0d3d0c380b41bc0529030021ac0141b40529030021b40141ac05290300210241a40529030021ba0141c405290300210141dc0529030021bd0141d40529030021c00141cc0529030021c101200841206b22002400200041206b22052400027f200121ae01230041406a220c240002400240101e2203450440200c41206b22092400200941206b22212400027f230041e0006b22062400419805412036020041a0054198051004024002400240024002400240024041a0052d000041a1052d000041a2052d000041a3052d000041a4052d000041a5052d000041a6052d000041a7052d000041a8052d000041a9052d000041aa052d000041ab052d000041ac052d000041ad052d000041ae052d000041af052d000041b0052d000041b1052d000041b2052d000041b3052d000041b4052d000041b5052d000041b6052d000041b7052d000041b8052d000041b9052d000041ba052d000041bb052d000041bc052d000041bd052d000041be052d000041bf052d000020061019220345044020ba012006290300582002200641086a29030022015820012002511b20b401200641106a29030022ab015820ac01200641186a290300220158200120ac01511b20ab0120b40185200120ac018584501b450d01200641206b2204240020ba012004102322030d07200441186a29030021ab01200441106a29030021b501200441086a29030021ad01200429030021b701200441206b220b2400230041f0006b220324000240024002400240024002400240024020ab014200590440200341206a220420ab01370300200320b701370308200320ad01370310200320b50137031820042903002101200341186a29030021bc01200341106a29030021b901200329030821be01200341206b220422102400200441186a420037030020044200370310200442003703082004420837030041980541203602002004412041a0054198051003210441a0052d0000210d41a1052d0000212241a2052d0000212341a3052d0000210a41a4052d0000210e41a5052d0000210f41a6052d0000211141a7052d0000211241a8052d0000211341a9052d0000211441aa052d0000211541ab052d0000211641ac052d0000211741ad052d0000211841ae052d0000211941af052d0000211a41b0052d0000211b41b1052d0000211c41b2052d0000211d41b3052d0000211e41b4052d0000211f41b5052d0000212041b6052d0000212441b7052d0000212541b8052d0000212641b9052d0000212841ba052d0000212a41bb052d0000212b41bc052d0000212d41bd052d0000212941be052d0000212741bf052d0000212c41244101417f10112107200341b184828507360228200341286a200741086a222e41041010419805412036020041a005419805100941a00529030021bf0141a80529030021c20141b00529030021c301200741246a41b8052903003700002007411c6a20c301370000200741146a20c2013700002007410c6a20bf0137000020034100202c20041b3a004b20034100202720041b3a004a20034100202920041b3a004920034100202d20041b3a004820034100202b20041b3a004720034100202a20041b3a004620034100202820041b3a004520034100202620041b3a004420034100202520041b3a004320034100202420041b3a004220034100202020041b3a004120034100201f20041b3a004020034100201e20041b3a003f20034100201d20041b3a003e20034100201c20041b3a003d20034100201b20041b3a003c20034100201a20041b3a003b20034100201920041b3a003a20034100201820041b3a003920034100201720041b3a003820034100201620041b3a003720034100201520041b3a003620034100201420041b3a003520034100201320041b3a003420034100201220041b3a003320034100201120041b3a003220034100200f20041b3a003120034100200e20041b3a003020034100200a20041b3a002f20034100202320041b3a002e20034100202220041b3a002d20034100200d20041b3a002c2007280200210d201041106b2204240020044200370308200442003703004198054180800236020041002003412c6a42002004202e200d410020071b41a00541980510080d01419805280200410141a00510112207280200410020071b2210411f4d0d02419805280200410141a00510112107201041204b0d03200741206a29030021bf01200741186a29030021c201200741106a29030021c301200741086a29030021c401200441206b22042400200441186a420037030020044200370310200442003703082004420a37030041980541203602002004412041a0054198051003047e42000541b80529030021b00141b00529030021b20141a80529030021b80141a0052903000b21c501200441206b22042400200441186a420037030020044200370310200442003703082004420e37030041980541203602002004412041a0054198051003047e42000541b80529030021af0141b00529030021b10141a00529030021b30141a8052903000b21c601200441206b220422102400200441186a420037030020044200370310200442003703082004420d37030041980541203602002004412041a0054198051003210441a0052d0000210d41a1052d0000212241a2052d0000212341a3052d0000210a41a4052d0000210e41a5052d0000210f41a6052d0000211141a7052d0000211241a8052d0000211341a9052d0000211441aa052d0000211541ab052d0000211641ac052d0000211741ad052d0000211841ae052d0000211941af052d0000211a41b0052d0000211b41b1052d0000211c41b2052d0000211d41b3052d0000211e41b4052d0000211f41b5052d0000212041b6052d0000212441b7052d0000212541b8052d0000212641b9052d0000212841ba052d0000212a41bb052d0000212b41bc052d0000212d41bd052d0000212941be052d0000212741bf052d0000212c4184014101417f10112107200341e587b1c37936024c200341cc006a200741086a222e4104101020074184016a20ab01370300200741fc006a20b501370300200741f4006a20ad01370300200741ec006a20b701370300200741e4006a20af01370300200741dc006a20b101370300200741d4006a20c601370300200741cc006a20b301370300200741c4006a20b0013703002007413c6a20b201370300200741346a20b8013703002007412c6a20c501370300200741246a20bf013703002007411c6a20c201370300200741146a20c3013703002007410c6a20c40137030020034100202c20041b3a006f20034100202720041b3a006e20034100202920041b3a006d20034100202d20041b3a006c20034100202b20041b3a006b20034100202a20041b3a006a20034100202820041b3a006920034100202620041b3a006820034100202520041b3a006720034100202420041b3a006620034100202020041b3a006520034100201f20041b3a006420034100201e20041b3a006320034100201d20041b3a006220034100201c20041b3a006120034100201b20041b3a006020034100201a20041b3a005f20034100201920041b3a005e20034100201820041b3a005d20034100201720041b3a005c20034100201620041b3a005b20034100201520041b3a005a20034100201420041b3a005920034100201320041b3a005820034100201220041b3a005720034100201120041b3a005620034100200f20041b3a005520034100200e20041b3a005420034100200a20041b3a005320034100202320041b3a005220034100202220041b3a005120034100200d20041b3a00502007280200210d201041106b220424002004420037030820044200370300419805418080023602004100200341d0006a42002004202e200d410020071b41a00541980510080d04419805280200410141a00510112207280200410020071b2210411f4d0d05419805280200410141a00510112107201041204b0d06200741206a29030021af01200441206b2204240020af014200530d07200741186a29030021b001200741106a29030021b2012004200741086a290300370300200420b201370308200420b001370310200441186a220720af013703002001200729030022af01852001200120af017d20bc01200441106a29030022af0154ad7d20bc0120af017d22b00120be01200429030022b20154220720b901200441086a29030022af015420af0120b901511bad22b10154ad7d22b30185834200590d08000b000b000b000b000b000b000b000b000b200b20be0120b2017d370300200b20b90120af017d2007ad7d370308200b20b00120b1017d370310200b41186a20b301370300200341f0006a2400410022030d074198054120360200200b41186a29030021af01200b41106a29030021b901200b41086a29030021b301200b290300210141a005419805100441bf052d0000211041be052d0000210d41bd052d0000212241bc052d0000212341bb052d0000210a41ba052d0000210e41b9052d0000210f41b8052d0000211141b7052d0000211241b6052d0000211341b5052d0000211441b4052d0000211541b3052d0000211641b2052d0000211741b1052d0000211841b0052d0000211941af052d0000211a41ae052d0000211b41ad052d0000211c41ac052d0000211d41ab052d0000211e41aa052d0000211f41a9052d0000212041a8052d0000212441a7052d0000212541a6052d0000212641a5052d0000212841a4052d0000212a41a3052d0000212b41a2052d0000212d41a1052d0000212941a0052d00002127200b41206b22072400027e0240027f230041406a22042400024002400240024002400240024020272029202d202b202a20282026202520242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d2010200410192203450440200429030020ba015a200441086a29030022b00120025a200220b001511b200441106a29030022b20120b4015a200441186a29030022b00120ac015a20ac0120b001511b20b20120b4018520ac0120b0018584501b450d01200120b7015420ad0120b3015620ad0120b301511b20b50120b9015620ab0120af015520ab0120af01511b20b50120b9018520ab0120af018584501b450d03200441206b2203240020ab014200530d02200320b701370300200320ad01370308200320b501370310200341186a220b20ab01370300200b29030022b00120af018520b00120b00120af017d200341106a29030022b20120b90154ad7d20b20120b9017d22b801200329030022bc01200154220b200341086a29030022b20120b3015420b20120b301511bad22be0154ad7d22b10185834200530d05200341206b2203240020b1014200530d04200320bc0120017d370300200320b20120b3017d200bad7d370308200320b80120be017d370310200341186a220b20b101370300200b29030021bc01200341106a29030021be01200341086a29030021bf01200329030021c20120272029202d202b202a20282026202520242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d201020ba01200220b40120ac01101d220b0d06200341206b220b2400420021b101200b41186a4200370300200b4200370310200b4200370308200b42083703004198054120360200200b412041a00541980510032103027e0240410041a0052d000020031b410041a1052d000020031b410041a2052d000020031b410041a3052d000020031b410041a4052d000020031b410041a5052d000020031b410041a6052d000020031b410041a7052d000020031b410041a8052d000020031b410041a9052d000020031b410041aa052d000020031b410041ab052d000020031b410041ac052d000020031b410041ad052d000020031b410041ae052d000020031b410041af052d000020031b410041b0052d000020031b410041b1052d000020031b410041b2052d000020031b410041b3052d000020031b410041b4052d000020031b410041b5052d000020031b410041b6052d000020031b410041b7052d000020031b410041b8052d000020031b410041b9052d000020031b410041ba052d000020031b410041bb052d000020031b410041bc052d000020031b410041bd052d000020031b410041be052d000020031b410041bf052d000020031b20272029202d202b202a20282026202520242020201f201e201d201c201b201a201920182017201620152014201320122011200f200e200a20232022200d201020c20120bf0120be0120bc0110212203450440200b41206b22032400200341186a420037030020034200370310200342003703082003420a37030041980541203602002003412041a0054198051003450d01420021b201420021b00142000c020b200441406b240020030c0a0b41b00529030021b00141a80529030021b20141a00529030021b10141b8052903000b21b80120b10120b7017d22c30120b1015620b20120ad017d20b10120b70154220bad7d22b10120b2015620b10120b201511b20b00120b5017d22b701200b20ad0120b2015620ad0120b201511bad22b2017d22ad0120b0015620b80120ab017d20b00120b50154ad7d20b20120b70156ad7d22ab0120b8015620ab0120b801511b20ad0120b0018520ab0120b8018584501b450d07000b200441406b240020030c070b000b000b000b000b000b200441406b2400200b0c010b200341206b22032400200441386a20ab01370300200341186a420037030020034200370310200342003703082003420a370300200420ad01370330200420b101370328200420c30137032020034120200441206a412010011a200741186a20bc01370300200720be01370310200720bf01370308200720c201370300200441406b240041000b2203450440200741186a29030021ab01200741106a29030021ad01200741086a29030021b001200729030021b201200741206b22032400200341186a420037030020034200370310200342003703082003420e37030041980541203602002003412041a0054198051003450d0142000c020b0c090b41b00529030021b60141a80529030021bb0141a00529030021c70141b8052903000b21b101200341206b2203240020b1014200530d02200320c701370300200320bb01370308200320b601370310200341186a220420b101370300200429030022b10120af0185427f8520b101200341106a29030022b70120b9017c22b50120b70154ad20af0120b1017c7c20b501200329030022b70120017c22b80120b7015422042004ad200341086a29030022b70120b3017c7c22b60120b7015420b60120b701511bad7c22b70120b50154ad7c22b50185834200530d04200341206b2203240020b5014200530d03200320b801370300200320b601370308200320b701370310200341186a220420b501370300200341086a29030021b101200341106a29030021b501200429030021b701200329030021b601200341206b220322072400200641386a20b701370300200341186a420037030020034200370310200342003703082003420e370300200620b501370330200620b101370328200620b60137032020034120200641206a412010011a20ae0120b2015820b00120c1015a20b00120c101511b20ad0120c0015a20ab0120bd015a20ab0120bd01511b20ad0120c0018520ab0120bd018584501b450d05419805412036020041a005419805100441a0052d0000211041a1052d0000210d41a2052d0000212241a3052d0000212341a4052d0000210a41a5052d0000210e41a6052d0000210f41a7052d0000211141a8052d0000211241a9052d0000211341aa052d0000211441ab052d0000211541ac052d0000211641ad052d0000211741ae052d0000211841af052d0000211941b0052d0000211a41b1052d0000211b41b2052d0000211c41b3052d0000211d41b4052d0000211e41b5052d0000211f41b6052d0000212041b7052d0000212441b8052d0000212541b9052d0000212641ba052d0000212841bb052d0000212a41bc052d0000212b41bd052d0000212d41be052d0000212941bf052d0000212741204101417f1011220341276a20273a0000200341266a20293a0000200341256a202d3a0000200341246a202b3a0000200341236a202a3a0000200341226a20283a0000200341216a20263a0000200341206a20253a00002003411f6a20243a00002003411e6a20203a00002003411d6a201f3a00002003411c6a201e3a00002003411b6a201d3a00002003411a6a201c3a0000200341196a201b3a0000200341186a201a3a0000200341176a20193a0000200341166a20183a0000200341156a20173a0000200341146a20163a0000200341136a20153a0000200341126a20143a0000200341116a20133a0000200341106a20123a00002003410f6a20113a00002003410e6a200f3a00002003410d6a200e3a00002003410c6a200a3a00002003410b6a20233a00002003410a6a20223a0000200341096a200d3a0000200341086a220420103a000041b003411c20042003280200410020031b10132204280200410020041b41204b044020042802002103200741206b220b2400200441086a222c2003410020041b200b1005200b41206b220322072400200b2003100f200641d8006a200341186a2903003703002006200341106a2903003703502006200341086a29030037034820062003290300370340200641406b202c412010100b41e1004101417f1011220b41086a222c41063a0000202c41016a2203200d3a0001200320103a0000200320223a0002200320233a00032003200a3a00042003200e3a00052003200f3a0006200320113a0007200320123a0008200320133a0009200320143a000a200320153a000b200320163a000c200320173a000d200320183a000e200320193a000f2003201a3a00102003201b3a00112003201c3a00122003201d3a00132003201e3a00142003201f3a0015200320203a0016200320243a0017200320253a0018200320263a0019200320283a001a2003202a3a001b2003202b3a001c2003202d3a001d200320293a001e200320273a001f202c41216a22032002370308200320ba01370300200320b401370310200341186a20ac013703000c060b200641e0006a240020030c070b000b000b000b000b000b200b41c9006a220320b001370308200320b201370300200320ad01370310200341186a20ab01370300200741d0006b22032400200341083a0000200741cf006b22104108100e201041d0034120100d2007412f6b200441086a2004280200410020041b100d200341c100200b41086a200b2802004100200b1b1006200941186a20ab01370300200920ad01370310200920b001370308200920b201370300202120b901370310202141186a20af0137030020212001370300202120b301370308200641e0006a240041000c010b200641e0006a240020030b22030d02202141186a2903002101202141106a2903002102202141086a29030021ae01200941186a29030021ab01200941106a29030021ac01200941086a29030021ad01202129030021af01200929030021b001200c41386a4200370300200c41186a4200370300200c4200370330200c4200370328200c4201370320200c4200370310200c4200370308200c4201370300200c4120200c41206a412010011a0c010b0c010b200020b001370300200020ad01370308200020ac01370310200041186a20ab0137030020052002370310200541186a2001370300200520af01370300200520ae01370308200c41406b240041000c010b200c41406b240020030b0d3c0c370b41c3052d0000210b41c2052d0000212141c1052d0000211041c0052d0000210d41bf052d0000212241be052d0000212341bd052d0000210a41bc052d0000210e41bb052d0000210f41ba052d0000211141b9052d0000211241b8052d0000211341b7052d0000211441b6052d0000211541b5052d0000211641b4052d0000211741b3052d0000211841b2052d0000211941b1052d0000211a41b0052d0000211b41af052d0000211c41ae052d0000211d41ad052d0000211e41ac052d0000211f41ab052d0000212041aa052d0000212441a9052d0000212541a8052d0000212641a7052d0000212841a6052d0000212a41a5052d0000212b41a4052d0000212d41c40529030021b00141dc0529030021b50141d40529030021b30141cc0529030021b40141e40529030021c00141fc0529030021b70141f40529030021bb0141ec0529030021bd01200841206b22052400027f230041406a220c240002400240101e2200450440200c41206b22092400027f230041a0046b22002400200041406a22032400200341186a4200370300200342003703102003420037030820034211370300200341206a202d3a0000200341216a202b3a0000200341226a202a3a0000200341236a20283a0000200341246a20263a0000200341256a20253a0000200341266a20243a0000200341276a20203a0000200341286a201f3a0000200341296a201e3a00002003412a6a201d3a00002003412b6a201c3a00002003412c6a201b3a00002003412d6a201a3a00002003412e6a20193a00002003412f6a20183a0000200341306a20173a0000200341316a20163a0000200341326a20153a0000200341336a20143a0000200341346a20133a0000200341356a20123a0000200341366a20113a0000200341376a200f3a0000200341386a200e3a0000200341396a200a3a00002003413a6a20233a00002003413b6a20223a00002003413c6a200d3a00002003413d6a20103a00002003413e6a20213a00002003413f6a200b3a0000200341c000200041286a10024198054101360200200041206a200041406b2903003703002000200041386a2903003703182000200041306a290300370310200020002903283703080240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200041086a412041a0054198051003047f41000541a0052d00000b4101710440200341206b22042400200441186a420037030020044200370310200442003703082004420837030041980541203602002004412041a0054198051003210341a0052d0000212c41a1052d0000212e41a2052d0000213041a3052d0000212f41a4052d0000213641a5052d0000213741a6052d0000213841a7052d0000213241a8052d0000213141a9052d0000213341aa052d0000213441ab052d0000213941ac052d0000213a41ad052d0000213b41ae052d0000213c41af052d0000213d41b0052d0000213e41b1052d0000213f41b2052d0000214041b3052d0000214141b4052d0000214241b5052d0000214341b6052d0000214441b7052d0000214641b8052d0000214541b9052d0000213541ba052d0000214741bb052d0000214841bc052d0000214b41bd052d0000214c41be052d0000214941bf052d0000214d200441206b22062400200641186a420037030020064200370310200642003703082006420837030041980541203602002006412041a0054198051003210441a0052d0000214a41a1052d0000214e41a2052d0000214f41a3052d0000215041a4052d0000215141a5052d0000215241a6052d0000215341a7052d0000215441a8052d0000215541a9052d0000215641aa052d0000215741ab052d0000215841ac052d0000215941ad052d0000215a41ae052d0000215b41af052d0000215c41b0052d0000215d41b1052d0000215e41b2052d0000215f41b3052d0000216041b4052d0000216141b5052d0000216241b6052d0000216341b7052d0000216441b8052d0000216741b9052d0000216841ba052d0000216941bb052d0000216a41bc052d0000216541bd052d0000216641be052d0000216b41bf052d0000216c200641206b2206226d2400200641186a420037030020064200370310200642003703082006420c37030041980541203602002006412041a0054198051003210641bf052d0000216e41be052d0000216f41bd052d0000217041bc052d0000217141bb052d0000217241ba052d0000217341b9052d0000217441b8052d0000217541b7052d0000217641b6052d0000217741b5052d0000217841b4052d0000217941b3052d0000217a41b2052d0000217b41b1052d0000217c41b0052d0000217d41af052d0000217e41ae052d0000217f41ad052d000021800141ac052d000021810141ab052d000021820141aa052d000021830141a9052d000021840141a8052d000021850141a7052d000021860141a6052d000021870141a5052d000021880141a4052d000021890141a3052d0000218a0141a2052d0000218b0141a1052d0000218c0141a0052d0000218d0141244101417f10112129200041b2e0d8c003360248200041c8006a202941086a222741041010202741046a22074100204e20041b3a000120074100204a20041b3a000020074100204f20041b3a000220074100205020041b3a000320074100205120041b3a000420074100205220041b3a000520074100205320041b3a000620074100205420041b3a000720074100205520041b3a000820074100205620041b3a000920074100205720041b3a000a20074100205820041b3a000b20074100205920041b3a000c20074100205a20041b3a000d20074100205b20041b3a000e20074100205c20041b3a000f20074100205d20041b3a001020074100205e20041b3a001120074100205f20041b3a001220074100206020041b3a001320074100206120041b3a001420074100206220041b3a001520074100206320041b3a001620074100206420041b3a001720074100206720041b3a001820074100206820041b3a001920074100206920041b3a001a20074100206a20041b3a001b20074100206520041b3a001c20074100206620041b3a001d20074100206b20041b3a001e20074100206c20041b3a001f20004100206e20061b3a006b20004100206f20061b3a006a20004100207020061b3a006920004100207120061b3a006820004100207220061b3a006720004100207320061b3a006620004100207420061b3a006520004100207520061b3a006420004100207620061b3a006320004100207720061b3a006220004100207820061b3a006120004100207920061b3a006020004100207a20061b3a005f20004100207b20061b3a005e20004100207c20061b3a005d20004100207d20061b3a005c20004100207e20061b3a005b20004100207f20061b3a005a2000410020800120061b3a00592000410020810120061b3a00582000410020820120061b3a00572000410020830120061b3a00562000410020840120061b3a00552000410020850120061b3a00542000410020860120061b3a00532000410020870120061b3a00522000410020880120061b3a00512000410020890120061b3a005020004100208a0120061b3a004f20004100208b0120061b3a004e20004100208c0120061b3a004d20004100208d0120061b3a004c20292802002106206d41106b2204224a24002004420037030820044200370300419805418080023602004100200041cc006a4200200420272006410020291b41a00541980510080d01419805280200410141a00510112204280200410020041b22064120490d02419805280200410141a00510112104200641204b0d03200441276a2d00002129200441266a2d00002127200441256a2d0000214e200441246a2d0000214f200441236a2d00002150200441226a2d00002151200441216a2d00002152200441206a2d000021532004411f6a2d000021542004411e6a2d000021552004411d6a2d000021562004411c6a2d000021572004411b6a2d000021582004411a6a2d00002159200441196a2d0000215a200441186a2d0000215b200441176a2d0000215c200441166a2d0000215d200441156a2d0000215e200441146a2d0000215f200441136a2d00002160200441126a2d00002161200441116a2d00002162200441106a2d000021632004410f6a2d000021642004410e6a2d000021672004410d6a2d000021682004410c6a2d000021692004410b6a2d0000216a2004410a6a2d00002165200441096a2d00002166200441086a2d0000216b41244101417f1011210620004187dee59a7b36026c200041ec006a200641086a220741041010200741046a22044100202e20031b3a000120044100202c20031b3a000020044100203020031b3a000220044100202f20031b3a000320044100203620031b3a000420044100203720031b3a000520044100203820031b3a000620044100203220031b3a000720044100203120031b3a000820044100203320031b3a000920044100203420031b3a000a20044100203920031b3a000b20044100203a20031b3a000c20044100203b20031b3a000d20044100203c20031b3a000e20044100203d20031b3a000f20044100203e20031b3a001020044100203f20031b3a001120044100204020031b3a001220044100204120031b3a001320044100204220031b3a001420044100204320031b3a001520044100204420031b3a001620044100204620031b3a001720044100204520031b3a001820044100203520031b3a001920044100204720031b3a001a20044100204820031b3a001b20044100204b20031b3a001c20044100204c20031b3a001d20044100204920031b3a001e20044100204d20031b3a001f200020293a008f01200020273a008e012000204e3a008d012000204f3a008c01200020503a008b01200020513a008a01200020523a008901200020533a008801200020543a008701200020553a008601200020563a008501200020573a008401200020583a008301200020593a0082012000205a3a0081012000205b3a0080012000205c3a007f2000205d3a007e2000205e3a007d2000205f3a007c200020603a007b200020613a007a200020623a0079200020633a0078200020643a0077200020673a0076200020683a0075200020693a00742000206a3a0073200020653a0072200020663a00712000206b3a007020062802002104204a41106b220324002003420037030820034200370300419805418080023602004100200041f0006a4200200320072004410020061b41a00541980510080d04419805280200410141a00510112204280200410020041b22064120490d05419805280200410141a00510112104200641204b0d06200441206a29030021ab01200441186a29030021ac01200441106a29030021ad01200441086a29030021af0141244101417f10112104200041c5ae91e07c3602900120004190016a200441086a220741041010200741046a220620b401370308200620b001370300200620b301370310200641186a20b501370300200020263a009801200020283a0097012000202a3a0096012000202b3a0095012000202d3a009401200020253a009901200020243a009a01200020203a009b012000201f3a009c012000201e3a009d012000201d3a009e012000201c3a009f012000201b3a00a0012000201a3a00a101200020193a00a201200020183a00a301200020173a00a401200020163a00a501200020153a00a601200020143a00a701200020133a00a801200020123a00a901200020113a00aa012000200f3a00ab012000200e3a00ac012000200a3a00ad01200020233a00ae01200020223a00af012000200d3a00b001200020103a00b101200020213a00b2012000200b3a00b30120042802002106200341106b22032400200342003703082003420037030041980541808002360200410020004194016a4200200320072006410020041b41a00541980510080d07419805280200410141a00510112204280200410020041b22064120490d08419805280200410141a00510112104200641204b0d09200441206a29030021b901200441186a29030021b601200441106a29030021ba01200441086a29030021b80141044101417f101121062000418fdcd4c6033602b401200041b4016a200641086a220741041010200020283a00bb012000202a3a00ba012000202b3a00b9012000202d3a00b801200020263a00bc01200020253a00bd01200020243a00be01200020203a00bf012000201f3a00c0012000201e3a00c1012000201d3a00c2012000201c3a00c3012000201b3a00c4012000201a3a00c501200020193a00c601200020183a00c701200020173a00c801200020163a00c901200020153a00ca01200020143a00cb01200020133a00cc01200020123a00cd01200020113a00ce012000200f3a00cf012000200e3a00d0012000200a3a00d101200020233a00d201200020223a00d3012000200d3a00d401200020103a00d501200020213a00d6012000200b3a00d70120062802002129200341106b220424002004420037030820044200370300419805418080023602004100200041b8016a4200200420072029410020061b41a00541980510080d0a419805280200410141a00510112203280200410020031b22064120490d0b419805280200410141a00510112103200641204b0d0c200341276a2d00002107200341266a2d00002129200341256a2d00002127200341246a2d0000212c200341236a2d0000212e200341226a2d00002130200341216a2d0000212f200341206a2d000021362003411f6a2d000021372003411e6a2d000021382003411d6a2d000021322003411c6a2d000021312003411b6a2d000021332003411a6a2d00002134200341196a2d00002139200341186a2d0000213a200341176a2d0000213b200341166a2d0000213c200341156a2d0000213d200341146a2d0000213e200341136a2d0000213f200341126a2d00002140200341116a2d00002141200341106a2d000021422003410f6a2d000021432003410e6a2d000021442003410d6a2d000021462003410c6a2d000021452003410b6a2d000021352003410a6a2d00002147200341096a2d00002148200341086a2d000041044101417f101121062000418ed4bdf47e3602d801200041d8016a200641086a224c41041010200020283a00df012000202a3a00de012000202b3a00dd012000202d3a00dc01200020263a00e001200020253a00e101200020243a00e201200020203a00e3012000201f3a00e4012000201e3a00e5012000201d3a00e6012000201c3a00e7012000201b3a00e8012000201a3a00e901200020193a00ea01200020183a00eb01200020173a00ec01200020163a00ed01200020153a00ee01200020143a00ef01200020133a00f001200020123a00f101200020113a00f2012000200f3a00f3012000200e3a00f4012000200a3a00f501200020233a00f601200020223a00f7012000200d3a00f801200020103a00f901200020213a00fa012000200b3a00fb0120062802002149200441106b220324002003420037030820034200370300419805418080023602004100200041dc016a42002003204c2049410020061b41a00541980510080d0d419805280200410141a00510112204280200410020041b220641c000490d0e419805280200410141a0051011220441206a2903002101200441186a2903002102200441106a29030021ae01200441086a290300419805280200410141a0051011200641c0004b0d0f41206a220441086a2903005a20ae01200441106a29030022b2015a20ae0120b201511b2002200441186a29030022b2015a2001200441206a29030022ae015a200120ae01511b200220b20185200120ae018584501b0d10200341206b220324002048204720352045204620442043204220412040203f203e203d203c203b203a20392034203320312032203820372036202f2030202e202c20272029200720b80120ba0120b60120b90120af0120ad0120ac0120ab012003102522040d19200341186a29030021ae01200341106a29030021ab01200341086a2903002101200329030021ac0141c4004101417f10112104200041bdeffca27e3602fc01200041fc016a200441086a220641041010419805412036020041a005419805100441a005290300210241a80529030021ad0141b00529030021af01200641046a220741b805290300370018200720af01370010200720ad0137000820072002370000200641246a220720b401370308200720b001370300200720b301370310200741186a20b501370300200020263a008402200020283a0083022000202a3a0082022000202b3a0081022000202d3a008002200020253a008502200020243a008602200020203a0087022000201f3a0088022000201e3a0089022000201d3a008a022000201c3a008b022000201b3a008c022000201a3a008d02200020193a008e02200020183a008f02200020173a009002200020163a009102200020153a009202200020143a009302200020133a009402200020123a009502200020113a0096022000200f3a0097022000200e3a0098022000200a3a009902200020233a009a02200020223a009b022000200d3a009c02200020103a009d02200020213a009e022000200b3a009f0220042802002107200341106b22032400200342003703082003420037030041980541808002360200410020004180026a4200200320062007410020041b41a00541980510080d11419805280200410141a00510112204280200410020041b22064120490d12419805280200410141a00510112104200641204b0d13420021af01200041d8026a027e0240200441086a29030020b80185200441186a29030020b6018584200441106a29030020ba0185200441206a29030020b901858484500440200341406a22032400200341186a4200370300200342003703102003420037030820034210370300200341206a202d3a0000200341216a202b3a0000200341226a202a3a0000200341236a20283a0000200341246a20263a0000200341256a20253a0000200341266a20243a0000200341276a20203a0000200341286a201f3a0000200341296a201e3a00002003412a6a201d3a00002003412b6a201c3a00002003412c6a201b3a00002003412d6a201a3a00002003412e6a20193a00002003412f6a20183a0000200341306a20173a0000200341316a20163a0000200341326a20153a0000200341336a20143a0000200341346a20133a0000200341356a20123a0000200341366a20113a0000200341376a200f3a0000200341386a200e3a0000200341396a200a3a00002003413a6a20233a00002003413b6a20223a00002003413c6a200d3a00002003413d6a20103a00002003413e6a20213a00002003413f6a200b3a0000200341206b22042400200341c0002004100220042903002102200441086a29030021ad01200441106a29030021b201200441186a29030021b101200441206b22032400200341186a20b101370300200320b201370310200320ad013703082003200237030041980541203602002003412041a0054198051003450d01420021b101420021b20142000c020b000b41b00529030021b20141a80529030021b10141a00529030021af0141b8052903000b370300200041b8026a20ae01370300200020af013703c002200020ac013703a002200020b1013703c802200020013703a802200020b2013703d002200020ab013703b002200041a0026a200041c0026a200041e0026a410810150d14200041f8026a2903002102200041f0026a29030021ad01200041e8026a29030021af0120002903e00221b201200041b8036a420037030020004198036a2002370300200042003703b003200042003703a80320004290ce003703a003200020b20137038003200020af0137038803200020ad013703900320004180036a200041a0036a200041c0036a200041e0036a10180d1520ac0120002903e00322ad017d22b20120ac01562001200041e8036a29030022027d20ac0120ad01542204ad7d22ad01200156200120ad01511b20ab01200041f0036a29030022b1017d22c1012004200120025420012002511bad22027d22af0120ab015620ae01200041f8036a2903007d20ab0120b10154ad7d200220c10156ad7d220220ae0156200220ae01511b20ab0120af0185200220ae018584501b0d1620b20120c0015a20ad0120bd015a20ad0120bd01511b20af0120bb015a200220b7015a200220b701511b20af0120bb0185200220b7018584501b450d17200341206b220322062400200341186a420037030020034200370310200342003703082003420837030041980541203602002003412041a0054198051003210341a0052d0000210441a1052d0000210741a2052d0000212941a3052d0000212741a4052d0000212c41a5052d0000212e41a6052d0000213041a7052d0000212f41a8052d0000213641a9052d0000213741aa052d0000213841ab052d0000213241ac052d0000213141ad052d0000213341ae052d0000213441af052d0000213941b0052d0000213a41b1052d0000213b41b2052d0000213c41b3052d0000213d41b4052d0000213e41b5052d0000213f41b6052d0000214041b7052d0000214141b8052d0000214241b9052d0000214341ba052d0000214441bb052d0000214641bc052d0000214541bd052d0000213541be052d0000214741bf052d00002148419805412036020041a00541980510044100200420031b4100200720031b4100202920031b4100202720031b4100202c20031b4100202e20031b4100203020031b4100202f20031b4100203620031b4100203720031b4100203820031b4100203220031b4100203120031b4100203320031b4100203420031b4100203920031b4100203a20031b4100203b20031b4100203c20031b4100203d20031b4100203e20031b4100203f20031b4100204020031b4100204120031b4100204220031b4100204320031b4100204420031b4100204620031b4100204520031b4100203520031b4100204720031b4100204820031b41a0052d000041a1052d000041a2052d000041a3052d000041a4052d000041a5052d000041a6052d000041a7052d000041a8052d000041a9052d000041aa052d000041ab052d000041ac052d000041ad052d000041ae052d000041af052d000041b0052d000041b1052d000041b2052d000041b3052d000041b4052d000041b5052d000041b6052d000041b7052d000041b8052d000041b9052d000041ba052d000041bb052d000041bc052d000041bd052d000041be052d000041bf052d000020b20120ad0120af012002102122040d19419805412036020041a005419805100441a0052d0000212941a1052d0000212741a2052d0000212c41a3052d0000212e41a4052d0000213041a5052d0000212f41a6052d0000213641a7052d0000213741a8052d0000213841a9052d0000213241aa052d0000213141ab052d0000213341ac052d0000213441ad052d0000213941ae052d0000213a41af052d0000213b41b0052d0000213c41b1052d0000213d41b2052d0000213e41b3052d0000213f41b4052d0000214041b5052d0000214141b6052d0000214241b7052d0000214341b8052d0000214441b9052d0000214641ba052d0000214541bb052d0000213541bc052d0000214741bd052d0000214841be052d0000214b41bf052d0000214c41204101417f1011220341276a204c3a0000200341266a204b3a0000200341256a20483a0000200341246a20473a0000200341236a20353a0000200341226a20453a0000200341216a20463a0000200341206a20443a00002003411f6a20433a00002003411e6a20423a00002003411d6a20413a00002003411c6a20403a00002003411b6a203f3a00002003411a6a203e3a0000200341196a203d3a0000200341186a203c3a0000200341176a203b3a0000200341166a203a3a0000200341156a20393a0000200341146a20343a0000200341136a20333a0000200341126a20313a0000200341116a20323a0000200341106a20383a00002003410f6a20373a00002003410e6a20363a00002003410d6a202f3a00002003410c6a20303a00002003410b6a202e3a00002003410a6a202c3a0000200341096a20273a0000200341086a220420293a000041f003412a20042003280200410020031b10132204280200410020041b41204b044020042802002103200641206b22072400200441086a22492003410020041b20071005200741206b22032206240020072003100f20004198046a200341186a2903003703002000200341106a290300370390042000200341086a29030037038804200020032903003703800420004180046a2049412010100b41a1014101417f1011220741086a224941073a0000204941016a220320273a0001200320293a00002003202c3a00022003202e3a0003200320303a00042003202f3a0005200320363a0006200320373a0007200320383a0008200320323a0009200320313a000a200320333a000b200320343a000c200320393a000d2003203a3a000e2003203b3a000f2003203c3a00102003203d3a00112003203e3a00122003203f3a0013200320403a0014200320413a0015200320423a0016200320433a0017200320443a0018200320463a0019200320453a001a200320353a001b200320473a001c200320483a001d2003204b3a001e2003204c3a001f204941216a2203202b3a00012003202d3a00002003202a3a0002200320283a0003200320263a0004200320253a0005200320243a0006200320203a00072003201f3a00082003201e3a00092003201d3a000a2003201c3a000b2003201b3a000c2003201a3a000d200320193a000e200320183a000f200320173a0010200320163a0011200320153a0012200320143a0013200320133a0014200320123a0015200320113a00162003200f3a00172003200e3a00182003200a3a0019200320233a001a200320223a001b2003200d3a001c200320103a001d200320213a001e2003200b3a001f200741216a220b41286a220320b401370308200320b001370300200320b301370310200341186a20b501370300200b41c8006a220320ba01370308200320b801370300200320b601370310200341186a20b9013703000c180b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b20074189016a22032001370308200320ac01370300200320ab01370310200341186a20ae01370300200641d0006b22032400200341083a0000200641cf006b220b4108100e200b41a0044120100d2006412f6b200441086a2004280200410020041b100d200341c100200741086a2007280200410020071b1006200941186a2002370300200920af01370310200920ad01370308200920b201370300200041a0046a240041000c010b200041a0046a240020040b22000d01200941186a2903002101200941106a2903002102200941086a29030021ae01200929030021ab01200c41386a4200370300200c41186a4200370300200c4200370330200c4200370328200c4201370320200c4200370310200c4200370308200c4201370300200c4120200c41206a412010011a0c020b200c41406b240020000c020b200c41406b240020000c010b200520ab01370300200520ae0137030820052002370310200541186a2001370300200c41406b240041000b450d2e0c3b0b41c3052d0000212141c2052d0000211041c1052d0000210d41c0052d0000212241bf052d0000212341be052d0000210a41bd052d0000210e41bc052d0000210f41bb052d0000211141ba052d0000211241b9052d0000211341b8052d0000211441b7052d0000211541b6052d0000211641b5052d0000211741b4052d0000211841b3052d0000211941b2052d0000211a41b1052d0000211b41b0052d0000211c41af052d0000211d41ae052d0000211e41ad052d0000211f41ac052d0000212041ab052d0000212441aa052d0000212541a9052d0000212641a8052d0000212841a7052d0000212a41a6052d0000212b41a5052d0000212d41a4052d0000212941c40529030021ba0141dc0529030021ab0141d40529030021b70141cc0529030021b90141e405290300210141fc0529030021ad0141f40529030021be0141ec0529030021bf01200841206b22052400027f2001210242002101230041406a220c240002400240101e2200450440200c41206b220b2400027f230041d0036b22032400200341406a22002400200041186a4200370300200042003703102000420037030820004211370300200041206a20293a0000200041216a202d3a0000200041226a202b3a0000200041236a202a3a0000200041246a20283a0000200041256a20263a0000200041266a20253a0000200041276a20243a0000200041286a20203a0000200041296a201f3a00002000412a6a201e3a00002000412b6a201d3a00002000412c6a201c3a00002000412d6a201b3a00002000412e6a201a3a00002000412f6a20193a0000200041306a20183a0000200041316a20173a0000200041326a20163a0000200041336a20153a0000200041346a20143a0000200041356a20133a0000200041366a20123a0000200041376a20113a0000200041386a200f3a0000200041396a200e3a00002000413a6a200a3a00002000413b6a20233a00002000413c6a20223a00002000413d6a200d3a00002000413e6a20103a00002000413f6a20213a0000200041c000200341206a10024198054101360200200341186a200341386a2903003703002003200341306a2903003703102003200341286a2903003703082003200329032037030002400240024002400240024002400240024002402003412041a0054198051003047f41000541a0052d00000b4101710440419805412036020041a005419805100441bf052d0000210441be052d0000210641bd052d0000210741bc052d0000210941bb052d0000212741ba052d0000212c41b9052d0000212e41b8052d0000213041b7052d0000212f41b6052d0000213641b5052d0000213741b4052d0000213841b3052d0000213241b2052d0000213141b1052d0000213341b0052d0000213441af052d0000213941ae052d0000213a41ad052d0000213b41ac052d0000213c41ab052d0000213d41aa052d0000213e41a9052d0000213f41a8052d0000214041a7052d0000214141a6052d0000214241a5052d0000214341a4052d0000214441a3052d0000214641a2052d0000214541a1052d0000213541a0052d0000200041206b2200240020352045204620442043204220412040203f203e203d203c203b203a20392034203320312032203820372036202f2030202e202c202720092007200620042000101922040d0a200029030020ba015a200041086a29030022ae0120b9015a20ae0120b901511b200041106a29030022ac0120b7015a200041186a29030022ae0120ab015a20ab0120ae01511b20ac0120b7018520ab0120ae018584501b450d0141044101417f101121062003418fdcd4c603360244200341c4006a200641086a2207410410102003202a3a004b2003202b3a004a2003202d3a0049200320293a0048200320283a004c200320263a004d200320253a004e200320243a004f200320203a00502003201f3a00512003201e3a00522003201d3a00532003201c3a00542003201b3a00552003201a3a0056200320193a0057200320183a0058200320173a0059200320163a005a200320153a005b200320143a005c200320133a005d200320123a005e200320113a005f2003200f3a00602003200e3a00612003200a3a0062200320233a0063200320223a00642003200d3a0065200320103a0066200320213a006720062802002109200041106b220424002004420037030820044200370300419805418080023602004100200341c8006a4200200420072009410020061b41a00541980510080d02419805280200410141a00510112200280200410020001b22064120490d03419805280200410141a00510112100200641204b0d04200041276a2d00002127200041266a2d0000212c200041256a2d0000212e200041246a2d00002130200041236a2d0000212f200041226a2d00002136200041216a2d00002137200041206a2d000021382000411f6a2d000021322000411e6a2d000021312000411d6a2d000021332000411c6a2d000021342000411b6a2d000021392000411a6a2d0000213a200041196a2d0000213b200041186a2d0000213c200041176a2d0000213d200041166a2d0000213e200041156a2d0000213f200041146a2d00002140200041136a2d00002141200041126a2d00002142200041116a2d00002143200041106a2d000021442000410f6a2d000021462000410e6a2d000021452000410d6a2d000021352000410c6a2d000021472000410b6a2d000021482000410a6a2d0000214b200041096a2d0000214c200041086a2d00002149200441206b22002400200041186a420037030020004200370310200042003703082000420a37030041980541203602002000412041a0054198051003047e42000541b00529030021b20141a805290300210141a00529030021b80141b8052903000b21ae01200041206b220024004198054120360200200341c8036a4200370300200342003703c003200342003703b803200342053703b003200341b0036a412041a0054198051003047e42000541b00529030021b50141a80529030021b10141a00529030021af0141b8052903000b21ac01200020af01370300200020b101370308200020b501370310200041186a220420ac0137030020034180016a20ae01370300200341a0016a20ab01370300200320b801370368200320ba013703880120032001370370200320b90137039001200320b201370378200320b7013703980120042903002101200041106a29030021ae01200041086a29030021ac01200029030021af01200341e8006a20034188016a200341a8016a410810150d05200341c0016a29030021b201200341b8016a29030021b101200341b0016a29030021b50120032903a80121b60120034180026a2001370300200341e0016a20b201370300200320af013703e801200320b6013703c801200320ac013703f001200320b5013703d001200320ae013703f801200320b1013703d801200341c8016a200341e8016a20034188026a200341a8026a10180d06200341c0026a29030021b801200341b8026a29030021b201200341b0026a29030021ac0120032903a80221b501200041206b22092400027f230041b0066b220024004198054120360200200041d0006a4200370300200042003703482000420037034020004208370338200041386a412041a0054198051003210641a0052d0000214d41a1052d0000214a41a2052d0000214e41a3052d0000214f41a4052d0000215041a5052d0000215141a6052d0000215241a7052d0000215341a8052d0000215441a9052d0000215541aa052d0000215641ab052d0000215741ac052d0000215841ad052d0000215941ae052d0000215a41af052d0000215b41b0052d0000215c41b1052d0000215d41b2052d0000215e41b3052d0000215f41b4052d0000216041b5052d0000216141b6052d0000216241b7052d0000216341b8052d0000216441b9052d0000216741ba052d0000216841bb052d0000216941bc052d0000216a41bd052d0000216541be052d0000216641bf052d0000216b200041306a4200370300419805412036020020004200370328200042003703202000420c370318200041186a412041a0054198051003210741a0052d0000216c41a1052d0000216d41a2052d0000216e41a3052d0000216f41a4052d0000217041a5052d0000217141a6052d0000217241a7052d0000217341a8052d0000217441a9052d0000217541aa052d0000217641ab052d0000217741ac052d0000217841ad052d0000217941ae052d0000217a41af052d0000217b41b0052d0000217c41b1052d0000217d41b2052d0000217e41b3052d0000217f41b4052d000021800141b5052d000021810141b6052d000021820141b7052d000021830141b8052d000021840141b9052d000021850141ba052d000021860141bb052d000021870141bc052d000021880141bd052d000021890141be052d0000218a0141bf052d0000218b0141244101417f10112104200041b2e0d8c00336025c200041dc006a200441086a228c01410410102004412b6a4100206b20061b226b3a00002004412a6a4100206620061b22663a0000200441296a4100206520061b22653a0000200441286a4100206a20061b226a3a0000200441276a4100206920061b22693a0000200441266a4100206820061b22683a0000200441256a4100206720061b22673a0000200441246a4100206420061b22643a0000200441236a4100206320061b22633a0000200441226a4100206220061b22623a0000200441216a4100206120061b22613a0000200441206a4100206020061b22603a00002004411f6a4100205f20061b225f3a00002004411e6a4100205e20061b225e3a00002004411d6a4100205d20061b225d3a00002004411c6a4100205c20061b225c3a00002004411b6a4100205b20061b225b3a00002004411a6a4100205a20061b225a3a0000200441196a4100205920061b22593a0000200441186a4100205820061b22583a0000200441176a4100205720061b22573a0000200441166a4100205620061b22563a0000200441156a4100205520061b22553a0000200441146a4100205420061b22543a0000200441136a4100205320061b22533a0000200441126a4100205220061b22523a0000200441116a4100205120061b22513a0000200441106a4100205020061b22503a00002004410f6a4100204f20061b224f3a00002004410e6a4100204e20061b224e3a00002004410d6a4100204a20061b224a3a00002004410c6a4100204d20061b22063a000020004100208b0120071b224d3a007f20004100208a0120071b228a013a007e2000410020890120071b2289013a007d2000410020880120071b2288013a007c2000410020870120071b2287013a007b2000410020860120071b2286013a007a2000410020850120071b2285013a00792000410020840120071b2284013a00782000410020830120071b2283013a00772000410020820120071b2282013a00762000410020810120071b2281013a00752000410020800120071b2280013a007420004100207f20071b227f3a007320004100207e20071b227e3a007220004100207d20071b227d3a007120004100207c20071b227c3a007020004100207b20071b227b3a006f20004100207a20071b227a3a006e20004100207920071b22793a006d20004100207820071b22783a006c20004100207720071b22773a006b20004100207620071b22763a006a20004100207520071b22753a006920004100207420071b22743a006820004100207320071b22733a006720004100207220071b22723a006620004100207120071b22713a006520004100207020071b22703a006420004100206f20071b226f3a006320004100206e20071b226e3a006220004100206d20071b226d3a006120004100206c20071b22073a00602004280200216c41980541808002360200200042003703102000420037030802400240024002400240024002400240024002400240024002400240024002400240024002404100200041e0006a4200200041086a208c01206c410020041b41a0054198051008450440419805280200410141a00510112204280200410020041b226c411f4d0d01419805280200410141a00510112104206c41204b0d02200441276a2d0000216c200441266a2d0000218b01200441256a2d0000218c01200441246a2d0000218d01200441236a2d0000218e01200441226a2d0000218f01200441216a2d0000219001200441206a2d00002191012004411f6a2d00002192012004411e6a2d00002193012004411d6a2d00002194012004411c6a2d00002195012004411b6a2d00002196012004411a6a2d0000219701200441196a2d0000219801200441186a2d0000219901200441176a2d0000219a01200441166a2d0000219b01200441156a2d0000219c01200441146a2d0000219d01200441136a2d0000219e01200441126a2d0000219f01200441116a2d000021a001200441106a2d000021a1012004410f6a2d000021a2012004410e6a2d000021a3012004410d6a2d000021a4012004410c6a2d000021a5012004410b6a2d000021a6012004410a6a2d000021a701200441096a2d000021a801200441086a2d000021a90141244101417f1011210420004187dee59a7b3602800120004180016a200441086a22aa01410410102004410f6a204f3a00002004410e6a204e3a00002004410d6a204a3a00002004410c6a20063a0000200441106a20503a0000200441116a20513a0000200441126a20523a0000200441136a20533a0000200441146a20543a0000200441156a20553a0000200441166a20563a0000200441176a20573a0000200441186a20583a0000200441196a20593a00002004411a6a205a3a00002004411b6a205b3a00002004411c6a205c3a00002004411d6a205d3a00002004411e6a205e3a00002004411f6a205f3a0000200441206a20603a0000200441216a20613a0000200441226a20623a0000200441236a20633a0000200441246a20643a0000200441256a20673a0000200441266a20683a0000200441276a20693a0000200441286a206a3a0000200441296a20653a00002004412a6a20663a00002004412b6a206b3a00002000206c3a00a3012000208b013a00a2012000208c013a00a1012000208d013a00a0012000208e013a009f012000208f013a009e0120002090013a009d0120002091013a009c0120002092013a009b0120002093013a009a0120002094013a00990120002095013a00980120002096013a00970120002097013a00960120002098013a00950120002099013a0094012000209a013a0093012000209b013a0092012000209c013a0091012000209d013a0090012000209e013a008f012000209f013a008e01200020a0013a008d01200020a1013a008c01200020a2013a008b01200020a3013a008a01200020a4013a008901200020a5013a008801200020a6013a008701200020a7013a008601200020a8013a008501200020a9013a0084012004280200214a200041106b22062400200642003703082006420037030041980541808002360200410020004184016a4200200620aa01204a410020041b41a00541980510080d03419805280200410141a00510112204280200410020041b224a411f4d0d04419805280200410141a00510112104204a41204b0d05200441206a2903002101200441186a29030021ae01200441106a29030021af01200441086a29030021b10141244101417f10112104200041b2e0d8c0033602a401200041a4016a200441086a224a410410102004410f6a20483a00002004410e6a204b3a00002004410d6a204c3a00002004410c6a20493a0000200441106a20473a0000200441116a20353a0000200441126a20453a0000200441136a20463a0000200441146a20443a0000200441156a20433a0000200441166a20423a0000200441176a20413a0000200441186a20403a0000200441196a203f3a00002004411a6a203e3a00002004411b6a203d3a00002004411c6a203c3a00002004411d6a203b3a00002004411e6a203a3a00002004411f6a20393a0000200441206a20343a0000200441216a20333a0000200441226a20313a0000200441236a20323a0000200441246a20383a0000200441256a20373a0000200441266a20363a0000200441276a202f3a0000200441286a20303a0000200441296a202e3a00002004412a6a202c3a00002004412b6a20273a00002000204d3a00c7012000208a013a00c60120002089013a00c50120002088013a00c40120002087013a00c30120002086013a00c20120002085013a00c10120002084013a00c00120002083013a00bf0120002082013a00be0120002081013a00bd0120002080013a00bc012000207f3a00bb012000207e3a00ba012000207d3a00b9012000207c3a00b8012000207b3a00b7012000207a3a00b601200020793a00b501200020783a00b401200020773a00b301200020763a00b201200020753a00b101200020743a00b001200020733a00af01200020723a00ae01200020713a00ad01200020703a00ac012000206f3a00ab012000206e3a00aa012000206d3a00a901200020073a00a80120042802002107200641106b220624002006420037030820064200370300419805418080023602004100200041a8016a42002006204a2007410020041b41a00541980510080d06419805280200410141a00510112204280200410020041b2207411f4d0d07419805280200410141a00510112104200741204b0d08200441276a2d00002107200441266a2d0000214d200441256a2d0000214a200441246a2d0000214e200441236a2d0000214f200441226a2d00002150200441216a2d00002151200441206a2d000021522004411f6a2d000021532004411e6a2d000021542004411d6a2d000021552004411c6a2d000021562004411b6a2d000021572004411a6a2d00002158200441196a2d00002159200441186a2d0000215a200441176a2d0000215b200441166a2d0000215c200441156a2d0000215d200441146a2d0000215e200441136a2d0000215f200441126a2d00002160200441116a2d00002161200441106a2d000021622004410f6a2d000021632004410e6a2d000021642004410d6a2d000021672004410c6a2d000021682004410b6a2d000021692004410a6a2d0000216a200441096a2d00002165200441086a2d0000216641244101417f1011210420004187dee59a7b3602c801200041c8016a200441086a226b410410102004410f6a20483a00002004410e6a204b3a00002004410d6a204c3a00002004410c6a20493a0000200441106a20473a0000200441116a20353a0000200441126a20453a0000200441136a20463a0000200441146a20443a0000200441156a20433a0000200441166a20423a0000200441176a20413a0000200441186a20403a0000200441196a203f3a00002004411a6a203e3a00002004411b6a203d3a00002004411c6a203c3a00002004411d6a203b3a00002004411e6a203a3a00002004411f6a20393a0000200441206a20343a0000200441216a20333a0000200441226a20313a0000200441236a20323a0000200441246a20383a0000200441256a20373a0000200441266a20363a0000200441276a202f3a0000200441286a20303a0000200441296a202e3a00002004412a6a202c3a00002004412b6a20273a0000200020073a00eb012000204d3a00ea012000204a3a00e9012000204e3a00e8012000204f3a00e701200020503a00e601200020513a00e501200020523a00e401200020533a00e301200020543a00e201200020553a00e101200020563a00e001200020573a00df01200020583a00de01200020593a00dd012000205a3a00dc012000205b3a00db012000205c3a00da012000205d3a00d9012000205e3a00d8012000205f3a00d701200020603a00d601200020613a00d501200020623a00d401200020633a00d301200020643a00d201200020673a00d101200020683a00d001200020693a00cf012000206a3a00ce01200020653a00cd01200020663a00cc0120042802002107200641106b220624002006420037030820064200370300419805418080023602004100200041cc016a42002006206b2007410020041b41a00541980510080d09419805280200410141a00510112204280200410020041b2207411f4d0d0a419805280200410141a00510112104200741204b0d0b200441086a29030022b601200441186a29030022bd0184200441106a29030022c201200441206a29030022c3018484500d0c41044101417f10112107200041e7caf389033602ec01200041ec016a200741086a224d41041010200020483a00f3012000204b3a00f2012000204c3a00f101200020493a00f001200020473a00f401200020353a00f501200020453a00f601200020463a00f701200020443a00f801200020433a00f901200020423a00fa01200020413a00fb01200020403a00fc012000203f3a00fd012000203e3a00fe012000203d3a00ff012000203c3a0080022000203b3a0081022000203a3a008202200020393a008302200020343a008402200020333a008502200020313a008602200020323a008702200020383a008802200020373a008902200020363a008a022000202f3a008b02200020303a008c022000202e3a008d022000202c3a008e02200020273a008f0220072802002127200641106b220424002004420037030820044200370300419805418080023602004100200041f0016a42002004204d2027410020071b41a00541980510080d0d419805280200410141a00510112206280200410020061b2206450d0e419805280200410141a0051011200641014b0d0f41086a2d0000200441206b22042400200441186a420037030020044200370310200442003703082004420b37030041980541203602002004412041a005419805100345044041a00529030021c4010b200041c8026a2001370300200041a8026a20b801370300200020b1013703b002200020b50137039002200020af013703b802200020ac0137039802200020ae013703c002200020b2013703a00220004190026a200041b0026a200041d0026a410810150d10200041e8026a2903002101200041e0026a29030021ae01200041d8026a29030021af0120002903d00221b101200041a8036a20c30137030020004188036a2001370300200020b60137039003200020b1013703f002200020c20137039803200020af013703f802200020bd013703a003200020ae0137038003200041f0026a20004190036a200041b0036a200041d0036a10180d12ad42ff018321b101200041e8036a29030021c201200041e0036a29030021c301200041d8036a29030021c50120002903d00321c601420a21af01420021bd0142002101420121b6010240034020b101a74101710440200041a8056a20c00137030020004188056a20b001370300200020af0137039005200020b6013703f004200020b40137039805200020b3013703f804200020c1013703a005200020bc0137038005200041f0046a20004190056a200041b0056a410810150d14200041c0056a29030021bc01200041b8056a29030021b30120002903b00521b601200041c8056a29030021b0010b20bd01423f8620b1014201888422b10120bb01423f8620014201888422ae01842001423f8620bd014201888422bd0120bb0142018822bb018484500d0120004188066a20c001370300200041e8056a20c001370300200020af013703f005200020af013703d005200020b4013703f805200020b4013703d805200020c10137038006200020c1013703e005200041d0056a200041f0056a20004190066a41081015200041a8066a29030021c001200041a0066a29030021c10120004198066a29030021b40120002903900621af0120ae012101450d000b000b20004188046a20b001370300200041a8046a20c201370300200041c8046a20b001370300200020b6013703f003200020b3013703f803200020bc0137038004200020c60137039004200020b6013703b004200020c50137039804200020b3013703b804200020c3013703a004200020bc013703c00420004190046a200041b0046a200041d0046a410810150d1320002903d00421012009420037031020094200370308200941186a42003703002009200120c40180370300200041b0066a240041000c140b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b22040d0a200941186a2903002101200941106a29030021ae01200941086a29030021b001200929030021b30141c4004101417f10112104200341deabac967c3602cc02200341cc026a200441086a220641041010200641046a220020b001370308200020b301370300200020ae01370310200041186a2001370300419805412036020041a005419805100441a00529030021af0141a80529030021b10141b00529030021b401200641246a220041b805290300370018200020b401370010200020b101370008200020af01370000200320283a00d4022003202a3a00d3022003202b3a00d2022003202d3a00d102200320293a00d002200320263a00d502200320253a00d602200320243a00d702200320203a00d8022003201f3a00d9022003201e3a00da022003201d3a00db022003201c3a00dc022003201b3a00dd022003201a3a00de02200320193a00df02200320183a00e002200320173a00e102200320163a00e202200320153a00e302200320143a00e402200320133a00e502200320123a00e602200320113a00e7022003200f3a00e8022003200e3a00e9022003200a3a00ea02200320233a00eb02200320223a00ec022003200d3a00ed02200320103a00ee02200320213a00ef0220042802002107200941106b220024002000420037030820004200370300419805418080023602004100200341d0026a4200200020062007410020041b41a00541980510080d07027e0240200220b3015820b00120bf015a20b00120bf01511b20ae0120be015a200120ad015a200120ad01511b20ae0120be0185200120ad018584501b0440200041206b22002400420021b101200041186a420037030020004200370310200042003703082000420a37030041980541203602002000412041a0054198051003450d01420021ad01420021af0142000c020b000b41b00529030021af0141a80529030021ad0141a00529030021b10141b8052903000b210220b10120b5017d22b60120b1015620ad0120ac017d20b10120b501542204ad7d22b10120ad015620ad0120b101511b20af0120b2017d22bb01200420ac0120ad015620ac0120ad01511bad22ad017d22b40120af0156200220b8017d20af0120b20154ad7d20ad0120bb0156ad7d22ad01200256200220ad01511b20af0120b40185200220ad018584501b0d08200041206b22002206240020034188036a20ad01370300200041186a420037030020004200370310200042003703082000420a370300200320b40137038003200320b1013703f802200320b6013703f00220004120200341f0026a412010011a419805412036020041a005419805100441a0052d000041a1052d000041a2052d000041a3052d000041a4052d000041a5052d000041a6052d000041a7052d000041a8052d000041a9052d000041aa052d000041ab052d000041ac052d000041ad052d000041ae052d000041af052d000041b0052d000041b1052d000041b2052d000041b3052d000041b4052d000041b5052d000041b6052d000041b7052d000041b8052d000041b9052d000041ba052d000041bb052d000041bc052d000041bd052d000041be052d000041bf052d000020ba0120b90120b70120ab01101d22040d0a419805412036020041a005419805100441a0052d0000210941a1052d0000212741a2052d0000212c41a3052d0000212e41a4052d0000213041a5052d0000212f41a6052d0000213641a7052d0000213741a8052d0000213841a9052d0000213241aa052d0000213141ab052d0000213341ac052d0000213441ad052d0000213941ae052d0000213a41af052d0000213b41b0052d0000213c41b1052d0000213d41b2052d0000213e41b3052d0000213f41b4052d0000214041b5052d0000214141b6052d0000214241b7052d0000214341b8052d0000214441b9052d0000214641ba052d0000214541bb052d0000213541bc052d0000214741bd052d0000214841be052d0000214b41bf052d0000214c41204101417f1011220041276a204c3a0000200041266a204b3a0000200041256a20483a0000200041246a20473a0000200041236a20353a0000200041226a20453a0000200041216a20463a0000200041206a20443a00002000411f6a20433a00002000411e6a20423a00002000411d6a20413a00002000411c6a20403a00002000411b6a203f3a00002000411a6a203e3a0000200041196a203d3a0000200041186a203c3a0000200041176a203b3a0000200041166a203a3a0000200041156a20393a0000200041146a20343a0000200041136a20333a0000200041126a20313a0000200041116a20323a0000200041106a20383a00002000410f6a20373a00002000410e6a20363a00002000410d6a202f3a00002000410c6a20303a00002000410b6a202e3a00002000410a6a202c3a0000200041096a20273a0000200041086a220420093a000041c004412c20042000280200410020001b10132204280200410020041b41204b044020042802002100200641206b22072400200441086a22492000410020041b20071005200741206b22002206240020072000100f200341a8036a200041186a2903003703002003200041106a2903003703a0032003200041086a29030037039803200320002903003703900320034190036a2049412010100b4181014101417f1011220741086a224941083a0000204941016a220020273a0001200020093a00002000202c3a00022000202e3a0003200020303a00042000202f3a0005200020363a0006200020373a0007200020383a0008200020323a0009200020313a000a200020333a000b200020343a000c200020393a000d2000203a3a000e2000203b3a000f2000203c3a00102000203d3a00112000203e3a00122000203f3a0013200020403a0014200020413a0015200020423a0016200020433a0017200020443a0018200020463a0019200020453a001a200020353a001b200020473a001c200020483a001d2000204b3a001e2000204c3a001f204941216a2200202d3a0001200020293a00002000202b3a00022000202a3a0003200020283a0004200020263a0005200020253a0006200020243a0007200020203a00082000201f3a00092000201e3a000a2000201d3a000b2000201c3a000c2000201b3a000d2000201a3a000e200020193a000f200020183a0010200020173a0011200020163a0012200020153a0013200020143a0014200020133a0015200020123a0016200020113a00172000200f3a00182000200e3a00192000200a3a001a200020233a001b200020223a001c2000200d3a001d200020103a001e200020213a001f200741c9006a220020b001370308200020b301370300200020ae01370310200041186a20013703000c090b000b000b000b000b000b000b000b000b000b200741e9006a220020ac01370308200020b501370300200020b201370310200041186a20b801370300200641d0006b22002400200041083a0000200641cf006b22094108100e200941f0044120100d2006412f6b200441086a2004280200410020041b100d200041c100200741086a2007280200410020071b1006200b41186a2001370300200b20ae01370310200b20b001370308200b20b301370300200341d0036a240041000c010b200341d0036a240020040b22000d01200b41186a2903002101200b41106a2903002102200b41086a29030021ae01200b29030021ab01200c41386a4200370300200c41186a4200370300200c4200370330200c4200370328200c4201370320200c4200370310200c4200370308200c4201370300200c4120200c41206a412010011a0c020b200c41406b240020000c020b200c41406b240020000c010b200520ab01370300200520ae0137030820052002370310200541186a2001370300200c41406b240041000b450d2d0c3a0b41bc05290300210141b40529030021ab0141ac05290300210241a40529030021ad01200841206b22052400027f230041206b220324004198054120360200200341186a420037030020034200370310200342003703082003420f3703002003412041a0054198051003047e42000541b00529030021b00141a80529030021b40141a00529030021ac0141b8052903000b21ae010240410020ac0120ad0156200220b40154200220b401511b20ab0120b00154200120ae0154200120ae01511b20ab0120b00185200120ae018584501b20ac0120b0018420ae0120b4018484501b044020ac0120ad0158200220b4015a200220b401511b20ab0120b0015a200120ae015a200120ae01511b20ab0120b00185200120ae018584501b0d01200341206b22002400200020ad0142cba3aeadf7999885177c22ae0137030041980541203602002000200220ad0120ae01562204ad7c4290c6e394d983bda0197c22ae01370308200020ab0142bda89192cdcbb4f6367c22ac012004200220ae0156200220ae01511bad7c2202370310200041186a200220ac0154ad200120ab0120ac0156ad7c7c42d19ed8fc8880b0c4f9007c3703002000412041a0054198051003210041a0052d0000210441a1052d0000210641a2052d0000210741a3052d0000210c41a4052d0000210941a5052d0000210b41a6052d0000212141a7052d0000211041a8052d0000210d41a9052d0000212241aa052d0000212341ab052d0000210a41ac052d0000210e41ad052d0000210f41ae052d0000211141af052d0000211241b0052d0000211341b1052d0000211441b2052d0000211541b3052d0000211641b4052d0000211741b5052d0000211841b6052d0000211941b7052d0000211a41b8052d0000211b41b9052d0000211c41ba052d0000211d41bb052d0000211e41bc052d0000211f41bd052d0000212041be052d000021242005410041bf052d000020001b3a001f20054100202420001b3a001e20054100202020001b3a001d20054100201f20001b3a001c20054100201e20001b3a001b20054100201d20001b3a001a20054100201c20001b3a001920054100201b20001b3a001820054100201a20001b3a001720054100201920001b3a001620054100201820001b3a001520054100201720001b3a001420054100201620001b3a001320054100201520001b3a001220054100201420001b3a001120054100201320001b3a001020054100201220001b3a000f20054100201120001b3a000e20054100200f20001b3a000d20054100200e20001b3a000c20054100200a20001b3a000b20054100202320001b3a000a20054100202220001b3a000920054100200d20001b3a000820054100201020001b3a000720054100202120001b3a000620054100200b20001b3a000520054100200920001b3a000420054100200c20001b3a000320054100200720001b3a000220054100200620001b3a000120054100200420001b3a0000200341206a240041000c020b000b000b450d350c390b41c3052d0000210441c2052d0000210641c1052d0000210741c0052d0000210c41bf052d0000210941be052d0000210b41bd052d0000212141bc052d0000211041bb052d0000210d41ba052d0000212241b9052d0000212341b8052d0000210a41b7052d0000210e41b6052d0000210f41b5052d0000211141b4052d0000211241b3052d0000211341b2052d0000211441b1052d0000211541b0052d0000211641af052d0000211741ae052d0000211841ad052d0000211941ac052d0000211a41ab052d0000211b41aa052d0000211c41a9052d0000211d41a8052d0000211e41a7052d0000211f41a6052d0000212041a5052d0000212441a4052d00002125200841206b2205240042002102230041406a22032400200341406a22002400200041186a4200370300200042003703102000420037030820004210370300200041206a20253a0000200041216a20243a0000200041226a20203a0000200041236a201f3a0000200041246a201e3a0000200041256a201d3a0000200041266a201c3a0000200041276a201b3a0000200041286a201a3a0000200041296a20193a00002000412a6a20183a00002000412b6a20173a00002000412c6a20163a00002000412d6a20153a00002000412e6a20143a00002000412f6a20133a0000200041306a20123a0000200041316a20113a0000200041326a200f3a0000200041336a200e3a0000200041346a200a3a0000200041356a20233a0000200041366a20223a0000200041376a200d3a0000200041386a20103a0000200041396a20213a00002000413a6a200b3a00002000413b6a20093a00002000413c6a200c3a00002000413d6a20073a00002000413e6a20063a00002000413f6a20043a0000200041c000200341206a10024198054120360200200341186a200341386a2903003703002003200341306a2903003703102003200341286a290300370308200320032903203703002003412041a0054198051003047e42000541b005290300210241a80529030021ab0141a00529030021ae0141b8052903000b2101200520ae01370300200520ab0137030820052002370310200541186a2001370300200341406b24000c2b0b000b000b2003413f4b0d01200341ffffffff03712003470d02200641086a2003410274360200410121040c270b2003413f4b0d02200341ffffffff03712003470d03200641086a2003410274360200410121040c260b200341ffff004b0d03200341ffffffff03712003470d0441022104200641086a20034102744101723602000c250b000b200341ffff004b0d03200341ffffffff03712003470d0441022104200641086a20034102744101723602000c230b000b2003200341ffffffff0371460440200641086a2003410274410272360200410421040c220b000b000b2003200341ffffffff0371460440200641086a2003410274410272360200410421040c200b000b000b000b000b000b000b000b000b000b000b000b000b027f024002400240024002402006200441e0006a4f0440200020046a220541e0006a20064b0d0120004101417f1011220341086a20044184066a2000100d20054184066a2d000022004103710e03030405020b000b000b000b4101210420004102760c020b4102210420054184066a2f01004102760c010b4104210420054184066a2802004102760b2100024002400240024002400240200541e0006a220720046a226520074f044020062065490d01200541e0006a2207200020046a22656a22662007490d0220062066490d0320004101417f101121072004200541e0006a22666a22042066490d04200741086a200441a4056a2000100d200541e0006a220020656a22052000490d05200520064f0d06000b000b000b000b000b000b000b027f41002105230041b0026b22042400419805412036020041a0054198051004200441b805290300220137008802200441b005290300220237008002200441a80529030022ae013700f801200441a00529030022ab013700f00120ab01a720042d00f10120042d00f20120042d00f30120042d00f40120042d00f50120042d00f60120042d00f70120ae01a720042d00f90120042d00fa0120042d00fb0120042d00fc0120042d00fd0120042d00fe0120042d00ff012002a720042d00810220042d00820220042d00830220042d00840220042d00850220042d00860220042d0087022001a720042d00890220042d008a0220042d008b0220042d008c0220042d008d0220042d008e0220042d008f02102022000440200021050b20032100024002400240024002400240024002402005450440200441a8026a2205420037030020044188026a4200370300200442003703a002200442003703980220044201370390022004420037038002200442003703f801200442013703f001200441f0016a2203412020044190026a2206412010011a20054200370300200441003a00f001200442003703a00220044200370398022004420237039002200641202003410110011a230041206b22052400200541186a420037030020054200370310200542003703082005420637030002402000280200410020001b22034504402005412010001a0c010b20054120200041086a200310011a0b200541206b22002400200041186a420037030020004200370310200042003703082000420737030002402007280200410020071b22034504402000412010001a0c010b20004120200741086a200310011a0b200541206a2400200420473a00f101200420483a00f001200420353a00f201200420453a00f301200420463a00f401200420443a00f501200420433a00f601200420423a00f701200420413a00f801200420403a00f9012004203f3a00fa012004203e3a00fb012004203d3a00fc012004203c3a00fd012004203b3a00fe012004203a3a00ff01200420393a008002200420343a008102200420333a008202200420313a008302200420323a008402200420383a008502200420373a008602200420363a0087022004202f3a008802200420303a0089022004202e3a008a022004202c3a008b02200420273a008c02200420293a008d022004202d3a008e022004202b3a008f02200441a8026a4200370300200442003703a0022004420037039802200442083703900220044190026a4120200441f0016a412010011a202b2047204872203572204572204672204472204372204272204172204072203f72203e72203d72203c72203b72203a72203972203472203372203172203272203872203772203672202f72203072202e72202c72202772202972202d7272450d01204b2069206a72206872206772206472206372206272206172206072205f72205e72205d72205c72205b72205a72205972205872205772205672205572205472205372205272205172205072204f72204e72204a72204d72204972204c7272450d02200c2028202a72202672202572202472202072201f72201e72201d72201c72201b72201a72201972201872201772201672201572201472201372201272201172200f72200e72200a72202372202272200d72201072202172200b7220097272450d03200441206b22052400200541206b220024002000201c3a00092000201d3a00082000201e3a00072000201f3a0006200020203a0005200020243a0004200020253a0003200020263a0002200020283a00012000202a3a00002000201b3a000a2000201a3a000b200020193a000c200020183a000d200020173a000e200020163a000f200020153a0010200020143a0011200020133a0012200020123a0013200020113a00142000200f3a00152000200e3a00162000200a3a0017200020233a0018200020223a00192000200d3a001a200020103a001b200020213a001c2000200b3a001d200020093a001e2000200c3a001f200541186a420037030020054200370310200542003703082005420c370300200541202000412010011a200041206b22052400200541206b220024002000204b3a001f2000204c3a001e200020493a001d2000204d3a001c2000204a3a001b2000204e3a001a2000204f3a0019200020503a0018200020513a0017200020523a0016200020533a0015200020543a0014200020553a0013200020563a0012200020573a0011200020583a0010200020593a000f2000205a3a000e2000205b3a000d2000205c3a000c2000205d3a000b2000205e3a000a2000205f3a0009200020603a0008200020613a0007200020623a0006200020633a0005200020643a0004200020673a0003200020683a0002200020693a00012000206a3a0000200541186a420037030020054200370310200542003703082005420d370300200541202000412010011a411e4120417f10112106200041206b220024002006280200200041186a220c420037030020004200370310200042003703082000420f370300410021074198054120360200410020061b21032000412041a005419805100345044041a00529030021b1010b200041206b22052400200541186a22094200370300200541106a220b4200370300200541086a2221420037030020052003ad370300200041202005412010011a2000412020051002200641086a2106200929030021b301200b29030021af01202129030021b5012005290300210120b101a721090340200320074b044020002001370300200020b501370308200020af01370310200c20b301370300200041202006412010011a20b30120af0120af01200142017c2202200154220b20b50120b501200bad7c22b5015620012002581bad7c22af0156ad7c21b301200741016a2107200641206a2106200221010c010b0b200041186a210603402003200949044020002001370300200020b501370308200020af01370310200620b3013703002000412010001a20b30120af0120af01200142017c2202200154220720b50120b5012007ad7c22b5015620012002581bad7c22af0156ad7c21b301200341016a2103200221010c010b0b200541206b220022032400200041186a420037030020004200370310200042003703082000420837030041980541203602002000412041a0054198051003210041a0052d0000210641a1052d0000210741a2052d0000210c41a3052d0000210941a4052d0000210b41a5052d0000212141a6052d0000211041a7052d0000210d41a8052d0000212241a9052d0000212341aa052d0000210a41ab052d0000210e41ac052d0000210f41ad052d0000211141ae052d0000211241af052d0000211341b0052d0000211441b1052d0000211541b2052d0000211641b3052d0000211741b4052d0000211841b5052d0000211941b6052d0000211a41b7052d0000211b41b8052d0000211c41b9052d0000211d41ba052d0000211e41bb052d0000211f41bc052d0000212041bd052d0000212441be052d0000212541bf052d0000212641044101417f10112105200441e7caf3890336020c2004410c6a200541086a22284104101020044100202620001b3a002f20044100202520001b3a002e20044100202420001b3a002d20044100202020001b3a002c20044100201f20001b3a002b20044100201e20001b3a002a20044100201d20001b3a002920044100201c20001b3a002820044100201b20001b3a002720044100201a20001b3a002620044100201920001b3a002520044100201820001b3a002420044100201720001b3a002320044100201620001b3a002220044100201520001b3a002120044100201420001b3a002020044100201320001b3a001f20044100201220001b3a001e20044100201120001b3a001d20044100200f20001b3a001c20044100200e20001b3a001b20044100200a20001b3a001a20044100202320001b3a001920044100202220001b3a001820044100200d20001b3a001720044100201020001b3a001620044100202120001b3a001520044100200b20001b3a001420044100200920001b3a001320044100200c20001b3a001220044100200720001b3a001120044100200620001b3a001020052802002106200341106b220024002000420037030820004200370300419805418080023602004100200441106a4200200020282006410020051b41a00541980510080d04419805280200410141a00510112205280200410020051b2205450d05419805280200410141a0051011200541014b0d0641086a31000042ff018321b10142002101420a21af01200441c0016a2105420021b501420021b301420021ab01420121ae010240034020b101a74101710440200441a8016a20b30137030020044188016a20b201370300200420af0137039001200420ae013703702004200137039801200420b001370378200420b5013703a001200420b40137038001200441f0006a20044190016a200441b0016a410810150d0a200441c8016a29030021b201200529030021b401200441b8016a29030021b00120042903b00121ae010b20ad01423f8620b1014201888422b10120ac01423f8620ab014201888422028420ab01423f8620ad014201888422ad0120ac0142018822ac018484500d0120044188026a20b301370300200441e8016a20b301370300200420af013703f001200420af013703d001200420013703f801200420013703d801200420b50137038002200420b5013703e001200441d0016a200441f0016a20044190026a41081015200441a8026a29030021b301200441a0026a29030021b50120044198026a290300210120042903900221af01200221ab01450d000b000b200441c8006a20b201370300200420ae01370330200420b001370338200420b401370340200041206b22002400200441e8006a20b201370300200041186a420037030020004200370310200042003703082000420b370300200420b401370360200420b001370358200420ae0137035020004120200441d0006a412010011a0c080b200441b0026a240020050c080b000b000b000b000b000b000b000b200441b0026a240041000b0d210c1b0b20242d00000c160b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b2004200641086a22066a200541086a2003100d200020002005280200410020051b6a22054d0440410020062005100a0c0d0b000b200541086a2903002101200541106a2903002102200541186a29030021ae010c090b20052d00000c010b20002d00000b210541014101417f101141086a220020054101713a00000b410020004101100a0c070b027e200841206a412041a005419805100304404200210242000c010b41b80529030021ab0141a805290300210241a00529030021ae0141b0052903000b2101200520ae013703002005200237030820052001370310200541186a220020ab01370300200541086a2903002101200541106a2903002102200029030021ae010c040b200841206a412041a0054198051003210041a0052d0000210341a1052d0000210441a2052d0000210641a3052d0000210741a4052d0000210c41a5052d0000210941a6052d0000210b41a7052d0000212141a8052d0000211041a9052d0000210d41aa052d0000212241ab052d0000212341ac052d0000210a41ad052d0000210e41ae052d0000210f41af052d0000211141b0052d0000211241b1052d0000211341b2052d0000211441b3052d0000211541b4052d0000211641b5052d0000211741b6052d0000211841b7052d0000211941b8052d0000211a41b9052d0000211b41ba052d0000211c41bb052d0000211d41bc052d0000211e41bd052d0000211f41be052d000021202005410041bf052d000020001b3a001f20054100202020001b3a001e20054100201f20001b3a001d20054100201e20001b3a001c20054100201d20001b3a001b20054100201c20001b3a001a20054100201b20001b3a001920054100201a20001b3a001820054100201920001b3a001720054100201820001b3a001620054100201720001b3a001520054100201620001b3a001420054100201520001b3a001320054100201420001b3a001220054100201320001b3a001120054100201220001b3a001020054100201120001b3a000f20054100200f20001b3a000e20054100200e20001b3a000d20054100200a20001b3a000c20054100202320001b3a000b20054100202220001b3a000a20054100200d20001b3a000920054100201020001b3a000820054100202120001b3a000720054100200b20001b3a000620054100200920001b3a000520054100200c20001b3a000420054100200720001b3a000320054100200620001b3a000220054100200420001b3a000120054100200320001b3a00000c020b410041004101417f101141086a4100100a0c040b200541186a2903002101200541106a2903002102200541086a29030021ae01200041186a29030021ab01200041106a29030021ac01200041086a29030021ad01200529030021af01200029030021b00141c0004101417f1011220041186a20ac01370300200041106a20ad01370300200041086a220520b001370300200041206a20ab01370300200541206a220520ae01370308200520af0137030020052002370310200541186a20013703004100200041086a41c000100a0c030b2005290000210120052900082102200529001021ae01200529001821ab0141204101417f1011220041206a20ab01370000200041186a20ae01370000200041106a2002370000200041086a220520013700000c010b200529030021ab0141204101417f1011220041206a20ae01370300200041186a2002370300200041106a2001370300200041086a220520ab013703000b410020054120100a0b200841406b24000f0b200841406b24000bdd0201037f230041206b2201240010144198054180800236020041a005419805100b4194054198052802002202360200230041c0016b22002400200041f8006a427f370300200041d8006a42003703002000427f3703702000427f3703682000427f370360200042003703502000420037034820004209370340200041406b4120200041e0006a412010011a20004198016a4200370300200041386a420037030020004200370390012000420037038801200042003703800120004200370330200042003703282000420a370320200041206a412020004180016a412010011a200041b8016a4200370300200041186a4200370300200042003703b001200042003703a801200042003703a00120004200370310200042003703082000420e37030020004120200041a0016a412010011a200041c0016a24002001411036020c200141106a2001410c6a100c20022001290310200141186a2903001026000b5401027f230041206b2200240010144198054180800236020041a005419805100b41940541980528020022013602002000411036020c200041106a2000410c6a100c20012000290310200041186a2903001026000b0bed04080041000b17584945524332303a3a5472616e736665723a3a66726f6d0041200b15504945524332303a3a5472616e736665723a3a746f0041c1000b104945524332303a3a5472616e736665720041e0000b515c4945524332303a3a417070726f76616c3a3a6f776e65720000000000000000644945524332303a3a417070726f76616c3a3a7370656e646572000000000000004945524332303a3a417070726f76616c0041c0010b58b04f776e61626c653a3a4f776e6572736869705472616e736665727265643a3a70726576696f75734f776e65720000009c4f776e61626c653a3a4f776e6572736869705472616e736665727265643a3a6e65774f776e65720041a1020b83014f776e61626c653a3a4f776e6572736869705472616e7366657272656400005361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656443616c6c2072657665727465640000006c494261636b73746f70506f6f6c3a3a4d696e743a3a73656e6465720000000000494261636b73746f70506f6f6c3a3a4d696e740041b0030b346c494261636b73746f70506f6f6c3a3a4275726e3a3a73656e6465720000000000494261636b73746f70506f6f6c3a3a4275726e0041f0030ba001a4494261636b73746f70506f6f6c3a3a436f766572537761705769746864726177616c3a3a6f776e657200000000000023e2d883b953abc19607682bbde1bc5e12ed54ae71797667464f8d65e9c036ceac494261636b73746f70506f6f6c3a3a5769746864726177537761704c69717569646974793a3a6f776e657200000000ae11651b16a43caf35eb9c519bea373f5838f930d722a6c5903da32e17ae89ab008e010970726f64756365727302086c616e6775616765010143000c70726f6365737365642d62790105636c616e676131352e302e34202868747470733a2f2f6769746875622e636f6d2f736f6c616e612d6c6162732f6c6c766d2d70726f6a6563742e676974203333633336323963616135396235396438663538353733366134613531393461613965393337376429', + compiler: 'solang 0.3.2', + hash: '0x09e907520a2e0be46d0a350df95c431857cbf88f52094be242f15ae79e524f3c', + language: 'Solidity 0.3.2', }, spec: { constructors: [ @@ -19,21 +18,14 @@ export const backstopPoolAbi = { { label: '_router', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_asset', type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: '_curve', - type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -52,16 +44,44 @@ export const backstopPoolAbi = { }, }, ], + default: false, docs: [''], label: 'new', payable: false, returnType: null, - selector: '0x3e6bb716', + selector: '0xf01fa595', }, ], docs: [ - 'The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees.\n\n', + 'The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees.', ], + environment: { + accountId: { + displayName: ['AccountId'], + type: 2, + }, + balance: { + displayName: ['Balance'], + type: 10, + }, + blockNumber: { + displayName: ['BlockNumber'], + type: 11, + }, + chainExtension: { + displayName: [], + type: 0, + }, + hash: { + displayName: ['Hash'], + type: 12, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 11, + }, + }, events: [ { args: [ @@ -70,7 +90,7 @@ export const backstopPoolAbi = { indexed: true, label: 'from', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -79,7 +99,7 @@ export const backstopPoolAbi = { indexed: true, label: 'to', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -88,7 +108,7 @@ export const backstopPoolAbi = { indexed: false, label: 'value', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -103,7 +123,7 @@ export const backstopPoolAbi = { indexed: true, label: 'owner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -112,7 +132,7 @@ export const backstopPoolAbi = { indexed: true, label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -121,7 +141,7 @@ export const backstopPoolAbi = { indexed: false, label: 'value', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -136,7 +156,7 @@ export const backstopPoolAbi = { indexed: false, label: 'account', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -151,7 +171,7 @@ export const backstopPoolAbi = { indexed: false, label: 'account', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -166,7 +186,7 @@ export const backstopPoolAbi = { indexed: true, label: 'previousOwner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -175,7 +195,7 @@ export const backstopPoolAbi = { indexed: true, label: 'newOwner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -190,7 +210,7 @@ export const backstopPoolAbi = { indexed: true, label: 'sender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -199,7 +219,7 @@ export const backstopPoolAbi = { indexed: false, label: 'poolSharesMinted', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -208,12 +228,12 @@ export const backstopPoolAbi = { indexed: false, label: 'amountPrincipleDeposited', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['emitted on every deposit\n\n'], + docs: ['emitted on every deposit'], label: 'Mint', }, { @@ -223,7 +243,7 @@ export const backstopPoolAbi = { indexed: true, label: 'sender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -232,7 +252,7 @@ export const backstopPoolAbi = { indexed: false, label: 'poolSharesBurned', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -241,13 +261,13 @@ export const backstopPoolAbi = { indexed: false, label: 'amountPrincipleWithdrawn', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], docs: [ - 'emitted on every withdrawal special case withdrawal using swap liquidiity: amountPrincipleWithdrawn = 0\n\n', + 'emitted on every withdrawal special case withdrawal using swap liquidiity: amountPrincipleWithdrawn = 0', ], label: 'Burn', }, @@ -258,7 +278,7 @@ export const backstopPoolAbi = { indexed: true, label: 'owner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -267,7 +287,7 @@ export const backstopPoolAbi = { indexed: false, label: 'swapPool', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -276,7 +296,7 @@ export const backstopPoolAbi = { indexed: false, label: 'amountSwapShares', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -285,7 +305,7 @@ export const backstopPoolAbi = { indexed: false, label: 'amountSwapTokens', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -294,12 +314,12 @@ export const backstopPoolAbi = { indexed: false, label: 'amountBackstopTokens', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['emitted when a swap pool LP withdraws from backstop pool\n\n'], + docs: ['emitted when a swap pool LP withdraws from backstop pool'], label: 'CoverSwapWithdrawal', }, { @@ -309,7 +329,7 @@ export const backstopPoolAbi = { indexed: true, label: 'owner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -318,7 +338,7 @@ export const backstopPoolAbi = { indexed: false, label: 'swapPool', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -327,7 +347,7 @@ export const backstopPoolAbi = { indexed: false, label: 'amountSwapTokens', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -336,22 +356,23 @@ export const backstopPoolAbi = { indexed: false, label: 'amountBackstopTokens', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['emitted when a backstop pool LP withdraws liquidity from swap pool\n\n'], + docs: ['emitted when a backstop pool LP withdraws liquidity from swap pool'], label: 'WithdrawSwapLiquidity', }, ], lang_error: { - displayName: [], - type: 0, + displayName: ['SolidityError'], + type: 15, }, messages: [ { args: [], + default: false, docs: [''], label: 'name', mutates: false, @@ -364,6 +385,7 @@ export const backstopPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'symbol', mutates: false, @@ -376,24 +398,26 @@ export const backstopPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'decimals', mutates: false, payable: false, returnType: { - displayName: ['u8'], + displayName: ['uint8'], type: 0, }, selector: '0x313ce567', }, { args: [], + default: false, docs: [''], label: 'totalSupply', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0x18160ddd', @@ -403,17 +427,18 @@ export const backstopPoolAbi = { { label: 'account', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [''], label: 'balanceOf', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0x70a08231', @@ -423,18 +448,19 @@ export const backstopPoolAbi = { { label: 'to', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'amount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'transfer', mutates: true, @@ -450,24 +476,25 @@ export const backstopPoolAbi = { { label: 'owner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [''], label: 'allowance', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0xdd62ed3e', @@ -477,18 +504,19 @@ export const backstopPoolAbi = { { label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'amount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'approve', mutates: true, @@ -504,25 +532,26 @@ export const backstopPoolAbi = { { label: 'from', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'to', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'amount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'transferFrom', mutates: true, @@ -538,18 +567,19 @@ export const backstopPoolAbi = { { label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'addedValue', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'increaseAllowance', mutates: true, @@ -565,18 +595,19 @@ export const backstopPoolAbi = { { label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'subtractedValue', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'decreaseAllowance', mutates: true, @@ -589,6 +620,7 @@ export const backstopPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'paused', mutates: false, @@ -601,18 +633,20 @@ export const backstopPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'owner', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0x8da5cb5b', }, { args: [], + default: false, docs: [''], label: 'renounceOwnership', mutates: true, @@ -625,11 +659,12 @@ export const backstopPoolAbi = { { label: 'newOwner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [''], label: 'transferOwnership', mutates: true, @@ -639,234 +674,267 @@ export const backstopPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'poolCap', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0xb954dc57', }, { args: [], - docs: ["Returns the pooled token's address\n\n"], + default: false, + docs: ["Returns the pooled token's address"], label: 'asset', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0x38d52e0f', }, { - args: [ - { - label: '_shares', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: ['Returns the worth of an amount of pool shares (LP tokens) in underlying principle\n\n'], - label: 'sharesTargetWorth', + args: [], + default: false, + docs: ['Returns the decimals of the pool asset'], + label: 'assetDecimals', mutates: false, payable: false, returnType: { - displayName: ['u256'], - type: 3, + displayName: ['uint8'], + type: 0, }, - selector: '0xcc045745', + selector: '0xc2d41601', }, { args: [], + default: false, docs: [''], label: 'router', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0xf887ea40', }, - { - args: [], - docs: [''], - label: 'slippageCurve', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - selector: '0xebe26b9e', - }, - { - args: [], - docs: [''], - label: 'accumulatedSlippage', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 3, - }, - selector: '0xe4182b09', - }, { args: [ { - label: '_amount', + label: '_maxTokens', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0\n\n'], - label: 'deposit', + default: false, + docs: [ + 'Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits.', + ], + label: 'setPoolCap', mutates: true, payable: false, - returnType: { - displayName: ['BackstopPool', 'deposit', 'return_type'], - type: 8, - }, - selector: '0xb6b55f25', + returnType: null, + selector: '0xd835f535', }, { args: [ { - label: '_maxTokens', + label: '_swapPool', type: { - displayName: ['u256'], + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_insuranceFeeBps', + type: { + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [ - 'Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits.\n\n', + 'Make this backstop pool cover another swap pool Beware: Adding a swap pool holding the same token as the backstop pool\ncan easily cause undesirable conditions and must be secured (i.e. long time lock)!', ], - label: 'setPoolCap', + label: 'addSwapPool', mutates: true, payable: false, returnType: null, - selector: '0xd835f535', + selector: '0xabb26587', }, { args: [ { - label: '_shares', + label: '_swapPool', type: { - displayName: ['u256'], - type: 3, + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, }, { - label: '_minimumAmount', + label: '_insuranceFeeBps', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: [ - 'Withdraws liquidity amount of asset ensuring minimum amount required Slippage is applied (withdrawal fee)\n\n', - ], - label: 'withdraw', + default: false, + docs: ["Change a swap pool's insurance withdrawal fee"], + label: 'setInsuranceFee', mutates: true, payable: false, + returnType: null, + selector: '0xc6a78196', + }, + { + args: [ + { + label: '_index', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + ], + default: false, + docs: ['enumerate swap pools backed by this backstop pool'], + label: 'getBackedPool', + mutates: false, + payable: false, returnType: { - displayName: ['BackstopPool', 'withdraw', 'return_type'], - type: 9, + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, - selector: '0x441a3e70', + selector: '0xa04345f2', + }, + { + args: [], + default: false, + docs: ['get swap pool count backed by this backstop pool'], + label: 'getBackedPoolCount', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x5fda8689', }, { args: [ { label: '_swapPool', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, + ], + default: false, + docs: ['get insurance withdrawal fee for a given swap pool'], + label: 'getInsuranceFee', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x504e0153', + }, + { + args: [ { - label: '_insuranceFeeBps', + label: '_depositAmount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: [ - 'Make this backstop pool cover another swap pool Beware: Adding a swap pool holding the same token as the backstop pool\ncan easily cause undesirable conditions and must be secured (i.e. long time lock)!\n\n', - ], - label: 'addSwapPool', + default: false, + docs: ['Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0'], + label: 'deposit', mutates: true, payable: false, - returnType: null, - selector: '0xabb26587', + returnType: { + displayName: ['BackstopPool', 'deposit', 'return_type'], + type: 8, + }, + selector: '0xb6b55f25', }, { args: [ { - label: '_swapPool', + label: '_sharesToBurn', type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, + displayName: ['uint256'], + type: 3, }, }, { - label: '_insuranceFeeBps', + label: '_minimumAmount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ["Change a swap pool's insurance withdrawal fee\n\n"], - label: 'setInsuranceFee', + default: false, + docs: [ + 'Withdraws liquidity amount of asset ensuring minimum amount required Slippage is applied (withdrawal fee)', + ], + label: 'withdraw', mutates: true, payable: false, - returnType: null, - selector: '0xc6a78196', + returnType: { + displayName: ['BackstopPool', 'withdraw', 'return_type'], + type: 9, + }, + selector: '0x441a3e70', }, { args: [ { label: '_swapPool', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_shares', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, { label: '_minAmount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [ - "withdraw from a swap pool using backstop liquidity without slippage only possible if swap pool's coverage ratio < 100%\n\n", + "withdraw from a swap pool using backstop liquidity without slippage only possible if swap pool's coverage ratio < 100%", ], label: 'redeemSwapPoolShares', mutates: true, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0x6e7e91fd', @@ -876,114 +944,73 @@ export const backstopPoolAbi = { { label: '_swapPool', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_shares', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, { label: '_minAmount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [ - 'withdraw from backstop pool, but receive excess liquidity\nof a swap pool without slippage, instead of backstop liquidity\n\n', + 'withdraw from backstop pool, but receive excess liquidity\nof a swap pool without slippage, instead of backstop liquidity', ], label: 'withdrawExcessSwapLiquidity', mutates: true, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0xcaf8c105', }, { args: [], - docs: ['returns pool coverage ratio\n\n'], - label: 'coverage', - mutates: false, - payable: false, - returnType: { - displayName: ['BackstopPool', 'coverage', 'return_type'], - type: 10, - }, - selector: '0xee8f6a0e', - }, - { - args: [ - { - label: '_index', - type: { - displayName: ['u256'], - type: 3, - }, - }, + default: false, + docs: [ + "return worth of the whole backstop pool in `asset()`, incl. all\nswap pools' excess liquidity and the backstop pool's liabilities", ], - docs: ['enumerate swap pools backed by this backstop pool\n\n'], - label: 'getBackedPool', + label: 'getTotalPoolWorth', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, + displayName: ['int256'], + type: 7, }, - selector: '0xa04345f2', - }, - { - args: [], - docs: ['get swap pool count backed by this backstop pool\n\n'], - label: 'getBackedPoolCount', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 3, - }, - selector: '0x5fda8689', + selector: '0x18ba24c4', }, { args: [ { - label: '_swapPool', + label: '_sharesToBurn', type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, + displayName: ['uint256'], + type: 3, }, }, ], - docs: ['get insurance withdrawal fee for a given swap pool\n\n'], - label: 'getInsuranceFee', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 3, - }, - selector: '0x504e0153', - }, - { - args: [], - docs: [ - "return worth of the whole backstop pool in `asset()`, incl. all\nswap pools' excess liquidity and the backstop pool's liabilities\n\n", - ], - label: 'getTotalPoolWorth', + default: false, + docs: ['Returns the worth of an amount of pool shares (LP tokens) in underlying principle'], + label: 'sharesTargetWorth', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, - selector: '0x18ba24c4', + selector: '0xcc045745', }, ], }, @@ -1142,13 +1169,13 @@ export const backstopPoolAbi = { layout: { leaf: { key: '0x00000009', - ty: 3, + ty: 0, }, }, root_key: '0x00000009', }, }, - name: 'poolCap', + name: 'poolAssetDecimals', }, { layout: { @@ -1162,21 +1189,7 @@ export const backstopPoolAbi = { root_key: '0x0000000a', }, }, - name: 'totalLiabilities', - }, - { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000b', - ty: 3, - }, - }, - root_key: '0x0000000b', - }, - }, - name: 'poolAssetMantissa', + name: 'poolCap', }, { layout: { @@ -1187,7 +1200,7 @@ export const backstopPoolAbi = { { layout: { leaf: { - key: '0x0000000c', + key: '0x0000000b', ty: 1, }, }, @@ -1197,59 +1210,21 @@ export const backstopPoolAbi = { name: 'AccountId', }, }, - root_key: '0x0000000c', + root_key: '0x0000000b', }, }, name: 'router', }, - { - layout: { - root: { - layout: { - struct: { - fields: [ - { - layout: { - leaf: { - key: '0x0000000d', - ty: 1, - }, - }, - name: '', - }, - ], - name: 'AccountId', - }, - }, - root_key: '0x0000000d', - }, - }, - name: 'slippageCurve', - }, { layout: { root: { layout: { leaf: { - key: '0x0000000e', - ty: 3, - }, - }, - root_key: '0x0000000e', - }, - }, - name: 'accumulatedSlippage', - }, - { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000f', + key: '0x0000000c', ty: 6, }, }, - root_key: '0x0000000f', + root_key: '0x0000000c', }, }, name: 'swapPools', @@ -1259,11 +1234,11 @@ export const backstopPoolAbi = { root: { layout: { leaf: { - key: '0x00000010', + key: '0x0000000d', ty: 3, }, }, - root_key: '0x00000010', + root_key: '0x0000000d', }, }, name: 'swapPoolInsuranceFeeBps', @@ -1273,11 +1248,11 @@ export const backstopPoolAbi = { root: { layout: { leaf: { - key: '0x00000011', + key: '0x0000000e', ty: 4, }, }, - root_key: '0x00000011', + root_key: '0x0000000e', }, }, name: 'swapPoolCovered', @@ -1293,7 +1268,7 @@ export const backstopPoolAbi = { def: { primitive: 'u8', }, - path: ['u8'], + path: ['uint8'], }, }, { @@ -1319,7 +1294,7 @@ export const backstopPoolAbi = { ], }, }, - path: ['ink_env', 'types', 'AccountId'], + path: ['ink_primitives', 'types', 'AccountId'], }, }, { @@ -1328,7 +1303,7 @@ export const backstopPoolAbi = { def: { primitive: 'u256', }, - path: ['u256'], + path: ['uint256'], }, }, { @@ -1365,7 +1340,7 @@ export const backstopPoolAbi = { def: { primitive: 'i256', }, - path: ['i256'], + path: ['int256'], }, }, { @@ -1390,9 +1365,93 @@ export const backstopPoolAbi = { id: 10, type: { def: { - tuple: [3, 3], + primitive: 'u128', + }, + path: ['uint128'], + }, + }, + { + id: 11, + type: { + def: { + primitive: 'u64', + }, + path: ['uint64'], + }, + }, + { + id: 12, + type: { + def: { + composite: { + fields: [ + { + type: 1, + }, + ], + }, + }, + path: ['ink_primitives', 'types', 'Hash'], + }, + }, + { + id: 13, + type: { + def: { + composite: { + fields: [ + { + type: 5, + }, + ], + }, + }, + path: ['0x08c379a0'], + }, + }, + { + id: 14, + type: { + def: { + composite: { + fields: [ + { + type: 3, + }, + ], + }, + }, + path: ['0x4e487b71'], + }, + }, + { + id: 15, + type: { + def: { + variant: { + variants: [ + { + fields: [ + { + type: 13, + }, + ], + index: 0, + name: 'Error', + }, + { + fields: [ + { + type: 14, + }, + ], + index: 1, + name: 'Panic', + }, + ], + }, }, - path: ['BackstopPool', 'coverage', 'return_type'], + path: ['SolidityError'], }, }, ], diff --git a/src/contracts/nabla/ChainlinkAdapter.ts b/src/contracts/nabla/ChainlinkAdapter.ts deleted file mode 100644 index 360a3465..00000000 --- a/src/contracts/nabla/ChainlinkAdapter.ts +++ /dev/null @@ -1,280 +0,0 @@ -export const chainlinkAdapterAbi = { - contract: { - authors: ['unknown'], - description: "ChainlinkAdapter\nPrice oracle that uses Chainlink's price feeds", - name: 'ChainlinkAdapter', - version: '0.0.1', - }, - source: { - compiler: 'solang 0.3.0', - hash: '0x921a6cf649b68d9ed49d94236140e39caab44a38b4eb0d5f4bf7af1e53f701cc', - language: 'Solidity 0.3.0', - wasm: '0x0061736d01000000015d0a60037f7f7f0060027f7f0060047f7f7f7f017f60027f7f017f60047f7f7f7f0060087f7f7e7f7f7f7f7f017f60017f017f6000017f60207f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60000002f1010c057365616c310b6765745f73746f726167650002057365616c300663616c6c65720001057365616c320b7365745f73746f726167650002057365616c300f686173685f626c616b65325f3235360000057365616c300d6465706f7369745f6576656e740004057365616c300f686173685f6b656363616b5f3235360000057365616c31097365616c5f63616c6c0005057365616c310d636c6561725f73746f726167650003057365616c300b7365616c5f72657475726e0000057365616c3005696e7075740001057365616c301176616c75655f7472616e73666572726564000103656e76066d656d6f727902011010030a090001000306020708090608017f01418080040b071102066465706c6f7900130463616c6c00130af86809b50101027f02402002450d00200241016b2002410771220304400340200020012d00003a0000200041016a2100200141016a2101200241016b2102200341016b22030d000b0b4107490d000340200020012d00003a0000200020012d00013a0001200020012d00023a0002200020012d00033a0003200020012d00043a0004200020012d00053a0005200020012d00063a0006200020012d00073a0007200041086a2100200141086a2101200241086b22020d000b0b0b930101037f4120210302404100450440200041206a21040c010b03402001200341016b220320006a22042d00003a0000200141016a2101200241016b22020d000b0b200441046b210203402001200241036a2d00003a00002001200241026a2d00003a00012001200241016a2d00003a0002200120022d00003a0003200241046b2102200141046a2101200341046b22030d000b0b9f0101037f200241016b024020024103712203450440200120026a21040c010b0340200241016b220220016a220420002d00003a0000200041016a2100200341016b22030d000b0b41034f0440200441046b21030340200341036a20002d00003a0000200341026a20002d00013a0000200341016a20002d00023a0000200320002d00033a0000200041046a2100200341046b2103200241046b22020d000b0b0bb30201047f2000220241086a100f2204200036020420042000360200200441086a210002402001417f4704402002450d01200241016b2002410771220304400340200020012d00003a0000200041016a2100200141016a2101200241016b2102200341016b22030d000b0b4107490d010340200020012d00003a0000200020012d00013a0001200020012d00023a0002200020012d00033a0003200020012d00043a0004200020012d00053a0005200020012d00063a0006200020012d00073a0007200041086a2100200141086a2101200241086b22020d000b0c010b2002450d00200241016b2002410771220104400340200041003a0000200041016a2100200241016b2102200141016b22010d000b0b4107490d00034020004200370000200041086a2100200241086b22020d000b0b20040b950101047f41808004210103400240200128020c0d00200128020822022000490d002002200041076a41787122026b220441184f0440200120026a41106a22002001280200220336020020030440200320003602040b2000200441106b3602082000410036020c2000200136020420012000360200200120023602080b2001410136020c200141106a0f0b200128020021010c000b000b890301047f200120036a220441086a100f2205200436020420052004360200200541086a210402402001450d00200141016b2001410771220604400340200420002d00003a0000200441016a2104200041016a2100200141016b2101200641016b22060d000b0b4107490d000340200420002d00003a0000200420002d00013a0001200420002d00023a0002200420002d00033a0003200420002d00043a0004200420002d00053a0005200420002d00063a0006200420002d00073a0007200441086a2104200041086a2100200141086b22010d000b0b02402003450d00200341016b2003410771220004400340200420022d00003a0000200441016a2104200241016a2102200341016b2103200041016b22000d000b0b4107490d000340200420022d00003a0000200420022d00013a0001200420022d00023a0002200420022d00033a0003200420022d00043a0004200420022d00053a0005200420022d00063a0006200420022d00073a0007200441086a2104200241086a2102200341086b22030d000b0b20050bb60a01227f230041406a220024004188014120360200200041386a4200370300200042003703302000420037032820004200370320200041206a4120419001418801100021024190012d000021034191012d000021044192012d000021054193012d000021064194012d000021074195012d000021084196012d000021094197012d0000210a4198012d0000210b4199012d0000210c419a012d0000210d419b012d0000210e419c012d0000210f419d012d00002110419e012d00002111419f012d0000211241a0012d0000211341a1012d0000211441a2012d0000211541a3012d0000211641a4012d0000211741a5012d0000211841a6012d0000211941a7012d0000211a41a8012d0000211b41a9012d0000211c41aa012d0000211d41ab012d0000211e41ac012d0000211f41ad012d0000212041ae012d000021212000410041af012d000020021b3a001f20004100202120021b3a001e20004100202020021b3a001d20004100201f20021b3a001c20004100201e20021b3a001b20004100201d20021b3a001a20004100201c20021b3a001920004100201b20021b3a001820004100201a20021b3a001720004100201920021b3a001620004100201820021b3a001520004100201720021b3a001420004100201620021b3a001320004100201520021b3a001220004100201420021b3a001120004100201320021b3a001020004100201220021b3a000f20004100201120021b3a000e20004100201020021b3a000d20004100200f20021b3a000c20004100200e20021b3a000b20004100200d20021b3a000a20004100200c20021b3a000920004100200b20021b3a000820004100200a20021b3a000720004100200920021b3a000620004100200820021b3a000520004100200720021b3a000420004100200620021b3a000320004100200520021b3a000220004100200420021b3a000120004100200320021b3a000020002d001f210220002d001e210320002d001d210420002d001c210520002d001b210620002d001a210720002d0019210820002d0018210920002d0017210a20002d0016210b20002d0015210c20002d0014210d20002d0013210e20002d0012210f20002d0011211020002d0010211120002d000f211220002d000e211320002d000d211420002d000c211520002d000b211620002d000a211720002d0009211820002d0008211920002d0007211a20002d0006211b20002d0005211c20002d0004211d20002d0003211e20002d0002211f20002d0001212020002d00002121200041206b220124004188014120360200419001418801100120014190012903003700002001419801290300370008200141a001290300370010200141a80129030037001802400240202120012d0000470d00202020012d0001470d00201f20012d0002470d00201e20012d0003470d00201d20012d0004470d00201c20012d0005470d00201b20012d0006470d00201a20012d0007470d00201920012d0008470d00201820012d0009470d00201720012d000a470d00201620012d000b470d00201520012d000c470d00201420012d000d470d00201320012d000e470d00201220012d000f470d00201120012d0010470d00201020012d0011470d00200f20012d0012470d00200e20012d0013470d00200d20012d0014470d00200c20012d0015470d00200b20012d0016470d00200a20012d0017470d00200920012d0018470d00200820012d0019470d00200720012d001a470d00200620012d001b470d00200520012d001c470d00200420012d001d470d00200320012d001e470d00200220012d001f460d010b000b200041406b240041000b8a1501277f230041a0016b2223240041880141203602002023222141d8006a4200370300202142003703502021420037034820214200370340202141406b4120419001418801100021224190012d000021244191012d000021264192012d000021274193012d000021284194012d000021294195012d0000212a4196012d0000212b4197012d0000212c4198012d0000212d4199012d0000212e419a012d0000212f419b012d00002130419c012d00002131419d012d00002132419e012d00002133419f012d0000213441a0012d0000213541a1012d0000213641a2012d0000213741a3012d0000213841a4012d0000213941a5012d0000213a41a6012d0000213b41a7012d0000213c41a8012d0000213d41a9012d0000213e41aa012d0000213f41ab012d0000214041ac012d0000214141ad012d0000214241ae012d0000214341af012d000021442021201f3a001f2021201e3a001e2021201d3a001d2021201c3a001c2021201b3a001b2021201a3a001a202120193a0019202120183a0018202120173a0017202120163a0016202120153a0015202120143a0014202120133a0013202120123a0012202120113a0011202120103a00102021200f3a000f2021200e3a000e2021200d3a000d2021200c3a000c2021200b3a000b2021200a3a000a202120093a0009202120083a0008202120073a0007202120063a0006202120053a0005202120043a0004202120033a0003202120023a0002202120013a0001202120003a0000202141386a4200370300202142003703302021420037032820214200370320202141206a41202021412010021a4120417f100e222041276a4100204420221b22443a0000202041266a4100204320221b22433a0000202041256a4100204220221b22423a0000202041246a4100204120221b22413a0000202041236a4100204020221b22403a0000202041226a4100203f20221b223f3a0000202041216a4100203e20221b223e3a0000202041206a4100203d20221b223d3a00002020411f6a4100203c20221b223c3a00002020411e6a4100203b20221b223b3a00002020411d6a4100203a20221b223a3a00002020411c6a4100203920221b22393a00002020411b6a4100203820221b22383a00002020411a6a4100203720221b22373a0000202041196a4100203620221b22363a0000202041186a4100203520221b22353a0000202041176a4100203420221b22343a0000202041166a4100203320221b22333a0000202041156a4100203220221b22323a0000202041146a4100203120221b22313a0000202041136a4100203020221b22303a0000202041126a4100202f20221b222f3a0000202041116a4100202e20221b222e3a0000202041106a4100202d20221b222d3a00002020410f6a4100202c20221b222c3a00002020410e6a4100202b20221b222b3a00002020410d6a4100202a20221b222a3a00002020410c6a4100202920221b22293a00002020410b6a4100202820221b22283a00002020410a6a4100202720221b22273a0000202041096a4100202620221b22263a0000202041086a22254100202420221b22453a00004100412d20252020280200410020201b10102222280200410020221b41214f044020222802002124202341206b222022232400202241086a22252024410020221b20201003202341206b2223240020202023100c202141f8006a202341186a2903003703002021202341106a2903003703702021202341086a29030037036820212023290300370360202141e0006a20254120100d0b4120417f100e2220410a6a20023a0000202041096a20013a0000202041086a222420003a00002020410b6a20033a00002020410c6a20043a00002020410d6a20053a00002020410e6a20063a00002020410f6a20073a0000202041106a20083a0000202041116a20093a0000202041126a200a3a0000202041136a200b3a0000202041146a200c3a0000202041156a200d3a0000202041166a200e3a0000202041176a200f3a0000202041186a20103a0000202041196a20113a00002020411a6a20123a00002020411b6a20133a00002020411c6a20143a00002020411d6a20153a00002020411e6a20163a00002020411f6a20173a0000202041206a20183a0000202041216a20193a0000202041226a201a3a0000202041236a201b3a0000202041246a201c3a0000202041256a201d3a0000202041266a201e3a0000202041276a201f3a00004130412820242020280200410020201b10102224280200410020241b41214f044020242802002125202341206b222022232400202441086a22462025410020241b20201003202341206b2223240020202023100c20214198016a202341186a2903003703002021202341106a290300370390012021202341086a29030037038801202120232903003703800120214180016a20464120100d0b41c100417f100e222041096a20453a0000202041086a222541003a00002020410a6a20263a00002020410b6a20273a00002020410c6a20283a00002020410d6a20293a00002020410e6a202a3a00002020410f6a202b3a0000202041106a202c3a0000202041116a202d3a0000202041126a202e3a0000202041136a202f3a0000202041146a20303a0000202041156a20313a0000202041166a20323a0000202041176a20333a0000202041186a20343a0000202041196a20353a00002020411a6a20363a00002020411b6a20373a00002020411c6a20383a00002020411d6a20393a00002020411e6a203a3a00002020411f6a203b3a0000202041206a203c3a0000202041216a203d3a0000202041226a203e3a0000202041236a203f3a0000202041246a20403a0000202041256a20413a0000202041266a20423a0000202041276a20433a0000202041286a20443a0000202041c8006a201f3a0000202041c7006a201e3a0000202041c6006a201d3a0000202041c5006a201c3a0000202041c4006a201b3a0000202041c3006a201a3a0000202041c2006a20193a0000202041c1006a20183a0000202041406b20173a00002020413f6a20163a00002020413e6a20153a00002020413d6a20143a00002020413c6a20133a00002020413b6a20123a00002020413a6a20113a0000202041396a20103a0000202041386a200f3a0000202041376a200e3a0000202041366a200d3a0000202041356a200c3a0000202041346a200b3a0000202041336a200a3a0000202041326a20093a0000202041316a20083a0000202041306a20073a00002020412f6a20063a00002020412e6a20053a00002020412d6a20043a00002020412c6a20033a00002020412b6a20023a00002020412a6a20013a0000202041296a20003a0000202341f0006b220224002002410c3a0000202341ef006b22042100410c2101410422030440034020004200370300200041086a2100200141016b2101200341016b22030d000b0b034020004200370300200041386a4200370300200041306a4200370300200041286a4200370300200041206a4200370300200041186a4200370300200041106a4200370300200041086a4200370300200041406b2100200141086b22010d000b200441e0004120100b202341cf006b202241086a2022280200410020221b100b2023412f6b202441086a2024280200410020241b100b200241e10020252020280200410020201b1004202141a0016a240041000bed3e02467f047e230041206b22002400418080044100360200418480044100360200418c80044100360200418880043f00411074419080046b36020041880141808002360200419001418801100941840141880128020022013602002000411036020c200041106a2000410c6a100a20002903102146200041186a2903002147230041206b2203240002400240024002400240024002400240200141034d0d004180014190012802002200360200024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200041d0ccf1254c0440200041f0a0e1b07a4c0440200041f2fb8fdf78460d04200041c6f4f7bc79470d1d2046204784500d0e000b200041f1a0e1b07a460d0220004186afc4a97d460d010c1c0b200041b7acc091034c0440200041d1ccf125460d05200041b3b3bd3b470d1c2046204784500d0e000b200041b8acc09103460d032000418dcbaede05470d1b2046204784500d05000b41880141203602004190014188011001200341a8012903002246370018200341a001290300224737001020034198012903002248370008200341900129030022493700002049a720032d000120032d000220032d000320032d000420032d000520032d000620032d00072048a720032d000920032d000a20032d000b20032d000c20032d000d20032d000e20032d000f2047a720032d001120032d001220032d001320032d001420032d001520032d001620032d00172046a720032d001920032d001a20032d001b20032d001c20032d001d20032d001e20032d001f10122201047f20010541000b0d1c0c1b0b20462047844200520d180240101122000d00410021004100210141004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100101222020440200221010b2001450d00200121000b20000d1b0c1a0b20462047844200520d162001200141046b2200490d0320004120490d04200041204d0d0b000b20462047844200520d142001200141046b2200490d0420004120490d05200041204d0d0d000b20462047844200520d122001200141046b2200490d05200041c000490d06200041c0004d0d0a000b200341206b220024004188014120360200200341186a420037030020034200370310200342003703082003420037030020034120419001418801100021014190012d000021024191012d000021044192012d000021054193012d000021064194012d000021074195012d000021084196012d000021094197012d0000210a4198012d0000210b4199012d0000210c419a012d0000210d419b012d0000210e419c012d0000210f419d012d00002110419e012d00002111419f012d0000211241a0012d0000211341a1012d0000211441a2012d0000211541a3012d0000211641a4012d0000211741a5012d0000211841a6012d0000211941a7012d0000211a41a8012d0000211b41a9012d0000211c41aa012d0000211d41ab012d0000211e41ac012d0000211f41ad012d0000212041ae012d000021212000410041af012d000020011b3a001f20004100202120011b3a001e20004100202020011b3a001d20004100201f20011b3a001c20004100201e20011b3a001b20004100201d20011b3a001a20004100201c20011b3a001920004100201b20011b3a001820004100201a20011b3a001720004100201920011b3a001620004100201820011b3a001520004100201720011b3a001420004100201620011b3a001320004100201520011b3a001220004100201420011b3a001120004100201320011b3a001020004100201220011b3a000f20004100201120011b3a000e20004100201020011b3a000d20004100200f20011b3a000c20004100200e20011b3a000b20004100200d20011b3a000a20004100200c20011b3a000920004100200b20011b3a000820004100200a20011b3a000720004100200920011b3a000620004100200820011b3a000520004100200720011b3a000420004100200620011b3a000320004100200520011b3a000220004100200420011b3a000120004100200220011b3a00000c190b000b000b000b000b000b000b2001200141046b2200490d06200041204f0440200041204d0d04000b000b2001200141046b2200490d06200041204f0440200041204d0d05000b000b41b3012d0000210241b2012d0000210441b1012d0000210541b0012d0000210641af012d0000210741ae012d0000210841ad012d0000210941ac012d0000210a41ab012d0000210b41aa012d0000210c41a9012d0000210d41a8012d0000210e41a7012d0000210f41a6012d0000211041a5012d0000211141a4012d0000211241a3012d0000211341a2012d0000211441a1012d0000211541a0012d00002116419f012d00002117419e012d00002118419d012d00002119419c012d0000211a419b012d0000211b419a012d0000211c4199012d0000211d4198012d0000211e4197012d0000211f4196012d000021204195012d000021214194012d000021220240101122000d0020022021202272202072201f72201e72201d72201c72201b72201a72201972201872201772201672201572201472201372201272201172201072200f72200e72200d72200c72200b72200a7220097220087220077220067220057220047272450d074100210041002101202220212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a2009200820072006200520042002101222020440200221010b2001450d00200121000b20000d0e0c0d0b41b3012d0000212441b2012d0000212541b1012d0000212641b0012d0000212741af012d0000212841ae012d0000212941ad012d0000212a41ac012d0000212b41ab012d0000212c41aa012d0000212d41a9012d0000212e41a8012d0000212f41a7012d0000213041a6012d0000213141a5012d0000213241a4012d0000213341a3012d0000213441a2012d0000213541a1012d0000213641a0012d00002137419f012d00002138419e012d00002139419d012d0000213a419c012d0000213b419b012d0000213c419a012d0000213d4199012d0000213e4198012d0000213f4197012d000021404196012d000021414195012d000021424194012d0000214341d3012d0000210541d2012d0000210641d1012d0000210741d0012d0000210841cf012d0000210941ce012d0000210a41cd012d0000210b41cc012d0000210c41cb012d0000210d41ca012d0000210e41c9012d0000210f41c8012d0000211041c7012d0000211141c6012d0000211241c5012d0000211341c4012d0000211441c3012d0000211541c2012d0000211641c1012d0000211741c0012d0000211841bf012d0000211941be012d0000211a41bd012d0000211b41bc012d0000211c41bb012d0000211d41ba012d0000211e41b9012d0000211f41b8012d0000212041b7012d0000212141b6012d0000212241b5012d0000210141b4012d000021230240101122000d00230041306b220224000240024020242042204372204172204072203f72203e72203d72203c72203b72203a72203972203872203772203672203572203472203372203272203172203072202f72202e72202d72202c72202b72202a722029722028722027722026722025727204402001202372202272202172202072201f72201e72201d72201c72201b72201a72201972201872201772201672201572201472201372201272201172201072200f72200e72200d72200c72200b72200a7220097220087220077220067220057241ff0171450d014104417f100e21042002418cadbe7536020c2002410c6a200441086a22444104100d200220213a0013200220223a0012200220013a0011200220233a0010200220203a00142002201f3a00152002201e3a00162002201d3a00172002201c3a00182002201b3a00192002201a3a001a200220193a001b200220183a001c200220173a001d200220163a001e200220153a001f200220143a0020200220133a0021200220123a0022200220113a0023200220103a00242002200f3a00252002200e3a00262002200d3a00272002200c3a00282002200b3a00292002200a3a002a200220093a002b200220083a002c200220073a002d200220063a002e200220053a002f20042802002145200241106b220024002000420037030820004200370300418801418080023602004100200241106a4200200020442045410020041b4190014188011006450d02000b000b000b200041406a22002400200041186a4200370300200042003703102000420037030820004201370300200041206a20433a0000200041216a20423a0000200041226a20413a0000200041236a20403a0000200041246a203f3a0000200041256a203e3a0000200041266a203d3a0000200041276a203c3a0000200041286a203b3a0000200041296a203a3a00002000412a6a20393a00002000412b6a20383a00002000412c6a20373a00002000412d6a20363a00002000412e6a20353a00002000412f6a20343a0000200041306a20333a0000200041316a20323a0000200041326a20313a0000200041336a20303a0000200041346a202f3a0000200041356a202e3a0000200041366a202d3a0000200041376a202c3a0000200041386a202b3a0000200041396a202a3a00002000413a6a20293a00002000413b6a20283a00002000413c6a20273a00002000413d6a20263a00002000413e6a20253a00002000413f6a20243a0000200041206b22042400200041c0002004100520042903002146200441086a2903002147200441106a2903002148200441186a2903002149200441206b220422002400200041206b22002400200020053a001f200020063a001e200020073a001d200020083a001c200020093a001b2000200a3a001a2000200b3a00192000200c3a00182000200d3a00172000200e3a00162000200f3a0015200020103a0014200020113a0013200020123a0012200020133a0011200020143a0010200020153a000f200020163a000e200020173a000d200020183a000c200020193a000b2000201a3a000a2000201b3a00092000201c3a00082000201d3a00072000201e3a00062000201f3a0005200020203a0004200020213a0003200020223a0002200020013a0001200020233a0000200441186a2049370300200420483703102004204737030820042046370300200441202000412010021a200241306a2400410022000d000b20000d0d0c0c0b41b3012d0000210241b2012d0000210441b1012d0000210541b0012d0000210641af012d0000210741ae012d0000210841ad012d0000210941ac012d0000210a41ab012d0000210b41aa012d0000210c41a9012d0000210d41a8012d0000210e41a7012d0000210f41a6012d0000211041a5012d0000211141a4012d0000211241a3012d0000211341a2012d0000211441a1012d0000211541a0012d00002116419f012d00002117419e012d00002118419d012d00002119419c012d0000211a419b012d0000211b419a012d0000211c4199012d0000211d4198012d0000211e4197012d0000211f4196012d000021204195012d000021214194012d000021220240101122000d00027f23002201212320022021202272202072201f72201e72201d72201c72201b72201a72201972201872201772201672201572201472201372201272201172201072200f72200e72200d72200c72200b72200a72200972200872200772200672200572200472720440200141406a22012400200141186a4200370300200142003703102001420037030820014201370300200141206a20223a0000200141216a20213a0000200141226a20203a0000200141236a201f3a0000200141246a201e3a0000200141256a201d3a0000200141266a201c3a0000200141276a201b3a0000200141286a201a3a0000200141296a20193a00002001412a6a20183a00002001412b6a20173a00002001412c6a20163a00002001412d6a20153a00002001412e6a20143a00002001412f6a20133a0000200141306a20123a0000200141316a20113a0000200141326a20103a0000200141336a200f3a0000200141346a200e3a0000200141356a200d3a0000200141366a200c3a0000200141376a200b3a0000200141386a200a3a0000200141396a20093a00002001413a6a20083a00002001413b6a20073a00002001413c6a20063a00002001413d6a20053a00002001413e6a20043a00002001413f6a20023a0000200141206b22002400200141c0002000100520002903002146200041086a2903002147200041106a2903002148200041186a2903002149200041206b22012400200141186a20493703002001204837031020012047370308200120463703002001412010071a2023240041000c010b000b22000d00410021000b20000d0c0c0b0b41b3012d0000210441b2012d0000210541b1012d0000210641b0012d0000210741af012d0000210841ae012d0000210941ad012d0000210a41ac012d0000210b41ab012d0000210c41aa012d0000210d41a9012d0000210e41a8012d0000210f41a7012d0000211041a6012d0000211141a5012d0000211241a4012d0000211341a3012d0000211441a2012d0000211541a1012d0000211641a0012d00002117419f012d00002118419e012d00002119419d012d0000211a419c012d0000211b419b012d0000211c419a012d0000211d4199012d0000211e4198012d0000211f4197012d000021204196012d000021214195012d000021224194012d00002123200341206b22002400230041406a22022400200241406a22012400200141186a4200370300200142003703102001420037030820014201370300200141206a20233a0000200141216a20223a0000200141226a20213a0000200141236a20203a0000200141246a201f3a0000200141256a201e3a0000200141266a201d3a0000200141276a201c3a0000200141286a201b3a0000200141296a201a3a00002001412a6a20193a00002001412b6a20183a00002001412c6a20173a00002001412d6a20163a00002001412e6a20153a00002001412f6a20143a0000200141306a20133a0000200141316a20123a0000200141326a20113a0000200141336a20103a0000200141346a200f3a0000200141356a200e3a0000200141366a200d3a0000200141376a200c3a0000200141386a200b3a0000200141396a200a3a00002001413a6a20093a00002001413b6a20083a00002001413c6a20073a00002001413d6a20063a00002001413e6a20053a00002001413f6a20043a0000200141c000200241206a10054188014120360200200241186a200241386a2903003703002002200241306a2903003703102002200241286a2903003703082002200229032037030020024120419001418801100021014190012d000021044191012d000021054192012d000021064193012d000021074194012d000021084195012d000021094196012d0000210a4197012d0000210b4198012d0000210c4199012d0000210d419a012d0000210e419b012d0000210f419c012d00002110419d012d00002111419e012d00002112419f012d0000211341a0012d0000211441a1012d0000211541a2012d0000211641a3012d0000211741a4012d0000211841a5012d0000211941a6012d0000211a41a7012d0000211b41a8012d0000211c41a9012d0000211d41aa012d0000211e41ab012d0000211f41ac012d0000212041ad012d0000212141ae012d000021222000410041af012d000020011b3a001f20004100202220011b3a001e20004100202120011b3a001d20004100202020011b3a001c20004100201f20011b3a001b20004100201e20011b3a001a20004100201d20011b3a001920004100201c20011b3a001820004100201b20011b3a001720004100201a20011b3a001620004100201920011b3a001520004100201820011b3a001420004100201720011b3a001320004100201620011b3a001220004100201520011b3a001120004100201420011b3a001020004100201320011b3a000f20004100201220011b3a000e20004100201120011b3a000d20004100201020011b3a000c20004100200f20011b3a000b20004100200e20011b3a000a20004100200d20011b3a000920004100200c20011b3a000820004100200b20011b3a000720004100200a20011b3a000620004100200920011b3a000520004100200820011b3a000420004100200720011b3a000320004100200620011b3a000220004100200520011b3a000120004100200420011b3a0000200241406b24000c0d0b41b3012d0000210441b2012d0000210541b1012d0000210641b0012d0000210741af012d0000210841ae012d0000210941ad012d0000210a41ac012d0000210b41ab012d0000210c41aa012d0000210d41a9012d0000210e41a8012d0000210f41a7012d0000211041a6012d0000211141a5012d0000211241a4012d0000211341a3012d0000211441a2012d0000211541a1012d0000211641a0012d00002117419f012d00002118419e012d00002119419d012d0000211a419c012d0000211b419b012d0000211c419a012d0000211d4199012d0000211e4198012d0000211f4197012d000021204196012d000021214195012d000021224194012d00002123200341206b22022400027f230041f0006b22012400200141406a220022242400200041186a4200370300200042003703102000420037030820004201370300200041206a20233a0000200041216a20223a0000200041226a20213a0000200041236a20203a0000200041246a201f3a0000200041256a201e3a0000200041266a201d3a0000200041276a201c3a0000200041286a201b3a0000200041296a201a3a00002000412a6a20193a00002000412b6a20183a00002000412c6a20173a00002000412d6a20163a00002000412e6a20153a00002000412f6a20143a0000200041306a20133a0000200041316a20123a0000200041326a20113a0000200041336a20103a0000200041346a200f3a0000200041356a200e3a0000200041366a200d3a0000200041376a200c3a0000200041386a200b3a0000200041396a200a3a00002000413a6a20093a00002000413b6a20083a00002000413c6a20073a00002000413d6a20063a00002000413e6a20053a00002000413f6a20043a0000200041c000200141286a10054188014120360200200141206a200141406b2903003703002001200141386a2903003703182001200141306a29030037031020012001290328370308200141086a412041900141880110002100024002400240410041af012d000020001b2204410041ae012d000020001b2205410041ad012d000020001b2206410041ac012d000020001b2207410041ab012d000020001b2208410041aa012d000020001b2209410041a9012d000020001b220a410041a8012d000020001b220b410041a7012d000020001b220c410041a6012d000020001b220d410041a5012d000020001b220e410041a4012d000020001b220f410041a3012d000020001b2210410041a2012d000020001b2211410041a1012d000020001b2212410041a0012d000020001b22134100419f012d000020001b22144100419e012d000020001b22154100419d012d000020001b22164100419c012d000020001b22174100419b012d000020001b22184100419a012d000020001b221941004199012d000020001b221a41004198012d000020001b221b41004197012d000020001b221c41004196012d000020001b221d41004195012d000020001b221e41004194012d000020001b221f41004193012d000020001b222041004192012d000020001b222141004190012d000020001b222241004191012d000020001b22237272727272727272727272727272727272727272727272727272727272727241ff017104404104417f100e21002001418cadbe7536024c200141cc006a200041086a22254104100d200120203a0053200120213a0052200120233a0051200120223a00502001201f3a00542001201e3a00552001201d3a00562001201c3a00572001201b3a00582001201a3a0059200120193a005a200120183a005b200120173a005c200120163a005d200120153a005e200120143a005f200120133a0060200120123a0061200120113a0062200120103a00632001200f3a00642001200e3a00652001200d3a00662001200c3a00672001200b3a00682001200a3a0069200120093a006a200120083a006b200120073a006c200120063a006d200120053a006e200120043a006f20002802002105202441106b220424002004420037030820044200370300418801418080023602004100200141d0006a4200200420252005410020001b41900141880110060d01418801280200419001100e2200280200410020001b220441f3004d0d02418801280200419001100e1a418801280200419001100e220041306a2903002146200041286a2903002147200041206a2903002148200041186a2903002149418801280200419001100e1a418801280200419001100e1a418801280200419001100e1a20044180014b0d03200220493703002002204837030820022047370310200241186a2046370300200141f0006a240041000c040b000b000b000b000b450d030c0b0b000b000b000b200241086a2903002146200241106a2903002147200241186a2903002148200229030021494120417f100e220141206a2048370300200141186a2047370300200141106a2046370300200141086a220020493703000c090b000b000b000b000b000b41004100417f100e41086a410010080c040b200341206a24000c040b200341206a24000c030b200029000021462000290008214720002900102148200029001821494120417f100e220141206a2049370000200141186a2048370000200141106a2047370000200141086a220020463700000b41002000412010080b200341206a24000b000b0b8101020041000b58b04f776e61626c653a3a4f776e6572736869705472616e736665727265643a3a70726576696f75734f776e65720000009c4f776e61626c653a3a4f776e6572736869705472616e736665727265643a3a6e65774f776e65720041e1000b1d4f776e61626c653a3a4f776e6572736869705472616e73666572726564008e010970726f64756365727302086c616e6775616765010143000c70726f6365737365642d62790105636c616e676131352e302e34202868747470733a2f2f6769746875622e636f6d2f736f6c616e612d6c6162732f6c6c766d2d70726f6a6563742e676974203333633336323963616135396235396438663538353733366134613531393461613965393337376429', - }, - spec: { - constructors: [ - { - args: [], - docs: [''], - label: 'new', - payable: false, - returnType: null, - selector: '0x861731d5', - }, - ], - docs: ["ChainlinkAdapter\n\nPrice oracle that uses Chainlink's price feeds\n\n"], - events: [ - { - args: [ - { - docs: [], - indexed: true, - label: 'previousOwner', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - docs: [], - indexed: true, - label: 'newOwner', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - ], - docs: [''], - label: 'OwnershipTransferred', - }, - ], - lang_error: { - displayName: [], - type: 0, - }, - messages: [ - { - args: [], - docs: [''], - label: 'owner', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - selector: '0x8da5cb5b', - }, - { - args: [], - docs: [''], - label: 'renounceOwnership', - mutates: true, - payable: false, - returnType: null, - selector: '0x715018a6', - }, - { - args: [ - { - label: 'newOwner', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - ], - docs: [''], - label: 'transferOwnership', - mutates: true, - payable: false, - returnType: null, - selector: '0xf2fde38b', - }, - { - args: [ - { - label: '', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - ], - docs: [''], - label: 'oracleByAsset', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - selector: '0x38163032', - }, - { - args: [ - { - label: '_asset', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: '_priceFeed', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - ], - docs: ['Registers a new price feed\n\n'], - label: 'registerPriceFeed', - mutates: true, - payable: false, - returnType: null, - selector: '0x5166bc04', - }, - { - args: [ - { - label: '_asset', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - ], - docs: ['Unregisters a price feed\n\n'], - label: 'unregisterPriceFeed', - mutates: true, - payable: false, - returnType: null, - selector: '0x46fa9d97', - }, - { - args: [ - { - label: '_asset', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - ], - docs: ['Returns the asset price in USD\n\n'], - label: 'getAssetPrice', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 3, - }, - selector: '0xb3596f07', - }, - ], - }, - storage: { - struct: { - fields: [ - { - layout: { - root: { - layout: { - struct: { - fields: [ - { - layout: { - leaf: { - key: '0x00000000', - ty: 1, - }, - }, - name: '', - }, - ], - name: 'AccountId', - }, - }, - root_key: '0x00000000', - }, - }, - name: '_owner', - }, - { - layout: { - root: { - layout: { - struct: { - fields: [ - { - layout: { - leaf: { - key: '0x00000001', - ty: 1, - }, - }, - name: '', - }, - ], - name: 'AccountId', - }, - }, - root_key: '0x00000001', - }, - }, - name: 'oracleByAsset', - }, - ], - name: 'ChainlinkAdapter', - }, - }, - types: [ - { - id: 0, - type: { - def: { - primitive: 'u8', - }, - path: ['u8'], - }, - }, - { - id: 1, - type: { - def: { - array: { - len: 32, - type: 0, - }, - }, - }, - }, - { - id: 2, - type: { - def: { - composite: { - fields: [ - { - type: 1, - }, - ], - }, - }, - path: ['ink_env', 'types', 'AccountId'], - }, - }, - { - id: 3, - type: { - def: { - primitive: 'u256', - }, - path: ['u256'], - }, - }, - ], - version: '4', -} as const; diff --git a/src/contracts/nabla/ERC20Wrapper.ts b/src/contracts/nabla/ERC20Wrapper.ts new file mode 100644 index 00000000..4fc387cb --- /dev/null +++ b/src/contracts/nabla/ERC20Wrapper.ts @@ -0,0 +1,654 @@ +export const erc20WrapperAbi = { + contract: { + authors: ['unknown'], + name: 'ERC20Wrapper', + version: '0.0.1', + }, + source: { + compiler: 'solang 0.3.2', + hash: '0xd070e8f0df66f4f13a8ee42d5bf90220b1867883444c8f73f400f8c57ae2c9cd', + language: 'Solidity 0.3.2', + }, + spec: { + constructors: [ + { + args: [ + { + label: 'name_', + type: { + displayName: ['string'], + type: 0, + }, + }, + { + label: 'symbol_', + type: { + displayName: ['string'], + type: 0, + }, + }, + { + label: 'decimals_', + type: { + displayName: ['uint8'], + type: 1, + }, + }, + { + label: 'variant_', + type: { + displayName: [], + type: 2, + }, + }, + { + label: 'index_', + type: { + displayName: [], + type: 2, + }, + }, + { + label: 'code_', + type: { + displayName: [], + type: 3, + }, + }, + { + label: 'issuer_', + type: { + displayName: [], + type: 4, + }, + }, + ], + default: false, + docs: [''], + label: 'new', + payable: false, + returnType: null, + selector: '0xd3b751bd', + }, + ], + docs: [''], + environment: { + accountId: { + displayName: ['AccountId'], + type: 6, + }, + balance: { + displayName: ['Balance'], + type: 8, + }, + blockNumber: { + displayName: ['BlockNumber'], + type: 9, + }, + chainExtension: { + displayName: [], + type: 0, + }, + hash: { + displayName: ['Hash'], + type: 10, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 9, + }, + }, + events: [ + { + args: [ + { + docs: [], + indexed: true, + label: 'from', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + { + docs: [], + indexed: true, + label: 'to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + { + docs: [], + indexed: false, + label: 'value', + type: { + displayName: ['uint256'], + type: 5, + }, + }, + ], + docs: [''], + label: 'Transfer', + }, + { + args: [ + { + docs: [], + indexed: true, + label: 'owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + { + docs: [], + indexed: true, + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + { + docs: [], + indexed: false, + label: 'value', + type: { + displayName: ['uint256'], + type: 5, + }, + }, + ], + docs: [''], + label: 'Approval', + }, + ], + lang_error: { + displayName: ['SolidityError'], + type: 13, + }, + messages: [ + { + args: [], + default: false, + docs: [''], + label: 'name', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 0, + }, + selector: '0x06fdde03', + }, + { + args: [], + default: false, + docs: [''], + label: 'symbol', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 0, + }, + selector: '0x95d89b41', + }, + { + args: [], + default: false, + docs: [''], + label: 'decimals', + mutates: false, + payable: false, + returnType: { + displayName: ['uint8'], + type: 1, + }, + selector: '0x313ce567', + }, + { + args: [], + default: false, + docs: [''], + label: 'totalSupply', + mutates: true, + payable: false, + returnType: { + displayName: ['uint256'], + type: 5, + }, + selector: '0x18160ddd', + }, + { + args: [ + { + label: '_owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + ], + default: false, + docs: [''], + label: 'balanceOf', + mutates: true, + payable: false, + returnType: { + displayName: ['uint256'], + type: 5, + }, + selector: '0x70a08231', + }, + { + args: [ + { + label: '_to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 5, + }, + }, + ], + default: false, + docs: [''], + label: 'transfer', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 7, + }, + selector: '0xa9059cbb', + }, + { + args: [ + { + label: '_owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + { + label: '_spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + ], + default: false, + docs: [''], + label: 'allowance', + mutates: true, + payable: false, + returnType: { + displayName: ['uint256'], + type: 5, + }, + selector: '0xdd62ed3e', + }, + { + args: [ + { + label: '_spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 5, + }, + }, + ], + default: false, + docs: [''], + label: 'approve', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 7, + }, + selector: '0x095ea7b3', + }, + { + args: [ + { + label: '_from', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + { + label: '_to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 5, + }, + }, + ], + default: false, + docs: [''], + label: 'transferFrom', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 7, + }, + selector: '0x23b872dd', + }, + ], + }, + storage: { + struct: { + fields: [ + { + layout: { + root: { + layout: { + leaf: { + key: '0x00000000', + ty: 0, + }, + }, + root_key: '0x00000000', + }, + }, + name: '_name', + }, + { + layout: { + root: { + layout: { + leaf: { + key: '0x00000001', + ty: 0, + }, + }, + root_key: '0x00000001', + }, + }, + name: '_symbol', + }, + { + layout: { + root: { + layout: { + leaf: { + key: '0x00000002', + ty: 1, + }, + }, + root_key: '0x00000002', + }, + }, + name: '_decimals', + }, + { + layout: { + root: { + layout: { + leaf: { + key: '0x00000003', + ty: 2, + }, + }, + root_key: '0x00000003', + }, + }, + name: '_variant', + }, + { + layout: { + root: { + layout: { + leaf: { + key: '0x00000004', + ty: 2, + }, + }, + root_key: '0x00000004', + }, + }, + name: '_index', + }, + { + layout: { + root: { + layout: { + leaf: { + key: '0x00000005', + ty: 3, + }, + }, + root_key: '0x00000005', + }, + }, + name: '_code', + }, + { + layout: { + root: { + layout: { + leaf: { + key: '0x00000006', + ty: 4, + }, + }, + root_key: '0x00000006', + }, + }, + name: '_issuer', + }, + ], + name: 'ERC20Wrapper', + }, + }, + types: [ + { + id: 0, + type: { + def: { + primitive: 'str', + }, + path: ['string'], + }, + }, + { + id: 1, + type: { + def: { + primitive: 'u8', + }, + path: ['uint8'], + }, + }, + { + id: 2, + type: { + def: { + array: { + len: 1, + type: 1, + }, + }, + }, + }, + { + id: 3, + type: { + def: { + array: { + len: 12, + type: 1, + }, + }, + }, + }, + { + id: 4, + type: { + def: { + array: { + len: 32, + type: 1, + }, + }, + }, + }, + { + id: 5, + type: { + def: { + primitive: 'u256', + }, + path: ['uint256'], + }, + }, + { + id: 6, + type: { + def: { + composite: { + fields: [ + { + type: 4, + }, + ], + }, + }, + path: ['ink_primitives', 'types', 'AccountId'], + }, + }, + { + id: 7, + type: { + def: { + primitive: 'bool', + }, + path: ['bool'], + }, + }, + { + id: 8, + type: { + def: { + primitive: 'u128', + }, + path: ['uint128'], + }, + }, + { + id: 9, + type: { + def: { + primitive: 'u64', + }, + path: ['uint64'], + }, + }, + { + id: 10, + type: { + def: { + composite: { + fields: [ + { + type: 4, + }, + ], + }, + }, + path: ['ink_primitives', 'types', 'Hash'], + }, + }, + { + id: 11, + type: { + def: { + composite: { + fields: [ + { + type: 0, + }, + ], + }, + }, + path: ['0x08c379a0'], + }, + }, + { + id: 12, + type: { + def: { + composite: { + fields: [ + { + type: 5, + }, + ], + }, + }, + path: ['0x4e487b71'], + }, + }, + { + id: 13, + type: { + def: { + variant: { + variants: [ + { + fields: [ + { + type: 11, + }, + ], + index: 0, + name: 'Error', + }, + { + fields: [ + { + type: 12, + }, + ], + index: 1, + name: 'Panic', + }, + ], + }, + }, + path: ['SolidityError'], + }, + }, + ], + version: '4', +} as const; diff --git a/src/contracts/nabla/MockERC20.ts b/src/contracts/nabla/MockERC20.ts deleted file mode 100644 index caf0aed6..00000000 --- a/src/contracts/nabla/MockERC20.ts +++ /dev/null @@ -1,542 +0,0 @@ -export const mockERC20 = { - contract: { - authors: ['unknown'], - name: 'MockERC20', - version: '0.0.1', - }, - source: { - compiler: 'solang 0.3.0', - hash: '0xfe10c188581e067f4695386c79b64326fcf95707bd96304bd3085c71f3356b1f', - language: 'Solidity 0.3.0', - wasm: '0x0061736d0100000001ba010a60027f7f0060037f7f7f0060047f7f7f7f017f60027f7f017f60447f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7e7e7e7e017f60047f7f7f7f0060017f0060017f017f60417f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60000002df010b057365616c310d636c6561725f73746f726167650003057365616c320b7365745f73746f726167650002057365616c300f686173685f6b656363616b5f3235360001057365616c310b6765745f73746f726167650002057365616c300663616c6c65720000057365616c300f686173685f626c616b65325f3235360001057365616c300d6465706f7369745f6576656e740005057365616c300b7365616c5f72657475726e0001057365616c3005696e7075740000057365616c301176616c75655f7472616e73666572726564000003656e76066d656d6f727902011010030c0b01060000030702080404090608017f01418080040b071102066465706c6f7900140463616c6c00140a87be010bb50101027f02402002450d00200241016b2002410771220304400340200020012d00003a0000200041016a2100200141016a2101200241016b2102200341016b22030d000b0b4107490d000340200020012d00003a0000200020012d00013a0001200020012d00023a0002200020012d00033a0003200020012d00043a0004200020012d00053a0005200020012d00063a0006200020012d00073a0007200041086a2100200141086a2101200241086b22020d000b0b0b900101027f410c2101410422020440034020004200370300200041086a2100200141016b2101200241016b22020d000b0b034020004200370300200041386a4200370300200041306a4200370300200041286a4200370300200041206a4200370300200041186a4200370300200041106a4200370300200041086a4200370300200041406b2100200141086b22010d000b0b930101037f4120210302404100450440200041206a21040c010b03402001200341016b220320006a22042d00003a0000200141016a2101200241016b22020d000b0b200441046b210203402001200241036a2d00003a00002001200241026a2d00003a00012001200241016a2d00003a0002200120022d00003a0003200241046b2102200141046a2101200341046b22030d000b0b930101037f4120210302404100450440200141206a21040c010b0340200341016b220320016a220420002d00003a0000200041016a2100200241016b22020d000b0b200441046b21020340200241036a20002d00003a0000200241026a20002d00013a0000200241016a20002d00023a0000200220002d00033a0000200041046a2100200241046b2102200341046b22030d000b0bb30201047f2000220241086a100f2204200036020420042000360200200441086a210002402001417f4704402002450d01200241016b2002410771220304400340200020012d00003a0000200041016a2100200141016a2101200241016b2102200341016b22030d000b0b4107490d010340200020012d00003a0000200020012d00013a0001200020012d00023a0002200020012d00033a0003200020012d00043a0004200020012d00053a0005200020012d00063a0006200020012d00073a0007200041086a2100200141086a2101200241086b22020d000b0c010b2002450d00200241016b2002410771220104400340200041003a0000200041016a2100200241016b2102200141016b22010d000b0b4107490d00034020004200370000200041086a2100200241086b22020d000b0b20040b950101047f41808004210103400240200128020c0d00200128020822022000490d002002200041076a41787122026b220441184f0440200120026a41106a22002001280200220336020020030440200320003602040b2000200441106b3602082000410036020c2000200136020420012000360200200120023602080b2001410136020c200141106a0f0b200128020021010c000b000b890301047f200120036a220441086a100f2205200436020420052004360200200541086a210402402001450d00200141016b2001410771220604400340200420002d00003a0000200441016a2104200041016a2100200141016b2101200641016b22060d000b0b4107490d000340200420002d00003a0000200420002d00013a0001200420002d00023a0002200420002d00033a0003200420002d00043a0004200420002d00053a0005200420002d00063a0006200420002d00073a0007200441086a2104200041086a2100200141086b22010d000b0b02402003450d00200341016b2003410771220004400340200420022d00003a0000200441016a2104200241016a2102200341016b2103200041016b22000d000b0b4107490d000340200420022d00003a0000200420022d00013a0001200420022d00023a0002200420022d00033a0003200420022d00043a0004200420022d00053a0005200420022d00063a0006200420022d00073a0007200441086a2104200241086a2102200341086b22030d000b0b20050bc30702027f057e230041e0006b22422400204241406a22412400204141186a4200370300204142003703102041420037030820414201370300204141206a20003a0000204141216a20013a0000204141226a20023a0000204141236a20033a0000204141246a20043a0000204141256a20053a0000204141266a20063a0000204141276a20073a0000204141286a20083a0000204141296a20093a00002041412a6a200a3a00002041412b6a200b3a00002041412c6a200c3a00002041412d6a200d3a00002041412e6a200e3a00002041412f6a200f3a0000204141306a20103a0000204141316a20113a0000204141326a20123a0000204141336a20133a0000204141346a20143a0000204141356a20153a0000204141366a20163a0000204141376a20173a0000204141386a20183a0000204141396a20193a00002041413a6a201a3a00002041413b6a201b3a00002041413c6a201c3a00002041413d6a201d3a00002041413e6a201e3a00002041413f6a201f3a0000204141c000204241406b1002204241c8006a2903002147204241d0006a2903002143204241d8006a290300214420422903402145204141406a22002400200041186a2044370300200020433703102000204737030820002045370300200041206a20203a0000200041216a20213a0000200041226a20223a0000200041236a20233a0000200041246a20243a0000200041256a20253a0000200041266a20263a0000200041276a20273a0000200041286a20283a0000200041296a20293a00002000412a6a202a3a00002000412b6a202b3a00002000412c6a202c3a00002000412d6a202d3a00002000412e6a202e3a00002000412f6a202f3a0000200041306a20303a0000200041316a20313a0000200041326a20323a0000200041336a20333a0000200041346a20343a0000200041356a20353a0000200041366a20363a0000200041376a20373a0000200041386a20383a0000200041396a20393a00002000413a6a203a3a00002000413b6a203b3a00002000413c6a203c3a00002000413d6a203d3a00002000413e6a203e3a00002000413f6a203f3a0000200041c000204241206a100241c8014120360200204241186a204241386a2903003703002042204241306a2903003703102042204241286a29030037030820422042290320370300027e2042412041d00141c80110030440420021434200214442000c010b41e001290300214441d801290300214341d001290300214641e8012903000b2145204020463703002040204337030820402044370310204041186a2045370300204241e0006a240041000be81602077f047e230041e0006b224421462044240002402000200172200272200372200472200572200672200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f7241ff017104402020202172202272202372202472202572202672202772202872202972202a72202b72202c72202d72202e72202f72203072203172203272203372203472203572203672203772203872203972203a72203b72203c72203d72203e72203f7241ff0171450d01204441406a22442400204441186a4200370300204442003703102044420037030820444201370300204441206a20003a0000204441216a20013a0000204441226a20023a0000204441236a20033a0000204441246a20043a0000204441256a20053a0000204441266a20063a0000204441276a20073a0000204441286a20083a0000204441296a20093a00002044412a6a200a3a00002044412b6a200b3a00002044412c6a200c3a00002044412d6a200d3a00002044412e6a200e3a00002044412f6a200f3a0000204441306a20103a0000204441316a20113a0000204441326a20123a0000204441336a20133a0000204441346a20143a0000204441356a20153a0000204441366a20163a0000204441376a20173a0000204441386a20183a0000204441396a20193a00002044413a6a201a3a00002044413b6a201b3a00002044413c6a201c3a00002044413d6a201d3a00002044413e6a201e3a00002044413f6a201f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214e204541406a22442400204441186a204e3703002044204d3703102044204c3703082044204b370300204441206a20203a0000204441216a20213a0000204441226a20223a0000204441236a20233a0000204441246a20243a0000204441256a20253a0000204441266a20263a0000204441276a20273a0000204441286a20283a0000204441296a20293a00002044412a6a202a3a00002044412b6a202b3a00002044412c6a202c3a00002044412d6a202d3a00002044412e6a202e3a00002044412f6a202f3a0000204441306a20303a0000204441316a20313a0000204441326a20323a0000204441336a20333a0000204441346a20343a0000204441356a20353a0000204441366a20363a0000204441376a20373a0000204441386a20383a0000204441396a20393a00002044413a6a203a3a00002044413b6a203b3a00002044413c6a203c3a00002044413d6a203d3a00002044413e6a203e3a00002044413f6a203f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214e204541206b224422452400204641186a2043370300204441186a204e3703002044204d3703102044204c3703082044204b370300204620423703102046204137030820462040370300204441202046412010011a4120417f100e224441276a201f3a0000204441266a201e3a0000204441256a201d3a0000204441246a201c3a0000204441236a201b3a0000204441226a201a3a0000204441216a20193a0000204441206a20183a00002044411f6a20173a00002044411e6a20163a00002044411d6a20153a00002044411c6a20143a00002044411b6a20133a00002044411a6a20123a0000204441196a20113a0000204441186a20103a0000204441176a200f3a0000204441166a200e3a0000204441156a200d3a0000204441146a200c3a0000204441136a200b3a0000204441126a200a3a0000204441116a20093a0000204441106a20083a00002044410f6a20073a00002044410e6a20063a00002044410d6a20053a00002044410c6a20043a00002044410b6a20033a00002044410a6a20023a0000204441096a20013a0000204441086a224820003a000041e000411820482044280200410020441b10102248280200410020481b41204b044020482802002144204541206b224722452400204841086a22492044410020481b20471005204541206b22442245240020472044100c204641386a204441186a2903003703002046204441106a2903003703302046204441086a29030037032820462044290300370320204641206a2049100d0b4120417f100e2244410a6a20223a0000204441096a20213a0000204441086a224720203a00002044410b6a20233a00002044410c6a20243a00002044410d6a20253a00002044410e6a20263a00002044410f6a20273a0000204441106a20283a0000204441116a20293a0000204441126a202a3a0000204441136a202b3a0000204441146a202c3a0000204441156a202d3a0000204441166a202e3a0000204441176a202f3a0000204441186a20303a0000204441196a20313a00002044411a6a20323a00002044411b6a20333a00002044411c6a20343a00002044411d6a20353a00002044411e6a20363a00002044411f6a20373a0000204441206a20383a0000204441216a20393a0000204441226a203a3a0000204441236a203b3a0000204441246a203c3a0000204441256a203d3a0000204441266a203e3a0000204441276a203f3a0000418001411a20472044280200410020441b10102247280200410020471b41214f044020472802002144204541206b224922452400204741086a224a2044410020471b20491005204541206b22442245240020492044100c204641d8006a204441186a2903003703002046204441106a2903003703502046204441086a29030037034820462044290300370340204641406b204a100d0b41e100417f100e224441096a20003a0000204441086a224941013a00002044410a6a20013a00002044410b6a20023a00002044410c6a20033a00002044410d6a20043a00002044410e6a20053a00002044410f6a20063a0000204441106a20073a0000204441116a20083a0000204441126a20093a0000204441136a200a3a0000204441146a200b3a0000204441156a200c3a0000204441166a200d3a0000204441176a200e3a0000204441186a200f3a0000204441196a20103a00002044411a6a20113a00002044411b6a20123a00002044411c6a20133a00002044411d6a20143a00002044411e6a20153a00002044411f6a20163a0000204441206a20173a0000204441216a20183a0000204441226a20193a0000204441236a201a3a0000204441246a201b3a0000204441256a201c3a0000204441266a201d3a0000204441276a201e3a0000204441286a201f3a0000204441c8006a203f3a0000204441c7006a203e3a0000204441c6006a203d3a0000204441c5006a203c3a0000204441c4006a203b3a0000204441c3006a203a3a0000204441c2006a20393a0000204441c1006a20383a0000204441406b20373a00002044413f6a20363a00002044413e6a20353a00002044413d6a20343a00002044413c6a20333a00002044413b6a20323a00002044413a6a20313a0000204441396a20303a0000204441386a202f3a0000204441376a202e3a0000204441366a202d3a0000204441356a202c3a0000204441346a202b3a0000204441336a202a3a0000204441326a20293a0000204441316a20283a0000204441306a20273a00002044412f6a20263a00002044412e6a20253a00002044412d6a20243a00002044412c6a20233a00002044412b6a20223a00002044412a6a20213a0000204441296a20203a0000204441e1006a2043370300204441d9006a2042370300204441d1006a2041370300204441c9006a2040370300204541f0006b220024002000410c3a0000204541ef006b2201100b200141a0014120100a204541cf006b204841086a2048280200410020481b100a2045412f6b204741086a2047280200410020471b100a200041e10020492044280200410020441b1006204641e0006a240041000f0b000b000bf72002077f087e23004180016b2244214620442400024002402000200172200272200372200472200572200672200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f7241ff017104402020202172202272202372202472202572202672202772202872202972202a72202b72202c72202d72202e72202f72203072203172203272203372203472203572203672203772203872203972203a72203b72203c72203d72203e72203f7241ff0171450d01027e204441406a22442400204441186a4200370300204442003703102044420037030820444200370300204441206a20003a0000204441216a20013a0000204441226a20023a0000204441236a20033a0000204441246a20043a0000204441256a20053a0000204441266a20063a0000204441276a20073a0000204441286a20083a0000204441296a20093a00002044412a6a200a3a00002044412b6a200b3a00002044412c6a200c3a00002044412d6a200d3a00002044412e6a200e3a00002044412f6a200f3a0000204441306a20103a0000204441316a20113a0000204441326a20123a0000204441336a20133a0000204441346a20143a0000204441356a20153a0000204441366a20163a0000204441376a20173a0000204441386a20183a0000204441396a20193a00002044413a6a201a3a00002044413b6a201b3a00002044413c6a201c3a00002044413d6a201d3a00002044413e6a201e3a00002044413f6a201f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214e204541206b22442400204441186a204e3703002044204d3703102044204c3703082044204b37030041c80141203602002044412041d00141c801100304404200214c4200214d42000c010b41e001290300214d41d801290300214c41d001290300214f41e8012903000b214b027e02402040204f5622482041204c562041204c511b22472042204d5622492043204b562043204b511b2042204d852043204b8584501b450440204441406a22442400204441186a4200370300204442003703102044420037030820444200370300204441206a20003a0000204441216a20013a0000204441226a20023a0000204441236a20033a0000204441246a20043a0000204441256a20053a0000204441266a20063a0000204441276a20073a0000204441286a20083a0000204441296a20093a00002044412a6a200a3a00002044412b6a200b3a00002044412c6a200c3a00002044412d6a200d3a00002044412e6a200e3a00002044412f6a200f3a0000204441306a20103a0000204441316a20113a0000204441326a20123a0000204441336a20133a0000204441346a20143a0000204441356a20153a0000204441366a20163a0000204441376a20173a0000204441386a20183a0000204441396a20193a00002044413a6a201a3a00002044413b6a201b3a00002044413c6a201c3a00002044413d6a201d3a00002044413e6a201e3a00002044413f6a201f3a0000204441206b22452400204441c000204510022045290300214e204541086a2903002150204541106a2903002151204541186a2903002152204541206b22442400204641186a204b20437d2049ad7d204d20427d224b2047ad224d54ad7d370300204441186a205237030020442051370310204420503703082044204e3703002046204b204d7d3703102046204c20417d2048ad7d3703082046204f20407d370300204441202046412010011a204441406a22442400204441186a4200370300204442003703102044420037030820444200370300204441206a20203a0000204441216a20213a0000204441226a20223a0000204441236a20233a0000204441246a20243a0000204441256a20253a0000204441266a20263a0000204441276a20273a0000204441286a20283a0000204441296a20293a00002044412a6a202a3a00002044412b6a202b3a00002044412c6a202c3a00002044412d6a202d3a00002044412e6a202e3a00002044412f6a202f3a0000204441306a20303a0000204441316a20313a0000204441326a20323a0000204441336a20333a0000204441346a20343a0000204441356a20353a0000204441366a20363a0000204441376a20373a0000204441386a20383a0000204441396a20393a00002044413a6a203a3a00002044413b6a203b3a00002044413c6a203c3a00002044413d6a203d3a00002044413e6a203e3a00002044413f6a203f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214f204541206b22442400204441186a204f3703002044204d3703102044204c3703082044204b37030041c80141203602002044412041d00141c8011003450d014200214c4200214d4200214f42000c020b000b41e801290300214f41e001290300214d41d001290300214c41d8012903000b214b204441406a22442400204441186a4200370300204442003703102044420037030820444200370300204441206a20203a0000204441216a20213a0000204441226a20223a0000204441236a20233a0000204441246a20243a0000204441256a20253a0000204441266a20263a0000204441276a20273a0000204441286a20283a0000204441296a20293a00002044412a6a202a3a00002044412b6a202b3a00002044412c6a202c3a00002044412d6a202d3a00002044412e6a202e3a00002044412f6a202f3a0000204441306a20303a0000204441316a20313a0000204441326a20323a0000204441336a20333a0000204441346a20343a0000204441356a20353a0000204441366a20363a0000204441376a20373a0000204441386a20383a0000204441396a20393a00002044413a6a203a3a00002044413b6a203b3a00002044413c6a203c3a00002044413d6a203d3a00002044413e6a203e3a00002044413f6a203f3a0000204441206b22452400204441c000204510022045290300214e204541086a2903002150204541106a2903002151204541186a2903002152204541206b224422452400204441186a205237030020442051370310204420503703082044204e37030020462040204c7c224e3703202046204c204e562248ad2041204b7c7c224c37032820462042204d7c224e2048204b204c56204b204c511bad7c224b370330204641386a204b204e54ad204d204e56ad2043204f7c7c7c37030020444120204641206a412010011a4120417f100e224441276a201f3a0000204441266a201e3a0000204441256a201d3a0000204441246a201c3a0000204441236a201b3a0000204441226a201a3a0000204441216a20193a0000204441206a20183a00002044411f6a20173a00002044411e6a20163a00002044411d6a20153a00002044411c6a20143a00002044411b6a20133a00002044411a6a20123a0000204441196a20113a0000204441186a20103a0000204441176a200f3a0000204441166a200e3a0000204441156a200d3a0000204441146a200c3a0000204441136a200b3a0000204441126a200a3a0000204441116a20093a0000204441106a20083a00002044410f6a20073a00002044410e6a20063a00002044410d6a20053a00002044410c6a20043a00002044410b6a20033a00002044410a6a20023a0000204441096a20013a0000204441086a224820003a00004100411720482044280200410020441b10102248280200410020481b41214f044020482802002144204541206b224722452400204841086a22492044410020481b20471005204541206b22442245240020472044100c204641d8006a204441186a2903003703002046204441106a2903003703502046204441086a29030037034820462044290300370340204641406b2049100d0b4120417f100e2244410a6a20223a0000204441096a20213a0000204441086a224720203a00002044410b6a20233a00002044410c6a20243a00002044410d6a20253a00002044410e6a20263a00002044410f6a20273a0000204441106a20283a0000204441116a20293a0000204441126a202a3a0000204441136a202b3a0000204441146a202c3a0000204441156a202d3a0000204441166a202e3a0000204441176a202f3a0000204441186a20303a0000204441196a20313a00002044411a6a20323a00002044411b6a20333a00002044411c6a20343a00002044411d6a20353a00002044411e6a20363a00002044411f6a20373a0000204441206a20383a0000204441216a20393a0000204441226a203a3a0000204441236a203b3a0000204441246a203c3a0000204441256a203d3a0000204441266a203e3a0000204441276a203f3a00004120411520472044280200410020441b10102247280200410020471b41214f044020472802002144204541206b224922452400204741086a224a2044410020471b20491005204541206b22442245240020492044100c204641f8006a204441186a2903003703002046204441106a2903003703702046204441086a29030037036820462044290300370360204641e0006a204a100d0b41e100417f100e224441096a20003a0000204441086a224941003a00002044410a6a20013a00002044410b6a20023a00002044410c6a20033a00002044410d6a20043a00002044410e6a20053a00002044410f6a20063a0000204441106a20073a0000204441116a20083a0000204441126a20093a0000204441136a200a3a0000204441146a200b3a0000204441156a200c3a0000204441166a200d3a0000204441176a200e3a0000204441186a200f3a0000204441196a20103a00002044411a6a20113a00002044411b6a20123a00002044411c6a20133a00002044411d6a20143a00002044411e6a20153a00002044411f6a20163a0000204441206a20173a0000204441216a20183a0000204441226a20193a0000204441236a201a3a0000204441246a201b3a0000204441256a201c3a0000204441266a201d3a0000204441276a201e3a0000204441286a201f3a0000204441c8006a203f3a0000204441c7006a203e3a0000204441c6006a203d3a0000204441c5006a203c3a0000204441c4006a203b3a0000204441c3006a203a3a0000204441c2006a20393a0000204441c1006a20383a0000204441406b20373a00002044413f6a20363a00002044413e6a20353a00002044413d6a20343a00002044413c6a20333a00002044413b6a20323a00002044413a6a20313a0000204441396a20303a0000204441386a202f3a0000204441376a202e3a0000204441366a202d3a0000204441356a202c3a0000204441346a202b3a0000204441336a202a3a0000204441326a20293a0000204441316a20283a0000204441306a20273a00002044412f6a20263a00002044412e6a20253a00002044412d6a20243a00002044412c6a20233a00002044412b6a20223a00002044412a6a20213a0000204441296a20203a0000204441e1006a2043370300204441d9006a2042370300204441d1006a2041370300204441c9006a2040370300204541f0006b220024002000410c3a0000204541ef006b2201100b200141c0004120100a204541cf006b204841086a2048280200410020481b100a2045412f6b204741086a2047280200410020471b100a200041e10020492044280200410020441b10060c020b000b000b20464180016a240041000b927302637f0c7e230041206b22022400418080044100360200418480044100360200418c80044100360200418880043f00411074419080046b36020041c8014180800236020041d00141c801100841c40141c80128020022003602002002411036020c200241106a2002410c6a100920022903102163200241186a2903002164230041406a22022400024002400240027f0240024002400240027e02400240024002400240024002400240024002400240024002400240024002400240200041034d0d0041c00141d0012802002201360200024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240027f0240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200141bf82bfc8014c0440200141a3af89be7d4c04402001419d85ffe47a460d0c20014189bc9d9d7b460d06200141a98bf0dc7b470d402063206484500d0f000b200141a2f0caeb7d4c0440200141a4af89be7d460d0920014198acb4e87d470d402063206484500d04000b200141a3f0caeb7d460d0620014186fafb1e470d3f2063206484500d01000b200141dcc5b5f7034c0440200141c082bfc801460d0a200141d28eadb902460d09200141f0c08a8c03470d3f2063206484500d0d000b200141b8a0cd8c054c0440200141ddc5b5f703460d0420014195b1ef8c04470d3f2063206484500d02000b200141b9a0cd8c05460d06200141b1f894bf06470d3e2063206484500d0b000b200241106b2200240041c80141808002360200200241386a42003703002002420037033020024200370328200242033703202000200241206a412041d00141c8011003047f41000541c80128020041d001100e0b36020020002802002200280200410020001b41ffffffff034d0d1d000b200241106b2200240041c80141808002360200200241386a42003703002002420037033020024200370328200242043703202000200241206a412041d00141c8011003047f41000541c80128020041d001100e0b36020020002802002200280200410020001b41ffffffff034d0d1d000b200241206b2200240041c8014120360200200241386a4200370300200242003703302002420037032820024202370320027e200241206a412041d00141c801100304404200216342000c010b41e801290300216641d801290300216341d001290300216541e0012903000b2164200020653703002000206337030820002064370310200041186a22012066370300200041106a290300216320012903002165200041086a2903000c4c0b20632064844200520d472000200041046b2201490d0a200141c000490d0b200141c0004d0d24000b20632064844200520d452000200041046b2201490d0b200141c000490d0c200141c0004d0d1c000b20632064844200520d432000200041046b2201490d0c200141e000490d0d200141e0004d0d1c000b20632064844200520d412000200041046b2201490d0d200141c000490d0e200141c0004d0d24000b20632064844200520d3f2000200041046b2201490d0e200141c000490d0f200141c0004d0d24000b0240024002402000200041046b22034f04404104210141d4012d000022004103710e03130102030b000b4102210141d4012f01004102760c120b41d4012802004102760c110b000b20632064844200520d3c2000200041046b2201490d10200141c000490d11200141c0004d0d1a000b20632064844200520d3a2000200041046b2201490d11200141c000490d12200141c0004d0d1a000b200241106b22002400200041123a00000c380b2000200041046b2201490d32200141204f0440200141204d0d1a000b000b2000200041046b2201490d32200141c0004f0440200141c0004d0d13000b000b000b000b000b000b000b000b000b000b000b000b4101210120004102760b2104200120034b0d09200120046a220020034b0d132004417f100e220541086a200141d4016a2004100a200041d4016a2d000022014103710e03191a1b160b000b000b000b000b027f41012000280200410020001b413f4d0d001a41042000280200410020001b41ffff004b0d001a41020b220120012000280200410020001b6a22034b0d0f2003417f100e21052000280200410020001b220341ffffffff034d0d12000b027f41012000280200410020001b413f4d0d001a41042000280200410020001b41ffff004b0d001a41020b220120012000280200410020001b6a22034b0d0f2003417f100e21052000280200410020001b220341ffffffff034d0d12000b41f3012d0000210041f2012d0000210341f1012d0000210441f0012d0000210541ef012d0000210641ee012d0000210741ed012d0000210841ec012d0000210941eb012d0000210a41ea012d0000210b41e9012d0000210c41e8012d0000210d41e7012d0000210e41e6012d0000210f41e5012d0000211041e4012d0000211141e3012d0000211241e2012d0000211341e1012d0000211441e0012d0000211541df012d0000211641de012d0000211741dd012d0000211841dc012d0000211941db012d0000211a41da012d0000211b41d9012d0000211c41d8012d0000211d41d7012d0000211e41d6012d0000211f41d5012d0000212041d4012d0000212141f4012903002165418c022903002163418402290300216441fc012903002166200241106b2201240041c801412036020041d00141c8011004200241e8012903002267370018200241e0012903002269370010200241d801290300226a370008200241d00129030022683700002068a720022d000120022d000220022d000320022d000420022d000520022d000620022d0007206aa720022d000920022d000a20022d000b20022d000c20022d000d20022d000e20022d000f2069a720022d001120022d001220022d001320022d001420022d001520022d001620022d00172067a720022d001920022d001a20022d001b20022d001c20022d001d20022d001e20022d001f20212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a200920082007200620052004200320002065206620642063101322000d06200141013a00000c320b41f3012d0000210041f2012d0000210341f1012d0000210441f0012d0000210541ef012d0000210641ee012d0000210741ed012d0000210841ec012d0000210941eb012d0000210a41ea012d0000210b41e9012d0000210c41e8012d0000210d41e7012d0000210e41e6012d0000210f41e5012d0000211041e4012d0000211141e3012d0000211241e2012d0000211341e1012d0000211441e0012d0000211541df012d0000211641de012d0000211741dd012d0000211841dc012d0000211941db012d0000211a41da012d0000211b41d9012d0000211c41d8012d0000211d41d7012d0000211e41d6012d0000211f41d5012d0000212041d4012d0000212141f4012903002165418c022903002163418402290300216441fc012903002166200241106b2201240041c801412036020041d00141c8011004200241e8012903002267370018200241e0012903002269370010200241d801290300226a370008200241d00129030022683700002068a720022d000120022d000220022d000320022d000420022d000520022d000620022d0007206aa720022d000920022d000a20022d000b20022d000c20022d000d20022d000e20022d000f2069a720022d001120022d001220022d001320022d001420022d001520022d001620022d00172067a720022d001920022d001a20022d001b20022d001c20022d001d20022d001e20022d001f20212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a200920082007200620052004200320002065206620642063101222000d07200141013a00000c310b41f3012d0000210141f2012d0000210341f1012d0000210441f0012d0000210541ef012d0000210641ee012d0000210741ed012d0000210841ec012d0000210941eb012d0000210a41ea012d0000210b41e9012d0000210c41e8012d0000210d41e7012d0000210e41e6012d0000210f41e5012d0000211041e4012d0000211141e3012d0000211241e2012d0000211341e1012d0000211441e0012d0000211541df012d0000211641de012d0000211741dd012d0000211841dc012d0000211941db012d0000211a41da012d0000211b41d9012d0000211c41d8012d0000211d41d7012d0000211e41d6012d0000211f41d5012d0000212041d4012d000021214193022d000021244192022d000021254191022d000021264190022d00002122418f022d00002127418e022d00002129418d022d0000212a418c022d0000212b418b022d0000212c418a022d0000212d4189022d0000212e4188022d0000212f4187022d000021304186022d000021314185022d000021324184022d000021334183022d000021344182022d000021354181022d000021364180022d0000213741ff012d0000213841fe012d0000213941fd012d0000213a41fc012d0000213b41fb012d0000213c41fa012d0000213d41f9012d0000213e41f8012d0000213f41f7012d0000214041f6012d0000214141f5012d0000214241f4012d00002144419402290300216641ac02290300216541a4022903002163419c022903002164200241106b2223240041c801412036020041d00141c8011004200241e8012903002267370018200241e0012903002269370010200241d801290300226a370008200241d0012903002268370000024020212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a200920082007200620052004200320012068a7224320022d0001222820022d0002224520022d0003224620022d0004224720022d0005224820022d0006224920022d0007224a206aa7224b20022d0009224c20022d000a224d20022d000b224e20022d000c224f20022d000d225020022d000e225120022d000f22522069a7225320022d0011225420022d0012225520022d0013225620022d0014225720022d0015225820022d0016225920022d0017225a2067a7225b20022d0019225c20022d001a225d20022d001b225e20022d001c225f20022d001d226020022d001e226120022d001f2262200241206a101122000d0020022903202268200241306a290300226783200241286a2903002269200241386a290300226a8383427f52044020662068582064206958206420695122001b20632067582065206a582065206a511b20632067852065206a8584501b450d2020212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a200920082007200620052004200320012043202820452046204720482049204a204b204c204d204e204f2050205120522053205420552056205720582059205a205b205c205d205e205f206020612062206820667d206920647d20662068562243ad7d206720637d22682043206420695620001bad22697d206a20657d2063206756ad7d2068206954ad7d101222000d010b410021000b20000d0720212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a200920082007200620052004200320012044204220412040203f203e203d203c203b203a2039203820372036203520342033203220312030202f202e202d202c202b202a202920272022202620252024206620642063206510132200047f200005202341013a000041000b0d2f0c200b000b41d4012d0000210641d5012d0000210741d6012d0000210841d7012d0000210941d8012d0000210a41d9012d0000210b41da012d0000210c41db012d0000210d41dc012d0000210e41dd012d0000210f41de012d0000211041df012d0000211141e0012d0000211241e1012d0000211341e2012d0000211441e3012d0000211541e4012d0000211641e5012d0000211741e6012d0000211841e7012d0000211941e8012d0000211a41e9012d0000211b41ea012d0000211c41eb012d0000211d41ec012d0000211e41ed012d0000211f41ee012d0000212041ef012d0000212141f0012d0000212341f1012d0000212441f2012d0000212541f3012d0000212641f401290300216441fc012903002169418402290300216a418c02290300216823004180016b2200210120002400024020262006200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f72202072202172202372202472202572720440027e200041206b22002400200041186a420037030020004200370310200042003703082000420237030041c801412036020042002000412041d00141c80110030d001a41e801290300216541d801290300216641d001290300216741e0012903000b2163027e0240206420677c226c20675422032003ad206620697c7c226b2066542066206b511b22032063206a7c22672003ad7c22662063542066206754ad2063206756ad206520687c7c7c226720655420652067511b2063206685206520678584501b450440200041206b22002400200141186a2067370300200041186a4200370300200042003703102000420037030820004202370300200120663703102001206b3703082001206c370300200041202001412010011a200041406a22002400200041186a4200370300200042003703102000420037030820004200370300200041206a20063a0000200041216a20073a0000200041226a20083a0000200041236a20093a0000200041246a200a3a0000200041256a200b3a0000200041266a200c3a0000200041276a200d3a0000200041286a200e3a0000200041296a200f3a00002000412a6a20103a00002000412b6a20113a00002000412c6a20123a00002000412d6a20133a00002000412e6a20143a00002000412f6a20153a0000200041306a20163a0000200041316a20173a0000200041326a20183a0000200041336a20193a0000200041346a201a3a0000200041356a201b3a0000200041366a201c3a0000200041376a201d3a0000200041386a201e3a0000200041396a201f3a00002000413a6a20203a00002000413b6a20213a00002000413c6a20233a00002000413d6a20243a00002000413e6a20253a00002000413f6a20263a0000200041206b22032400200041c0002003100220032903002165200341086a2903002163200341106a2903002166200341186a2903002167200341206b22002400200041186a206737030020002066370310200020633703082000206537030041c80141203602002000412041d00141c8011003450d0142002165420021664200216742000c020b000b41e801290300216741e001290300216641d001290300216541d8012903000b2163200041406a22002400200041186a4200370300200042003703102000420037030820004200370300200041206a20063a0000200041216a20073a0000200041226a20083a0000200041236a20093a0000200041246a200a3a0000200041256a200b3a0000200041266a200c3a0000200041276a200d3a0000200041286a200e3a0000200041296a200f3a00002000412a6a20103a00002000412b6a20113a00002000412c6a20123a00002000412d6a20133a00002000412e6a20143a00002000412f6a20153a0000200041306a20163a0000200041316a20173a0000200041326a20183a0000200041336a20193a0000200041346a201a3a0000200041356a201b3a0000200041366a201c3a0000200041376a201d3a0000200041386a201e3a0000200041396a201f3a00002000413a6a20203a00002000413b6a20213a00002000413c6a20233a00002000413d6a20243a00002000413e6a20253a00002000413f6a20263a0000200041206b22032400200041c000200310022003290300216b200341086a290300216c200341106a290300216d200341186a290300216e200341206b220022032400200041186a206e3703002000206d3703102000206c3703082000206b3703002001206420657c226b37032020012065206b562204ad206320697c7c226537032820012066206a7c226b2004206320655620632065511bad7c2265370330200141386a2065206b54ad2066206b56ad206720687c7c7c37030020004120200141206a412010011a4120417f100e220041206a4200370000200041186a4200370000200041106a4200370000200041086a220442003700004100411720042000280200410020001b10102204280200410020041b41214f044020042802002100200341206b22052400200441086a22222000410020041b20051005200541206b22002203240020052000100c200141d8006a200041186a2903003703002001200041106a2903003703502001200041086a29030037034820012000290300370340200141406b2022100d0b4120417f100e2200410a6a20083a0000200041096a20073a0000200041086a220520063a00002000410b6a20093a00002000410c6a200a3a00002000410d6a200b3a00002000410e6a200c3a00002000410f6a200d3a0000200041106a200e3a0000200041116a200f3a0000200041126a20103a0000200041136a20113a0000200041146a20123a0000200041156a20133a0000200041166a20143a0000200041176a20153a0000200041186a20163a0000200041196a20173a00002000411a6a20183a00002000411b6a20193a00002000411c6a201a3a00002000411d6a201b3a00002000411e6a201c3a00002000411f6a201d3a0000200041206a201e3a0000200041216a201f3a0000200041226a20203a0000200041236a20213a0000200041246a20233a0000200041256a20243a0000200041266a20253a0000200041276a20263a00004120411520052000280200410020001b10102205280200410020051b41214f044020052802002100200341206b22222400200541086a22272000410020051b20221005202241206b22002203240020222000100c200141f8006a200041186a2903003703002001200041106a2903003703702001200041086a29030037036820012000290300370360200141e0006a2027100d0b41e100417f100e220041086a22224200370000200041106a4200370000200041186a4200370000200041206a4200370000200041286a41003a0000200041296a20063a00002000412a6a20073a00002000412b6a20083a00002000412c6a20093a00002000412d6a200a3a00002000412e6a200b3a00002000412f6a200c3a0000200041306a200d3a0000200041316a200e3a0000200041326a200f3a0000200041336a20103a0000200041346a20113a0000200041356a20123a0000200041366a20133a0000200041376a20143a0000200041386a20153a0000200041396a20163a00002000413a6a20173a00002000413b6a20183a00002000413c6a20193a00002000413d6a201a3a00002000413e6a201b3a00002000413f6a201c3a0000200041406b201d3a0000200041c1006a201e3a0000200041c2006a201f3a0000200041c3006a20203a0000200041c4006a20213a0000200041c5006a20233a0000200041c6006a20243a0000200041c7006a20253a0000200041c8006a20263a0000200041e1006a2068370300200041d9006a206a370300200041d1006a2069370300200041c9006a2064370300200341f0006b220624002006410c3a0000200341ef006b2207100b200741c0004120100a200341cf006b200441086a2004280200410020041b100a2003412f6b200541086a2005280200410020051b100a200641e10020222000280200410020001b10060c010b000b20014180016a24000c2b0b41d4012d0000210641d5012d0000210741d6012d0000210841d7012d0000210941d8012d0000210a41d9012d0000210b41da012d0000210c41db012d0000210d41dc012d0000210e41dd012d0000210f41de012d0000211041df012d0000211141e0012d0000211241e1012d0000211341e2012d0000211441e3012d0000211541e4012d0000211641e5012d0000211741e6012d0000211841e7012d0000211941e8012d0000211a41e9012d0000211b41ea012d0000211c41eb012d0000211d41ec012d0000211e41ed012d0000211f41ee012d0000212041ef012d0000212141f0012d0000212341f1012d0000212441f2012d0000212541f3012d0000212641f401290300216a41fc0129030021644184022903002167418c02290300216923004180016b2200210120002400024020262006200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f72202072202172202372202472202572720440027e200041406a22002400200041186a4200370300200042003703102000420037030820004200370300200041206a20063a0000200041216a20073a0000200041226a20083a0000200041236a20093a0000200041246a200a3a0000200041256a200b3a0000200041266a200c3a0000200041276a200d3a0000200041286a200e3a0000200041296a200f3a00002000412a6a20103a00002000412b6a20113a00002000412c6a20123a00002000412d6a20133a00002000412e6a20143a00002000412f6a20153a0000200041306a20163a0000200041316a20173a0000200041326a20183a0000200041336a20193a0000200041346a201a3a0000200041356a201b3a0000200041366a201c3a0000200041376a201d3a0000200041386a201e3a0000200041396a201f3a00002000413a6a20203a00002000413b6a20213a00002000413c6a20233a00002000413d6a20243a00002000413e6a20253a00002000413f6a20263a0000200041206b22032400200041c0002003100220032903002163200341086a2903002168200341106a290300216b200341186a290300216c200341206b22002400200041186a206c3703002000206b370310200020683703082000206337030041c80141203602002000412041d00141c801100304404200216342000c010b41e001290300216341d801290300216541d001290300216641e8012903000b2168027e02402066206a542204206420655620642065511b220520632067542222206820695420682069511b2063206785206820698584501b450440200041406a22002400200041186a4200370300200042003703102000420037030820004200370300200041206a20063a0000200041216a20073a0000200041226a20083a0000200041236a20093a0000200041246a200a3a0000200041256a200b3a0000200041266a200c3a0000200041276a200d3a0000200041286a200e3a0000200041296a200f3a00002000412a6a20103a00002000412b6a20113a00002000412c6a20123a00002000412d6a20133a00002000412e6a20143a00002000412f6a20153a0000200041306a20163a0000200041316a20173a0000200041326a20183a0000200041336a20193a0000200041346a201a3a0000200041356a201b3a0000200041366a201c3a0000200041376a201d3a0000200041386a201e3a0000200041396a201f3a00002000413a6a20203a00002000413b6a20213a00002000413c6a20233a00002000413d6a20243a00002000413e6a20253a00002000413f6a20263a0000200041206b22032400200041c000200310022003290300216b200341086a290300216c200341106a290300216d200341186a290300216e200341206b22002400200141186a206820697d2022ad7d206320677d22632005ad226854ad7d370300200041186a206e3703002000206d3703102000206c3703082000206b3703002001206320687d3703102001206520647d2004ad7d37030820012066206a7d370300200041202001412010011a200041206b22002400200041186a420037030020004200370310200042003703082000420237030041c80141203602002000412041d00141c8011003450d0142002165420021634200216642000c020b000b41e801290300216641e001290300216341d001290300216541d8012903000b2168200041206b220022032400200041186a4200370300200042003703102000420037030820004202370300200141386a206620697d2063206754ad7d206320677d22632065206a542204206420685620642068511bad226654ad7d3703002001206820647d2004ad7d37032820012065206a7d3703202001206320667d37033020004120200141206a412010011a4120417f100e220041136a20113a0000200041126a20103a0000200041116a200f3a0000200041106a200e3a00002000410f6a200d3a00002000410e6a200c3a00002000410d6a200b3a00002000410c6a200a3a00002000410b6a20093a00002000410a6a20083a0000200041096a20073a0000200041086a220420063a0000200041146a20123a0000200041156a20133a0000200041166a20143a0000200041176a20153a0000200041186a20163a0000200041196a20173a00002000411a6a20183a00002000411b6a20193a00002000411c6a201a3a00002000411d6a201b3a00002000411e6a201c3a00002000411f6a201d3a0000200041206a201e3a0000200041216a201f3a0000200041226a20203a0000200041236a20213a0000200041246a20233a0000200041256a20243a0000200041266a20253a0000200041276a20263a00004100411720042000280200410020001b10102204280200410020041b41214f044020042802002100200341206b22052400200441086a22222000410020041b20051005200541206b22002203240020052000100c200141d8006a200041186a2903003703002001200041106a2903003703502001200041086a29030037034820012000290300370340200141406b2022100d0b4120417f100e220041206a4200370000200041186a4200370000200041106a4200370000200041086a220542003700004120411520052000280200410020001b10102205280200410020051b41214f044020052802002100200341206b22222400200541086a22272000410020051b20221005202241206b22002203240020222000100c200141f8006a200041186a2903003703002001200041106a2903003703702001200041086a29030037036820012000290300370360200141e0006a2027100d0b41e100417f100e220041096a20063a0000200041086a222241003a00002000410a6a20073a00002000410b6a20083a00002000410c6a20093a00002000410d6a200a3a00002000410e6a200b3a00002000410f6a200c3a0000200041106a200d3a0000200041116a200e3a0000200041126a200f3a0000200041136a20103a0000200041146a20113a0000200041156a20123a0000200041166a20133a0000200041176a20143a0000200041186a20153a0000200041196a20163a00002000411a6a20173a00002000411b6a20183a00002000411c6a20193a00002000411d6a201a3a00002000411e6a201b3a00002000411f6a201c3a0000200041206a201d3a0000200041216a201e3a0000200041226a201f3a0000200041236a20203a0000200041246a20213a0000200041256a20233a0000200041266a20243a0000200041276a20253a0000200041286a20263a0000200041e1006a2069370300200041d9006a2067370300200041d1006a2064370300200041c9006a206a370300200041c1006a4200370000200041396a4200370000200041316a4200370000200041296a4200370000200341f0006b220624002006410c3a0000200341ef006b2207100b200741c0004120100a200341cf006b200441086a2004280200410020041b100a2003412f6b200541086a2005280200410020051b100a200641e10020222000280200410020001b10060c010b000b20014180016a24000c2a0b41f3012d0000210441f2012d0000210541f1012d0000210641f0012d0000210741ef012d0000210841ee012d0000210941ed012d0000210a41ec012d0000210b41eb012d0000210c41ea012d0000210d41e9012d0000210e41e8012d0000210f41e7012d0000211041e6012d0000211141e5012d0000211241e4012d0000211341e3012d0000211441e2012d0000211541e1012d0000211641e0012d0000211741df012d0000211841de012d0000211941dd012d0000211a41dc012d0000211b41db012d0000211c41da012d0000211d41d9012d0000211e41d8012d0000211f41d7012d0000212041d6012d0000212141d5012d0000212341d4012d00002124200241206b2200240042002163230041406a22032400200341406a22012400200141186a4200370300200142003703102001420037030820014200370300200141206a20243a0000200141216a20233a0000200141226a20213a0000200141236a20203a0000200141246a201f3a0000200141256a201e3a0000200141266a201d3a0000200141276a201c3a0000200141286a201b3a0000200141296a201a3a00002001412a6a20193a00002001412b6a20183a00002001412c6a20173a00002001412d6a20163a00002001412e6a20153a00002001412f6a20143a0000200141306a20133a0000200141316a20123a0000200141326a20113a0000200141336a20103a0000200141346a200f3a0000200141356a200e3a0000200141366a200d3a0000200141376a200c3a0000200141386a200b3a0000200141396a200a3a00002001413a6a20093a00002001413b6a20083a00002001413c6a20073a00002001413d6a20063a00002001413e6a20053a00002001413f6a20043a0000200141c000200341206a100241c8014120360200200341186a200341386a2903003703002003200341306a2903003703102003200341286a290300370308200320032903203703002003412041d00141c8011003047e42000541e001290300216341d801290300216641d001290300216541e8012903000b2164200020653703002000206637030820002063370310200041186a2064370300200341406b24000c270b2000450d2b0c2a0b41f3012d0000210141f2012d0000210341f1012d0000210441f0012d0000210541ef012d0000210641ee012d0000210741ed012d0000210841ec012d0000210941eb012d0000210a41ea012d0000210b41e9012d0000210c41e8012d0000210d41e7012d0000210e41e6012d0000210f41e5012d0000211041e4012d0000211141e3012d0000211241e2012d0000211341e1012d0000211441e0012d0000211541df012d0000211641de012d0000211741dd012d0000211841dc012d0000211941db012d0000211a41da012d0000211b41d9012d0000211c41d8012d0000211d41d7012d0000211e41d6012d0000211f41d5012d0000212041d4012d00004193022d000021234192022d000021244191022d000021254190022d00002126418f022d00002122418e022d00002127418d022d00002129418c022d0000212a418b022d0000212b418a022d0000212c4189022d0000212d4188022d0000212e4187022d0000212f4186022d000021304185022d000021314184022d000021324183022d000021334182022d000021344181022d000021354180022d0000213641ff012d0000213741fe012d0000213841fd012d0000213941fc012d0000213a41fb012d0000213b41fa012d0000213c41f9012d0000213d41f8012d0000213e41f7012d0000213f41f6012d0000214041f5012d0000214141f4012d00002142200241206b220024002020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a20092008200720062005200420032001204220412040203f203e203d203c203b203a2039203820372036203520342033203220312030202f202e202d202c202b202a202920272022202620252024202320001011450d250c280b2000450d290c280b2000450d180c270b41f3012d0000210441f2012d0000210541f1012d0000210641f0012d0000210741ef012d0000210841ee012d0000210941ed012d0000210a41ec012d0000210b41eb012d0000210c41ea012d0000210d41e9012d0000210e41e8012d0000210f41e7012d0000211041e6012d0000211141e5012d0000211241e4012d0000211341e3012d0000211441e2012d0000211541e1012d0000211641e0012d0000211741df012d0000211841de012d0000211941dd012d0000211a41dc012d0000211b41db012d0000211c41da012d0000211d41d9012d0000211e41d8012d0000211f41d7012d0000212041d6012d0000212141d5012d0000212341d4012d0000212441f4012903002165418c022903002166418402290300216341fc012903002164200241106b22002400027f230041206b2201240041c801412036020041d00141c8011004200141d001290300370000200141d801290300370008200141e001290300370010200141e80129030037001820012d001f212520012d001e212620012d001d212220012d001c212720012d001b212920012d001a212a20012d0019212b20012d0018212c20012d0017212d20012d0016212e20012d0015212f20012d0014213020012d0013213120012d0012213220012d0011213320012d0010213420012d000f213520012d000e213620012d000d213720012d000c213820012d000b213920012d000a213a20012d0009213b20012d0008213c20012d0007213d20012d0006213e20012d0005213f20012d0004214020012d0003214120012d0002214220012d0001214420012d00002143200141206b220324000240024020432044204220412040203f203e203d203c203b203a2039203820372036203520342033203220312030202f202e202d202c202b202a202920272022202620252024202320212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a2009200820072006200520042003101122284504402065200329030022657c226920655422282028ad2064200341086a29030022657c7c226720655420652067511b2228200341106a290300226520637c22642028ad7c22632065542063206454ad2064206554ad200341186a290300226420667c7c7c226620645420642066511b2063206585206420668584501b0d0120432044204220412040203f203e203d203c203b203a2039203820372036203520342033203220312030202f202e202d202c202b202a202920272022202620252024202320212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a200920082007200620052004206920672063206610122203450d02200141206a240020030c030b200141206a240020280c020b000b200041013a0000200141206a240041000b450d210c250b41f3012d0000210441f2012d0000210541f1012d0000210641f0012d0000210741ef012d0000210841ee012d0000210941ed012d0000210a41ec012d0000210b41eb012d0000210c41ea012d0000210d41e9012d0000210e41e8012d0000210f41e7012d0000211041e6012d0000211141e5012d0000211241e4012d0000211341e3012d0000211441e2012d0000211541e1012d0000211641e0012d0000211741df012d0000211841de012d0000211941dd012d0000211a41dc012d0000211b41db012d0000211c41da012d0000211d41d9012d0000211e41d8012d0000211f41d7012d0000212041d6012d0000212141d5012d0000212341d4012d0000212441f4012903002166418c022903002165418402290300216341fc012903002164200241106b22002400027f230041206b2201240041c801412036020041d00141c8011004200141d001290300370000200141d801290300370008200141e001290300370010200141e80129030037001820012d001f212520012d001e212620012d001d212220012d001c212720012d001b212920012d001a212a20012d0019212b20012d0018212c20012d0017212d20012d0016212e20012d0015212f20012d0014213020012d0013213120012d0012213220012d0011213320012d0010213420012d000f213520012d000e213620012d000d213720012d000c213820012d000b213920012d000a213a20012d0009213b20012d0008213c20012d0007213d20012d0006213e20012d0005213f20012d0004214020012d0003214120012d0002214220012d0001214420012d00002143200141206b220324000240024020432044204220412040203f203e203d203c203b203a2039203820372036203520342033203220312030202f202e202d202c202b202a202920272022202620252024202320212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a2009200820072006200520042003101122284504402003290300226820665a200341086a290300226720645a206420675122281b200341106a290300226920635a200341186a290300226a20655a2065206a511b20632069852065206a8584501b450d0120432044204220412040203f203e203d203c203b203a2039203820372036203520342033203220312030202f202e202d202c202b202a202920272022202620252024202320212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a200920082007200620052004206820667d206720647d20662068562203ad7d206920637d22662003206420675620281bad22647d206a20657d2063206956ad7d2064206656ad7d10122203450d02200141206a240020030c030b200141206a240020280c020b000b200041013a0000200141206a240041000b450d200c240b000b000b000b000b2003413f4b0d04200341ffffffff03712003470d05200541086a2003410274360200410121040c1a0b2003413f4b0d05200341ffffffff03712003470d06200541086a2003410274360200410121040c190b20014102762101410121040c0e0b41022104200041d4016a2f010041027621010c0d0b200041d4016a2802004102762101410421040c0c0b200341ffff004b0d03200341ffffffff03712003470d0441022104200541086a20034102744101723602000c150b000b200341ffff004b0d03200341ffffffff03712003470d0441022104200541086a20034102744101723602000c130b000b2003200341ffffffff0371460440200541086a2003410274410272360200410421040c120b000b000b2003200341ffffffff0371460440200541086a2003410274410272360200410421040c100b000b000b000b000b000b000b024002402003200020046a22064f04402000200120046a22076a20034b0d012001417f100e220441086a200641d4016a2001100a200020076a20034f0d02000b000b000b230041206b22002400200041186a420037030020004200370310200042003703082000420337030002402005280200410020051b22014504402000412010001a0c010b20004120200541086a200110011a0b200041206b22012400200141186a420037030020014200370310200142003703082001420437030002402004280200410020041b22034504402001412010001a0c010b20014120200441086a200310011a0b200041206a24000c0d0b20232d00000c100b20002d000021004101417f100e41086a220120003a00000c100b000b000b000b000b000b000b000b2004200541086a22056a200041086a2003100a200120012000280200410020001b6a22004d044041002005200010070c0a0b000b20002d00000c060b200041106a2903002163200041186a2903002165200041086a2903000b2164200029030021664120417f100e220041206a2065370300200041186a2063370300200041106a2064370300200041086a2200206637030041002000412010070c060b41004100417f100e41086a410010070c050b200241406b24000c050b200241406b24000c040b20012d00000b21004101417f100e41086a220120004101713a00000b41002001410110070b200241406b24000b000b0ba401040041000b17584945524332303a3a5472616e736665723a3a66726f6d0041200b15504945524332303a3a5472616e736665723a3a746f0041c1000b104945524332303a3a5472616e736665720041e0000b515c4945524332303a3a417070726f76616c3a3a6f776e65720000000000000000644945524332303a3a417070726f76616c3a3a7370656e646572000000000000004945524332303a3a417070726f76616c008e010970726f64756365727302086c616e6775616765010143000c70726f6365737365642d62790105636c616e676131352e302e34202868747470733a2f2f6769746875622e636f6d2f736f6c616e612d6c6162732f6c6c766d2d70726f6a6563742e676974203333633336323963616135396235396438663538353733366134613531393461613965393337376429', - }, - spec: { - constructors: [ - { - args: [ - { - label: '_name', - type: { - displayName: ['string'], - type: 4, - }, - }, - { - label: '_symbol', - type: { - displayName: ['string'], - type: 4, - }, - }, - ], - docs: [''], - label: 'new', - payable: false, - returnType: null, - selector: '0x52472b27', - }, - ], - docs: [''], - events: [ - { - args: [ - { - docs: [], - indexed: true, - label: 'from', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - docs: [], - indexed: true, - label: 'to', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - docs: [], - indexed: false, - label: 'value', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: [''], - label: 'Transfer', - }, - { - args: [ - { - docs: [], - indexed: true, - label: 'owner', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - docs: [], - indexed: true, - label: 'spender', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - docs: [], - indexed: false, - label: 'value', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: [''], - label: 'Approval', - }, - ], - lang_error: { - displayName: [], - type: 0, - }, - messages: [ - { - args: [], - docs: [''], - label: 'name', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 4, - }, - selector: '0x06fdde03', - }, - { - args: [], - docs: [''], - label: 'symbol', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 4, - }, - selector: '0x95d89b41', - }, - { - args: [], - docs: [''], - label: 'decimals', - mutates: false, - payable: false, - returnType: { - displayName: ['u8'], - type: 0, - }, - selector: '0x313ce567', - }, - { - args: [], - docs: [''], - label: 'totalSupply', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 3, - }, - selector: '0x18160ddd', - }, - { - args: [ - { - label: 'account', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - ], - docs: [''], - label: 'balanceOf', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 3, - }, - selector: '0x70a08231', - }, - { - args: [ - { - label: 'to', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: 'amount', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: [''], - label: 'transfer', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 5, - }, - selector: '0xa9059cbb', - }, - { - args: [ - { - label: 'owner', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: 'spender', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - ], - docs: [''], - label: 'allowance', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 3, - }, - selector: '0xdd62ed3e', - }, - { - args: [ - { - label: 'spender', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: 'amount', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: [''], - label: 'approve', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 5, - }, - selector: '0x095ea7b3', - }, - { - args: [ - { - label: 'from', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: 'to', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: 'amount', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: [''], - label: 'transferFrom', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 5, - }, - selector: '0x23b872dd', - }, - { - args: [ - { - label: 'spender', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: 'addedValue', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: [''], - label: 'increaseAllowance', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 5, - }, - selector: '0x39509351', - }, - { - args: [ - { - label: 'spender', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: 'subtractedValue', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: [''], - label: 'decreaseAllowance', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 5, - }, - selector: '0xa457c2d7', - }, - { - args: [ - { - label: '_to', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: '_amount', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: [''], - label: 'mint', - mutates: true, - payable: false, - returnType: null, - selector: '0x40c10f19', - }, - { - args: [ - { - label: 'from', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, - { - label: '_amount', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: [''], - label: 'burn', - mutates: true, - payable: false, - returnType: null, - selector: '0x9dc29fac', - }, - ], - }, - storage: { - struct: { - fields: [ - { - layout: { - root: { - layout: { - leaf: { - key: '0x00000000', - ty: 3, - }, - }, - root_key: '0x00000000', - }, - }, - name: '_balances', - }, - { - layout: { - root: { - layout: { - leaf: { - key: '0x00000001', - ty: 3, - }, - }, - root_key: '0x00000001', - }, - }, - name: '_allowances', - }, - { - layout: { - root: { - layout: { - leaf: { - key: '0x00000002', - ty: 3, - }, - }, - root_key: '0x00000002', - }, - }, - name: '_totalSupply', - }, - { - layout: { - root: { - layout: { - leaf: { - key: '0x00000003', - ty: 4, - }, - }, - root_key: '0x00000003', - }, - }, - name: '_name', - }, - { - layout: { - root: { - layout: { - leaf: { - key: '0x00000004', - ty: 4, - }, - }, - root_key: '0x00000004', - }, - }, - name: '_symbol', - }, - ], - name: 'MockERC20', - }, - }, - types: [ - { - id: 0, - type: { - def: { - primitive: 'u8', - }, - path: ['u8'], - }, - }, - { - id: 1, - type: { - def: { - array: { - len: 32, - type: 0, - }, - }, - }, - }, - { - id: 2, - type: { - def: { - composite: { - fields: [ - { - type: 1, - }, - ], - }, - }, - path: ['ink_env', 'types', 'AccountId'], - }, - }, - { - id: 3, - type: { - def: { - primitive: 'u256', - }, - path: ['u256'], - }, - }, - { - id: 4, - type: { - def: { - primitive: 'str', - }, - path: ['string'], - }, - }, - { - id: 5, - type: { - def: { - primitive: 'bool', - }, - path: ['bool'], - }, - }, - ], - version: '4', -} as const; diff --git a/src/contracts/nabla/NablaCurve.ts b/src/contracts/nabla/NablaCurve.ts new file mode 100644 index 00000000..63edf9af --- /dev/null +++ b/src/contracts/nabla/NablaCurve.ts @@ -0,0 +1,438 @@ +export const nablaCurveAbi = { + contract: { + authors: ['unknown'], + description: + 'implementation of the Nabla slippage curve\nIt represents the function Psi(b,l) = beta * (b-l) ** 2 / (b + c * l) + b', + name: 'NablaCurve', + version: '0.0.1', + }, + source: { + compiler: 'solang 0.3.2', + hash: '0x228ecf05004b7a73783f6479db3e8125ddaaae3a25c72d70e89604d65728a0b6', + language: 'Solidity 0.3.2', + }, + spec: { + constructors: [ + { + args: [ + { + label: '_alpha', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + { + label: '_beta', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + ], + default: false, + docs: [''], + label: 'new', + payable: false, + returnType: null, + selector: '0x19b51a53', + }, + ], + docs: [ + 'implementation of the Nabla slippage curve\nIt represents the function Psi(b,l) = beta * (b-l) ** 2 / (b + c * l) + b', + ], + environment: { + accountId: { + displayName: ['AccountId'], + type: 6, + }, + balance: { + displayName: ['Balance'], + type: 7, + }, + blockNumber: { + displayName: ['BlockNumber'], + type: 8, + }, + chainExtension: { + displayName: [], + type: 0, + }, + hash: { + displayName: ['Hash'], + type: 9, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 8, + }, + }, + events: [], + lang_error: { + displayName: ['SolidityError'], + type: 13, + }, + messages: [ + { + args: [], + default: false, + docs: [''], + label: 'params', + mutates: false, + payable: false, + returnType: { + displayName: ['NablaCurve', 'params', 'return_type'], + type: 3, + }, + selector: '0xcff0ab96', + }, + { + args: [ + { + label: '_b', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + { + label: '_l', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + { + label: '_decimals', + type: { + displayName: ['uint8'], + type: 4, + }, + }, + ], + default: false, + docs: ['Calculates the output of the function Psi for input values b and l'], + label: 'psi', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 2, + }, + selector: '0x44ff824c', + }, + { + args: [ + { + label: '_b', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + { + label: '_l', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + { + label: '_capitalB', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + { + label: '_decimals', + type: { + displayName: ['uint8'], + type: 4, + }, + }, + ], + default: false, + docs: ['Given b,l and B >= Psi(b, l), this function determines the unique t>=0\nsuch that Psi(b+t, l+t) = B'], + label: 'inverseDiagonal', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 2, + }, + selector: '0x79e3ddf2', + }, + { + args: [ + { + label: '_b', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + { + label: '_l', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + { + label: '_capitalB', + type: { + displayName: ['uint256'], + type: 2, + }, + }, + { + label: '_decimals', + type: { + displayName: ['uint8'], + type: 4, + }, + }, + ], + default: false, + docs: ['Given b,l and B >= Psi(b, l), this function determines the unique t>=0\nsuch that Psi(b+t, l) = B'], + label: 'inverseHorizontal', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 2, + }, + selector: '0xe67b3643', + }, + ], + }, + storage: { + struct: { + fields: [ + { + layout: { + root: { + layout: { + struct: { + fields: [ + { + layout: { + leaf: { + key: '0x00000000', + ty: 0, + }, + }, + name: 'beta', + }, + { + layout: { + leaf: { + key: '0x00000000', + ty: 0, + }, + }, + name: 'c', + }, + ], + name: 'Params', + }, + }, + root_key: '0x00000000', + }, + }, + name: 'params', + }, + ], + name: 'NablaCurve', + }, + }, + types: [ + { + id: 0, + type: { + def: { + primitive: 'i256', + }, + path: ['int256'], + }, + }, + { + id: 1, + type: { + def: { + composite: { + fields: [ + { + name: 'beta', + type: 0, + }, + { + name: 'c', + type: 0, + }, + ], + }, + }, + path: ['Params'], + }, + }, + { + id: 2, + type: { + def: { + primitive: 'u256', + }, + path: ['uint256'], + }, + }, + { + id: 3, + type: { + def: { + tuple: [0, 0], + }, + path: ['NablaCurve', 'params', 'return_type'], + }, + }, + { + id: 4, + type: { + def: { + primitive: 'u8', + }, + path: ['uint8'], + }, + }, + { + id: 5, + type: { + def: { + array: { + len: 32, + type: 4, + }, + }, + }, + }, + { + id: 6, + type: { + def: { + composite: { + fields: [ + { + type: 5, + }, + ], + }, + }, + path: ['ink_primitives', 'types', 'AccountId'], + }, + }, + { + id: 7, + type: { + def: { + primitive: 'u128', + }, + path: ['uint128'], + }, + }, + { + id: 8, + type: { + def: { + primitive: 'u64', + }, + path: ['uint64'], + }, + }, + { + id: 9, + type: { + def: { + composite: { + fields: [ + { + type: 5, + }, + ], + }, + }, + path: ['ink_primitives', 'types', 'Hash'], + }, + }, + { + id: 10, + type: { + def: { + primitive: 'str', + }, + path: ['string'], + }, + }, + { + id: 11, + type: { + def: { + composite: { + fields: [ + { + type: 10, + }, + ], + }, + }, + path: ['0x08c379a0'], + }, + }, + { + id: 12, + type: { + def: { + composite: { + fields: [ + { + type: 2, + }, + ], + }, + }, + path: ['0x4e487b71'], + }, + }, + { + id: 13, + type: { + def: { + variant: { + variants: [ + { + fields: [ + { + type: 11, + }, + ], + index: 0, + name: 'Error', + }, + { + fields: [ + { + type: 12, + }, + ], + index: 1, + name: 'Panic', + }, + ], + }, + }, + path: ['SolidityError'], + }, + }, + ], + version: '4', +} as const; diff --git a/src/contracts/nabla/PriceOracle.ts b/src/contracts/nabla/PriceOracle.ts index cf836963..e7d45f8a 100644 --- a/src/contracts/nabla/PriceOracle.ts +++ b/src/contracts/nabla/PriceOracle.ts @@ -7,10 +7,9 @@ export const priceOracleAbi = { version: '0.0.1', }, source: { - compiler: 'solang 0.3.3', - hash: '0xc24be0a73954d653018f8ec7e1a9290120f8f181bfb59ed48dc3944250b7e0f6', - language: 'Solidity 0.3.3', - wasm: '0x0061736d01000000018d010c60037f7f7f0060047f7f7f7f017f60027f7f017f60057f7f7f7f7f017f60027f7f0060037f7f7f017f60017f017f60000060027f7e017f60237f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60217f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60057f7f7e7e7f017f02d5010a03656e76066d656d6f727902011010057365616c300f686173685f6b656363616b5f3235360000057365616c310b6765745f73746f726167650001057365616c300d64656275675f6d6573736167650002057365616c320b7365745f73746f726167650001057365616c310d636c6561725f73746f726167650002057365616c300b7365616c5f72657475726e0000057365616c301463616c6c5f636861696e5f657874656e73696f6e0003057365616c3005696e7075740004057365616c301176616c75655f7472616e73666572726564000403131200040506070809060a0a0a0a05020b0b07070608017f01418080040b071102066465706c6f7900190463616c6c001a0ae88e0412bc0101027f02402002450d002002417f6a2103024020024107712204450d000340200020012d00003a0000200041016a2100200141016a21012002417f6a21022004417f6a22040d000b0b20034107490d000340200020012d00003a0000200020012d00013a0001200020012d00023a0002200020012d00033a0003200020012d00043a0004200020012d00053a0005200020012d00063a0006200020012d00073a0007200041086a2100200141086a2101200241786a22020d000b0b0ba90101027f02402001450d002001417f6a2102024020014107712203450d00034020004200370300200041086a21002001417f6a21012003417f6a22030d000b0b20024107490d00034020004200370300200041386a4200370300200041306a4200370300200041286a4200370300200041206a4200370300200041186a4200370300200041106a4200370300200041086a4200370300200041c0006a2100200141786a22010d000b0b0bca0201037f200120006c220141086a108c808080002203200036020420032000360200200341086a2100024002402002417f460d002001450d012001417f6a2104024020014107712205450d000340200020022d00003a0000200041016a2100200241016a21022001417f6a21012005417f6a22050d000b0b20044107490d010340200020022d00003a0000200020022d00013a0001200020022d00023a0002200020022d00033a0003200020022d00043a0004200020022d00053a0005200020022d00063a0006200020022d00073a0007200041086a2100200241086a2102200141786a22010d000c020b0b2001450d002001417f6a2105024020014107712202450d000340200041003a0000200041016a21002001417f6a21012002417f6a22020d000b0b20054107490d00034020004200370000200041086a2100200141786a22010d000b0b20030b990101047f418080042101037f0240200128020c0d00200128020822022000490d0002402002200041076a41787122036b22024118490d00200120036a41106a22002001280200220436020002402004450d00200420003602040b2000200241706a3602082000410036020c2000200136020420012000360200200120033602080b2001410136020c200141106a0f0b200128020021010c000b0b2e004100410036028080044100410036028480044100410036028c800441003f0041107441f0ff7b6a36028880040b990203047f017e027f23808080800041206b2102410021034101210403402002200322056a20012001420a802206420a7e7d3c00002004220741016a2104200541016a2103200142095621082006210120080d000b02402003410371450d00200741037121072002417f6a2108410021040340200020046a200820036a2d000041306a3a00002008417f6a21082007200441016a2204470d000b200020046a2100200320046b21030b024020054103490d002002417c6a21050340200041036a200520036a22042d000041306a3a00002000200441036a2d000041306a3a0000200041016a200441026a2d000041306a3a0000200041026a200441016a2d000041306a3a0000200041046a21002003417c6a22030d000b0b20000ba70f04037f047e037f037e23808080800041c0016b2223248080808000202341406a22242225248080808000202441186a4200370300202442003703102024420037030820244200370300202441206a20003a0000202441216a20013a0000202441226a20023a0000202441236a20033a0000202441246a20043a0000202441256a20053a0000202441266a20063a0000202441276a20073a0000202441286a20083a0000202441296a20093a00002024412a6a200a3a00002024412b6a200b3a00002024412c6a200c3a00002024412d6a200d3a00002024412e6a200e3a00002024412f6a200f3a0000202441306a20103a0000202441316a20113a0000202441326a20123a0000202441336a20133a0000202441346a20143a0000202441356a20153a0000202441366a20163a0000202441376a20173a0000202441386a20183a0000202441396a20193a00002024413a6a201a3a00002024413b6a201b3a00002024413c6a201c3a00002024413d6a201d3a00002024413e6a201e3a00002024413f6a201f3a0000202441c0002023222341a0016a10808080800041002101410041203602b89280800020234180016a41186a202341a0016a41186a29030022263703002023202341b0016a2903002227370390012023202341a8016a290300222837038801202320232903a00122293703800120234180016a412041c09280800041b8928080001081808080002124202341d7006a4180808080004117108980808000202341d7006a41176a2024ad108e8080800022004197808080004102108980808000202341d7006a2000202341d7006a6b41026a1082808080001a41002d00c092808000210341002d00c192808000210441002d00c292808000210541002d00c392808000210641002d00c492808000210741002d00c592808000210841002d00c692808000210941002d00c792808000210a41002d00c892808000210b41002d00c992808000210c41002d00ca92808000210d41002d00cb92808000210e41002d00cc92808000210f41002d00cd92808000211041002d00ce92808000211141002d00cf92808000211241002d00d092808000211341002d00d192808000211441002d00d292808000211541002d00d392808000211641002d00d492808000211741002d00d592808000211841002d00d692808000211941002d00d792808000211a41002d00d892808000211b41002d00d992808000211c41002d00da92808000211d41002d00db92808000211e41002d00dc92808000211f41002d00dd92808000212a41002d00de92808000212b41002d00df92808000212c4100418080023602b892808000202341306a41186a20262027202942017c222d202954220020282000ad7c222e202854202d20295a1bad7c222f202754ad7c3703002023202f3703402023202e3703382023202d370330202341306a412041c09280800041b8928080001081808080002100202341056a41a0808080004119108980808000202341056a41196a2000ad108e8080800022024197808080004102108980808000202341056a2002202341056a6b41026a1082808080001a41002102024020000d0041002802b892808000410141c092808000108b8080800021020b4100202c20241b212c4100202b20241b212b4100202a20241b212a4100201f20241b211f4100201e20241b211e4100201d20241b211d4100201c20241b211c4100201b20241b211b4100201a20241b211a4100201920241b21194100201820241b21184100201720241b21174100201620241b21164100201520241b21154100201420241b21144100201320241b21134100201220241b21124100201120241b21114100201020241b21104100200f20241b210f4100200e20241b210e4100200d20241b210d4100200c20241b210c4100200b20241b210b4100200a20241b210a4100200920241b21094100200820241b21084100200720241b21074100200620241b21064100200520241b21054100200420241b21044100200320241b2103202541606a2224222524808080800020242028202942027c222d2029542200ad7c222e3703082024202d3703004100418080023602b892808000202420272000202e202854202d20295a1bad7c2229370310202441186a20262029202754ad7c3703002024412041c09280800041b89280800010818080800021002025222541506a2224248080808000202441a0808080004119108980808000202541696a2000ad108e80808000222541978080800041021089808080002024202520246b41026a1082808080001a024020000d0041002802b892808000410141c092808000108b8080800021010b202020033a0000202020043a0001202020053a0002202020063a0003202020073a0004202020083a0005202020093a00062020200a3a00072020200b3a00082020200c3a00092020200d3a000a2020200e3a000b2020200f3a000c202020103a000d202020113a000e202020123a000f202020133a0010202020143a0011202020153a0012202020163a0013202020173a0014202020183a0015202020193a00162020201a3a00172020201b3a00182020201c3a00192020201d3a001a2020201e3a001b2020201f3a001c2020202a3a001d2020202b3a001e2020202c3a001f2021200236020020222001360200202341c0016a24808080800041000bb80c08027f047e037f037e017f027e037f017e2380808080002201210242002103420021044200210542002106024002400240034020032000280200410020001bad5a410120045022071b410120052006845022081b0d0120032000280200410020001bad5a410120071b410120081b0d0220032000280200410020001bad54410020071b410020081b450d0320002003a741286c6a220941206a290000210a200941186a290000210b200941106a290000210c200941086a220d290000210e200141406a22072208248080808000200741186a4200370300200742003703102007420037030820074200370300200741206a200e370000200741286a200c370000200741306a200b370000200741386a200a370000200841606a22082201248080808000200741c00020081080808080002008290300210b200841086a290300210c200841106a290300210e200841186a290300210f200141606a22072208248080808000200741186a2201200f3703002007200e3703102007200c3703082007200b37030020074120200d412010838080800021102008221141506a22082212248080808000200841b0828080004117108980808000201141676a2010ad108e80808000221041978080800041021089808080002008201020086b41026a1082808080001a2001200f200e200b42017c220a200b542208200c2008ad7c2213200c54200a200b5a1bad7c220b200e54ad7c220e3703002007200b370310200720133703082007200a37030002400240200941286a2802002208280200410020081b22090d002007412010848080800021102012221141506a22082209248080808000200841d0828080004119108980808000201141696a2010ad108e80808000221041978080800041021089808080002008201020086b41026a1082808080001a0c010b20074120200841086a200910838080800021102012221141506a22082209248080808000200841b0828080004117108980808000201141676a2010ad108e80808000221041978080800041021089808080002008201020086b41026a1082808080001a0b2007200a42017c220c37030020072013200c200a542208ad7c220f3703082007200b2008200f201354200c200a5a1bad7c220a3703102001200e200a200b54ad7c37030002400240200d41246a2802002208280200410020081b220d0d002007412010848080800021082009220941506a22072201248080808000200741d0828080004119108980808000200941696a2008ad108e80808000220841978080800041021089808080002007200820076b41026a1082808080001a0c010b20074120200841086a200d10838080800021082009220941506a22072201248080808000200741b0828080004117108980808000200941676a2008ad108e80808000220841978080800041021089808080002007200820076b41026a1082808080001a0b02402005200342017c220a200354220720042007ad7c220c200454200a20035a1b2207ad7c220b200554220820062008ad7c220e200654200b20055a1b200720071b0d00200a2103200c2104200b2105200e21060c010b0b41f08280800041c10010828080800021002001220841506a220724808080800020074190818080004119108980808000200841696a2000ad108e80808000220041978080800041021089808080002007200020076b41026a1082808080001a410141c0838080004124108580808000000b200224808080800041000f0b41cd004101417f108b80808000220741086a220041c08080800041cd00108980808000200741cd00360200200041cd00410020071b10828080800021002001220841506a220724808080800020074190818080004119108980808000200841696a2000ad108e80808000220041978080800041021089808080002007200020076b41026a1082808080001a410141b0818080004124108580808000000b41cd004101417f108b80808000220741086a220041e08180800041cd00108980808000200741cd00360200200041cd00410020071b10828080800021002001220841506a220724808080800020074190818080004119108980808000200841696a2000ad108e80808000220041978080800041021089808080002007200020076b41026a1082808080001a410141b0818080004124108580808000000bad0a01027f23808080800041f0006b2221248080808000202141406a2222248080808000202241186a4200370300202242003703102022420037030820224200370300202241206a20003a0000202241216a20013a0000202241226a20023a0000202241236a20033a0000202241246a20043a0000202241256a20053a0000202241266a20063a0000202241276a20073a0000202241286a20083a0000202241296a20093a00002022412a6a200a3a00002022412b6a200b3a00002022412c6a200c3a00002022412d6a200d3a00002022412e6a200e3a00002022412f6a200f3a0000202241306a20103a0000202241316a20113a0000202241326a20123a0000202241336a20133a0000202241346a20143a0000202241356a20153a0000202241366a20163a0000202241376a20173a0000202241386a20183a0000202241396a20193a00002022413a6a201a3a00002022413b6a201b3a00002022413c6a201c3a00002022413d6a201d3a00002022413e6a201e3a00002022413f6a201f3a0000202241c0002021222141d0006a108080808000410041203602b892808000202141306a41186a202141d0006a41186a2903003703002021202141e0006a2903003703402021202141d8006a29030037033820212021290350370330202141306a412041c09280800041b8928080001081808080002122202141076a4180808080004117108980808000202141076a41176a2022ad108e8080800022004197808080004102108980808000202141076a2000202141076a6b41026a1082808080001a41002d00c092808000210041002d00c192808000210141002d00c292808000210241002d00c392808000210341002d00c492808000210441002d00c592808000210541002d00c692808000210641002d00c792808000210741002d00c892808000210841002d00c992808000210941002d00ca92808000210a41002d00cb92808000210b41002d00cc92808000210c41002d00cd92808000210d41002d00ce92808000210e41002d00cf92808000210f41002d00d092808000211041002d00d192808000211141002d00d292808000211241002d00d392808000211341002d00d492808000211441002d00d592808000211541002d00d692808000211641002d00d792808000211741002d00d892808000211841002d00d992808000211941002d00da92808000211a41002d00db92808000211b41002d00dc92808000211c41002d00dd92808000211d41002d00de92808000211e2020410041002d00df9280800020221b3a001f20204100201e20221b3a001e20204100201d20221b3a001d20204100201c20221b3a001c20204100201b20221b3a001b20204100201a20221b3a001a20204100201920221b3a001920204100201820221b3a001820204100201720221b3a001720204100201620221b3a001620204100201520221b3a001520204100201420221b3a001420204100201320221b3a001320204100201220221b3a001220204100201120221b3a001120204100201020221b3a001020204100200f20221b3a000f20204100200e20221b3a000e20204100200d20221b3a000d20204100200c20221b3a000c20204100200b20221b3a000b20204100200a20221b3a000a20204100200920221b3a000920204100200820221b3a000820204100200720221b3a000720204100200620221b3a000620204100200520221b3a000520204100200420221b3a000420204100200320221b3a000320204100200220221b3a000220204100200120221b3a000120204100200020221b3a0000202141f0006a24808080800041000bae0502027f057e23808080800041f0006b2221248080808000202141406a2222248080808000202241186a4200370300202242003703102022420037030820224200370300202241206a20003a0000202241216a20013a0000202241226a20023a0000202241236a20033a0000202241246a20043a0000202241256a20053a0000202241266a20063a0000202241276a20073a0000202241286a20083a0000202241296a20093a00002022412a6a200a3a00002022412b6a200b3a00002022412c6a200c3a00002022412d6a200d3a00002022412e6a200e3a00002022412f6a200f3a0000202241306a20103a0000202241316a20113a0000202241326a20123a0000202241336a20133a0000202241346a20143a0000202241356a20153a0000202241366a20163a0000202241376a20173a0000202241386a20183a0000202241396a20193a00002022413a6a201a3a00002022413b6a201b3a00002022413c6a201c3a00002022413d6a201d3a00002022413e6a201e3a00002022413f6a201f3a0000202241c0002021222141d0006a1080808080004100418080023602b892808000202141306a41186a202141d0006a41186a290300202141e0006a29030022232021290350222442017c22252024542222202141d8006a29030022262022ad7c2227202654202520245a1bad7c2224202354ad7c370300202120253703302021202737033820212024370340202141306a412041c09280800041b8928080001081808080002122202141056a41a0808080004119108980808000202141056a41196a2022ad108e8080800022004197808080004102108980808000202141056a2000202141056a6b41026a1082808080001a41002100024020220d0041002802b892808000410141c092808000108b8080800021000b20202000360200202141f0006a24808080800041000bae0502027f057e23808080800041f0006b2221248080808000202141406a2222248080808000202241186a4200370300202242003703102022420037030820224200370300202241206a20003a0000202241216a20013a0000202241226a20023a0000202241236a20033a0000202241246a20043a0000202241256a20053a0000202241266a20063a0000202241276a20073a0000202241286a20083a0000202241296a20093a00002022412a6a200a3a00002022412b6a200b3a00002022412c6a200c3a00002022412d6a200d3a00002022412e6a200e3a00002022412f6a200f3a0000202241306a20103a0000202241316a20113a0000202241326a20123a0000202241336a20133a0000202241346a20143a0000202241356a20153a0000202241366a20163a0000202241376a20173a0000202241386a20183a0000202241396a20193a00002022413a6a201a3a00002022413b6a201b3a00002022413c6a201c3a00002022413d6a201d3a00002022413e6a201e3a00002022413f6a201f3a0000202241c0002021222141d0006a1080808080004100418080023602b892808000202141306a41186a202141d0006a41186a290300202141e0006a29030022232021290350222442027c22252024542222202141d8006a29030022262022ad7c2227202654202520245a1bad7c2224202354ad7c370300202120253703302021202737033820212024370340202141306a412041c09280800041b8928080001081808080002122202141056a41a0808080004119108980808000202141056a41196a2022ad108e8080800022004197808080004102108980808000202141056a2000202141056a6b41026a1082808080001a41002100024020220d0041002802b892808000410141c092808000108b8080800021000b20202000360200202141f0006a24808080800041000bf31805047f047e017f027e017f2380808080004180016b2221248080808000202141406a22222223248080808000202241186a4200370300202242003703102022420037030820224200370300202241206a20003a0000202241216a20013a0000202241226a20023a0000202241236a20033a0000202241246a20043a0000202241256a20053a0000202241266a20063a0000202241276a20073a0000202241286a20083a0000202241296a20093a00002022412a6a200a3a00002022412b6a200b3a00002022412c6a200c3a00002022412d6a200d3a00002022412e6a200e3a00002022412f6a200f3a0000202241306a20103a0000202241316a20113a0000202241326a20123a0000202241336a20133a0000202241346a20143a0000202241356a20153a0000202241366a20163a0000202241376a20173a0000202241386a20183a0000202241396a20193a00002022413a6a201a3a00002022413b6a201b3a00002022413c6a201c3a00002022413d6a201d3a00002022413e6a201e3a00002022413f6a201f3a0000202241c0002021222141d8006a108080808000410041203602b892808000202141386a41186a202141d8006a41186a2903003703002021202141e8006a2903003703482021202141d8006a41086a29030037034020212021290358370338202141386a412041c09280800041b89280800010818080800021222021410f6a41808080800041171089808080002021410f6a41176a2022ad108e80808000222441978080800041021089808080002021410f6a20242021410f6a6b41026a1082808080001a0240024041000d00410041002d00c09280800020221b41ff0171200041ff0171470d00410041002d00c19280800020221b41ff0171200141ff0171470d00410041002d00c29280800020221b41ff0171200241ff0171470d00410041002d00c39280800020221b41ff0171200341ff0171470d00410041002d00c49280800020221b41ff0171200441ff0171470d00410041002d00c59280800020221b41ff0171200541ff0171470d00410041002d00c69280800020221b41ff0171200641ff0171470d00410041002d00c79280800020221b41ff0171200741ff0171470d00410041002d00c89280800020221b41ff0171200841ff0171470d00410041002d00c99280800020221b41ff0171200941ff0171470d00410041002d00ca9280800020221b41ff0171200a41ff0171470d00410041002d00cb9280800020221b41ff0171200b41ff0171470d00410041002d00cc9280800020221b41ff0171200c41ff0171470d00410041002d00cd9280800020221b41ff0171200d41ff0171470d00410041002d00ce9280800020221b41ff0171200e41ff0171470d00410041002d00cf9280800020221b41ff0171200f41ff0171470d00410041002d00d09280800020221b41ff0171201041ff0171470d00410041002d00d19280800020221b41ff0171201141ff0171470d00410041002d00d29280800020221b41ff0171201241ff0171470d00410041002d00d39280800020221b41ff0171201341ff0171470d00410041002d00d49280800020221b41ff0171201441ff0171470d00410041002d00d59280800020221b41ff0171201541ff0171470d00410041002d00d69280800020221b41ff0171201641ff0171470d00410041002d00d79280800020221b41ff0171201741ff0171470d00410041002d00d89280800020221b41ff0171201841ff0171470d00410041002d00d99280800020221b41ff0171201941ff0171470d00410041002d00da9280800020221b41ff0171201a41ff0171470d00410041002d00db9280800020221b41ff0171201b41ff0171470d00410041002d00dc9280800020221b41ff0171201c41ff0171470d00410041002d00dd9280800020221b41ff0171201d41ff0171470d00410041002d00de9280800020221b41ff0171201e41ff0171470d00410041002d00df9280800020221b41ff0171201f41ff0171470d00202341406a22222223248080808000202241186a4200370300202242003703102022420037030820224200370300202241206a20003a0000202241216a20013a0000202241226a20023a0000202241236a20033a0000202241246a20043a0000202241256a20053a0000202241266a20063a0000202241276a20073a0000202241286a20083a0000202241296a20093a00002022412a6a200a3a00002022412b6a200b3a00002022412c6a200c3a00002022412d6a200d3a00002022412e6a200e3a00002022412f6a200f3a0000202241306a20103a0000202241316a20113a0000202241326a20123a0000202241336a20133a0000202241346a20143a0000202241356a20153a0000202241366a20163a0000202241376a20173a0000202241386a20183a0000202241396a20193a00002022413a6a201a3a00002022413b6a201b3a00002022413c6a201c3a00002022413d6a201d3a00002022413e6a201e3a00002022413f6a201f3a0000202341606a22232224248080808000202241c000202310808080800020232903002125202341086a2903002126202341186a2903002127202341106a2903002128202441606a2222222924808080800020222026202542017c222a2025542223ad7c222b3703082022202a370300410021244100418080023602b892808000202220282023202b202654202a20255a1bad7c2225370310202241186a20272025202854ad7c3703002022412041c09280800041b89280800010818080800021232029222941506a2222222c248080808000202241a0808080004119108980808000202941696a2023ad108e80808000222941978080800041021089808080002022202920226b41026a1082808080001a41002129024020230d0041002802b892808000410141c092808000108b8080800021290b202c41406a22222223248080808000202241186a4200370300202242003703102022420037030820224200370300202241206a20003a0000202241216a20013a0000202241226a20023a0000202241236a20033a0000202241246a20043a0000202241256a20053a0000202241266a20063a0000202241276a20073a0000202241286a20083a0000202241296a20093a00002022412a6a200a3a00002022412b6a200b3a00002022412c6a200c3a00002022412d6a200d3a00002022412e6a200e3a00002022412f6a200f3a0000202241306a20103a0000202241316a20113a0000202241326a20123a0000202241336a20133a0000202241346a20143a0000202241356a20153a0000202241366a20163a0000202241376a20173a0000202241386a20183a0000202241396a20193a00002022413a6a201a3a00002022413b6a201b3a00002022413c6a201c3a00002022413d6a201d3a00002022413e6a201e3a00002022413f6a201f3a0000202341606a22232200248080808000202241c000202310808080800020232903002125202341086a2903002126202341186a2903002127202341106a2903002128200041606a2222220024808080800020222026202542027c222a2025542223ad7c222b3703082022202a3703004100418080023602b892808000202220282023202b202654202a20255a1bad7c2225370310202241186a20272025202854ad7c3703002022412041c09280800041b89280800010818080800021232000220041506a22222201248080808000202241a0808080004119108980808000200041696a2023ad108e80808000220041978080800041021089808080002022200020226b41026a1082808080001a024020230d0041002802b892808000410141c092808000108b8080800021240b200141706a2223248080808000024020292024202141fc006a10958080800022220d002023202128027c22222903283703002023202241306a290300370308410021220b2022450d0120214180016a24808080800020220f0b4113410141f083808000108b808080002222280200410020221b41cd006a4101417f108b80808000222141086a2200418384808000410f108980808000202141176a2201202241086a2022280200410020221b2222108980808000200120226a222241a084808000413e1089808080002021202220006b413e6a222236020020002022410020211b10828080800021212023222341506a222224808080800020224190818080004119108980808000202341696a2021ad108e80808000222141978080800041021089808080002022202120226b41026a1082808080001a410141e0848080004118108580808000000b20204200370310202041186a4200370300202020232903003703002020202341086a29030037030820214180016a24808080800041000bf344020c7f057e23808080800041106b22032480808080004138108c808080001a0240024002400240024002400240024002400240024002400240024002400240200020032204410c6a10968080800022000d00200428020c2100200341706a220322052480808080002001200310968080800022010d012000280200410020001b220120032802002203280200410020031b6a22062001490d0220064101417f108b80808000220141086a2206200041086a2000280200410020001b220010898080800041000d03200620006a200341086a2003280200410020031b108980808000200541706a22052203248080808000200341706a22072208248080808000200128020021034100418080013602b89280800041c092808000418010108a8080800041b00920062003410020011b41c09280800041b8928080001086808080002100200741002802b892808000410141c092808000108b8080800022033602002005200036020020000d042003280200410020031b450d05200341086a2d00000d060240024002400240024002402003280200410020031b2200450d00200341096a22052d000022014103710e03040102030b410141e0888080004124108580808000000b4102210120052f010041027621050c030b20052802004102762105410421010c020b410141004100108580808000000b20014102762105410121010b41000d07200141016a220620004b0d0841000d0941000d0a200520016a220141016a220720004b0d0b20054101417f108b80808000220941086a200320066a41086a200510898080800041000d0c0240024002400240024041000d002003200141016a6a41086a2d000022054103710e03020304010b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b2005410276210a410121050c110b41000d0e024041000d00410221052003200141016a6a41086a2f0100410276210a0c110b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41000d0e024041000d002003200141016a6a41086a280200410276210a410421050c100b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b200441106a24808080800020000f0b200441106a24808080800020010f0b41f884808000410f10828080800021042005220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41908580800041c10010828080800021042005220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b411f410141e085808000108b808080002203280200410020031b41cd006a4101417f108b80808000220441086a2200418384808000410f108980808000200441176a2201200341086a2003280200410020031b2203108980808000200120036a2203418086808000413e1089808080002004200320006b413e6a220336020020002003410020041b10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0868080004124108580808000000b41cd004101417f108b80808000220341086a220441f08680800041cd00108980808000200341cd00360200200441cd00410020031b10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141b0818080004124108580808000000b4127410141c087808000108b808080002203280200410020031b41cd006a4101417f108b80808000220441086a2200418384808000410f108980808000200441176a2201200341086a2003280200410020031b2203108980808000200120036a220341f087808000413e1089808080002004200320006b413e6a220336020020002003410020041b10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141b088808000412c108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b02400240024002400240024002400240024002400240024002400240024002400240024002400240200720056a220b2007490d00200b20004b0d0141000d022007200a20056a22066a22052007490d03200520004b0d04200a4101417f108b80808000220c41086a2003200b6a41086a200a10898080800041000d0541000d0641000d07200141016a220720066a220a2007490d082003200a6a41086a2d000022074103710e030a0b0c090b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b2007410276210a410121070c080b41000d0141000d0241000d030240200141016a220720066a220a2007490d00410221072003200a6a41086a2f0100410276210a0c080b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41000d0341000d0441000d050240200141016a220720066a220a2007490d002003200a6a41086a280200410276210a410421070c070b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b02400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200520076a220b2005490d00200b20004b0d0141000d022005200a20076a22076a220d2005490d03200d20004b0d04200a4101417f108b80808000220d41086a2003200b6a41086a200a108980808000200541286a220a2005490d05200a20004b0d0641000d0741000d0841000d09200141016a220a20066a2205200a490d0a41000d0b200520076a220b2005490d0c41000d0d41000d0e41000d0f200141016a220a20066a2205200a490d1041000d11200520076a220a2005490d12200a41106a220e200a490d1341000d1441000d1541000d16200141016a220a20066a2205200a490d1741000d18200520076a220a2005490d19200a41106a2205200a490d1a200541086a220a2005490d1b2003200b6a220541106a290300210f200541086a29030021102003200e6a41086a29030021112003200a6a220341086a2903002112200341106a29030021134138108c8080800022032009360200200341306a2013370300200341286a2012370300200341186a200f370300200341106a2010370300200341206a2011370300200341086a200d360200200341046a200c36020041000d1c200120066a220520076a22012005490d1d200141106a22052001490d1e200541086a22012005490d1f200141106a22052001490d20200541016a2201450d21200120004f0d22410141e0888080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b41908980800041c10010828080800021042008220041506a220324808080800020034190818080004119108980808000200041696a2004ad108e80808000220441978080800041021089808080002003200420036b41026a1082808080001a410141c0838080004124108580808000000b20022003360200200441106a24808080800041000bf70506027f017e017f037e037f047e2380808080002202210341004101417f108b808080001a4200210441204101417f108b808080002105420021064200210742002108024002400240034041002109024020042005280200410020051bad5a4101200650220a1b4101200720088450220b1b0d0020042000280200410020001bad544100200a1b4100200b1b21090b2009450d0120042000280200410020001bad5a4101200a1b4101200b1b0d0220042005280200410020051bad544100200a1b4100200b1b450d0320052004a7220a6a41086a2000200a6a41086a2d00003a000002402007200442017c220c200454220a2006200aad7c220d200654200c20045a1b220aad7c220e200754220b2008200bad7c220f200854200e20075a1b200a200a1b0d00200c2104200d2106200e2107200f21080c010b0b41808b80800041c10010828080800021002002220a41506a220524808080800020054190818080004119108980808000200a41696a2000ad108e80808000220041978080800041021089808080002005200020056b41026a1082808080001a410141c0838080004124108580808000000b20012005360200200324808080800041000f0b41cd004101417f108b80808000220541086a220041e08980800041cd00108980808000200541cd00360200200041cd00410020051b10828080800021002002220a41506a220524808080800020054190818080004119108980808000200a41696a2000ad108e80808000220041978080800041021089808080002005200020056b41026a1082808080001a410141b0818080004124108580808000000b41cd004101417f108b80808000220541086a220041b08a80800041cd00108980808000200541cd00360200200041cd00410020051b10828080800021002002220a41506a220524808080800020054190818080004119108980808000200a41696a2000ad108e80808000220041978080800041021089808080002005200020056b41026a1082808080001a410141b0818080004124108580808000000b8c3b02317f027e238080808000220521060240200141034d0d00200420002802002207360200200741d0cbb1cb78470d000240200220038450450d000240024002400240024002402001417c6a20014b0d0041042108200041046a22042d000022074103710e03040102030b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41022108200041046a2f010041027621040c030b200428020041027621040c020b410141004100108580808000000b20074102762104410121080b024041000d0002402001417c6a220720014b0d000240200820074b0d00024041000d0020044128417f108b80808000220941086a21072001417c6a210a200041046a210b4100210c0240024002400240024002400240024002400240024002400240024002400240024002400240024002400240034002400240024002400240024002400240024002400240024002400240200c2009280200410020091b4f0d00200841206a220d20084922040d07200a20014b220e0d080240200d200a4b0d0020040d02200b20086a22002d001f210f20002d001e211020002d001d211120002d001c211220002d001b211320002d001a211420002d0019211520002d0018211620002d0017211720002d0016211820002d0015211920002d0014211a20002d0013211b20002d0012211c20002d0011211d20002d0010211e20002d000f211f20002d000e212020002d000d212120002d000c212220002d000b212320002d000a212420002d0009212520002d0008212620002d0007212720002d0006212820002d0005212920002d0004212a20002d0003212b20002d0002212c20002d0001212d20002d0000212e200b200d6a222f2d000022004103710e03050607030b410141e0888080004124108580808000000b41000d0841000d092001417c6a220020014b0d0a20082000490d0b200910908080800022000d02410041004101417f108b8080800041086a4100108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b200624808080800020000f0b2000410276212f410121000c080b024020040d0041022100202f2f0100410276212f0c080b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b024020040d00202f280200410276212f410421000c070b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b0240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024020040d00200d20006a2230200d4922310d01200e0d022030200a4b0d0320040d0441000d05200d202f20006a22326a2200200d49220d0d06200e0d072000200a4b0d08202f4101417f108b80808000213320040d0920310d0a203341086a200b20306a202f10898080800020040d0b41000d0c200d0d0d200b20006a222f2d000022304103710e030f10110e0b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b2030410276212f410121300c060b20040d0141000d020240200d0d0041022130202f2f0100410276212f0c060b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b20040d0241000d030240200d0d00202f280200410276212f410421300c050b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b024020040d0041000d02200d0d03200020306a223120004922340d04200e0d052031200a4b0d0620040d0741000d08200d0d0941000d0a2000202f20306a22306a22352000490d0b200e0d0c2035200a4b0d0d202f4101417f108b80808000210e20040d0e41000d0f200d0d1020340d11200e41086a200b20316a202f1089808080004128108c808080002200202b3a00032000202c3a00022000202d3a00012000202e3a00002000202a3a0004200020293a0005200020283a0006200020273a0007200020263a0008200020253a0009200020243a000a200020233a000b200020223a000c200020213a000d200020203a000e2000201f3a000f2000201e3a00102000201d3a00112000201c3a00122000201b3a00132000201a3a0014200020193a0015200020183a0016200020173a0017200020163a0018200020153a0019200020143a001a200020133a001b200020123a001c200020113a001d200020103a001e2000200f3a001f200041246a200e360200200041206a2204203336020020042902002103200029020021022000290218213620002902102137200720002902083702082007203737021020072036370218200720033702202007200237020041000d1241000d1341000d14203241206a220420306a22002004490d15200020086a22082000490d16200c417f460d17200741286a2107200c41016a210c0c010b0b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141c0838080004124108580808000000b41c0004101417f108b80808000220041086a220441d08b80800041c000108980808000200041c0003602002004200041004741067410828080800021042005220741506a220024808080800020004190818080004119108980808000200741696a2004ad108e80808000220441978080800041021089808080002000200420006b41026a1082808080001a410141004100108580808000000b410141004100108580808000000bd3b30202247f027e23808080800041106b220521062005248080808000024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200141034d0d0020042000280200220736020002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200741b1ffcdea7d4a0d000240200741d993e9c77c4a0d00200741b5f791cd79460d06200741f4afa9af7b470d7820022003844200510d0b41d4004101417f108b80808000220041086a220141b08d80800041d400108980808000200041d400360200200141d400410020001b10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141004100108580808000000b200741da93e9c77c460d012007419dcec98a7d470d7720022003844200510d0941cf004101417f108b80808000220041086a220141e08c80800041cf00108980808000200041cf00360200200141cf00410020001b10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141004100108580808000000b0240200741b2b3bd3b4a0d00200741b2ffcdea7d460d0420074196c38bb47f470d7720022003844200510d1641d4004101417f108b80808000220041086a220141809180800041d400108980808000200041d400360200200141d400410020001b10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141004100108580808000000b200741b3b3bd3b460d02200741c1d8a1a104460d01200741b090e3c606470d7620022003844200510d1441e2004101417f108b80808000220041086a220141909080800041e200108980808000200041e200360200200141e200410020001b10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141004100108580808000000b20022003844200520d92012001417c6a220720014b22040d0420040d052007411f4d0d062001417c6a220720014b0d19200741204d0d26410141e0888080004124108580808000000b20022003844200520d90012001417c6a220720014b22040d0820040d092007411f4d0d0a2001417c6a220720014b0d1b200741204d0d28410141e0888080004124108580808000000b20022003844200520d8e012001417c6a220720014b22040d0a20040d0b2007411f4d0d0c2001417c6a220720014b0d1b200741204d0d28410141e0888080004124108580808000000b20022003844200520d8c012001417c6a20014b0d0c41042104200041046a22072d000022084103710e031b0d0e0f0b20022003844200520d8a012001417c6a20014b0d1141042104200041046a22072d000022084103710e03201213140b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b2001417c6a220720014b22040d6e20040d6f02402007411f4d0d002001417c6a220720014b0d13200741204d0d20410141e0888080004124108580808000000b410141e0888080004124108580808000000b2001417c6a220720014b22040d6f20040d7002402007411f4d0d002001417c6a220720014b0d13200741204d0d20410141e0888080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41022104200041046a2f010041027621080c0e0b200728020041027621080c0d0b410141004100108580808000000b02400240024002402001417c6a20014b0d0041042104200041046a22072d000022084103710e03100102030b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41022104200041046a2f010041027621080c0f0b200728020041027621080c0e0b410141004100108580808000000b02400240024002402001417c6a20014b0d0041042104200041046a22072d000022084103710e03110102030b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41022104200041046a2f010041027621080c100b200728020041027621080c0f0b410141004100108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41022104200041046a2f010041027621080c0e0b200728020041027621080c0d0b410141004100108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b20084102762108410121040b41000d0b2001417c6a220720014b0d0c200420074b0d0d41000d1741000d182001417c6a220920014b0d19200820046a220720094b0d1a20084101417f108b80808000210941000d27200941086a200041046a220a20046a200810898080800041000d2841000d29200a20076a2d000022044103710e03393a3b2a0b20084102762108410121040b41000d0c2001417c6a220720014b0d0d200420074b0d0e41000d1941000d1a2001417c6a220920014b0d1b200820046a220720094b0d1c20084101417f108b80808000210941000d29200941086a200041046a220a20046a200810898080800041000d2a41000d2b200a20076a2d000022044103710e033a3b3c2c0b20084102762108410121040b41000d0d2001417c6a220720014b0d0e200420074b0d0f41000d1b41000d1c2001417c6a220920014b0d1d200820046a220720094b0d1e20084101417f108b80808000210941000d2b200941086a200041046a220a20046a200810898080800041000d2c41000d2d200a20076a2d000022044103710e033b3c3d2e0b20084102762108410121040b41000d0e2001417c6a220720014b0d0f200420074b0d1041000d1d41000d1e2001417c6a220920014b0d1f200820046a220720094b0d2020084101417f108b80808000210941000d2d200941086a200041046a220a20046a200810898080800041000d2e41000d2f200a20076a2d000022044103710e033c3d3e300b200041236a2d00002101200041226a2d00002107200041216a2d00002104200041206a2d000021082000411f6a2d000021092000411e6a2d0000210a2000411d6a2d0000210b2000411c6a2d0000210c2000411b6a2d0000210d2000411a6a2d0000210e200041196a2d0000210f200041186a2d00002110200041176a2d00002111200041166a2d00002112200041156a2d00002113200041146a2d00002114200041136a2d00002115200041126a2d00002116200041116a2d00002117200041106a2d000021182000410f6a2d000021192000410e6a2d0000211a2000410d6a2d0000211b2000410c6a2d0000211c2000410b6a2d0000211d2000410a6a2d0000211e200041096a2d0000211f200041086a2d00002120200041076a2d00002121200041066a2d00002122200041056a2d00002123200041046a2d00002100200541606a22052224248080808000202441706a22242225248080808000202541706a22252226248080808000024020002023202220212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a20092008200420072001200520242025108f808080002200450d00200641106a24808080800020000f0b20242802002200280200410020001b41ffffffff034b0d66202528020021014101210702402000280200410020001b413f4d0d00410421072000280200410020001b41ffff004b0d00410221070b2001280200410020011b41ffffffff034d0d3e410141004100108580808000000b200041236a2d00002101200041226a2d00002107200041216a2d00002104200041206a2d000021082000411f6a2d000021092000411e6a2d0000210a2000411d6a2d0000210b2000411c6a2d0000210c2000411b6a2d0000210d2000411a6a2d0000210e200041196a2d0000210f200041186a2d00002110200041176a2d00002111200041166a2d00002112200041156a2d00002113200041146a2d00002114200041136a2d00002115200041126a2d00002116200041116a2d00002117200041106a2d000021182000410f6a2d000021192000410e6a2d0000211a2000410d6a2d0000211b2000410c6a2d0000211c2000410b6a2d0000211d2000410a6a2d0000211e200041096a2d0000211f200041086a2d00002120200041076a2d00002121200041066a2d00002122200041056a2d00002123200041046a2d00002124200541606a220024808080800020242023202220212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a2009200820042007200120001091808080002201450d64200641106a24808080800020010f0b200041236a2d00002101200041226a2d00002107200041216a2d00002104200041206a2d000021082000411f6a2d000021092000411e6a2d0000210a2000411d6a2d0000210b2000411c6a2d0000210c2000411b6a2d0000210d2000411a6a2d0000210e200041196a2d0000210f200041186a2d00002110200041176a2d00002111200041166a2d00002112200041156a2d00002113200041146a2d00002114200041136a2d00002115200041126a2d00002116200041116a2d00002117200041106a2d000021182000410f6a2d000021192000410e6a2d0000211a2000410d6a2d0000211b2000410c6a2d0000211c2000410b6a2d0000211d2000410a6a2d0000211e200041096a2d0000211f200041086a2d00002120200041076a2d00002121200041066a2d00002122200041056a2d00002123200041046a2d00002100200541706a22052224248080808000024020002023202220212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a2009200820042007200120051092808080002200450d00200641106a24808080800020000f0b20052802002200280200410020001b41ffffffff034b0d624101210102402000280200410020001b413f4d0d00410421012000280200410020001b41ffff004b0d00410221010b20012000280200410020001b6a22072001490d2e20074101417f108b8080800021052000280200410020001b220741ffffffff034d0d3d410141004100108580808000000b200041236a2d00002101200041226a2d00002107200041216a2d00002104200041206a2d000021082000411f6a2d000021092000411e6a2d0000210a2000411d6a2d0000210b2000411c6a2d0000210c2000411b6a2d0000210d2000411a6a2d0000210e200041196a2d0000210f200041186a2d00002110200041176a2d00002111200041166a2d00002112200041156a2d00002113200041146a2d00002114200041136a2d00002115200041126a2d00002116200041116a2d00002117200041106a2d000021182000410f6a2d000021192000410e6a2d0000211a2000410d6a2d0000211b2000410c6a2d0000211c2000410b6a2d0000211d2000410a6a2d0000211e200041096a2d0000211f200041086a2d00002120200041076a2d00002121200041066a2d00002122200041056a2d00002123200041046a2d00002100200541706a22052224248080808000024020002023202220212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a2009200820042007200120051093808080002200450d00200641106a24808080800020000f0b20052802002200280200410020001b41ffffffff034b0d604101210102402000280200410020001b413f4d0d00410421012000280200410020001b41ffff004b0d00410221010b20012000280200410020001b6a22072001490d2e20074101417f108b8080800021052000280200410020001b220741ffffffff034d0d3d410141004100108580808000000b200041236a2d00002101200041226a2d00002107200041216a2d00002104200041206a2d000021082000411f6a2d000021092000411e6a2d0000210a2000411d6a2d0000210b2000411c6a2d0000210c2000411b6a2d0000210d2000411a6a2d0000210e200041196a2d0000210f200041186a2d00002110200041176a2d00002111200041166a2d00002112200041156a2d00002113200041146a2d00002114200041136a2d00002115200041126a2d00002116200041116a2d00002117200041106a2d000021182000410f6a2d000021192000410e6a2d0000211a2000410d6a2d0000211b2000410c6a2d0000211c2000410b6a2d0000211d2000410a6a2d0000211e200041096a2d0000211f200041086a2d00002120200041076a2d00002121200041066a2d00002122200041056a2d00002123200041046a2d00002124200541606a220024808080800020242023202220212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200b200a2009200820042007200120001094808080002201450d5e200641106a24808080800020010f0b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b20044102762104410121080c2e0b41000d1f024041000d0041022108200041046a20076a2f010041027621040c2e0b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41000d1f024041000d00200041046a20076a2802004102762104410421080c2d0b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b20044102762104410121080c2a0b41000d1e024041000d0041022108200041046a20076a2f010041027621040c2a0b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41000d1e024041000d00200041046a20076a2802004102762104410421080c290b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b20044102762104410121080c260b41000d1d024041000d0041022108200041046a20076a2f010041027621040c260b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41000d1d024041000d00200041046a20076a2802004102762104410421080c250b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b20044102762104410121080c220b41000d1c024041000d0041022108200041046a20076a2f010041027621040c220b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41000d1c024041000d00200041046a20076a2802004102762104410421080c210b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b4101210602402001280200410020011b413f4d0d00410421062001280200410020011b41ffff004b0d00410221060b20072000280200410020001b6a22042007490d06200441206a22082004490d0720062001280200410020011b6a22042006490d08200820046a22042008490d0920052d001f210820052d001e210920052d001d210a20052d001c210b20052d001b210c20052d001a210d20052d0019210e20052d0018210f20052d0017211020052d0016211120052d0015211220052d0014211320052d0013211420052d0012211520052d0011211620052d0010211720052d000f211820052d000e211920052d000d211a20052d000c211b20052d000b211c20052d000a211d20052d0009211e20052d0008211f20052d0007212020052d0006212120052d0005212220052d0004212320052d0003212420052d0002212520052d0001212720052d0000212820044101417f108b808080002205410a6a20253a0000200541096a20273a0000200541086a20283a00002005410b6a20243a00002005410c6a20233a00002005410d6a20223a00002005410e6a20213a00002005410f6a20203a0000200541106a201f3a0000200541116a201e3a0000200541126a201d3a0000200541136a201c3a0000200541146a201b3a0000200541156a201a3a0000200541166a20193a0000200541176a20183a0000200541186a20173a0000200541196a20163a00002005411a6a20153a00002005411b6a20143a00002005411c6a20133a00002005411d6a20123a00002005411e6a20113a00002005411f6a20103a0000200541206a200f3a0000200541216a200e3a0000200541226a200d3a0000200541236a200c3a0000200541246a200b3a0000200541256a200a3a0000200541266a20093a0000200541276a20083a00002000280200410020001b220441ffffffff034d0d0e410141004100108580808000000b2007413f4b0d01200741ffffffff03712007470d02200541086a20074102743a0000410121060c1d0b2007413f4b0d02200741ffffffff03712007470d03200541086a20074102743a0000410121060c1b0b200741ffff004b0d07200741ffffffff03712007470d0841022106200541086a20074102744101723b01000c1b0b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b200741ffff004b0d07200741ffffffff03712007470d0841022106200541086a20074102744101723b01000c180b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240200741ffffffff03712007470d00200541086a2007410274410272360200410421060c140b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240200741ffffffff03712007470d00200541086a2007410274410272360200410421060c110b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b02400240024002402004413f4b0d00200441ffffffff03712004470d01200541286a20044102743a0000410121080c110b200441ffff004b0d01200441ffffffff03712004470d0241022108200541286a20044102744101723b01000c100b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240200441ffffffff03712004470d00200541286a2004410274410272360200410421080c0f0b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240024041000d00200541086a20084120726a200041086a20041089808080002001280200410020011b220941ffffffff034d0d01410141004100108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b024002400240024002400240024002400240024002402009413f4b0d00200420086a220a2004490d01200a41206a220b200a490d02200941ffffffff03712009470d03200541086a200b6a20094102743a00004101210a0c0a0b200941ffff004b0d03200420086a220a2004490d04200a41206a220b200a490d05200941ffffffff03712009470d064102210a200541086a200b6a20094102744101723b01000c090b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b200420086a220a2004490d03200a41206a220b200a490d040240200941ffffffff03712009470d00200541086a200b6a20094102744102723602004104210a0c060b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240024002400240024002400240200420086a22082004490d00200841206a22042008490d012004200a6a22082004490d02200541086a20086a200141086a200910898080800020072000280200410020001b6a22002007490d03200041206a22072000490d0420062001280200410020011b6a22002006490d05200720006a22002007490d064100200541086a2000108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012026220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240024041000d00200541086a220520066a200041086a200710898080800020012000280200410020001b6a22002001490d01410020052000108580808000000b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240024041000d00200541086a220520066a200041086a200710898080800020012000280200410020001b6a22002001490d01410020052000108580808000000b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012024220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240024002400240024002400240024002400240024002400240024002400240024002400240024041000d0041000d0141000d022001417c6a220a20014b0d03200720086a220b200a4b0d0441000d0541000d0641000d0741000d082001417c6a220a20014b0d092007200420086a220c6a200a4b0d0a20044101417f108b80808000210841000d0b41000d0c41000d0d200841086a200041046a200b6a200410898080800041000d0e41000d0f41000d1041000d112001417c6a220020014b0d122007200c6a20004f0d13410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b200541706a2200220724808080800002400240024002400240024002400240024002400240024002400240024020092008200010958080800022010d0002402000280200220028020022010d0020004108108c8080800022013602000b2001280200410020011b4180808080044f0d010240200028020022010d0020004108108c8080800022013602000b4101210502402001280200410020011b41c000490d000240200028020022010d0020004108108c8080800022013602000b410421052001280200410020011b41ffff004b0d00410221050b0240200028020422010d0020004108108c8080800022013602040b2001280200410020011b4180808080044f0d020240200028020422010d0020004108108c8080800022013602040b4101210602402001280200410020011b41c000490d000240200028020422010d0020004108108c8080800022013602040b410421062001280200410020011b41ffff004b0d00410221060b0240200028020822010d0020004108108c8080800022013602080b2001280200410020011b4180808080044f0d030240200028020822010d0020004108108c8080800022013602080b4101210402402001280200410020011b41c000490d000240200028020822010d0020004108108c8080800022013602080b410421042001280200410020011b41ffff004b0d00410221040b0240200028020022010d0020004108108c8080800022013602000b20052001280200410020011b6a22082005490d040240200028020422010d0020004108108c8080800022013602040b20062001280200410020011b6a22012006490d05200820016a22092008490d060240200028020822010d0020004108108c8080800022013602080b20042001280200410020011b6a22012004490d07200920016a22012009490d08200141106a22082001490d09200841086a22012008490d0a200141106a22082001490d0b20084101417f108b8080800021080240200028020022010d0020004108108c8080800022013602000b2001280200410020011b22014180808080044f0d0c024002400240200141c000490d00200141ffff004d0d02200141ffffffff03712001470d01200841086a20014102744102723602004104210a0c110b200141ffffffff03712001470d0f200841086a20014102743a00004101210a0c100b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240200141ffffffff03712001470d004102210a200841086a20014102744101723b01000c0f0b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b200641106a24808080800020010f0b410141004100108580808000000b410141004100108580808000000b410141004100108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b0240200028020022090d0020004108108c8080800022093602000b0240024002400240024002400240024041000d00200841086a200a6a200941086a20011089808080000240200028020422090d0020004108108c8080800022093602040b2009280200410020091b22094180808080044f0d0102400240024002400240200941c000490d00200941ffff004d0d042001200a6a220b2001490d0141000d02200941ffffffff03712009470d03200841086a200b6a20094102744102723602004104210c0c0c0b2001200a6a220b2001490d0641000d07200941ffffffff03712009470d08200841086a200b6a20094102743a00004101210c0c0b0b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b2001200a6a220b2001490d0541000d060240200941ffffffff03712009470d004102210c200841086a200b6a20094102744101723b01000c080b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b02402000280204220b0d0020004108108c80808000220b3602040b024002400240024002400240024002400240024002400240024002402001200a6a220a20014922010d0041000d01200a200c6a220d200a490d02200841086a200d6a200b41086a200910898080800002402000280208220b0d0020004108108c80808000220b3602080b200b2802004100200b1b220b4180808080044f0d030240024002400240024002400240200b41c000490d00200b41ffff004d0d0620010d0141000d022009200c6a220d2009490d03200a200d6a220d200a490d04200b41ffffffff0371200b470d05200841086a200d6a200b4102744102723602004104210d0c140b20010d0a41000d0b2009200c6a220d2009490d0c200a200d6a220d200a490d0d200b41ffffffff0371200b470d0e200841086a200d6a200b4102743a00004101210d0c130b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b20010d0941000d0a2009200c6a220d2009490d0b200a200d6a220e200a490d0c0240200b41ffffffff0371200b470d004102210d200841086a200e6a200b4102744101723b01000c0e0b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141004100108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b02402000280208220e0d0020004108108c80808000220e3602080b024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024020010d0041000d012009200c6a220c20094922090d02200a200c6a220f200a490d03200f200d6a2210200f490d04200841086a20106a200e41086a200b10898080800020010d0541000d0620090d07200a200c6a220e200a490d08200b200d6a220d200b49220b0d09200e200d6a220f200e490d0a20002903102103200841086a200f6a220e200041186a290300370308200e200337030020010d0b41000d0c20090d0d200a200c6a220e200a490d0e200b0d0f200e200d6a220f200e490d10200f41106a220e200f490d11200841086a200e6a200029032037030020010d1241000d1320090d14200a200c6a2201200a490d15200b0d162001200d6a22092001490d17200941106a22012009490d18200141086a22092001490d1920002903282103200841086a20096a2201200041306a290300370308200120033703000240200028020022010d0020004108108c8080800022013602000b20052001280200410020011b6a22092005490d1a0240200028020422010d0020004108108c8080800022013602040b20062001280200410020011b6a22012006490d1b200920016a22052009490d1c0240200028020822010d0020004108108c8080800022013602080b20042001280200410020011b6a22002004490d1d200520006a22002005490d1e200041106a22012000490d1f200141086a22002001490d20200041106a220120004f0d2141f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012007220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b4100200841086a2001108580808000000b0240024002400240024002400240024002400240024002400240024002400240024002400240024041000d0041000d0141000d022001417c6a220a20014b0d03200720086a220b200a4b0d0441000d0541000d0641000d0741000d082001417c6a220a20014b0d092007200420086a220c6a200a4b0d0a20044101417f108b80808000210841000d0b41000d0c41000d0d200841086a200041046a200b6a200410898080800041000d0e41000d0f41000d1041000d112001417c6a220020014b0d122007200c6a20004f0d13410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b200541706a22012480808080000240200920082006410c6a10958080800022000d002001200628020c22002903283703002001200041306a290300370308410021000b024020000d00200141086a29030021032001290300210241104101417f108b80808000220041106a2003370300200041086a22002002370300410020004110108580808000000b200641106a24808080800020000f0b0240024002400240024002400240024002400240024002400240024002400240024002400240024041000d0041000d0141000d022001417c6a220a20014b0d03200720086a220b200a4b0d0441000d0541000d0641000d0741000d082001417c6a220a20014b0d092007200420086a220c6a200a4b0d0a20044101417f108b80808000210841000d0b41000d0c41000d0d200841086a200041046a200b6a200410898080800041000d0e41000d0f41000d1041000d112001417c6a220020014b0d122007200c6a20004f0d13410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b200541706a2201248080808000024020092008200641086a10958080800022000d0020012006280208290320370300410021000b024020000d002001290300210341084101417f108b8080800041086a22002003370300410020004108108580808000000b200641106a24808080800020000f0b0240024002400240024002400240024002400240024002400240024002400240024002400240024041000d0041000d0141000d022001417c6a220a20014b0d03200720086a220b200a4b0d0441000d0541000d0641000d0741000d082001417c6a220a20014b0d092007200420086a220c6a200a4b0d0a20044101417f108b80808000210841000d0b41000d0c41000d0d200841086a200041046a200b6a200410898080800041000d0e41000d0f41000d1041000d112001417c6a220020014b0d122007200c6a20004f0d13410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b410141e0888080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b41f884808000410f10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141c0838080004124108580808000000b200541706a2201248080808000024020092008200641046a10958080800022000d002001200628020422002903103703002001200041186a290300370308410021000b024020000d00200141086a29030021032001290300210241104101417f108b80808000220041106a2003370300200041086a22002002370300410020004110108580808000000b200641106a24808080800020000f0b200041086a2903002103200041106a2903002102200041186a29030021292000290300212a41204101417f108b80808000220041206a2029370300200041186a2002370300200041106a2003370300200041086a2200202a370300410020004120108580808000000b410141004100108580808000000b410141004100108580808000000b2000290000210320002900082102200029001021292000290018212a41204101417f108b80808000220041206a202a370000200041186a2029370000200041106a2002370000200041086a22002003370000410020004120108580808000000b410141004100108580808000000b41cf004101417f108b80808000220041086a220141e09180800041cf00108980808000200041cf00360200200141cf00410020001b10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141004100108580808000000b41d5004101417f108b80808000220041086a220141b08f80800041d500108980808000200041d500360200200141d500410020001b10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141004100108580808000000b41cb004101417f108b80808000220041086a220141e08e80800041cb00108980808000200041cb00360200200141cb00410020001b10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141004100108580808000000b41d0004101417f108b80808000220041086a220141908e80800041d000108980808000200041d000360200200141d000410020001b10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141004100108580808000000b41cc004101417f108b80808000220041086a220141908c80800041cc00108980808000200041cc00360200200141cc00410020001b10828080800021012005220741506a220024808080800020004190818080004119108980808000200741696a2001ad108e80808000220141978080800041021089808080002000200120006b41026a1082808080001a410141004100108580808000000b880101027f23808080800041206b2200248080808000108d808080004100418080023602b89280800041c09280800041b892808000108780808000410041002802b89280800022013602b4928080002000411036020c200041106a2000410c6a10888080800041c09280800020012000290310200041186a29030041b0928080001097808080001a000b880101027f23808080800041206b2200248080808000108d808080004100418080023602b89280800041c09280800041b892808000108780808000410041002802b89280800022013602b4928080002000411036020c200041106a2000410c6a10888080800041c09280800020012000290310200041186a29030041b0928080001098808080001a000b0bce9202020041000baf1263616c6c3a207365616c5f6765745f73746f726167653d2c0a0000000000000063616c6c3a207365616c5f6765745f73746f726167653a203d0000000000000072756e74696d655f6572726f723a20617272617920696e646578206f7574206f6620626f756e647320696e2050726963654f7261636c65577261707065722e736f6c3a31393a35312d36342c0a00000063616c6c3a207365616c5f64656275675f6d6573736167653d000000000000004e487b71320000000000000000000000000000000000000000000000000000000000000000000000000000000000000072756e74696d655f6572726f723a20617272617920696e646578206f7574206f6620626f756e647320696e2050726963654f7261636c65577261707065722e736f6c3a31393a32382d34312c0a00000063616c6c3a207365616c5f7365745f73746f726167653d00000000000000000063616c6c3a207365616c5f636c6561725f73746f726167653d0000000000000072756e74696d655f6572726f723a206d617468206f766572666c6f7720696e2050726963654f7261636c65577261707065722e736f6c3a31383a34392d35322c0a0000000000000000000000000000004e487b7111000000000000000000000000000000000000000000000000000000000000000000000000000000000000004173736574206e6f7420737570706f7274656472756e74696d655f6572726f723a200000000000000000000000000000207265717569726520636f6e646974696f6e206661696c656420696e2050726963654f7261636c65577261707065722e736f6c3a34313a35352d37362c0a000008c379a04c4173736574206e6f7420737570706f727465646d617468206f766572666c6f772c0a00000000000000000072756e74696d655f6572726f723a206d617468206f766572666c6f7720696e2050726963654f7261636c65577261707065722e736f6c3a36343a32332d39332c0a00000000000000000000000000000043616c6c20746f20636861696e5f657874656e73696f6e206661696c65642e00207265717569726520636f6e646974696f6e206661696c656420696e2050726963654f7261636c65577261707065722e736f6c3a36363a34302d37332c0a000008c379a07c43616c6c20746f20636861696e5f657874656e73696f6e206661696c65642e00000000000000000000000072756e74696d655f6572726f723a20617272617920696e646578206f7574206f6620626f756e647320696e2050726963654f7261636c65577261707065722e736f6c3a36393a31372d32382c0a000000436861696e20657874656e73696f6e2063616c6c2072657475726e656420616e206572726f722e000000000000000000207265717569726520636f6e646974696f6e206661696c656420696e2050726963654f7261636c65577261707065722e736f6c3a36393a33352d37362c0a000008c379a09c436861696e20657874656e73696f6e2063616c6c2072657475726e656420616e206572726f722e000000004e487b71000000000000000000000000000000000000000000000000000000000000000000000000000000000000000072756e74696d655f6572726f723a206d617468206f766572666c6f7720696e2050726963654f7261636c65577261707065722e736f6c3a37303a34302d37392c0a00000000000000000000000000000072756e74696d655f6572726f723a20617272617920696e646578206f7574206f6620626f756e647320696e2050726963654f7261636c65577261707065722e736f6c3a38333a32352d34302c0a00000072756e74696d655f6572726f723a20617272617920696e646578206f7574206f6620626f756e647320696e2050726963654f7261636c65577261707065722e736f6c3a38333a31332d32322c0a00000072756e74696d655f6572726f723a206d617468206f766572666c6f7720696e2050726963654f7261636c65577261707065722e736f6c3a38323a36352d36382c0a00000000000000000000000000000072756e74696d655f6572726f723a206e6f6e2070617961626c6520636f6e7374727563746f722064303635366338392072656365697665642076616c75652c0a72756e74696d655f6572726f723a206e6f6e2070617961626c652066756e6374696f6e205f6f7261636c65427941737365745f5f616464726573732072656365697665642076616c75652c0a0000000072756e74696d655f6572726f723a206e6f6e2070617961626c652066756e6374696f6e206765744f7261636c654b657941737365745f5f616464726573732072656365697665642076616c75652c0a0072756e74696d655f6572726f723a206e6f6e2070617961626c652066756e6374696f6e206765744f7261636c654b6579426c6f636b636861696e5f5f616464726573732072656365697665642076616c75652c0a00000000000000000000000072756e74696d655f6572726f723a206e6f6e2070617961626c652066756e6374696f6e206765744f7261636c654b657953796d626f6c5f5f616464726573732072656365697665642076616c75652c0a72756e74696d655f6572726f723a206e6f6e2070617961626c652066756e6374696f6e20676574417373657450726963655f5f616464726573732072656365697665642076616c75652c0a000000000072756e74696d655f6572726f723a206e6f6e2070617961626c652066756e6374696f6e20676574416e794173736574537570706c795f5f737472696e675f737472696e672072656365697665642076616c75652c0a000000000000000000000072756e74696d655f6572726f723a206e6f6e2070617961626c652066756e6374696f6e20676574416e7941737365744c61737455706461746554696d657374616d705f5f737472696e675f737472696e672072656365697665642076616c75652c0a000000000000000000000000000072756e74696d655f6572726f723a206e6f6e2070617961626c652066756e6374696f6e20676574416e79417373657450726963655f5f737472696e675f737472696e672072656365697665642076616c75652c0a00000000000000000000000072756e74696d655f6572726f723a206e6f6e2070617961626c652066756e6374696f6e20676574416e7941737365745f5f737472696e675f737472696e672072656365697665642076616c75652c0a0041b0120b908002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000009307046e616d6501e5061b000f686173685f6b656363616b5f323536010b6765745f73746f72616765020d64656275675f6d657373616765030b7365745f73746f72616765040d636c6561725f73746f72616765050b7365616c5f72657475726e061463616c6c5f636861696e5f657874656e73696f6e0705696e707574081176616c75655f7472616e7366657272656409085f5f6d656d6370790a085f5f627a65726f380b0a766563746f725f6e65770c085f5f6d616c6c6f630d0b5f5f696e69745f686561700e0875696e74326465630f4950726963654f7261636c65577261707065723a3a50726963654f7261636c65577261707065723a3a66756e6374696f6e3a3a5f6f7261636c65427941737365745f5f61646472657373103d50726963654f7261636c65577261707065723a3a50726963654f7261636c65577261707065723a3a636f6e7374727563746f723a3a6430363536633839114c50726963654f7261636c65577261707065723a3a50726963654f7261636c65577261707065723a3a66756e6374696f6e3a3a6765744f7261636c654b657941737365745f5f61646472657373125150726963654f7261636c65577261707065723a3a50726963654f7261636c65577261707065723a3a66756e6374696f6e3a3a6765744f7261636c654b6579426c6f636b636861696e5f5f61646472657373134d50726963654f7261636c65577261707065723a3a50726963654f7261636c65577261707065723a3a66756e6374696f6e3a3a6765744f7261636c654b657953796d626f6c5f5f61646472657373144850726963654f7261636c65577261707065723a3a50726963654f7261636c65577261707065723a3a66756e6374696f6e3a3a676574417373657450726963655f5f61646472657373154c50726963654f7261636c65577261707065723a3a50726963654f7261636c65577261707065723a3a66756e6374696f6e3a3a676574416e7941737365745f5f737472696e675f737472696e67164950726963654f7261636c65577261707065723a3a50726963654f7261636c65577261707065723a3a66756e6374696f6e3a3a737472696e67546f427974657333325f5f737472696e671718706f6c6b61646f745f6465706c6f795f64697370617463681816706f6c6b61646f745f63616c6c5f646973706174636819066465706c6f791a0463616c6c071201000f5f5f737461636b5f706f696e74657209100200072e726f6461746101042e627373008e010970726f64756365727302086c616e6775616765010143000c70726f6365737365642d62790105636c616e676131352e302e34202868747470733a2f2f6769746875622e636f6d2f736f6c616e612d6c6162732f6c6c766d2d70726f6a6563742e676974203333633336323963616135396235396438663538353733366134613531393461613965393337376429', + compiler: 'solang 0.3.2', + hash: '0x03b6e72dd745ae29cddc8f15ad73b91bd1b32f2c7369b8f4dc8be1c363116740', + language: 'Solidity 0.3.2', }, spec: { constructors: [ @@ -80,14 +79,14 @@ export const priceOracleAbi = { ], default: false, docs: [''], - label: '_oracleByAsset', + label: 'oracleByAsset', mutates: false, payable: false, returnType: { - displayName: ['PriceOracleWrapper', '_oracleByAsset', 'return_type'], + displayName: ['PriceOracleWrapper', 'oracleByAsset', 'return_type'], type: 6, }, - selector: '0xda49fac8', + selector: '0x38163032', }, { args: [ @@ -344,7 +343,7 @@ export const priceOracleAbi = { root_key: '0x00000000', }, }, - name: '_oracleByAsset', + name: 'oracleByAsset', }, ], name: 'PriceOracleWrapper', @@ -435,7 +434,7 @@ export const priceOracleAbi = { def: { tuple: [2, 3, 3], }, - path: ['PriceOracleWrapper', '_oracleByAsset', 'return_type'], + path: ['PriceOracleWrapper', 'oracleByAsset', 'return_type'], }, }, { @@ -588,4 +587,4 @@ export const priceOracleAbi = { }, ], version: '4', -}; +} as const; diff --git a/src/contracts/nabla/Router.ts b/src/contracts/nabla/Router.ts index c128709a..cd1fad9d 100644 --- a/src/contracts/nabla/Router.ts +++ b/src/contracts/nabla/Router.ts @@ -5,15 +5,15 @@ export const routerAbi = { version: '0.0.1', }, source: { - compiler: 'solang 0.3.0', - hash: '0x000a2783517e66e52a665b53e27d2e61d37f4136984b83f245b7d1ffdc7fdb8a', - language: 'Solidity 0.3.0', - wasm: '0x0061736d01000000018c010c60027f7f0060037f7f7f0060047f7f7f7f017f60037f7f7f017f60047f7e7e7f0060047f7f7f7f0060087f7f7e7f7f7f7f7f017f60017f017f6000017f60207f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60237f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f6000000287020e057365616c310b6765745f73746f726167650002057365616c300663616c6c65720000057365616c320b7365745f73746f726167650002057365616c300f686173685f626c616b65325f3235360001057365616c300d6465706f7369745f6576656e740005057365616c300762616c616e63650000057365616c31097365616c5f63616c6c0006057365616c300f686173685f6b656363616b5f3235360001057365616c3007616464726573730000057365616c30036e6f770000057365616c300b7365616c5f72657475726e0001057365616c3005696e7075740000057365616c301176616c75655f7472616e73666572726564000003656e76066d656d6f72790201101003100f010000010307020304040208090a0b0608017f01418080040b071102066465706c6f79001b0463616c6c001b0a81f5020fb50101027f02402002450d00200241016b2002410771220304400340200020012d00003a0000200041016a2100200141016a2101200241016b2102200341016b22030d000b0b4107490d000340200020012d00003a0000200020012d00013a0001200020012d00023a0002200020012d00033a0003200020012d00043a0004200020012d00053a0005200020012d00063a0006200020012d00073a0007200041086a2100200141086a2101200241086b22020d000b0b0ba10101027f02402001450d00200141016b200141077122020440034020004200370300200041086a2100200141016b2101200241016b22020d000b0b4107490d00034020004200370300200041386a4200370300200041306a4200370300200041286a4200370300200041206a4200370300200041186a4200370300200041106a4200370300200041086a4200370300200041406b2100200141086b22010d000b0b0b930101037f4120210302404100450440200041206a21040c010b03402001200341016b220320006a22042d00003a0000200141016a2101200241016b22020d000b0b200441046b210203402001200241036a2d00003a00002001200241026a2d00003a00012001200241016a2d00003a0002200120022d00003a0003200241046b2102200141046a2101200341046b22030d000b0b9f0101037f200241016b024020024103712203450440200120026a21040c010b0340200241016b220220016a220420002d00003a0000200041016a2100200341016b22030d000b0b41034f0440200441046b21030340200341036a20002d00003a0000200341026a20002d00013a0000200341016a20002d00023a0000200320002d00033a0000200041046a2100200341046b2103200241046b22020d000b0b0bb60201037f200020016c220141086a10122204200036020420042000360200200441086a210002402002417f4704402001450d01200141016b2001410771220304400340200020022d00003a0000200041016a2100200241016a2102200141016b2101200341016b22030d000b0b4107490d010340200020022d00003a0000200020022d00013a0001200020022d00023a0002200020022d00033a0003200020022d00043a0004200020022d00053a0005200020022d00063a0006200020022d00073a0007200041086a2100200241086a2102200141086b22010d000b0c010b2001450d00200141016b2001410771220204400340200041003a0000200041016a2100200141016b2101200241016b22020d000b0b4107490d00034020004200370000200041086a2100200141086b22010d000b0b20040b950101047f41808004210103400240200128020c0d00200128020822022000490d002002200041076a41787122026b220441184f0440200120026a41106a22002001280200220336020020030440200320003602040b2000200441106b3602082000410036020c2000200136020420012000360200200120023602080b2001410136020c200141106a0f0b200128020021010c000b000b890301047f200120036a220441086a10122205200436020420052004360200200541086a210402402001450d00200141016b2001410771220604400340200420002d00003a0000200441016a2104200041016a2100200141016b2101200641016b22060d000b0b4107490d000340200420002d00003a0000200420002d00013a0001200420002d00023a0002200420002d00033a0003200420002d00043a0004200420002d00053a0005200420002d00063a0006200420002d00073a0007200441086a2104200041086a2100200141086b22010d000b0b02402003450d00200341016b2003410771220004400340200420022d00003a0000200441016a2104200241016a2102200341016b2103200041016b22000d000b0b4107490d000340200420022d00003a0000200420022d00013a0001200420022d00023a0002200420022d00033a0003200420022d00043a0004200420022d00053a0005200420022d00063a0006200420022d00073a0007200441086a2104200241086a2102200341086b22030d000b0b20050bd102020a7f027e2000411c6a210441082103027f03404100200341004c0d011a200341016b21032004280200200441046b2104450d000b200341016a0b210b2001411c6a21044108210302400340200341004c0d01200341016b21032004280200200441046b2104450d000b200341016a21060b200141046b210c41002101410121074100210503402008200120064e6a21080240200520052006486a220520092001200b4e6a22094d04404200210e0c010b200520096b210a200020084102746a2103200c20054102746a21044200210e0340200e4280808080107c200e200d200d200435020020033502007e7c220d561b210e200341046a2103200441046b2104200a41016b220a0d000b0b0240024020014108480440200220014102746a200d3e02000c010b200d4200520d010b200141016a22014110482107200d422088200e84210d20014110470d010b0b20070b5001017e02402003450d00200341c00071044020012003413f71ad862102420021010c010b20022003ad220486200141c00020036bad88842102200120048621010b20002002370308200020013703000b5001017e02402003450d00200341c00071044020022003413f71ad882101420021020c010b200241c00020036bad8620012003ad220488842101200220048821020b20002002370308200020013703000bb51102197e047f230041f0006b221d2400200041186a2903002106200041106a2903002108200041086a29030021072000290300210a027f02402001290300220f420156200141086a290300220c420052200c501b200141106a2903002210420052200141186a290300220b420052200b5022201b200b201084501b4504404101200fa741016b0d021a200242003703102002420037030820024200370300200241186a4200370300200320083703102003200a37030020032007370308200341186a20063703000c010b20082010852204200a200f85842006200b8522052007200c858484500440200242003703102002420037030820024200370300200241186a420037030020034200370310200341186a420037030020034201370300200342003703080c010b2008200a84200620078484504101200a200f5a2007200c5a2007200c511b200820105a2006200b5a2006200b511b2004200584501b1b04402002200a3703002002200737030820022008370310200241186a200637030020034200370310200341186a420037030020034200370300200342003703080c010b41c0012100027f02402006220450221f450d004180012100200822044200520d0041c0002100200722044200520d0041002200200a2204500d011a0b2000411f413f20044280808080105422001b220141106b20012004422086200420001b220442808080808080c0005422001b220141086b20012004421086200420001b2204428080808080808080015422001b220141046b20012004420886200420001b2204428080808080808080105422001b220141026b20012004420486200420001b2204428080808080808080c0005422001b6a2004420286200420001b423f87a7417f736a0b210041c0012101200b2104201d41306a200f200c4180012000027f02402020450d004180012101201022044200520d0041c0002101200c22044200520d0041002201200f2204500d011a0b2001411f413f20044280808080105422011b221e41106b201e2004422086200420011b220442808080808080c0005422011b221e41086b201e2004421086200420011b2204428080808080808080015422011b221e41046b201e2004420886200420011b2204428080808080808080105422011b221e41026b201e2004420486200420011b2204428080808080808080c0005422011b6a2004420286200420011b423f87a7417f736a0b6b22006b1016201d41e0006a2010200b20001015201d41406b200f200c20004180016b1015201d41d0006a200f200c20001015201d41e8006a290300201d41386a29030084201d41c8006a290300200041800149221e1b201d290360201d29033084201d290340201e1b2109201d41d8006a290300210d201d290350211141c001210120062104027f0240201f450d004180012101200822044200520d0041c0002101200722044200520d0041002201200a2204500d011a0b2001411f413f20044280808080105422011b221f41106b201f2004422086200420011b220442808080808080c0005422011b221f41086b201f2004421086200420011b2204428080808080808080015422011b221f41046b201f2004420886200420011b2204428080808080808080105422011b221f41026b201f2004420486200420011b2204428080808080808080c0005422011b6a2004420286200420011b423f87a7417f736a0b2101200b20001b21042009201020001b210e200d4200201e1b210d20114200201e1b211141c0012100200b2105201d41106a420142002001027f02402020450d004180012100201022054200520d0041c0002100200c22054200520d0041002200200f2205500d011a0b2000411f413f20054280808080105422001b221e41106b201e2005422086200520001b220542808080808080c0005422001b221e41086b201e2005421086200520001b2205428080808080808080015422001b221e41046b201e2005420886200520001b2205428080808080808080105422001b221e41026b201e2005420486200520001b2205428080808080808080c0005422001b6a2005420286200520001b423f87a7417f736a0b6b22004180016b1015201d4201420041800120006b1016201d41206a4201420020001015200e200a2011542007200d542007200d511b2008200e54200420065620042006511b2008200e85200420068584501b221ead2209882004420186201e413f73ad221286842105200d4201862012862011200988842111201d290300201d29031020004180014922011b420020001b2213200988201d41086a290300201d41186a29030020011b420020001b2214420186201286842117201d41286a290300420020011b2215420186201286201d290320420020011b200988842112200e420186201e417f73413f71ad221686200d20098884210e2013420186201686201520098884210d20042009882104201420098821094200211342002114420021154200211603404200200e200a2011542007200e542007200e511b2005200856200420065620042006511b2005200885200420068584501b22001b21184200201120001b211a4200200420001b211b20084200200520001b22195421014200200920001b20168421164200201720001b20158421154200200d20001b20148421144200201220001b2013842113200d423f862012420188842112200e423f8620114201888421112017423f86200d42018884210d2005423f86200e42018884210e2009423f8620174201888421172004423f8620054201888421052009420188210920044201882104200820197d2219200a201a542200200720185420072018511bad221c7d2108200a201a7d220a200f5a200720187d2000ad7d2207200c5a2007200c511b200820105a2006201b7d2001ad7d2019201c54ad7d2206200b5a2006200b511b20082010852006200b8584501b0d000b200320133703002003201437030820032015370310200341186a201637030020022008370310200241186a20063703002002200a370300200220073703080b41000b201d41f0006a24000bb60a01227f230041406a2200240041f8024120360200200041386a4200370300200042003703302000420037032820004200370320200041206a412041800341f802100021024180032d000021034181032d000021044182032d000021054183032d000021064184032d000021074185032d000021084186032d000021094187032d0000210a4188032d0000210b4189032d0000210c418a032d0000210d418b032d0000210e418c032d0000210f418d032d00002110418e032d00002111418f032d000021124190032d000021134191032d000021144192032d000021154193032d000021164194032d000021174195032d000021184196032d000021194197032d0000211a4198032d0000211b4199032d0000211c419a032d0000211d419b032d0000211e419c032d0000211f419d032d00002120419e032d0000212120004100419f032d000020021b3a001f20004100202120021b3a001e20004100202020021b3a001d20004100201f20021b3a001c20004100201e20021b3a001b20004100201d20021b3a001a20004100201c20021b3a001920004100201b20021b3a001820004100201a20021b3a001720004100201920021b3a001620004100201820021b3a001520004100201720021b3a001420004100201620021b3a001320004100201520021b3a001220004100201420021b3a001120004100201320021b3a001020004100201220021b3a000f20004100201120021b3a000e20004100201020021b3a000d20004100200f20021b3a000c20004100200e20021b3a000b20004100200d20021b3a000a20004100200c20021b3a000920004100200b20021b3a000820004100200a20021b3a000720004100200920021b3a000620004100200820021b3a000520004100200720021b3a000420004100200620021b3a000320004100200520021b3a000220004100200420021b3a000120004100200320021b3a000020002d001f210220002d001e210320002d001d210420002d001c210520002d001b210620002d001a210720002d0019210820002d0018210920002d0017210a20002d0016210b20002d0015210c20002d0014210d20002d0013210e20002d0012210f20002d0011211020002d0010211120002d000f211220002d000e211320002d000d211420002d000c211520002d000b211620002d000a211720002d0009211820002d0008211920002d0007211a20002d0006211b20002d0005211c20002d0004211d20002d0003211e20002d0002211f20002d0001212020002d00002121200041206b2201240041f802412036020041800341f8021001200141800329030037000020014188032903003700082001419003290300370010200141980329030037001802400240202120012d0000470d00202020012d0001470d00201f20012d0002470d00201e20012d0003470d00201d20012d0004470d00201c20012d0005470d00201b20012d0006470d00201a20012d0007470d00201920012d0008470d00201820012d0009470d00201720012d000a470d00201620012d000b470d00201520012d000c470d00201420012d000d470d00201320012d000e470d00201220012d000f470d00201120012d0010470d00201020012d0011470d00200f20012d0012470d00200e20012d0013470d00200d20012d0014470d00200c20012d0015470d00200b20012d0016470d00200a20012d0017470d00200920012d0018470d00200820012d0019470d00200720012d001a470d00200620012d001b470d00200520012d001c470d00200420012d001d470d00200320012d001e470d00200220012d001f460d010b000b200041406b240041000b861401277f230041a0016b2223240041f80241203602002023222141d8006a4200370300202142003703502021420037034820214200370340202141406b412041800341f802100021224180032d000021244181032d000021264182032d000021274183032d000021284184032d000021294185032d0000212a4186032d0000212b4187032d0000212c4188032d0000212d4189032d0000212e418a032d0000212f418b032d00002130418c032d00002131418d032d00002132418e032d00002133418f032d000021344190032d000021354191032d000021364192032d000021374193032d000021384194032d000021394195032d0000213a4196032d0000213b4197032d0000213c4198032d0000213d4199032d0000213e419a032d0000213f419b032d00002140419c032d00002141419d032d00002142419e032d00002143419f032d000021442021201f3a001f2021201e3a001e2021201d3a001d2021201c3a001c2021201b3a001b2021201a3a001a202120193a0019202120183a0018202120173a0017202120163a0016202120153a0015202120143a0014202120133a0013202120123a0012202120113a0011202120103a00102021200f3a000f2021200e3a000e2021200d3a000d2021200c3a000c2021200b3a000b2021200a3a000a202120093a0009202120083a0008202120073a0007202120063a0006202120053a0005202120043a0004202120033a0003202120023a0002202120013a0001202120003a0000202141386a4200370300202142003703302021420037032820214200370320202141206a41202021412010021a41204101417f1011222041276a4100204420221b22443a0000202041266a4100204320221b22433a0000202041256a4100204220221b22423a0000202041246a4100204120221b22413a0000202041236a4100204020221b22403a0000202041226a4100203f20221b223f3a0000202041216a4100203e20221b223e3a0000202041206a4100203d20221b223d3a00002020411f6a4100203c20221b223c3a00002020411e6a4100203b20221b223b3a00002020411d6a4100203a20221b223a3a00002020411c6a4100203920221b22393a00002020411b6a4100203820221b22383a00002020411a6a4100203720221b22373a0000202041196a4100203620221b22363a0000202041186a4100203520221b22353a0000202041176a4100203420221b22343a0000202041166a4100203320221b22333a0000202041156a4100203220221b22323a0000202041146a4100203120221b22313a0000202041136a4100203020221b22303a0000202041126a4100202f20221b222f3a0000202041116a4100202e20221b222e3a0000202041106a4100202d20221b222d3a00002020410f6a4100202c20221b222c3a00002020410e6a4100202b20221b222b3a00002020410d6a4100202a20221b222a3a00002020410c6a4100202920221b22293a00002020410b6a4100202820221b22283a00002020410a6a4100202720221b22273a0000202041096a4100202620221b22263a0000202041086a22254100202420221b22453a00004100412d20252020280200410020201b10132222280200410020221b41214f044020222802002124202341206b222022232400202241086a22252024410020221b20201003202341206b2223240020202023100f202141f8006a202341186a2903003703002021202341106a2903003703702021202341086a29030037036820212023290300370360202141e0006a2025412010100b41204101417f10112220410a6a20023a0000202041096a20013a0000202041086a222420003a00002020410b6a20033a00002020410c6a20043a00002020410d6a20053a00002020410e6a20063a00002020410f6a20073a0000202041106a20083a0000202041116a20093a0000202041126a200a3a0000202041136a200b3a0000202041146a200c3a0000202041156a200d3a0000202041166a200e3a0000202041176a200f3a0000202041186a20103a0000202041196a20113a00002020411a6a20123a00002020411b6a20133a00002020411c6a20143a00002020411d6a20153a00002020411e6a20163a00002020411f6a20173a0000202041206a20183a0000202041216a20193a0000202041226a201a3a0000202041236a201b3a0000202041246a201c3a0000202041256a201d3a0000202041266a201e3a0000202041276a201f3a00004130412820242020280200410020201b10132224280200410020241b41214f044020242802002125202341206b222022232400202441086a22462025410020241b20201003202341206b2223240020202023100f20214198016a202341186a2903003703002021202341106a290300370390012021202341086a29030037038801202120232903003703800120214180016a2046412010100b41c1004101417f1011222041096a20453a0000202041086a222541023a00002020410a6a20263a00002020410b6a20273a00002020410c6a20283a00002020410d6a20293a00002020410e6a202a3a00002020410f6a202b3a0000202041106a202c3a0000202041116a202d3a0000202041126a202e3a0000202041136a202f3a0000202041146a20303a0000202041156a20313a0000202041166a20323a0000202041176a20333a0000202041186a20343a0000202041196a20353a00002020411a6a20363a00002020411b6a20373a00002020411c6a20383a00002020411d6a20393a00002020411e6a203a3a00002020411f6a203b3a0000202041206a203c3a0000202041216a203d3a0000202041226a203e3a0000202041236a203f3a0000202041246a20403a0000202041256a20413a0000202041266a20423a0000202041276a20433a0000202041286a20443a0000202041c8006a201f3a0000202041c7006a201e3a0000202041c6006a201d3a0000202041c5006a201c3a0000202041c4006a201b3a0000202041c3006a201a3a0000202041c2006a20193a0000202041c1006a20183a0000202041406b20173a00002020413f6a20163a00002020413e6a20153a00002020413d6a20143a00002020413c6a20133a00002020413b6a20123a00002020413a6a20113a0000202041396a20103a0000202041386a200f3a0000202041376a200e3a0000202041366a200d3a0000202041356a200c3a0000202041346a200b3a0000202041336a200a3a0000202041326a20093a0000202041316a20083a0000202041306a20073a00002020412f6a20063a00002020412e6a20053a00002020412d6a20043a00002020412c6a20033a00002020412b6a20023a00002020412a6a20013a0000202041296a20003a0000202341f0006b220024002000410c3a0000202341ef006b2201410c100e200141e0004120100d202341cf006b202241086a2022280200410020221b100d2023412f6b202441086a2024280200410020241b100d200041e10020252020280200410020201b1004202141a0016a240041000be20802017f017e230041206b2223240041f802411036020041800341f80210050240024002400240024041800329030042005441880329030022244200542024501b2024423f872224420054202450712024501b450440202320003a0000202320013a0001202320023a0002202320033a0003202320043a0004202320053a0005202320063a0006202320073a0007202320083a0008202320093a00092023200a3a000a2023200b3a000b2023200c3a000c2023200d3a000d2023200e3a000e2023200f3a000f202320103a0010202320113a0011202320123a0012202320133a0013202320143a0014202320153a0015202320163a0016202320173a0017202320183a0018202320193a00192023201a3a001a2023201b3a001b2023201c3a001c2023201d3a001d2023201e3a001e2023201f3a001f20202802002101202341106b220022022400200042003703082000420037030041f802418080023602004100202342002000202041086a2001410020201b41800341f802100641f802280200410141800310112100200241106b220124000440024002400240024002400240024002400240024002400240024002402000280200410020001b044041012100410d410141a00110112201280200410020011b41ffffffff034b0d110240410d410141a00110112201280200410020011b413f4d0d0041042100410d410141a00110112201280200410020011b41ffff004b0d00410221000b20002000410d410141a00110112201280200410020011b6a22014b0d012001200141046a22004b0d0220004101417f1011220241086a41a0f38dc600360200410d410141a00110112200280200410020001b220041ffffffff034d0d05000b2021280200410020211b41ffffffff034b0d14027f41012021280200410020211b413f4d0d001a41042021280200410020211b41ffff004b0d001a41020b220020002021280200410020211b6a22004b0d022000200041046a22014b0d0320014101417f1011220241086a41a0f38dc6003602002021280200410020211b220041ffffffff034d0d05000b000b000b000b000b2000413f4b0d01200041ffffffff03712000470d022002410c6a2000410274360200410121010c0e0b2000413f4b0d02200041ffffffff03712000470d032002410c6a2000410274360200410121010c0c0b200041ffff004b0d03200041ffffffff03712000470d04410221012002410c6a20004102744101723602000c0c0b000b200041ffff004b0d03200041ffffffff03712000470d04410221012002410c6a20004102744101723602000c090b000b2000200041ffffffff03714604402002410c6a2000410274410272360200410421010c090b000b000b2000200041ffffffff03714604402002410c6a2000410274410272360200410421010c060b000b000b200120003602000c020b000b000b20222001280200360200202341206a240041000f0b200120026a410c6a202141086a2000100d000b200120026a410c6a410d410141a001101141086a2000100d000b000bc3ac02028c017f1d7e230041206b22002400418080044100360200418480044100360200418c80044100360200418880043f00411074419080046b36020041f8024180800236020041800341f802100b41f40241f80228020022043602002000411036020c200041106a2000410c6a100c2000290310218c01200041186a290300218e0141002100230041406a220724000240024002400240024002400240024002400240024002400240024002400240024002400240200441034d0d0041f0024180032802002201360200024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200141e6ceb6e27d4c0440200141b7c7f8dc7b4c0440200141f2fb8fdf78460d05200141f1a0e1b07a460d04200141dcaeeada7b470d26208c01208e0184500d03000b200141b8c7f8dc7b460d0a20014186afc4a97d460d0120014186bcd3c47d470d25208c01208e0184500d0e000b200141b7dadfc8034c0440200141e7ceb6e27d460d05200141f28c96af7e460d06200141b8acc09103470d25208c01208e0184500d0f000b20014183adadce054c0440200141b8dadfc803460d09200141bf96a1d503470d25208c01208e0184500d08000b20014184adadce05460d062001418dcbaede05470d24208c01208e0184500d0a000b41f802412036020041800341f80210012007419803290300228c0137003820074190032903002290013700302007418803290300228e013700282007418003290300229101370020209101a720072d002120072d002220072d002320072d002420072d002520072d002620072d0027208e01a720072d002920072d002a20072d002b20072d002c20072d002d20072d002e20072d002f209001a720072d003120072d003220072d003320072d003420072d003520072d003620072d0037208c01a720072d003920072d003a20072d003b20072d003c20072d003d20072d003e20072d003f101922010440200121000b2000047f200005200741386a22004200370300200741186a420037030020074200370330200742003703282007420137032020074200370310200742003703082007420137030020074120200741206a2201412010021a20004200370300200741003a0000200742003703302007420037032820074202370320200141202007410110021a41000b0d350c320b200741106b2200240041f8024101360200200741386a42003703002007420037033020074200370328200742023703202000200741206a412041800341f8021000047f4100054180032d00000b4101713a000020002d0000210041014101417f101141086a220120004101713a0000410020014101100a0c340b208c01208e01844200520d2f0240101822000d00410021004100210141004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100101922040440200421010b2001450d00200121000b20000d330c300b208c01208e01844200520d2d2004200441046b2200490d0720004120490d08200041204d0d13000b208c01208e01844200520d2b2004200441046b2200490d0a200041c000490d0b200041c0004d0d13000b208c01208e01844200520d292004200441046b2200490d0b200041c000490d0c200041c0004d0d13000b208c01208e01844200520d2710182200047f20000541f8024101360200200741386a42003703002007420037033020074200370328200742023703202007200741206a412041800341f8021000047f4100054180032d00000b41017122003a000020000d1f230041d0006b22002400200041406b4200370300200042003703382000420037033020004202370328200041013a004f200041286a4120200041cf006a410110021a41f802412036020041800341f8021001200041800329030037000820004188032903003700102000419003290300370018200041980329030037002020002d0027210820002d0026210920002d0025210a20002d0024210c20002d0023210d20002d0022210e20002d0021210f20002d0020211020002d001f211120002d001e211220002d001d211320002d001c211420002d001b211520002d001a211620002d0019211720002d0018211820002d0017211920002d0016211a20002d0015211b20002d0014211c20002d0013211d20002d0012211e20002d0011211f20002d0010212020002d000f212120002d000e212220002d000d212320002d000c212420002d000b212520002d000a210b20002d0009210320002d0008210241214101417f1011220441086a220541003a0000200541016a220120033a0001200120023a00002001200b3a0002200120253a0003200120243a0004200120233a0005200120223a0006200120213a0007200120203a00082001201f3a00092001201e3a000a2001201d3a000b2001201c3a000c2001201b3a000d2001201a3a000e200120193a000f200120183a0010200120173a0011200120163a0012200120153a0013200120143a0014200120133a0015200120123a0016200120113a0017200120103a00182001200f3a00192001200e3a001a2001200d3a001b2001200c3a001c2001200a3a001d200120093a001e200120083a001f200041306b22012400200141043a00002000412f6b22084104100e200841b0014120100d2001412120052004280200410020041b1004200041d0006a240041000b0d2f0c2c0b10182200047f20000541f8024101360200200741386a42003703002007420037033020074200370328200742023703202007200741206a412041800341f8021000047f4100054180032d00000b41017122003a00002000450d1f230041d0006b22002400200041406b4200370300200042003703382000420037033020004202370328200041003a004f200041286a4120200041cf006a410110021a41f802412036020041800341f8021001200041800329030037000820004188032903003700102000419003290300370018200041980329030037002020002d0027210820002d0026210920002d0025210a20002d0024210c20002d0023210d20002d0022210e20002d0021210f20002d0020211020002d001f211120002d001e211220002d001d211320002d001c211420002d001b211520002d001a211620002d0019211720002d0018211820002d0017211920002d0016211a20002d0015211b20002d0014211c20002d0013211d20002d0012211e20002d0011211f20002d0010212020002d000f212120002d000e212220002d000d212320002d000c212420002d000b212520002d000a210b20002d0009210320002d0008210241214101417f1011220441086a220541013a0000200541016a220120033a0001200120023a00002001200b3a0002200120253a0003200120243a0004200120233a0005200120223a0006200120213a0007200120203a00082001201f3a00092001201e3a000a2001201d3a000b2001201c3a000c2001201b3a000d2001201a3a000e200120193a000f200120183a0010200120173a0011200120163a0012200120153a0013200120143a0014200120133a0015200120123a0016200120113a0017200120103a00182001200f3a00192001200e3a001a2001200d3a001b2001200c3a001c2001200a3a001d200120093a001e200120083a001f200041306b22012400200141043a00002000412f6b22084104100e200841d0014120100d2001412120052004280200410020041b1004200041d0006a240041000b0d2e0c2b0b208c01208e01844200520d24200441046b220520044b0d0a200541c000490d0b419c03290300219101419403290300218e01418c03290300219001418403290300218c0141a40329030021950141bc0329030021970141b40329030021980141ac0329030021960141c4032d000022004103710e03151617110b208c01208e01844200520d22200441046b220020044b0d0b20004120490d0c419c03290300219a01419403290300219b01418c03290300219401418403290300219c0141a4032d000022014103710e03171819110b200741206b2200240041f8024120360200200741386a4200370300200742003703302007420037032820074200370320200741206a412041800341f802100021014180032d000021044181032d000021054182032d000021084183032d000021094184032d0000210a4185032d0000210c4186032d0000210d4187032d0000210e4188032d0000210f4189032d00002110418a032d00002111418b032d00002112418c032d00002113418d032d00002114418e032d00002115418f032d000021164190032d000021174191032d000021184192032d000021194193032d0000211a4194032d0000211b4195032d0000211c4196032d0000211d4197032d0000211e4198032d0000211f4199032d00002120419a032d00002121419b032d00002122419c032d00002123419d032d00002124419e032d0000212520004100419f032d000020011b3a001f20004100202520011b3a001e20004100202420011b3a001d20004100202320011b3a001c20004100202220011b3a001b20004100202120011b3a001a20004100202020011b3a001920004100201f20011b3a001820004100201e20011b3a001720004100201d20011b3a001620004100201c20011b3a001520004100201b20011b3a001420004100201a20011b3a001320004100201920011b3a001220004100201820011b3a001120004100201720011b3a001020004100201620011b3a000f20004100201520011b3a000e20004100201420011b3a000d20004100201320011b3a000c20004100201220011b3a000b20004100201120011b3a000a20004100201020011b3a000920004100200f20011b3a000820004100200e20011b3a000720004100200d20011b3a000620004100200c20011b3a000520004100200a20011b3a000420004100200920011b3a000320004100200820011b3a000220004100200520011b3a000120004100200420011b3a00000c290b000b000b2004200441046b2200490d19200041204f0440200041204d0d0f000b000b2004200441046b2200490d19200041204f0440200041204d0d0f000b000b000b000b000b000b000b000b000b000b41a3032d0000210141a2032d0000210541a1032d0000210841a0032d00002109419f032d0000210a419e032d0000210c419d032d0000210d419c032d0000210e419b032d0000210f419a032d000021104199032d000021114198032d000021124197032d000021134196032d000021144195032d000021154194032d000021164193032d000021174192032d000021184191032d000021194190032d0000211a418f032d0000211b418e032d0000211c418d032d0000211d418c032d0000211e418b032d0000211f418a032d000021204189032d000021214188032d000021224187032d000021234186032d000021244185032d000021254184032d0000210b0240101822000d002001200b202572202472202372202272202172202072201f72201e72201d72201c72201b72201a72201972201872201772201672201572201472201372201272201172201072200f72200e72200d72200c72200a7220097220087220057272450d124100210041002104200b202520242023202220212020201f201e201d201c201b201a2019201820172016201520142013201220112010200f200e200d200c200a2009200820052001101922010440200121040b2004450d00200421000b20000d1e0c1b0b41a3032d0000210141a2032d0000210441a1032d0000210541a0032d00002108419f032d00002109419e032d0000210a419d032d0000210c419c032d0000210d419b032d0000210e419a032d0000210f4199032d000021104198032d000021114197032d000021124196032d000021134195032d000021144194032d000021154193032d000021164192032d000021174191032d000021184190032d00002119418f032d0000211a418e032d0000211b418d032d0000211c418c032d0000211d418b032d0000211e418a032d0000211f4189032d000021204188032d000021214187032d000021224186032d000021234185032d000021244184032d0000212541c3032d0000210b41c2032d0000210341c1032d0000210241c0032d0000210641bf032d0000212841be032d0000214341bd032d0000214741bc032d0000212641bb032d0000212941ba032d0000212c41b9032d0000212d41b8032d0000212e41b7032d0000212f41b6032d0000213041b5032d0000213141b4032d0000213241b3032d0000213341b2032d0000213441b1032d0000213541b0032d0000213641af032d0000213741ae032d0000213841ad032d0000213941ac032d0000213a41ab032d0000213b41aa032d0000213c41a9032d0000213d41a8032d0000213e41a7032d0000213f41a6032d0000214041a5032d0000214141a4032d000021420240101822000d0023002200024020012024202572202372202272202172202072201f72201e72201d72201c72201b72201a72201972201872201772201672201572201472201372201272201172201072200f72200e72200d72200c72200a72200972200872200572200472720440200b2041204272204072203f72203e72203d72203c72203b72203a72203972203872203772203672203572203472203372203272203172203072202f72202e72202d72202c72202972202672204772204372202872200672200272200372720d01000b000b200041406a22002400200041186a4200370300200042003703102000420037030820004204370300200041206a20253a0000200041216a20243a0000200041226a20233a0000200041236a20223a0000200041246a20213a0000200041256a20203a0000200041266a201f3a0000200041276a201e3a0000200041286a201d3a0000200041296a201c3a00002000412a6a201b3a00002000412b6a201a3a00002000412c6a20193a00002000412d6a20183a00002000412e6a20173a00002000412f6a20163a0000200041306a20153a0000200041316a20143a0000200041326a20133a0000200041336a20123a0000200041346a20113a0000200041356a20103a0000200041366a200f3a0000200041376a200e3a0000200041386a200d3a0000200041396a200c3a00002000413a6a200a3a00002000413b6a20093a00002000413c6a20083a00002000413d6a20053a00002000413e6a20043a00002000413f6a20013a0000200041206b22012400200041c000200110072001290300218c01200141086a290300219001200141106a290300218e01200141186a290300219101200141206b22012400200141206b220024002000200b3a001f200020033a001e200020023a001d200020063a001c200020283a001b200020433a001a200020473a0019200020263a0018200020293a00172000202c3a00162000202d3a00152000202e3a00142000202f3a0013200020303a0012200020313a0011200020323a0010200020333a000f200020343a000e200020353a000d200020363a000c200020373a000b200020383a000a200020393a00092000203a3a00082000203b3a00072000203c3a00062000203d3a00052000203e3a00042000203f3a0003200020403a0002200020413a0001200020423a0000200141186a2091013703002001208e0137031020012090013703082001208c01370300200141202000412010021a2400410022000d000b20000d1d0c1a0b41a3032d0000210541a2032d0000210841a1032d0000210941a0032d0000210a419f032d0000210c419e032d0000210d419d032d0000210e419c032d0000210f419b032d00002110419a032d000021114199032d000021124198032d000021134197032d000021144196032d000021154195032d000021164194032d000021174193032d000021184192032d000021194191032d0000211a4190032d0000211b418f032d0000211c418e032d0000211d418d032d0000211e418c032d0000211f418b032d00002120418a032d000021214189032d000021224188032d000021234187032d000021244186032d000021254185032d0000210b4184032d0000210341c3032d0000210241c2032d0000210641c1032d0000212841c0032d0000214341bf032d0000214741be032d0000212641bd032d0000212941bc032d0000212c41bb032d0000212d41ba032d0000212e41b9032d0000212f41b8032d0000213041b7032d0000213141b6032d0000213241b5032d0000213341b4032d0000213441b3032d0000213541b2032d0000213641b1032d0000213741b0032d0000213841af032d0000213941ae032d0000213a41ad032d0000213b41ac032d0000213c41ab032d0000213d41aa032d0000213e41a9032d0000213f41a8032d0000214041a7032d0000214141a6032d0000214241a5032d0000214441a4032d000021460240101822000d0023004190026b2200240002400240024002400240024020052003200b72202572202472202372202272202172202072201f72201e72201d72201c72201b72201a72201972201872201772201672201572201472201372201272201172201072200f72200e72200d72200c72200a7220097220087272044020022044204672204272204172204072203f72203e72203d72203c72203b72203a72203972203872203772203672203572203472203372203272203172203072202f72202e72202d72202c7220297220267220477220437220287220067272450d01200041406a22012400200141186a4200370300200142003703102001420037030820014204370300200141206a20033a0000200141216a200b3a0000200141226a20253a0000200141236a20243a0000200141246a20233a0000200141256a20223a0000200141266a20213a0000200141276a20203a0000200141286a201f3a0000200141296a201e3a00002001412a6a201d3a00002001412b6a201c3a00002001412c6a201b3a00002001412d6a201a3a00002001412e6a20193a00002001412f6a20183a0000200141306a20173a0000200141316a20163a0000200141326a20153a0000200141336a20143a0000200141346a20133a0000200141356a20123a0000200141366a20113a0000200141376a20103a0000200141386a200f3a0000200141396a200e3a00002001413a6a200d3a00002001413b6a200c3a00002001413c6a200a3a00002001413d6a20093a00002001413e6a20083a00002001413f6a20053a0000200141206b22042400200141c000200410072004290300218c01200441086a290300218e01200441106a290300219101200441186a290300219801200441206b22042400200441186a20980137030020042091013703102004208e013703082004208c0137030041f80241203602002004412041800341f8021000210141004180032d000020011b41004181032d000020011b7241004182032d000020011b7241004183032d000020011b7241004184032d000020011b7241004185032d000020011b7241004186032d000020011b7241004187032d000020011b7241004188032d000020011b7241004189032d000020011b724100418a032d000020011b724100418b032d000020011b724100418c032d000020011b724100418d032d000020011b724100418e032d000020011b724100418f032d000020011b7241004190032d000020011b7241004191032d000020011b7241004192032d000020011b7241004193032d000020011b7241004194032d000020011b7241004195032d000020011b7241004196032d000020011b7241004197032d000020011b7241004198032d000020011b7241004199032d000020011b724100419a032d000020011b724100419b032d000020011b724100419c032d000020011b724100419d032d000020011b724100419e032d000020011b724100419f032d000020011b7241ff0171450d02200441406a22012400200141186a4200370300200142003703102001420037030820014203370300200141206a20033a0000200141216a200b3a0000200141226a20253a0000200141236a20243a0000200141246a20233a0000200141256a20223a0000200141266a20213a0000200141276a20203a0000200141286a201f3a0000200141296a201e3a00002001412a6a201d3a00002001412b6a201c3a00002001412c6a201b3a00002001412d6a201a3a00002001412e6a20193a00002001412f6a20183a0000200141306a20173a0000200141316a20163a0000200141326a20153a0000200141336a20143a0000200141346a20133a0000200141356a20123a0000200141366a20113a0000200141376a20103a0000200141386a200f3a0000200141396a200e3a00002001413a6a200d3a00002001413b6a200c3a00002001413c6a200a3a00002001413d6a20093a00002001413e6a20083a00002001413f6a20053a0000200141206b22042400200141c000200410072004290300218c01200441086a290300218e01200441106a290300219101200441186a290300219801200441206b22042400200441206b220122272400200120023a001f200120063a001e200120283a001d200120433a001c200120473a001b200120263a001a200120293a00192001202c3a00182001202d3a00172001202e3a00162001202f3a0015200120303a0014200120313a0013200120323a0012200120333a0011200120343a0010200120353a000f200120363a000e200120373a000d200120383a000c200120393a000b2001203a3a000a2001203b3a00092001203c3a00082001203d3a00072001203e3a00062001203f3a0005200120403a0004200120413a0003200120423a0002200120443a0001200120463a0000200441186a20980137030020042091013703102004208e013703082004208c01370300200441202001412010021a41c4004101417f1011212b200041b3cffaca0036020c2000410c6a202b41086a220441041010200441046a220120443a0001200120463a0000200120423a0002200120413a0003200120403a00042001203f3a00052001203e3a00062001203d3a00072001203c3a00082001203b3a00092001203a3a000a200120393a000b200120383a000c200120373a000d200120363a000e200120353a000f200120343a0010200120333a0011200120323a0012200120313a0013200120303a00142001202f3a00152001202e3a00162001202d3a00172001202c3a0018200120293a0019200120263a001a200120473a001b200120433a001c200120283a001d200120063a001e200120023a001f4280022198014202219101200041a0016a21014200218c014201218f0102400340209801a7410171044020004188016a209501370300200041e8006a208d0137030020002091013703702000208f01370350200020900137037820002099013703582000209701370380012000209201370360200041d0006a200041f0006a20004190016a10140d06200129030021920120004198016a290300219901200029039001218f01200041a8016a290300218d010b209601423f8620980142018884229801209301423f86208c0142018884228e0184208c01423f86209601420188842296012093014201882293018484500d01200041e8016a209501370300200041c8016a20950137030020002091013703d00120002091013703b00120002090013703d80120002090013703b80120002097013703e00120002097013703c001200041b0016a200041d0016a200041f0016a101420004188026a29030021950120004180026a290300219701200041f8016a29030021900120002903f001219101208e01218c01450d000b000b2000208f0137031020002099013703182000209201370320200041286a208d01370300209201208f015022012099015071222aad228c017d22900120920156208d01208d01208c0120920156ad7d228e0154208c01209201581b208f0142017d228c01208f01562099012001ad7d22910120990156208f014200521b202a1b0d04200441246a22012091013703082001208c013703002001209001370310200141186a208e01370300200020233a0034200020243a0033200020253a00322000200b3a0031200020033a0030200020223a0035200020213a0036200020203a00372000201f3a00382000201e3a00392000201d3a003a2000201c3a003b2000201b3a003c2000201a3a003d200020193a003e200020183a003f200020173a0040200020163a0041200020153a0042200020143a0043200020133a0044200020123a0045200020113a0046200020103a00472000200f3a00482000200e3a00492000200d3a004a2000200c3a004b2000200a3a004c200020093a004d200020083a004e200020053a004f202b2802002101202741106b22042400200442003703082004420037030041f802418080023602004100200041306a42002004202b41086a20014100202b1b41800341f80210060d0541c1004101417f1011222b41086a222741033a0000202741016a220120443a0001200120463a0000200120423a0002200120413a0003200120403a00042001203f3a00052001203e3a00062001203d3a00072001203c3a00082001203b3a00092001203a3a000a200120393a000b200120383a000c200120373a000d200120363a000e200120353a000f200120343a0010200120333a0011200120323a0012200120313a0013200120303a00142001202f3a00152001202e3a00162001202d3a00172001202c3a0018200120293a0019200120263a001a200120473a001b200120433a001c200120283a001d200120063a001e200120023a001f0c060b000b000b000b000b000b000b202741216a2201200b3a0001200120033a0000200120253a0002200120243a0003200120233a0004200120223a0005200120213a0006200120203a00072001201f3a00082001201e3a00092001201d3a000a2001201c3a000b2001201b3a000c2001201a3a000d200120193a000e200120183a000f200120173a0010200120163a0011200120153a0012200120143a0013200120133a0014200120123a0015200120113a0016200120103a00172001200f3a00182001200e3a00192001200d3a001a2001200c3a001b2001200a3a001c200120093a001d200120083a001e200120053a001f200441306b22012400200141043a00002004412f6b22044104100e200441f0014120100d20014121202b41086a202b2802004100202b1b100420004190026a2400410022000d000b20000d1c0c190b000b000b41a3032d0000210541a2032d0000210841a1032d0000210941a0032d0000210a419f032d0000210c419e032d0000210d419d032d0000210e419c032d0000210f419b032d00002110419a032d000021114199032d000021124198032d000021134197032d000021144196032d000021154195032d000021164194032d000021174193032d000021184192032d000021194191032d0000211a4190032d0000211b418f032d0000211c418e032d0000211d418d032d0000211e418c032d0000211f418b032d00002120418a032d000021214189032d000021224188032d000021234187032d000021244186032d000021254185032d0000210b4184032d00002103200741206b22002400230041406a22042400200441406a22012400200141186a4200370300200142003703102001420037030820014203370300200141206a20033a0000200141216a200b3a0000200141226a20253a0000200141236a20243a0000200141246a20233a0000200141256a20223a0000200141266a20213a0000200141276a20203a0000200141286a201f3a0000200141296a201e3a00002001412a6a201d3a00002001412b6a201c3a00002001412c6a201b3a00002001412d6a201a3a00002001412e6a20193a00002001412f6a20183a0000200141306a20173a0000200141316a20163a0000200141326a20153a0000200141336a20143a0000200141346a20133a0000200141356a20123a0000200141366a20113a0000200141376a20103a0000200141386a200f3a0000200141396a200e3a00002001413a6a200d3a00002001413b6a200c3a00002001413c6a200a3a00002001413d6a20093a00002001413e6a20083a00002001413f6a20053a0000200141c000200441206a100741f8024120360200200441186a200441386a2903003703002004200441306a2903003703102004200441286a290300370308200420042903203703002004412041800341f802100021014180032d000021054181032d000021084182032d000021094183032d0000210a4184032d0000210c4185032d0000210d4186032d0000210e4187032d0000210f4188032d000021104189032d00002111418a032d00002112418b032d00002113418c032d00002114418d032d00002115418e032d00002116418f032d000021174190032d000021184191032d000021194192032d0000211a4193032d0000211b4194032d0000211c4195032d0000211d4196032d0000211e4197032d0000211f4198032d000021204199032d00002121419a032d00002122419b032d00002123419c032d00002124419d032d00002125419e032d0000210b20004100419f032d000020011b3a001f20004100200b20011b3a001e20004100202520011b3a001d20004100202420011b3a001c20004100202320011b3a001b20004100202220011b3a001a20004100202120011b3a001920004100202020011b3a001820004100201f20011b3a001720004100201e20011b3a001620004100201d20011b3a001520004100201c20011b3a001420004100201b20011b3a001320004100201a20011b3a001220004100201920011b3a001120004100201820011b3a001020004100201720011b3a000f20004100201620011b3a000e20004100201520011b3a000d20004100201420011b3a000c20004100201320011b3a000b20004100201220011b3a000a20004100201120011b3a000920004100201020011b3a000820004100200f20011b3a000720004100200e20011b3a000620004100200d20011b3a000520004100200c20011b3a000420004100200a20011b3a000320004100200920011b3a000220004100200820011b3a000120004100200520011b3a0000200441406b24000c170b41a3032d0000210541a2032d0000210841a1032d0000210941a0032d0000210a419f032d0000210c419e032d0000210d419d032d0000210e419c032d0000210f419b032d00002110419a032d000021114199032d000021124198032d000021134197032d000021144196032d000021154195032d000021164194032d000021174193032d000021184192032d000021194191032d0000211a4190032d0000211b418f032d0000211c418e032d0000211d418d032d0000211e418c032d0000211f418b032d00002120418a032d000021214189032d000021224188032d000021234187032d000021244186032d000021254185032d0000210b4184032d00002103200741206b22002400230041406a22042400200441406a22012400200141186a4200370300200142003703102001420037030820014204370300200141206a20033a0000200141216a200b3a0000200141226a20253a0000200141236a20243a0000200141246a20233a0000200141256a20223a0000200141266a20213a0000200141276a20203a0000200141286a201f3a0000200141296a201e3a00002001412a6a201d3a00002001412b6a201c3a00002001412c6a201b3a00002001412d6a201a3a00002001412e6a20193a00002001412f6a20183a0000200141306a20173a0000200141316a20163a0000200141326a20153a0000200141336a20143a0000200141346a20133a0000200141356a20123a0000200141366a20113a0000200141376a20103a0000200141386a200f3a0000200141396a200e3a00002001413a6a200d3a00002001413b6a200c3a00002001413c6a200a3a00002001413d6a20093a00002001413e6a20083a00002001413f6a20053a0000200141c000200441206a100741f8024120360200200441186a200441386a2903003703002004200441306a2903003703102004200441286a290300370308200420042903203703002004412041800341f802100021014180032d000021054181032d000021084182032d000021094183032d0000210a4184032d0000210c4185032d0000210d4186032d0000210e4187032d0000210f4188032d000021104189032d00002111418a032d00002112418b032d00002113418c032d00002114418d032d00002115418e032d00002116418f032d000021174190032d000021184191032d000021194192032d0000211a4193032d0000211b4194032d0000211c4195032d0000211d4196032d0000211e4197032d0000211f4198032d000021204199032d00002121419a032d00002122419b032d00002123419c032d00002124419d032d00002125419e032d0000210b20004100419f032d000020011b3a001f20004100200b20011b3a001e20004100202520011b3a001d20004100202420011b3a001c20004100202320011b3a001b20004100202220011b3a001a20004100202120011b3a001920004100202020011b3a001820004100201f20011b3a001720004100201e20011b3a001620004100201d20011b3a001520004100201c20011b3a001420004100201b20011b3a001320004100201a20011b3a001220004100201920011b3a001120004100201820011b3a001020004100201720011b3a000f20004100201620011b3a000e20004100201520011b3a000d20004100201420011b3a000c20004100201320011b3a000b20004100201220011b3a000a20004100201120011b3a000920004100201020011b3a000820004100200f20011b3a000720004100200e20011b3a000620004100200d20011b3a000520004100200c20011b3a000420004100200a20011b3a000320004100200920011b3a000220004100200820011b3a000120004100200520011b3a0000200441406b24000c160b20004102762101410121040c0c0b4102210441c4032f010041027621010c0b0b41c4032802004102762101410421040c0a0b20014102762101410121040c080b4102210441a4032f010041027621010c070b4104210441a40328020041027621010c060b000b000b000b000b000b000b024002400240024002400240024002402000200441206a4f044020014120417f10112105200141ffffff3f712001470d01200441206a220820014105746a22092008490d0220002009490d03200141ffffff3f712001470d04200541086a200441a4036a2001410574100d200141ffffff3f712001470d052004200141057422016a22042001490d06200441206a22014120490d07200020014d0d08000b000b000b000b000b000b000b000b000b200741206b22082400027f230041e0066b220024000240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002402005280200410020051b41024604402005280200410020051b450d012005280200410020051b41014d0d02200541086a2d0000200541286a2d000046200541096a2d0000200541296a2d000046712005410a6a2d00002005412a6a2d000046712005410b6a2d00002005412b6a2d000046712005410c6a2d00002005412c6a2d000046712005410d6a2d00002005412d6a2d000046712005410e6a2d00002005412e6a2d000046712005410f6a2d00002005412f6a2d00004671200541106a2d0000200541306a2d00004671200541116a2d0000200541316a2d00004671200541126a2d0000200541326a2d00004671200541136a2d0000200541336a2d00004671200541146a2d0000200541346a2d00004671200541156a2d0000200541356a2d00004671200541166a2d0000200541366a2d00004671200541176a2d0000200541376a2d00004671200541186a2d0000200541386a2d00004671200541196a2d0000200541396a2d000046712005411a6a2d00002005413a6a2d000046712005411b6a2d00002005413b6a2d000046712005411c6a2d00002005413c6a2d000046712005411d6a2d00002005413d6a2d000046712005411e6a2d00002005413e6a2d000046712005411f6a2d00002005413f6a2d00004671200541206a2d0000200541406b2d00004671200541216a2d0000200541c1006a2d00004671200541226a2d0000200541c2006a2d00004671200541236a2d0000200541c3006a2d00004671200541246a2d0000200541c4006a2d00004671200541256a2d0000200541c5006a2d00004671200541266a2d0000200541c6006a2d00004671200541276a2d0000200541c7006a2d000046710d032005280200410020051b450d042005280200410020051b41014d0d05200541276a2d00002109200541266a2d0000210a200541256a2d0000210c200541246a2d0000210d200541236a2d0000210e200541226a2d0000210f200541216a2d00002110200541206a2d000021112005411f6a2d000021122005411e6a2d000021132005411d6a2d000021142005411c6a2d000021152005411b6a2d000021162005411a6a2d00002117200541196a2d00002118200541186a2d00002119200541176a2d0000211a200541166a2d0000211b200541156a2d0000211c200541146a2d0000211d200541136a2d0000211e200541126a2d0000211f200541116a2d00002120200541106a2d000021212005410f6a2d000021222005410e6a2d000021232005410d6a2d000021242005410c6a2d000021252005410b6a2d0000210b2005410a6a2d00002103200541096a2d00002102200541086a2d00002106200541c7006a2d00002128200541c6006a2d00002143200541c5006a2d00002147200541c4006a2d00002126200541c3006a2d00002129200541c2006a2d0000212c200541c1006a2d0000212d200541406b2d0000212e2005413f6a2d0000212f2005413e6a2d000021302005413d6a2d000021312005413c6a2d000021322005413b6a2d000021332005413a6a2d00002134200541396a2d00002135200541386a2d00002136200541376a2d00002137200541366a2d00002138200541356a2d00002139200541346a2d0000213a200541336a2d0000213b200541326a2d0000213c200541316a2d0000213d200541306a2d0000213e2005412f6a2d0000213f2005412e6a2d000021402005412d6a2d000021412005412c6a2d000021422005412b6a2d000021442005412a6a2d00002146200541296a2d0000212b200541286a2d00002105200041406a22012400200141186a4200370300200142003703102001420037030820014204370300200141206a20063a0000200141216a20023a0000200141226a20033a0000200141236a200b3a0000200141246a20253a0000200141256a20243a0000200141266a20233a0000200141276a20223a0000200141286a20213a0000200141296a20203a00002001412a6a201f3a00002001412b6a201e3a00002001412c6a201d3a00002001412d6a201c3a00002001412e6a201b3a00002001412f6a201a3a0000200141306a20193a0000200141316a20183a0000200141326a20173a0000200141336a20163a0000200141346a20153a0000200141356a20143a0000200141366a20133a0000200141376a20123a0000200141386a20113a0000200141396a20103a00002001413a6a200f3a00002001413b6a200e3a00002001413c6a200d3a00002001413d6a200c3a00002001413e6a200a3a00002001413f6a20093a0000200141206b22042400200141c000200410072004290300218c01200441086a290300219001200441106a290300218e01200441186a290300218d01200441206b220122272400200141186a208d013703002001208e0137031020012090013703082001208c0137030041f80241203602002001412041800341f802100021044180032d0000212a4181032d000021484182032d000021494183032d0000214c4184032d0000214a4185032d0000214d4186032d0000214e4187032d0000214f4188032d000021504189032d00002151418a032d00002152418b032d00002153418c032d00002154418d032d00002155418e032d00002156418f032d000021574190032d000021584191032d000021594192032d0000215a4193032d0000215b4194032d0000215c4195032d0000215d4196032d0000215e4197032d0000215f4198032d000021604199032d00002161419a032d00002162419b032d00002163419c032d00002164419d032d00002165419e032d00002166419f032d0000216741244101417f1011210120004187dee59a7b360204200041046a200141086a2268410410102001412b6a20093a00002001412a6a200a3a0000200141296a200c3a0000200141286a200d3a0000200141276a200e3a0000200141266a200f3a0000200141256a20103a0000200141246a20113a0000200141236a20123a0000200141226a20133a0000200141216a20143a0000200141206a20153a00002001411f6a20163a00002001411e6a20173a00002001411d6a20183a00002001411c6a20193a00002001411b6a201a3a00002001411a6a201b3a0000200141196a201c3a0000200141186a201d3a0000200141176a201e3a0000200141166a201f3a0000200141156a20203a0000200141146a20213a0000200141136a20223a0000200141126a20233a0000200141116a20243a0000200141106a20253a00002001410f6a200b3a00002001410e6a20033a00002001410d6a20023a00002001410c6a20063a000020004100206720041b3a002720004100206620041b3a002620004100206520041b3a002520004100206420041b3a002420004100206320041b3a002320004100206220041b3a002220004100206120041b3a002120004100206020041b3a002020004100205f20041b3a001f20004100205e20041b3a001e20004100205d20041b3a001d20004100205c20041b3a001c20004100205b20041b3a001b20004100205a20041b3a001a20004100205920041b3a001920004100205820041b3a001820004100205720041b3a001720004100205620041b3a001620004100205520041b3a001520004100205420041b3a001420004100205320041b3a001320004100205220041b3a001220004100205120041b3a001120004100205020041b3a001020004100204f20041b3a000f20004100204e20041b3a000e20004100204d20041b3a000d20004100204a20041b3a000c20004100204c20041b3a000b20004100204920041b3a000a20004100204820041b3a000920004100202a20041b3a00082001280200212a202741106b22042400200442003703082004420037030041f802418080023602004100200041086a420020042068202a410020011b41800341f80210060d0641f802280200410141800310112201280200410020011b2227411f4d0d0741f802280200410141800310112101202741204b0d08200141206a290300219d01200141186a290300219e01200141106a290300219f01200141086a29030021a001200441406a22012400200141186a4200370300200142003703102001420037030820014204370300200141206a20053a0000200141216a202b3a0000200141226a20463a0000200141236a20443a0000200141246a20423a0000200141256a20413a0000200141266a20403a0000200141276a203f3a0000200141286a203e3a0000200141296a203d3a00002001412a6a203c3a00002001412b6a203b3a00002001412c6a203a3a00002001412d6a20393a00002001412e6a20383a00002001412f6a20373a0000200141306a20363a0000200141316a20353a0000200141326a20343a0000200141336a20333a0000200141346a20323a0000200141356a20313a0000200141366a20303a0000200141376a202f3a0000200141386a202e3a0000200141396a202d3a00002001413a6a202c3a00002001413b6a20293a00002001413c6a20263a00002001413d6a20473a00002001413e6a20433a00002001413f6a20283a0000200141206b22042400200141c000200410072004290300218c01200441086a290300219001200441106a290300218e01200441186a290300218d01200441206b220122272400200141186a208d013703002001208e0137031020012090013703082001208c0137030041f80241203602002001412041800341f802100021044180032d0000212a4181032d000021484182032d000021494183032d0000214c4184032d0000214a4185032d0000214d4186032d0000214e4187032d0000214f4188032d000021504189032d00002151418a032d00002152418b032d00002153418c032d00002154418d032d00002155418e032d00002156418f032d000021574190032d000021584191032d000021594192032d0000215a4193032d0000215b4194032d0000215c4195032d0000215d4196032d0000215e4197032d0000215f4198032d000021604199032d00002161419a032d00002162419b032d00002163419c032d00002164419d032d00002165419e032d00002166419f032d0000216741244101417f1011210120004187dee59a7b360228200041286a200141086a2268410410102001412b6a20283a00002001412a6a20433a0000200141296a20473a0000200141286a20263a0000200141276a20293a0000200141266a202c3a0000200141256a202d3a0000200141246a202e3a0000200141236a202f3a0000200141226a20303a0000200141216a20313a0000200141206a20323a00002001411f6a20333a00002001411e6a20343a00002001411d6a20353a00002001411c6a20363a00002001411b6a20373a00002001411a6a20383a0000200141196a20393a0000200141186a203a3a0000200141176a203b3a0000200141166a203c3a0000200141156a203d3a0000200141146a203e3a0000200141136a203f3a0000200141126a20403a0000200141116a20413a0000200141106a20423a00002001410f6a20443a00002001410e6a20463a00002001410d6a202b3a00002001410c6a20053a000020004100206720041b3a004b20004100206620041b3a004a20004100206520041b3a004920004100206420041b3a004820004100206320041b3a004720004100206220041b3a004620004100206120041b3a004520004100206020041b3a004420004100205f20041b3a004320004100205e20041b3a004220004100205d20041b3a004120004100205c20041b3a004020004100205b20041b3a003f20004100205a20041b3a003e20004100205920041b3a003d20004100205820041b3a003c20004100205720041b3a003b20004100205620041b3a003a20004100205520041b3a003920004100205420041b3a003820004100205320041b3a003720004100205220041b3a003620004100205120041b3a003520004100205020041b3a003420004100204f20041b3a003320004100204e20041b3a003220004100204d20041b3a003120004100204a20041b3a003020004100204c20041b3a002f20004100204920041b3a002e20004100204820041b3a002d20004100202a20041b3a002c2001280200212a202741106b22042400200442003703082004420037030041f8024180800236020041002000412c6a420020042068202a410020011b41800341f80210060d0941f802280200410141800310112201280200410020011b2227411f4d0d0a41f802280200410141800310112101202741204b0d0b200141206a29030021a101200141186a29030021a201200141106a29030021a301200141086a29030021a40141044101417f10112127200041e7caf3890336024c200041cc006a202741086a222a410410102000200b3a0053200020033a0052200020023a0051200020063a0050200020253a0054200020243a0055200020233a0056200020223a0057200020213a0058200020203a00592000201f3a005a2000201e3a005b2000201d3a005c2000201c3a005d2000201b3a005e2000201a3a005f200020193a0060200020183a0061200020173a0062200020163a0063200020153a0064200020143a0065200020133a0066200020123a0067200020113a0068200020103a00692000200f3a006a2000200e3a006b2000200d3a006c2000200c3a006d2000200a3a006e200020093a006f20272802002148200441106b22012400200142003703082001420037030041f802418080023602004100200041d0006a42002001202a2048410020271b41800341f80210060d0c41f802280200410141800310112204280200410020041b2204450d0d41f802280200410141800310112127200441014b0d0e02404212202741086a31000042ff0183228c017d2292014212564200208c01421256ad7d2290014200522204208c0142135422271b200420271b450440420a218f01200041f0056a2104209001228c01218d0142012196010340209201a74101710440200041d8056a209901370300200041b8056a2091013703002000208f013703c00520002096013703a00520002093013703c80520002097013703a80520002098013703d00520002095013703b005200041a0056a200041c0056a200041e0056a10140d1320002903e005219601200041e8056a2903002197012004290300219501200041f8056a2903002191010b209001423f8620920142018884229201208d01423f86208c0142018884228e0184208c01423f8620900142018884229001208d01420188228d018484500d02200041b8066a20990137030020004198066a2099013703002000208f013703a0062000208f013703800620002093013703a80620002093013703880620002098013703b00620002098013703900620004180066a200041a0066a200041c0066a1014200041d8066a290300219901200041d0066a290300219801200041c8066a29030021930120002903c006218f01208e01218c01450d000b000b000b20004188016a20910137030020002096013703702000209701370378200020950137038001200141406a22012400200141186a4200370300200142003703102001420037030820014203370300200141206a20063a0000200141216a20023a0000200141226a20033a0000200141236a200b3a0000200141246a20253a0000200141256a20243a0000200141266a20233a0000200141276a20223a0000200141286a20213a0000200141296a20203a00002001412a6a201f3a00002001412b6a201e3a00002001412c6a201d3a00002001412d6a201c3a00002001412e6a201b3a00002001412f6a201a3a0000200141306a20193a0000200141316a20183a0000200141326a20173a0000200141336a20163a0000200141346a20153a0000200141356a20143a0000200141366a20133a0000200141376a20123a0000200141386a20113a0000200141396a20103a00002001413a6a200f3a00002001413b6a200e3a00002001413c6a200d3a00002001413d6a200c3a00002001413e6a200a3a00002001413f6a20093a0000200141206b22042400200141c000200410072004290300218c01200441086a290300219001200441106a290300218e01200441186a290300218d01200441206b220122092400200141186a208d013703002001208e0137031020012090013703082001208c0137030041f80241203602002001412041800341f802100021014180032d0000210a4181032d0000210c4182032d0000210d4183032d0000210e4184032d0000210f4185032d000021104186032d000021114187032d000021124188032d000021134189032d00002114418a032d00002115418b032d00002116418c032d00002117418d032d00002118418e032d00002119418f032d0000211a4190032d0000211b4191032d0000211c4192032d0000211d4193032d0000211e4194032d0000211f4195032d000021204196032d000021214197032d000021224198032d000021234199032d00002124419a032d00002125419b032d0000210b419c032d00002103419d032d00002102419e032d00002106419f032d0000212741244101417f10112104200041c8a4d1e4033602940120004194016a200441086a222a41041010200441246a209a013703002004411c6a209b01370300200441146a2094013703002004410c6a209c0137030020004100202720011b3a00b70120004100200620011b3a00b60120004100200220011b3a00b50120004100200320011b3a00b40120004100200b20011b3a00b30120004100202520011b3a00b20120004100202420011b3a00b10120004100202320011b3a00b00120004100202220011b3a00af0120004100202120011b3a00ae0120004100202020011b3a00ad0120004100201f20011b3a00ac0120004100201e20011b3a00ab0120004100201d20011b3a00aa0120004100201c20011b3a00a90120004100201b20011b3a00a80120004100201a20011b3a00a70120004100201920011b3a00a60120004100201820011b3a00a50120004100201720011b3a00a40120004100201620011b3a00a30120004100201520011b3a00a20120004100201420011b3a00a10120004100201320011b3a00a00120004100201220011b3a009f0120004100201120011b3a009e0120004100201020011b3a009d0120004100200f20011b3a009c0120004100200e20011b3a009b0120004100200d20011b3a009a0120004100200c20011b3a00990120004100200a20011b3a0098012004280200210a200941106b22012400200142003703082001420037030041f80241808002360200410020004198016a42002001202a200a410020041b41800341f80210060d1741f802280200410141800310112204280200410020041b2209411f4d0440000b41f802280200410141800310112104200941204b0d18200441206a290300218c01200441186a290300219001200441106a290300218e01200441086a290300218d01200041f0016a209101370300200041d0016a208c0137030020002096013703d8012000208d013703b80120002097013703e0012000208e013703c00120002095013703e80120002090013703c801200041b8016a200041d8016a200041f8016a10140d1020004190026a290300218c0120004188026a29030021900120004180026a290300218e0120002903f801218d01200041d0026a209d01370300200041b0026a208c01370300200020a0013703b8022000208d01370398022000209f013703c0022000208e013703a0022000209e013703c80220002090013703a80220004198026a200041b8026a200041d8026a10140d11200041f0026a290300218c01200041e8026a290300219001200041e0026a290300218e0120002903d802218d01200041b0036a20a10137030020004190036a208c01370300200020a401370398032000208d013703f802200020a3013703a0032000208e0137038003200020a2013703a803200020900137038803200041f8026a20004198036a200041b8036a200041d8036a10170d1220004190046a200041f0036a290300370300200041b0046a209101370300200020002903d8033703f80320002096013703980420002097013703a0042000200041e8036a290300370388042000200041e0036a2903003703800420002095013703a804200041f8036a20004198046a200041b8046a200041d8046a10170d13200041e0046a290300218c01200041e8046a290300219001200041f0046a290300218e0120002903d804219101200141406a22012400200141186a4200370300200142003703102001420037030820014203370300200141206a20053a0000200141216a202b3a0000200141226a20463a0000200141236a20443a0000200141246a20423a0000200141256a20413a0000200141266a20403a0000200141276a203f3a0000200141286a203e3a0000200141296a203d3a00002001412a6a203c3a00002001412b6a203b3a00002001412c6a203a3a00002001412d6a20393a00002001412e6a20383a00002001412f6a20373a0000200141306a20363a0000200141316a20353a0000200141326a20343a0000200141336a20333a0000200141346a20323a0000200141356a20313a0000200141366a20303a0000200141376a202f3a0000200141386a202e3a0000200141396a202d3a00002001413a6a202c3a00002001413b6a20293a00002001413c6a20263a00002001413d6a20473a00002001413e6a20433a00002001413f6a20283a0000200141206b22042400200141c000200410072004290300219501200441086a290300218d01200441106a290300219701200441186a290300219601200441206b220122052400200141186a20960137030020012097013703102001208d01370308200120950137030041f80241203602002001412041800341f802100021014180032d000021094181032d0000210a4182032d0000210c4183032d0000210d4184032d0000210e4185032d0000210f4186032d000021104187032d000021114188032d000021124189032d00002113418a032d00002114418b032d00002115418c032d00002116418d032d00002117418e032d00002118418f032d000021194190032d0000211a4191032d0000211b4192032d0000211c4193032d0000211d4194032d0000211e4195032d0000211f4196032d000021204197032d000021214198032d000021224199032d00002123419a032d00002124419b032d00002125419c032d0000210b419d032d00002103419e032d00002102419f032d0000210641244101417f10112104200041c684d7b9783602fc04200041fc046a200441086a222841041010200441246a208e013703002004411c6a209001370300200441146a208c013703002004410c6a20910137030020004100200620011b3a009f0520004100200220011b3a009e0520004100200320011b3a009d0520004100200b20011b3a009c0520004100202520011b3a009b0520004100202420011b3a009a0520004100202320011b3a00990520004100202220011b3a00980520004100202120011b3a00970520004100202020011b3a00960520004100201f20011b3a00950520004100201e20011b3a00940520004100201d20011b3a00930520004100201c20011b3a00920520004100201b20011b3a00910520004100201a20011b3a00900520004100201920011b3a008f0520004100201820011b3a008e0520004100201720011b3a008d0520004100201620011b3a008c0520004100201520011b3a008b0520004100201420011b3a008a0520004100201320011b3a00890520004100201220011b3a00880520004100201120011b3a00870520004100201020011b3a00860520004100200f20011b3a00850520004100200e20011b3a00840520004100200d20011b3a00830520004100200c20011b3a00820520004100200a20011b3a00810520004100200920011b3a00800520042802002109200541106b22012400200142003703082001420037030041f80241808002360200410020004180056a4200200120282009410020041b41800341f80210060d1441f802280200410141800310112201280200410020011b2204411f4d0d1541f802280200410141800310112101200441204b0d16200141206a290300218c01200141186a290300219001200141106a290300218e012008200141086a2903003703002008208e013703082008209001370310200841186a208c01370300200041e0066a240041000c190b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b0d0b200841086a290300218c01200841106a290300219001200841186a290300218e01200829030021910141204101417f1011220041206a208e01370300200041186a209001370300200041106a208c01370300200041086a22002091013703000c0a0b02400240024002400240024002400240024002400240024002400240024002400240024002400240024002402005200441406b4f044020014120417f10112100200141ffffff3f712001470d01200441406b220820014105746a22092008490d0220052009490d03200141ffffff3f712001470d04200041086a200441c4036a2001410574100d200141ffffff3f712001470d052001410574220820046a22092008490d06200941406b220841c000490d072008200841406b22094b0d0820052009490d09200141ffffff3f712001470d0a2001410574220820046a22092008490d0b200941406b220941c000490d0c200141ffffff3f712001470d0d2001410574220820046a220a2008490d0e200a41406b220841c000490d0f2008200841206a220b4b0d10200141ffffff3f712001470d112004200141057422016a22042001490d12200441406b220141c000490d132001200141206a22044b0d142004200441206a22014b0d15200120054f0d16000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b20094184036a22012d001f212520012d001e212420012d001d212320012d001c212220012d001b212120012d001a212020012d0019211f20012d0018211e20012d0017211d20012d0016211c20012d0015211b20012d0014211a20012d0013211920012d0012211820012d0011211720012d0010211620012d000f211520012d000e211420012d000d211320012d000c211220012d000b211120012d000a211020012d0009210f20012d0008210e20012d0007210d20012d0006210c20012d0005210a20012d0004210920012d0003210820012d0002210520012d0001210420012d00002101200b4184036a220b290300218d01200b41186a290300218f01200b41106a290300219201200b41086a290300219301200741106b220b2400024002400240024002400240027f209501219901230041306b2247240041f8024101360200204741286a42003703002047420037032020474200370318204742023703102047204741106a412041800341f8021000047f4100054180032d00000b41017122033a000f02402003450440204741106b228b012400027f230041406a220321432003240041004120417f10111a41f802410836020041800341f802100902400240024002400240208f0120920184502093015041800329030042e80780208d01567171450440200341206b22282400027f208c012195014200219201230041e0066b22032400024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002402000280200410020001b41024604402000280200410020001b450d012000280200410020001b41014d0d02200041086a2d0000200041286a2d000046200041096a2d0000200041296a2d000046712000410a6a2d00002000412a6a2d000046712000410b6a2d00002000412b6a2d000046712000410c6a2d00002000412c6a2d000046712000410d6a2d00002000412d6a2d000046712000410e6a2d00002000412e6a2d000046712000410f6a2d00002000412f6a2d00004671200041106a2d0000200041306a2d00004671200041116a2d0000200041316a2d00004671200041126a2d0000200041326a2d00004671200041136a2d0000200041336a2d00004671200041146a2d0000200041346a2d00004671200041156a2d0000200041356a2d00004671200041166a2d0000200041366a2d00004671200041176a2d0000200041376a2d00004671200041186a2d0000200041386a2d00004671200041196a2d0000200041396a2d000046712000411a6a2d00002000413a6a2d000046712000411b6a2d00002000413b6a2d000046712000411c6a2d00002000413c6a2d000046712000411d6a2d00002000413d6a2d000046712000411e6a2d00002000413e6a2d000046712000411f6a2d00002000413f6a2d00004671200041206a2d0000200041406b2d00004671200041216a2d0000200041c1006a2d00004671200041226a2d0000200041c2006a2d00004671200041236a2d0000200041c3006a2d00004671200041246a2d0000200041c4006a2d00004671200041256a2d0000200041c5006a2d00004671200041266a2d0000200041c6006a2d00004671200041276a2d0000200041c7006a2d000046710d032000280200410020001b450d042000280200410020001b41014d0d05200041276a2d00002126200041266a2d00002129200041256a2d0000212c200041246a2d0000212d200041236a2d0000212e200041226a2d0000212f200041216a2d00002130200041206a2d000021312000411f6a2d000021322000411e6a2d000021332000411d6a2d000021342000411c6a2d000021352000411b6a2d000021362000411a6a2d00002137200041196a2d00002138200041186a2d00002139200041176a2d0000213a200041166a2d0000213b200041156a2d0000213c200041146a2d0000213d200041136a2d0000213e200041126a2d0000213f200041116a2d00002140200041106a2d000021412000410f6a2d000021422000410e6a2d000021442000410d6a2d000021462000410c6a2d0000212b2000410b6a2d000021272000410a6a2d0000212a200041096a2d00002148200041086a2d00002149200041c7006a2d0000214c200041c6006a2d0000214a200041c5006a2d0000214d200041c4006a2d0000214e200041c3006a2d0000214f200041c2006a2d00002150200041c1006a2d00002151200041406b2d000021522000413f6a2d000021532000413e6a2d000021542000413d6a2d000021552000413c6a2d000021562000413b6a2d000021572000413a6a2d00002158200041396a2d00002159200041386a2d0000215a200041376a2d0000215b200041366a2d0000215c200041356a2d0000215d200041346a2d0000215e200041336a2d0000215f200041326a2d00002160200041316a2d00002161200041306a2d000021622000412f6a2d000021632000412e6a2d000021642000412d6a2d000021652000412c6a2d000021662000412b6a2d000021672000412a6a2d00002168200041296a2d00002169200041286a2d0000216a200341406a22022400200241186a4200370300200242003703102002420037030820024203370300200241206a20493a0000200241216a20483a0000200241226a202a3a0000200241236a20273a0000200241246a202b3a0000200241256a20463a0000200241266a20443a0000200241276a20423a0000200241286a20413a0000200241296a20403a00002002412a6a203f3a00002002412b6a203e3a00002002412c6a203d3a00002002412d6a203c3a00002002412e6a203b3a00002002412f6a203a3a0000200241306a20393a0000200241316a20383a0000200241326a20373a0000200241336a20363a0000200241346a20353a0000200241356a20343a0000200241366a20333a0000200241376a20323a0000200241386a20313a0000200241396a20303a00002002413a6a202f3a00002002413b6a202e3a00002002413c6a202d3a00002002413d6a202c3a00002002413e6a20293a00002002413f6a20263a0000200241206b22062400200241c000200610072006290300218c01200641086a290300218d01200641106a290300218f01200641186a290300219301200641206b220222062400200241186a2093013703002002208f013703102002208d013703082002208c0137030041f80241203602002002412041800341f8021000210241004180032d000020021b41004181032d000020021b7241004182032d000020021b7241004183032d000020021b7241004184032d000020021b7241004185032d000020021b7241004186032d000020021b7241004187032d000020021b7241004188032d000020021b7241004189032d000020021b724100418a032d000020021b724100418b032d000020021b724100418c032d000020021b724100418d032d000020021b724100418e032d000020021b724100418f032d000020021b7241004190032d000020021b7241004191032d000020021b7241004192032d000020021b7241004193032d000020021b7241004194032d000020021b7241004195032d000020021b7241004196032d000020021b7241004197032d000020021b7241004198032d000020021b7241004199032d000020021b724100419a032d000020021b724100419b032d000020021b724100419c032d000020021b724100419d032d000020021b724100419e032d000020021b724100419f032d000020021b7241ff0171047f200641406a22022400200241186a4200370300200242003703102002420037030820024203370300200241206a206a3a0000200241216a20693a0000200241226a20683a0000200241236a20673a0000200241246a20663a0000200241256a20653a0000200241266a20643a0000200241276a20633a0000200241286a20623a0000200241296a20613a00002002412a6a20603a00002002412b6a205f3a00002002412c6a205e3a00002002412d6a205d3a00002002412e6a205c3a00002002412f6a205b3a0000200241306a205a3a0000200241316a20593a0000200241326a20583a0000200241336a20573a0000200241346a20563a0000200241356a20553a0000200241366a20543a0000200241376a20533a0000200241386a20523a0000200241396a20513a00002002413a6a20503a00002002413b6a204f3a00002002413c6a204e3a00002002413d6a204d3a00002002413e6a204a3a00002002413f6a204c3a0000200241206b22062400200241c000200610072006290300218c01200641086a290300218d01200641106a290300218f01200641186a290300219301200641206b220222062400200241186a2093013703002002208f013703102002208d013703082002208c0137030041f80241203602002002412041800341f8021000210241004180032d000020021b41004181032d000020021b7241004182032d000020021b7241004183032d000020021b7241004184032d000020021b7241004185032d000020021b7241004186032d000020021b7241004187032d000020021b7241004188032d000020021b7241004189032d000020021b724100418a032d000020021b724100418b032d000020021b724100418c032d000020021b724100418d032d000020021b724100418e032d000020021b724100418f032d000020021b7241004190032d000020021b7241004191032d000020021b7241004192032d000020021b7241004193032d000020021b7241004194032d000020021b7241004195032d000020021b7241004196032d000020021b7241004197032d000020021b7241004198032d000020021b7241004199032d000020021b724100419a032d000020021b724100419b032d000020021b724100419c032d000020021b724100419d032d000020021b724100419e032d000020021b724100419f032d000020021b7241ff01714100470541000b450d06200641406a22022400200241186a4200370300200242003703102002420037030820024204370300200241206a20493a0000200241216a20483a0000200241226a202a3a0000200241236a20273a0000200241246a202b3a0000200241256a20463a0000200241266a20443a0000200241276a20423a0000200241286a20413a0000200241296a20403a00002002412a6a203f3a00002002412b6a203e3a00002002412c6a203d3a00002002412d6a203c3a00002002412e6a203b3a00002002412f6a203a3a0000200241306a20393a0000200241316a20383a0000200241326a20373a0000200241336a20363a0000200241346a20353a0000200241356a20343a0000200241366a20333a0000200241376a20323a0000200241386a20313a0000200241396a20303a00002002413a6a202f3a00002002413b6a202e3a00002002413c6a202d3a00002002413d6a202c3a00002002413e6a20293a00002002413f6a20263a0000200241206b22062400200241c000200610072006290300218c01200641086a290300218d01200641106a290300218f01200641186a290300219301200641206b220222452400200241186a2093013703002002208f013703102002208d013703082002208c0137030041f80241203602002002412041800341f802100021064180032d0000214b4181032d0000216b4182032d0000216c4183032d0000216d4184032d0000216e4185032d0000216f4186032d000021704187032d000021714188032d000021724189032d00002173418a032d00002174418b032d00002175418c032d00002176418d032d00002177418e032d00002178418f032d000021794190032d0000217a4191032d0000217b4192032d0000217c4193032d0000217d4194032d0000217e4195032d0000217f4196032d00002180014197032d00002181014198032d00002182014199032d0000218301419a032d0000218401419b032d0000218501419c032d0000218601419d032d0000218701419e032d0000218801419f032d000021890141244101417f1011210220034187dee59a7b360204200341046a200241086a228a01410410102002412b6a20263a00002002412a6a20293a0000200241296a202c3a0000200241286a202d3a0000200241276a202e3a0000200241266a202f3a0000200241256a20303a0000200241246a20313a0000200241236a20323a0000200241226a20333a0000200241216a20343a0000200241206a20353a00002002411f6a20363a00002002411e6a20373a00002002411d6a20383a00002002411c6a20393a00002002411b6a203a3a00002002411a6a203b3a0000200241196a203c3a0000200241186a203d3a0000200241176a203e3a0000200241166a203f3a0000200241156a20403a0000200241146a20413a0000200241136a20423a0000200241126a20443a0000200241116a20463a0000200241106a202b3a00002002410f6a20273a00002002410e6a202a3a00002002410d6a20483a00002002410c6a20493a00002003410020890120061b3a00272003410020880120061b3a00262003410020870120061b3a00252003410020860120061b3a00242003410020850120061b3a00232003410020840120061b3a00222003410020830120061b3a00212003410020820120061b3a00202003410020810120061b3a001f2003410020800120061b3a001e20034100207f20061b3a001d20034100207e20061b3a001c20034100207d20061b3a001b20034100207c20061b3a001a20034100207b20061b3a001920034100207a20061b3a001820034100207920061b3a001720034100207820061b3a001620034100207720061b3a001520034100207620061b3a001420034100207520061b3a001320034100207420061b3a001220034100207320061b3a001120034100207220061b3a001020034100207120061b3a000f20034100207020061b3a000e20034100206f20061b3a000d20034100206e20061b3a000c20034100206d20061b3a000b20034100206c20061b3a000a20034100206b20061b3a000920034100204b20061b3a00082002280200214b204541106b22062400200642003703082006420037030041f802418080023602004100200341086a42002006208a01204b410020021b41800341f80210060d0741f802280200410141800310112202280200410020021b2245411f4d0d0841f802280200410141800310112102204541204b0d09200241206a29030021a101200241186a29030021a201200241106a29030021a301200241086a29030021a401200641406a22022400200241186a4200370300200242003703102002420037030820024204370300200241206a206a3a0000200241216a20693a0000200241226a20683a0000200241236a20673a0000200241246a20663a0000200241256a20653a0000200241266a20643a0000200241276a20633a0000200241286a20623a0000200241296a20613a00002002412a6a20603a00002002412b6a205f3a00002002412c6a205e3a00002002412d6a205d3a00002002412e6a205c3a00002002412f6a205b3a0000200241306a205a3a0000200241316a20593a0000200241326a20583a0000200241336a20573a0000200241346a20563a0000200241356a20553a0000200241366a20543a0000200241376a20533a0000200241386a20523a0000200241396a20513a00002002413a6a20503a00002002413b6a204f3a00002002413c6a204e3a00002002413d6a204d3a00002002413e6a204a3a00002002413f6a204c3a0000200241206b22062400200241c000200610072006290300218c01200641086a290300218d01200641106a290300218f01200641186a290300219301200641206b220222452400200241186a2093013703002002208f013703102002208d013703082002208c0137030041f80241203602002002412041800341f802100021064180032d0000214b4181032d0000216b4182032d0000216c4183032d0000216d4184032d0000216e4185032d0000216f4186032d000021704187032d000021714188032d000021724189032d00002173418a032d00002174418b032d00002175418c032d00002176418d032d00002177418e032d00002178418f032d000021794190032d0000217a4191032d0000217b4192032d0000217c4193032d0000217d4194032d0000217e4195032d0000217f4196032d00002180014197032d00002181014198032d00002182014199032d0000218301419a032d0000218401419b032d0000218501419c032d0000218601419d032d0000218701419e032d0000218801419f032d000021890141244101417f1011210220034187dee59a7b360228200341286a200241086a228a01410410102002412b6a204c3a00002002412a6a204a3a0000200241296a204d3a0000200241286a204e3a0000200241276a204f3a0000200241266a20503a0000200241256a20513a0000200241246a20523a0000200241236a20533a0000200241226a20543a0000200241216a20553a0000200241206a20563a00002002411f6a20573a00002002411e6a20583a00002002411d6a20593a00002002411c6a205a3a00002002411b6a205b3a00002002411a6a205c3a0000200241196a205d3a0000200241186a205e3a0000200241176a205f3a0000200241166a20603a0000200241156a20613a0000200241146a20623a0000200241136a20633a0000200241126a20643a0000200241116a20653a0000200241106a20663a00002002410f6a20673a00002002410e6a20683a00002002410d6a20693a00002002410c6a206a3a00002003410020890120061b3a004b2003410020880120061b3a004a2003410020870120061b3a00492003410020860120061b3a00482003410020850120061b3a00472003410020840120061b3a00462003410020830120061b3a00452003410020820120061b3a00442003410020810120061b3a00432003410020800120061b3a004220034100207f20061b3a004120034100207e20061b3a004020034100207d20061b3a003f20034100207c20061b3a003e20034100207b20061b3a003d20034100207a20061b3a003c20034100207920061b3a003b20034100207820061b3a003a20034100207720061b3a003920034100207620061b3a003820034100207520061b3a003720034100207420061b3a003620034100207320061b3a003520034100207220061b3a003420034100207120061b3a003320034100207020061b3a003220034100206f20061b3a003120034100206e20061b3a003020034100206d20061b3a002f20034100206c20061b3a002e20034100206b20061b3a002d20034100204b20061b3a002c2002280200214b204541106b22062400200642003703082006420037030041f8024180800236020041002003412c6a42002006208a01204b410020021b41800341f80210060d0a41f802280200410141800310112202280200410020021b2245411f4d0d0b41f802280200410141800310112102204541204b0d0c200241206a29030021a501200241186a29030021a601200241106a29030021a701200241086a29030021a80141044101417f10112102200341e7caf3890336024c200341cc006a200241086a224541041010200320273a00532003202a3a0052200320483a0051200320493a00502003202b3a0054200320463a0055200320443a0056200320423a0057200320413a0058200320403a00592003203f3a005a2003203e3a005b2003203d3a005c2003203c3a005d2003203b3a005e2003203a3a005f200320393a0060200320383a0061200320373a0062200320363a0063200320353a0064200320343a0065200320333a0066200320323a0067200320313a0068200320303a00692003202f3a006a2003202e3a006b2003202d3a006c2003202c3a006d200320293a006e200320263a006f2002280200214b200641106b22062400200642003703082006420037030041f802418080023602004100200341d0006a420020062045204b410020021b41800341f80210060d0d41f802280200410141800310112202280200410020021b2202450d0e41f802280200410141800310112145200241014b0d0f4212204541086a31000042ff0183228c017d229f014212564200208c01421256ad7d228d014200522202208c0142135422451b200220451b0d14420a219e01200341f0056a2102208d01228c0121a001420121930102400340209f01a74101710440200341d8056a209d01370300200341b8056a209b013703002003209e013703c00520032093013703a00520032094013703c80520032092013703a8052003209c013703d0052003209a013703b005200341a0056a200341c0056a200341e0056a10140d13200341f8056a290300219b012002290300219a0120032903e005219301200341e8056a2903002192010b208d01423f86209f0142018884229f0120a001423f86208c0142018884228f0184208c01423f86208d0142018884228d0120a00142018822a0018484500d01200341b8066a209d0137030020034198066a209d013703002003209e013703a0062003209e013703800620032094013703a8062003209401370388062003209c013703b0062003209c013703900620034180066a200341a0066a200341c0066a1014200341d8066a290300219d01200341d0066a290300219c01200341c8066a29030021940120032903c006219e01208f01218c01450d000b000b20034188016a209b0137030041f8024120360200200320930137037020032092013703782003209a013703800141800341f802100141f8024120360200418003290300218c01418803290300218d01419003290300218f0141980329030021940141800341f8021008419803290300219c01419003290300219d01418803290300219e01418003290300219f0141e4004101417f10112102200341dde5e19d023602a006200341a0066a200241086a41041010200241e4006a209101370300200241dc006a208e01370300200241d4006a209001370300200241cc006a209501370300200241246a2094013700002002411c6a208f01370000200241146a208d013700002002410c6a208c013700002002412c6a209f01370000200241346a209e013700002002413c6a209d01370000200241c4006a209c0137000020492048202a2027202b20462044204220412040203f203e203d203c203b203a2039203820372036203520342033203220312030202f202e202d202c202920262002412041014180011011200341c0066a101a220245044020032802c0062202280200410020021b04402002280200410020021b2245450d13204541014b0d14200241086a2d0000410171450d150b410021020b2002450440410021020b20020d23200641406a22022400200241186a4200370300200242003703102002420037030820024203370300200241206a20493a0000200241216a20483a0000200241226a202a3a0000200241236a20273a0000200241246a202b3a0000200241256a20463a0000200241266a20443a0000200241276a20423a0000200241286a20413a0000200241296a20403a00002002412a6a203f3a00002002412b6a203e3a00002002412c6a203d3a00002002412d6a203c3a00002002412e6a203b3a00002002412f6a203a3a0000200241306a20393a0000200241316a20383a0000200241326a20373a0000200241336a20363a0000200241346a20353a0000200241356a20343a0000200241366a20333a0000200241376a20323a0000200241386a20313a0000200241396a20303a00002002413a6a202f3a00002002413b6a202e3a00002002413c6a202d3a00002002413d6a202c3a00002002413e6a20293a00002002413f6a20263a0000200241206b22062400200241c000200610072006290300218c01200641086a290300218d01200641106a290300218f01200641186a290300219401200641206b220222262400200241186a2094013703002002208f013703102002208d013703082002208c0137030041f80241203602002002412041800341f802100021024180032d000021294181032d0000212c4182032d0000212d4183032d0000212e4184032d0000212f4185032d000021304186032d000021314187032d000021324188032d000021334189032d00002134418a032d00002135418b032d00002136418c032d00002137418d032d00002138418e032d00002139418f032d0000213a4190032d0000213b4191032d0000213c4192032d0000213d4193032d0000213e4194032d0000213f4195032d000021404196032d000021414197032d000021424198032d000021444199032d00002146419a032d0000212b419b032d00002127419c032d0000212a419d032d00002148419e032d00002149419f032d0000214541244101417f10112106200341bfd0baec043602940120034194016a200641086a224b41041010200641246a2091013703002006411c6a208e01370300200641146a2090013703002006410c6a20950137030020034100204520021b3a00b70120034100204920021b3a00b60120034100204820021b3a00b50120034100202a20021b3a00b40120034100202720021b3a00b30120034100202b20021b3a00b20120034100204620021b3a00b10120034100204420021b3a00b00120034100204220021b3a00af0120034100204120021b3a00ae0120034100204020021b3a00ad0120034100203f20021b3a00ac0120034100203e20021b3a00ab0120034100203d20021b3a00aa0120034100203c20021b3a00a90120034100203b20021b3a00a80120034100203a20021b3a00a70120034100203920021b3a00a60120034100203820021b3a00a50120034100203720021b3a00a40120034100203620021b3a00a30120034100203520021b3a00a20120034100203420021b3a00a10120034100203320021b3a00a00120034100203220021b3a009f0120034100203120021b3a009e0120034100203020021b3a009d0120034100202f20021b3a009c0120034100202e20021b3a009b0120034100202d20021b3a009a0120034100202c20021b3a00990120034100202920021b3a00980120062802002129202641106b220222262400200242003703082002420037030041f80241808002360200410020034198016a42002002204b2029410020061b41800341f80210060d1541f802280200410141800310112202280200410020021b2206411f4d0d1641f802280200410141800310112102200641204b0d17200241206a290300218c01200241186a290300218d01200241106a290300218f01200241086a290300219401200341f0016a209b01370300200341d0016a208c0137030020032093013703d80120032094013703b80120032092013703e0012003208f013703c0012003209a013703e8012003208d013703c801200341b8016a200341d8016a200341f8016a10140d1820034190026a290300218c0120034188026a290300218d0120034180026a290300218f0120032903f801219401200341d0026a20a101370300200341b0026a208c01370300200320a4013703b802200320940137039802200320a3013703c0022003208f013703a002200320a2013703c8022003208d013703a80220034198026a200341b8026a200341d8026a10140d19200341f0026a290300218c01200341e8026a290300218d01200341e0026a290300218f0120032903d802219401200341b0036a20a50137030020034190036a208c01370300200320a8013703980320032094013703f802200320a7013703a0032003208f0137038003200320a6013703a8032003208d0137038803200341f8026a20034198036a200341b8036a200341d8036a10170d1a20034190046a200341f0036a290300370300200341b0046a209b01370300200320032903d8033703f80320032093013703980420032092013703a0042003200341e8036a290300370388042003200341e0036a290300370380042003209a013703a804200341f8036a20034198046a200341b8046a200341d8046a10170d1b200341e0046a290300218c01200341e8046a290300218d01200341f0046a290300218f0120032903d804219201202641406a22022400200241186a4200370300200242003703102002420037030820024203370300200241206a206a3a0000200241216a20693a0000200241226a20683a0000200241236a20673a0000200241246a20663a0000200241256a20653a0000200241266a20643a0000200241276a20633a0000200241286a20623a0000200241296a20613a00002002412a6a20603a00002002412b6a205f3a00002002412c6a205e3a00002002412d6a205d3a00002002412e6a205c3a00002002412f6a205b3a0000200241306a205a3a0000200241316a20593a0000200241326a20583a0000200241336a20573a0000200241346a20563a0000200241356a20553a0000200241366a20543a0000200241376a20533a0000200241386a20523a0000200241396a20513a00002002413a6a20503a00002002413b6a204f3a00002002413c6a204e3a00002002413d6a204d3a00002002413e6a204a3a00002002413f6a204c3a0000200241206b22062400200241c000200610072006290300219301200641086a290300219a01200641106a290300219b01200641186a290300219401200641206b220222262400200241186a2094013703002002209b013703102002209a01370308200220930137030041f80241203602002002412041800341f802100021024180032d000021294181032d0000212c4182032d0000212d4183032d0000212e4184032d0000212f4185032d000021304186032d000021314187032d000021324188032d000021334189032d00002134418a032d00002135418b032d00002136418c032d00002137418d032d00002138418e032d00002139418f032d0000213a4190032d0000213b4191032d0000213c4192032d0000213d4193032d0000213e4194032d0000213f4195032d000021404196032d000021414197032d000021424198032d000021444199032d00002146419a032d0000212b419b032d00002127419c032d0000212a419d032d00002148419e032d00002149419f032d0000214541244101417f10112106200341cfa8e7fb053602fc04200341fc046a200641086a224b41041010200641246a208f013703002006411c6a208d01370300200641146a208c013703002006410c6a20920137030020034100204520021b3a009f0520034100204920021b3a009e0520034100204820021b3a009d0520034100202a20021b3a009c0520034100202720021b3a009b0520034100202b20021b3a009a0520034100204620021b3a00990520034100204420021b3a00980520034100204220021b3a00970520034100204120021b3a00960520034100204020021b3a00950520034100203f20021b3a00940520034100203e20021b3a00930520034100203d20021b3a00920520034100203c20021b3a00910520034100203b20021b3a00900520034100203a20021b3a008f0520034100203920021b3a008e0520034100203820021b3a008d0520034100203720021b3a008c0520034100203620021b3a008b0520034100203520021b3a008a0520034100203420021b3a00890520034100203320021b3a00880520034100203220021b3a00870520034100203120021b3a00860520034100203020021b3a00850520034100202f20021b3a00840520034100202e20021b3a00830520034100202d20021b3a00820520034100202c20021b3a00810520034100202920021b3a00800520062802002129202641106b22022400200242003703082002420037030041f80241808002360200410020034180056a42002002204b2029410020061b41800341f80210060d1c41f802280200410141800310112202280200410020021b2206411f4d0d1d41f802280200410141800310112102200641204b0d1e200241206a290300218c01200241186a290300218d01200241106a290300218f01200241086a29030021920141c4004101417f10112102200341bbb996c87a3602a006200341a0066a200241086a410410102002410f6a20083a00002002410e6a20053a00002002410d6a20043a00002002410c6a20013a0000200241106a20093a0000200241116a200a3a0000200241126a200c3a0000200241136a200d3a0000200241146a200e3a0000200241156a200f3a0000200241166a20103a0000200241176a20113a0000200241186a20123a0000200241196a20133a00002002411a6a20143a00002002411b6a20153a00002002411c6a20163a00002002411d6a20173a00002002411e6a20183a00002002411f6a20193a0000200241206a201a3a0000200241216a201b3a0000200241226a201c3a0000200241236a201d3a0000200241246a201e3a0000200241256a201f3a0000200241266a20203a0000200241276a20213a0000200241286a20223a0000200241296a20233a00002002412a6a20243a00002002412b6a20253a0000200241c4006a208c013703002002413c6a208d01370300200241346a208f013703002002412c6a2092013703000240206a2069206820672066206520642063206220612060205f205e205d205c205b205a2059205820572056205520542053205220512050204f204e204d204a204c2002412041014180011011200341c0066a101a22020d004100210220032802c0062206280200410020061b450d002006280200410020061b2226450d20202641014b0d21200641086a2d0000410171450d220b2002450d220c230b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b20282092013703002028208f013703082028208d01370310202841186a208c01370300200341e0066a240041000c010b200341e0066a240020020b22030d012028290300228f012099015a202841086a290300228d012096015a208d01209601511b202841106a2903002296012098015a202841186a290300228c012097015a208c01209701511b20960120980185208c012097018584501b450d0241024120417f1011210241f8024120360200200241386a209601370300200241306a208d01370300200241286a208f01370300200241186a208e01370300200241106a209001370300200241086a209501370300200241406b208c01370300200241206a20910137030041800341f80210014180032d000021294181032d0000212c4182032d0000212d4183032d0000212e4184032d0000212f4185032d000021304186032d000021314187032d000021324188032d000021334189032d00002134418a032d00002135418b032d00002136418c032d00002137418d032d00002138418e032d00002139418f032d0000213a4190032d0000213b4191032d0000213c4192032d0000213d4193032d0000213e4194032d0000213f4195032d000021404196032d000021414197032d000021424198032d000021444199032d00002146419a032d0000212b419b032d00002127419c032d0000212a419d032d00002148419e032d00002149419f032d0000214c41204101417f1011220341276a204c3a0000200341266a20493a0000200341256a20483a0000200341246a202a3a0000200341236a20273a0000200341226a202b3a0000200341216a20463a0000200341206a20443a00002003411f6a20423a00002003411e6a20413a00002003411d6a20403a00002003411c6a203f3a00002003411b6a203e3a00002003411a6a203d3a0000200341196a203c3a0000200341186a203b3a0000200341176a203a3a0000200341166a20393a0000200341156a20383a0000200341146a20373a0000200341136a20363a0000200341126a20353a0000200341116a20343a0000200341106a20333a00002003410f6a20323a00002003410e6a20313a00002003410d6a20303a00002003410c6a202f3a00002003410b6a202e3a00002003410a6a202d3a0000200341096a202c3a0000200341086a220620293a0000419002411620062003280200410020031b10132203280200410020031b41204b044020032802002126202841206b22062400200341086a224a2026410020031b20061003200641206b2228240020062028100f204341186a202841186a2903003703002043202841106a2903003703102043202841086a290300370308204320282903003703002043204a412010100b2000280200410020001b450d032000280200410020001b41014d0d04200041276a2d0000214d200041266a2d0000214e200041256a2d0000214f200041246a2d00002150200041236a2d00002151200041226a2d00002152200041216a2d00002153200041206a2d000021542000411f6a2d000021552000411e6a2d000021562000411d6a2d000021572000411c6a2d000021582000411b6a2d000021592000411a6a2d0000215a200041196a2d0000215b200041186a2d0000215c200041176a2d0000215d200041166a2d0000215e200041156a2d0000215f200041146a2d00002160200041136a2d00002161200041126a2d00002162200041116a2d00002163200041106a2d000021642000410f6a2d000021652000410e6a2d000021662000410d6a2d000021672000410c6a2d000021682000410b6a2d000021692000410a6a2d0000216a200041096a2d00002145200041086a2d0000214b200041c7006a2d0000216b200041c6006a2d0000216c200041c5006a2d0000216d200041c4006a2d0000216e200041c3006a2d0000216f200041c2006a2d00002170200041c1006a2d00002171200041406b2d000021722000413f6a2d000021732000413e6a2d000021742000413d6a2d000021752000413c6a2d000021762000413b6a2d000021772000413a6a2d00002178200041396a2d00002179200041386a2d0000217a200041376a2d0000217b200041366a2d0000217c200041356a2d0000217d200041346a2d0000217e200041336a2d0000217f200041326a2d0000218001200041316a2d0000218101200041306a2d00002182012000412f6a2d00002183012000412e6a2d00002184012000412d6a2d00002185012000412c6a2d00002186012000412b6a2d00002187012000412a6a2d0000218801200041296a2d0000218901200041286a2d0000218a0141204101417f10112200410c6a20093a00002000410b6a20083a00002000410a6a20053a0000200041096a20043a0000200041086a220620013a00002000410d6a200a3a00002000410e6a200c3a00002000410f6a200d3a0000200041106a200e3a0000200041116a200f3a0000200041126a20103a0000200041136a20113a0000200041146a20123a0000200041156a20133a0000200041166a20143a0000200041176a20153a0000200041186a20163a0000200041196a20173a00002000411a6a20183a00002000411b6a20193a00002000411c6a201a3a00002000411d6a201b3a00002000411e6a201c3a00002000411f6a201d3a0000200041206a201e3a0000200041216a201f3a0000200041226a20203a0000200041236a20213a0000200041246a20223a0000200041256a20233a0000200041266a20243a0000200041276a20253a000041b002411220062000280200410020001b10132206280200410020061b41214f044020062802002100202841206b22262400200641086a224a2000410020061b20261003202641206b22002228240020262000100f204341386a200041186a2903003703002043200041106a2903003703302043200041086a29030037032820432000290300370320204341206a204a412010100b41c1014101417f1011222641086a224a41043a0000204a41016a2200202c3a0001200020293a00002000202d3a00022000202e3a00032000202f3a0004200020303a0005200020313a0006200020323a0007200020333a0008200020343a0009200020353a000a200020363a000b200020373a000c200020383a000d200020393a000e2000203a3a000f2000203b3a00102000203c3a00112000203d3a00122000203e3a00132000203f3a0014200020403a0015200020413a0016200020423a0017200020443a0018200020463a00192000202b3a001a200020273a001b2000202a3a001c200020483a001d200020493a001e2000204c3a001f204a41216a220020900137030820002095013703002000208e01370310200041186a209101370300202641216a222941286a2200208d013703082000208f013703002000209601370310200041186a208c01370300202941c8006a220020453a00012000204b3a00002000206a3a0002200020693a0003200020683a0004200020673a0005200020663a0006200020653a0007200020643a0008200020633a0009200020623a000a200020613a000b200020603a000c2000205f3a000d2000205e3a000e2000205d3a000f2000205c3a00102000205b3a00112000205a3a0012200020593a0013200020583a0014200020573a0015200020563a0016200020553a0017200020543a0018200020533a0019200020523a001a200020513a001b200020503a001c2000204f3a001d2000204e3a001e2000204d3a001f202941e8006a22002089013a00012000208a013a000020002088013a000220002087013a000320002086013a000420002085013a000520002084013a000620002083013a000720002082013a000820002081013a000920002080013a000a2000207f3a000b2000207e3a000c2000207d3a000d2000207c3a000e2000207b3a000f2000207a3a0010200020793a0011200020783a0012200020773a0013200020763a0014200020753a0015200020743a0016200020733a0017200020723a0018200020713a0019200020703a001a2000206f3a001b2000206e3a001c2000206d3a001d2000206c3a001e2000206b3a001f0c050b000b204341406b240020030c040b000b000b000b202641a9016a220020043a0001200020013a0000200020053a0002200020083a0003200020093a00042000200a3a00052000200c3a00062000200d3a00072000200e3a00082000200f3a0009200020103a000a200020113a000b200020123a000c200020133a000d200020143a000e200020153a000f200020163a0010200020173a0011200020183a0012200020193a00132000201a3a00142000201b3a00152000201c3a00162000201d3a00172000201e3a00182000201f3a0019200020203a001a200020213a001b200020223a001c200020233a001d200020243a001e200020253a001f202841f0006b220024002000410c3a0000202841ef006b2201410c100e200141d0024120100d202841cf006b200341086a2003280200410020031b100d2028412f6b200641086a2006280200410020061b100d200041e100202641086a2026280200410020261b1004208b012002360200204341406b240041000b2200450d01204741306a240020000c020b000b200b208b01280200360200204741306a240041000b450440200b2802002205280200410020051b220041ffffff3f712000470d012000410574220041ffffffff034b0d02027f4101200041c000490d001a4104200041ffff004b0d001a41020b20006a220820004922090d0320084101417f101121042005280200410020051b220041ffffffff034b0d0402400240200041c0004f0440200041ffff004d0d02200041ffffffff03712000470d01200441086a2000410274410272360200410421010c090b200041ffffffff03712000470d07200441086a2000410274360200410121010c080b000b2000200041ffffffff037146044041022101200441086a20004102744101723602000c070b000b0c100b000b000b000b000b000b02402000200041ffffff3f71460440200441086a20016a200541086a2000410574100d20090d014100200441086a2008100a0c0c0b000b000b000b000b000b000b000b000b000b410041004101417f101141086a4100100a0c020b2000290000218c0120002900082190012000290010218e01200029001821910141204101417f1011220041206a209101370000200041186a208e01370000200041106a209001370000200041086a2200208c013700000b410020004120100a0b200741406b2400000b0bc202060041000b58b04f776e61626c653a3a4f776e6572736869705472616e736665727265643a3a70726576696f75734f776e65720000009c4f776e61626c653a3a4f776e6572736869705472616e736665727265643a3a6e65774f776e65720041e1000b604f776e61626c653a3a4f776e6572736869705472616e7366657272656400005361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656443616c6c207265766572746564000000005061757361626c653a3a5061757365640041d1010b125061757361626c653a3a556e7061757365640041f1010b3549526f757465723a3a53776170506f6f6c52656769737465726564000000005449526f757465723a3a537761703a3a73656e6465720041b0020b124449526f757465723a3a537761703a3a746f0041d1020b0d49526f757465723a3a53776170008e010970726f64756365727302086c616e6775616765010143000c70726f6365737365642d62790105636c616e676131352e302e34202868747470733a2f2f6769746875622e636f6d2f736f6c616e612d6c6162732f6c6c766d2d70726f6a6563742e676974203333633336323963616135396235396438663538353733366134613531393461613965393337376429', + compiler: 'solang 0.3.2', + hash: '0xc3a4799cb3feb885864b7bda2b7340893d52fc4f096024e42c5c59319e9cf4ed', + language: 'Solidity 0.3.2', }, spec: { constructors: [ { args: [], + default: false, docs: [''], label: 'new', payable: false, @@ -22,6 +22,33 @@ export const routerAbi = { }, ], docs: [''], + environment: { + accountId: { + displayName: ['AccountId'], + type: 2, + }, + balance: { + displayName: ['Balance'], + type: 7, + }, + blockNumber: { + displayName: ['BlockNumber'], + type: 8, + }, + chainExtension: { + displayName: [], + type: 0, + }, + hash: { + displayName: ['Hash'], + type: 9, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 8, + }, + }, events: [ { args: [ @@ -30,7 +57,7 @@ export const routerAbi = { indexed: false, label: 'account', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -45,7 +72,7 @@ export const routerAbi = { indexed: false, label: 'account', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -60,7 +87,7 @@ export const routerAbi = { indexed: true, label: 'previousOwner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -69,7 +96,7 @@ export const routerAbi = { indexed: true, label: 'newOwner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -84,7 +111,7 @@ export const routerAbi = { indexed: false, label: 'pool', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -93,12 +120,12 @@ export const routerAbi = { indexed: false, label: 'asset', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], - docs: ['Emitted when a new pool is registered\n\n'], + docs: ['Emitted when a new pool is registered'], label: 'SwapPoolRegistered', }, { @@ -108,7 +135,7 @@ export const routerAbi = { indexed: true, label: 'sender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -117,7 +144,7 @@ export const routerAbi = { indexed: false, label: 'amountIn', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -126,7 +153,7 @@ export const routerAbi = { indexed: false, label: 'amountOut', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -135,7 +162,7 @@ export const routerAbi = { indexed: false, label: 'tokenIn', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -144,7 +171,7 @@ export const routerAbi = { indexed: false, label: 'tokenOut', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -153,22 +180,23 @@ export const routerAbi = { indexed: true, label: 'to', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], - docs: ['Emitted on each swap\n\n'], + docs: ['Emitted on each swap'], label: 'Swap', }, ], lang_error: { - displayName: [], - type: 0, + displayName: ['SolidityError'], + type: 13, }, messages: [ { args: [], + default: false, docs: [''], label: 'paused', mutates: false, @@ -181,18 +209,20 @@ export const routerAbi = { }, { args: [], + default: false, docs: [''], label: 'owner', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0x8da5cb5b', }, { args: [], + default: false, docs: [''], label: 'renounceOwnership', mutates: true, @@ -205,11 +235,12 @@ export const routerAbi = { { label: 'newOwner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [''], label: 'transferOwnership', mutates: true, @@ -222,17 +253,18 @@ export const routerAbi = { { label: '', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [''], label: 'poolByAsset', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0x06de94d8', @@ -242,17 +274,18 @@ export const routerAbi = { { label: '', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [''], label: 'oracleByAsset', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0x38163032', @@ -262,19 +295,20 @@ export const routerAbi = { { label: '_asset', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_priceOracle', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], - docs: ['Changes the pools priceOracle. Can only be set by the contract owner.\n\n'], + default: false, + docs: ['Changes the pools priceOracle. Can only be set by the contract owner.'], label: 'setPriceOracle', mutates: true, payable: false, @@ -286,19 +320,20 @@ export const routerAbi = { { label: '_asset', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_swapPool', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], - docs: ['Registers a newly created swap pool.\n\n'], + default: false, + docs: ['Registers a newly created swap pool.'], label: 'registerPool', mutates: true, payable: false, @@ -307,7 +342,8 @@ export const routerAbi = { }, { args: [], - docs: ['Disable all swaps\n\n'], + default: false, + docs: ['Disable all swaps'], label: 'pause', mutates: true, payable: false, @@ -316,7 +352,8 @@ export const routerAbi = { }, { args: [], - docs: ['Resume all swaps\n\n'], + default: false, + docs: ['Resume all swaps'], label: 'unpause', mutates: true, payable: false, @@ -328,14 +365,14 @@ export const routerAbi = { { label: '_amountIn', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, { label: '_amountOutMin', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -349,20 +386,21 @@ export const routerAbi = { { label: '_to', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_deadline', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [ - 'Swap some `_fromToken` tokens for `_toToken` tokens,\nensures `_amountOutMin` and `_deadline`, sends funds to `_to` address `msg.sender` needs to grant the chef contract a sufficient allowance beforehand\n\n', + 'Swap some `_fromToken` tokens for `_toToken` tokens,\nensures `_amountOutMin` and `_deadline`, sends funds to `_to` address `msg.sender` needs to grant the chef contract a sufficient allowance beforehand', ], label: 'swapExactTokensForTokens', mutates: true, @@ -378,7 +416,7 @@ export const routerAbi = { { label: '_amountIn', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -390,14 +428,15 @@ export const routerAbi = { }, }, ], + default: false, docs: [ - 'Get a quote for how many `_toToken` tokens `_amountIn` many `tokenIn`\ntokens can currently be swapped for.\n\n', + 'Get a quote for how many `_toToken` tokens `_amountIn` many `tokenIn`\ntokens can currently be swapped for.', ], label: 'getAmountOut', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0xb8239ebb', @@ -518,7 +557,7 @@ export const routerAbi = { def: { primitive: 'u8', }, - path: ['u8'], + path: ['uint8'], }, }, { @@ -544,7 +583,7 @@ export const routerAbi = { ], }, }, - path: ['ink_env', 'types', 'AccountId'], + path: ['ink_primitives', 'types', 'AccountId'], }, }, { @@ -553,7 +592,7 @@ export const routerAbi = { def: { primitive: 'u256', }, - path: ['u256'], + path: ['uint256'], }, }, { @@ -585,6 +624,108 @@ export const routerAbi = { }, }, }, + { + id: 7, + type: { + def: { + primitive: 'u128', + }, + path: ['uint128'], + }, + }, + { + id: 8, + type: { + def: { + primitive: 'u64', + }, + path: ['uint64'], + }, + }, + { + id: 9, + type: { + def: { + composite: { + fields: [ + { + type: 1, + }, + ], + }, + }, + path: ['ink_primitives', 'types', 'Hash'], + }, + }, + { + id: 10, + type: { + def: { + primitive: 'str', + }, + path: ['string'], + }, + }, + { + id: 11, + type: { + def: { + composite: { + fields: [ + { + type: 10, + }, + ], + }, + }, + path: ['0x08c379a0'], + }, + }, + { + id: 12, + type: { + def: { + composite: { + fields: [ + { + type: 3, + }, + ], + }, + }, + path: ['0x4e487b71'], + }, + }, + { + id: 13, + type: { + def: { + variant: { + variants: [ + { + fields: [ + { + type: 11, + }, + ], + index: 0, + name: 'Error', + }, + { + fields: [ + { + type: 12, + }, + ], + index: 1, + name: 'Panic', + }, + ], + }, + }, + path: ['SolidityError'], + }, + }, ], version: '4', } as const; diff --git a/src/contracts/nabla/SwapPool.ts b/src/contracts/nabla/SwapPool.ts index 36c840dc..1527b9d9 100644 --- a/src/contracts/nabla/SwapPool.ts +++ b/src/contracts/nabla/SwapPool.ts @@ -2,15 +2,14 @@ export const swapPoolAbi = { contract: { authors: ['unknown'], description: - 'Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool:\nThe owner can either pause the pool, disabling deposits, swaps & backstop,\nor the owner can set the pool cap to zero which only prevents deposits.\nThe former is for security incidents, the latter for phasing out a pool.', + 'Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool.', name: 'SwapPool', version: '0.0.1', }, source: { - compiler: 'solang 0.3.0', - hash: '0x4a12c227b7d0f5c0f9f5cd85c30f802f50f54542082eaf6a0440dea049265827', - language: 'Solidity 0.3.0', - wasm: '0x0061736d010000000192031560027f7f0060047f7f7f7f017f60037f7f7f0060000060027f7f017f60047f7e7e7f0060447f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7e7e7e7e017f6000017f60067e7e7e7e7f7f017f60047f7f7f7f0060087f7f7e7f7f7f7f7f017f60017f017f60217f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60417f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60247f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7e7e7e7e017f60207f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60237f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f017f60027e7f017f60087e7e7e7e7f7f7f7f017f60037f7e7e0060077e7e7e7e7f7f7f017f02a6020f057365616c310d636c6561725f73746f726167650004057365616c320b7365745f73746f726167650001057365616c300f686173685f6b656363616b5f3235360002057365616c310b6765745f73746f726167650001057365616c300663616c6c65720000057365616c300f686173685f626c616b65325f3235360002057365616c300d6465706f7369745f6576656e740009057365616c300762616c616e63650000057365616c31097365616c5f63616c6c000a057365616c3007616464726573730000057365616c300c626c6f636b5f6e756d6265720000057365616c300b7365616c5f72657475726e0002057365616c3005696e7075740000057365616c301176616c75655f7472616e73666572726564000003656e76066d656d6f727902011010031e1d02000002040b0103010505010c0d06060e07070f1011081208130303140608017f01418080040b071102066465706c6f7900280463616c6c00290aa398051db50101027f02402002450d00200241016b2002410771220304400340200020012d00003a0000200041016a2100200141016a2101200241016b2102200341016b22030d000b0b4107490d000340200020012d00003a0000200020012d00013a0001200020012d00023a0002200020012d00033a0003200020012d00043a0004200020012d00053a0005200020012d00063a0006200020012d00073a0007200041086a2100200141086a2101200241086b22020d000b0b0ba10101027f02402001450d00200141016b200141077122020440034020004200370300200041086a2100200141016b2101200241016b22020d000b0b4107490d00034020004200370300200041386a4200370300200041306a4200370300200041286a4200370300200041206a4200370300200041186a4200370300200041106a4200370300200041086a4200370300200041406b2100200141086b22010d000b0b0b930101037f4120210302404100450440200041206a21040c010b03402001200341016b220320006a22042d00003a0000200141016a2101200241016b22020d000b0b200441046b210203402001200241036a2d00003a00002001200241026a2d00003a00012001200241016a2d00003a0002200120022d00003a0003200241046b2102200141046a2101200341046b22030d000b0b9f0101037f200241016b024020024103712203450440200120026a21040c010b0340200241016b220220016a220420002d00003a0000200041016a2100200341016b22030d000b0b41034f0440200441046b21030340200341036a20002d00003a0000200341026a20002d00013a0000200341016a20002d00023a0000200320002d00033a0000200041046a2100200341046b2103200241046b22020d000b0b0bb30201047f2000220241086a10132204200036020420042000360200200441086a210002402001417f4704402002450d01200241016b2002410771220304400340200020012d00003a0000200041016a2100200141016a2101200241016b2102200341016b22030d000b0b4107490d010340200020012d00003a0000200020012d00013a0001200020012d00023a0002200020012d00033a0003200020012d00043a0004200020012d00053a0005200020012d00063a0006200020012d00073a0007200041086a2100200141086a2101200241086b22020d000b0c010b2002450d00200241016b2002410771220104400340200041003a0000200041016a2100200241016b2102200141016b22010d000b0b4107490d00034020004200370000200041086a2100200241086b22020d000b0b20040b950101047f41808004210103400240200128020c0d00200128020822022000490d002002200041076a41787122026b220441184f0440200120026a41106a22002001280200220336020020030440200320003602040b2000200441106b3602082000410036020c2000200136020420012000360200200120023602080b2001410136020c200141106a0f0b200128020021010c000b000b890301047f200120036a220441086a10132205200436020420052004360200200541086a210402402001450d00200141016b2001410771220604400340200420002d00003a0000200441016a2104200041016a2100200141016b2101200641016b22060d000b0b4107490d000340200420002d00003a0000200420002d00013a0001200420002d00023a0002200420002d00033a0003200420002d00043a0004200420002d00053a0005200420002d00063a0006200420002d00073a0007200441086a2104200041086a2100200141086b22010d000b0b02402003450d00200341016b2003410771220004400340200420022d00003a0000200441016a2104200241016a2102200341016b2103200041016b22000d000b0b4107490d000340200420022d00003a0000200420022d00013a0001200420022d00023a0002200420022d00033a0003200420022d00043a0004200420022d00053a0005200420022d00063a0006200420022d00073a0007200441086a2104200241086a2102200341086b22030d000b0b20050b2e00418080044100360200418480044100360200418c80044100360200418880043f00411074419080046b3602000b8303020c7f027e2003411f752003712107200341027420006a41046b210520032104027f03402007200441004c0d011a200441016b21042005280200200541046b2105450d000b200441016a0b2108200341027420016a41046b21052003210402400340200441004c0d01200441016b21042005280200200541046b2105450d000b200441016a21070b200341004c044041000f0b41012003410174220b200b41014c1b210e200141046b210f410021014101210c4100210603402009200120074e6a21090240200620062007486a2206200a200120084e6a220a4d0440420021110c010b2006200a6b210d200020094102746a2104200f20064102746a210542002111034020114280808080107c201120102010200535020020043502007e7c2210561b2111200441046a2104200541046b2105200d41016b220d0d000b0b0240024020012003480440200220014102746a20103e02000c010b20104200520d010b200141016a2201200b48210c201042208820118421102001200e470d010b0b200c0b5001017e02402003450d00200341c00071044020012003413f71ad862102420021010c010b20022003ad220486200141c00020036bad88842102200120048621010b20002002370308200020013703000b5001017e02402003450d00200341c00071044020022003413f71ad882101420021020c010b200241c00020036bad8620012003ad220488842101200220048821020b20002002370308200020013703000bb51102197e047f230041f0006b221d2400200041186a2903002106200041106a2903002108200041086a29030021072000290300210a027f02402001290300220f420156200141086a290300220c420052200c501b200141106a2903002210420052200141186a290300220b420052200b5022201b200b201084501b4504404101200fa741016b0d021a200242003703102002420037030820024200370300200241186a4200370300200320083703102003200a37030020032007370308200341186a20063703000c010b20082010852204200a200f85842006200b8522052007200c858484500440200242003703102002420037030820024200370300200241186a420037030020034200370310200341186a420037030020034201370300200342003703080c010b2008200a84200620078484504101200a200f5a2007200c5a2007200c511b200820105a2006200b5a2006200b511b2004200584501b1b04402002200a3703002002200737030820022008370310200241186a200637030020034200370310200341186a420037030020034200370300200342003703080c010b41c0012100027f02402006220450221f450d004180012100200822044200520d0041c0002100200722044200520d0041002200200a2204500d011a0b2000411f413f20044280808080105422001b220141106b20012004422086200420001b220442808080808080c0005422001b220141086b20012004421086200420001b2204428080808080808080015422001b220141046b20012004420886200420001b2204428080808080808080105422001b220141026b20012004420486200420001b2204428080808080808080c0005422001b6a2004420286200420001b423f87a7417f736a0b210041c0012101200b2104201d41306a200f200c4180012000027f02402020450d004180012101201022044200520d0041c0002101200c22044200520d0041002201200f2204500d011a0b2001411f413f20044280808080105422011b221e41106b201e2004422086200420011b220442808080808080c0005422011b221e41086b201e2004421086200420011b2204428080808080808080015422011b221e41046b201e2004420886200420011b2204428080808080808080105422011b221e41026b201e2004420486200420011b2204428080808080808080c0005422011b6a2004420286200420011b423f87a7417f736a0b6b22006b1018201d41e0006a2010200b20001017201d41406b200f200c20004180016b1017201d41d0006a200f200c20001017201d41e8006a290300201d41386a29030084201d41c8006a290300200041800149221e1b201d290360201d29033084201d290340201e1b2109201d41d8006a290300210d201d290350211141c001210120062104027f0240201f450d004180012101200822044200520d0041c0002101200722044200520d0041002201200a2204500d011a0b2001411f413f20044280808080105422011b221f41106b201f2004422086200420011b220442808080808080c0005422011b221f41086b201f2004421086200420011b2204428080808080808080015422011b221f41046b201f2004420886200420011b2204428080808080808080105422011b221f41026b201f2004420486200420011b2204428080808080808080c0005422011b6a2004420286200420011b423f87a7417f736a0b2101200b20001b21042009201020001b210e200d4200201e1b210d20114200201e1b211141c0012100200b2105201d41106a420142002001027f02402020450d004180012100201022054200520d0041c0002100200c22054200520d0041002200200f2205500d011a0b2000411f413f20054280808080105422001b221e41106b201e2005422086200520001b220542808080808080c0005422001b221e41086b201e2005421086200520001b2205428080808080808080015422001b221e41046b201e2005420886200520001b2205428080808080808080105422001b221e41026b201e2005420486200520001b2205428080808080808080c0005422001b6a2005420286200520001b423f87a7417f736a0b6b22004180016b1017201d4201420041800120006b1018201d41206a4201420020001017200e200a2011542007200d542007200d511b2008200e54200420065620042006511b2008200e85200420068584501b221ead2209882004420186201e413f73ad221286842105200d4201862012862011200988842111201d290300201d29031020004180014922011b420020001b2213200988201d41086a290300201d41186a29030020011b420020001b2214420186201286842117201d41286a290300420020011b2215420186201286201d290320420020011b200988842112200e420186201e417f73413f71ad221686200d20098884210e2013420186201686201520098884210d20042009882104201420098821094200211342002114420021154200211603404200200e200a2011542007200e542007200e511b2005200856200420065620042006511b2005200885200420068584501b22001b21184200201120001b211a4200200420001b211b20084200200520001b22195421014200200920001b20168421164200201720001b20158421154200200d20001b20148421144200201220001b2013842113200d423f862012420188842112200e423f8620114201888421112017423f86200d42018884210d2005423f86200e42018884210e2009423f8620174201888421172004423f8620054201888421052009420188210920044201882104200820197d2219200a201a542200200720185420072018511bad221c7d2108200a201a7d220a200f5a200720187d2000ad7d2207200c5a2007200c511b200820105a2006201b7d2001ad7d2019201c54ad7d2206200b5a2006200b511b20082010852006200b8584501b0d000b200320133703002003201437030820032015370310200341186a201637030020022008370310200241186a20063703002002200a370300200220073703080b41000b201d41f0006a24000b9d0402027f047e230041406a22222400202241406a22212400202141186a4200370300202142003703102021420037030820214203370300202141206a20003a0000202141216a20013a0000202141226a20023a0000202141236a20033a0000202141246a20043a0000202141256a20053a0000202141266a20063a0000202141276a20073a0000202141286a20083a0000202141296a20093a00002021412a6a200a3a00002021412b6a200b3a00002021412c6a200c3a00002021412d6a200d3a00002021412e6a200e3a00002021412f6a200f3a0000202141306a20103a0000202141316a20113a0000202141326a20123a0000202141336a20133a0000202141346a20143a0000202141356a20153a0000202141366a20163a0000202141376a20173a0000202141386a20183a0000202141396a20193a00002021413a6a201a3a00002021413b6a201b3a00002021413c6a201c3a00002021413d6a201d3a00002021413e6a201e3a00002021413f6a201f3a0000202141c000202241206a100241f8044120360200202241186a202241386a2903003703002022202241306a2903003703102022202241286a29030037030820222022290320370300027e2022412041800541f8041003044042000c010b4190052903002125418805290300212441800529030021234198052903000b2126202020233703002020202437030820202025370310202041186a2026370300202241406b240041000bc30702027f057e230041e0006b22422400204241406a22412400204141186a4200370300204142003703102041420037030820414204370300204141206a20003a0000204141216a20013a0000204141226a20023a0000204141236a20033a0000204141246a20043a0000204141256a20053a0000204141266a20063a0000204141276a20073a0000204141286a20083a0000204141296a20093a00002041412a6a200a3a00002041412b6a200b3a00002041412c6a200c3a00002041412d6a200d3a00002041412e6a200e3a00002041412f6a200f3a0000204141306a20103a0000204141316a20113a0000204141326a20123a0000204141336a20133a0000204141346a20143a0000204141356a20153a0000204141366a20163a0000204141376a20173a0000204141386a20183a0000204141396a20193a00002041413a6a201a3a00002041413b6a201b3a00002041413c6a201c3a00002041413d6a201d3a00002041413e6a201e3a00002041413f6a201f3a0000204141c000204241406b1002204241c8006a2903002147204241d0006a2903002143204241d8006a290300214420422903402145204141406a22002400200041186a2044370300200020433703102000204737030820002045370300200041206a20203a0000200041216a20213a0000200041226a20223a0000200041236a20233a0000200041246a20243a0000200041256a20253a0000200041266a20263a0000200041276a20273a0000200041286a20283a0000200041296a20293a00002000412a6a202a3a00002000412b6a202b3a00002000412c6a202c3a00002000412d6a202d3a00002000412e6a202e3a00002000412f6a202f3a0000200041306a20303a0000200041316a20313a0000200041326a20323a0000200041336a20333a0000200041346a20343a0000200041356a20353a0000200041366a20363a0000200041376a20373a0000200041386a20383a0000200041396a20393a00002000413a6a203a3a00002000413b6a203b3a00002000413c6a203c3a00002000413d6a203d3a00002000413e6a203e3a00002000413f6a203f3a0000200041c000204241206a100241f8044120360200204241186a204241386a2903003703002042204241306a2903003703102042204241286a29030037030820422042290320370300027e2042412041800541f80410030440420021434200214442000c010b4190052903002144418805290300214341800529030021464198052903000b2145204020463703002040204337030820402044370310204041186a2045370300204241e0006a240041000bee1602077f047e230041e0006b224421462044240002402000200172200272200372200472200572200672200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f7241ff017104402020202172202272202372202472202572202672202772202872202972202a72202b72202c72202d72202e72202f72203072203172203272203372203472203572203672203772203872203972203a72203b72203c72203d72203e72203f7241ff0171450d01204441406a22442400204441186a4200370300204442003703102044420037030820444204370300204441206a20003a0000204441216a20013a0000204441226a20023a0000204441236a20033a0000204441246a20043a0000204441256a20053a0000204441266a20063a0000204441276a20073a0000204441286a20083a0000204441296a20093a00002044412a6a200a3a00002044412b6a200b3a00002044412c6a200c3a00002044412d6a200d3a00002044412e6a200e3a00002044412f6a200f3a0000204441306a20103a0000204441316a20113a0000204441326a20123a0000204441336a20133a0000204441346a20143a0000204441356a20153a0000204441366a20163a0000204441376a20173a0000204441386a20183a0000204441396a20193a00002044413a6a201a3a00002044413b6a201b3a00002044413c6a201c3a00002044413d6a201d3a00002044413e6a201e3a00002044413f6a201f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214e204541406a22442400204441186a204e3703002044204d3703102044204c3703082044204b370300204441206a20203a0000204441216a20213a0000204441226a20223a0000204441236a20233a0000204441246a20243a0000204441256a20253a0000204441266a20263a0000204441276a20273a0000204441286a20283a0000204441296a20293a00002044412a6a202a3a00002044412b6a202b3a00002044412c6a202c3a00002044412d6a202d3a00002044412e6a202e3a00002044412f6a202f3a0000204441306a20303a0000204441316a20313a0000204441326a20323a0000204441336a20333a0000204441346a20343a0000204441356a20353a0000204441366a20363a0000204441376a20373a0000204441386a20383a0000204441396a20393a00002044413a6a203a3a00002044413b6a203b3a00002044413c6a203c3a00002044413d6a203d3a00002044413e6a203e3a00002044413f6a203f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214e204541206b224422452400204641186a2043370300204441186a204e3703002044204d3703102044204c3703082044204b370300204620423703102046204137030820462040370300204441202046412010011a4120417f1012224441276a201f3a0000204441266a201e3a0000204441256a201d3a0000204441246a201c3a0000204441236a201b3a0000204441226a201a3a0000204441216a20193a0000204441206a20183a00002044411f6a20173a00002044411e6a20163a00002044411d6a20153a00002044411c6a20143a00002044411b6a20133a00002044411a6a20123a0000204441196a20113a0000204441186a20103a0000204441176a200f3a0000204441166a200e3a0000204441156a200d3a0000204441146a200c3a0000204441136a200b3a0000204441126a200a3a0000204441116a20093a0000204441106a20083a00002044410f6a20073a00002044410e6a20063a00002044410d6a20053a00002044410c6a20043a00002044410b6a20033a00002044410a6a20023a0000204441096a20013a0000204441086a224820003a000041e000411820482044280200410020441b10142248280200410020481b41204b044020482802002144204541206b224722452400204841086a22492044410020481b20471005204541206b224422452400204720441010204641386a204441186a2903003703002046204441106a2903003703302046204441086a29030037032820462044290300370320204641206a2049412010110b4120417f10122244410a6a20223a0000204441096a20213a0000204441086a224720203a00002044410b6a20233a00002044410c6a20243a00002044410d6a20253a00002044410e6a20263a00002044410f6a20273a0000204441106a20283a0000204441116a20293a0000204441126a202a3a0000204441136a202b3a0000204441146a202c3a0000204441156a202d3a0000204441166a202e3a0000204441176a202f3a0000204441186a20303a0000204441196a20313a00002044411a6a20323a00002044411b6a20333a00002044411c6a20343a00002044411d6a20353a00002044411e6a20363a00002044411f6a20373a0000204441206a20383a0000204441216a20393a0000204441226a203a3a0000204441236a203b3a0000204441246a203c3a0000204441256a203d3a0000204441266a203e3a0000204441276a203f3a0000418001411a20472044280200410020441b10142247280200410020471b41214f044020472802002144204541206b224922452400204741086a224a2044410020471b20491005204541206b224422452400204920441010204641d8006a204441186a2903003703002046204441106a2903003703502046204441086a29030037034820462044290300370340204641406b204a412010110b41e100417f1012224441096a20003a0000204441086a224941013a00002044410a6a20013a00002044410b6a20023a00002044410c6a20033a00002044410d6a20043a00002044410e6a20053a00002044410f6a20063a0000204441106a20073a0000204441116a20083a0000204441126a20093a0000204441136a200a3a0000204441146a200b3a0000204441156a200c3a0000204441166a200d3a0000204441176a200e3a0000204441186a200f3a0000204441196a20103a00002044411a6a20113a00002044411b6a20123a00002044411c6a20133a00002044411d6a20143a00002044411e6a20153a00002044411f6a20163a0000204441206a20173a0000204441216a20183a0000204441226a20193a0000204441236a201a3a0000204441246a201b3a0000204441256a201c3a0000204441266a201d3a0000204441276a201e3a0000204441286a201f3a0000204441c8006a203f3a0000204441c7006a203e3a0000204441c6006a203d3a0000204441c5006a203c3a0000204441c4006a203b3a0000204441c3006a203a3a0000204441c2006a20393a0000204441c1006a20383a0000204441406b20373a00002044413f6a20363a00002044413e6a20353a00002044413d6a20343a00002044413c6a20333a00002044413b6a20323a00002044413a6a20313a0000204441396a20303a0000204441386a202f3a0000204441376a202e3a0000204441366a202d3a0000204441356a202c3a0000204441346a202b3a0000204441336a202a3a0000204441326a20293a0000204441316a20283a0000204441306a20273a00002044412f6a20263a00002044412e6a20253a00002044412d6a20243a00002044412c6a20233a00002044412b6a20223a00002044412a6a20213a0000204441296a20203a0000204441e1006a2043370300204441d9006a2042370300204441d1006a2041370300204441c9006a2040370300204541f0006b220024002000410c3a0000204541ef006b2201410c100f200141a0014120100e204541cf006b204841086a2048280200410020481b100e2045412f6b204741086a2047280200410020471b100e200041e10020492044280200410020441b1006204641e0006a240041000f0b000b000bfd2002077f087e23004180016b2244214620442400024002402000200172200272200372200472200572200672200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f7241ff017104402020202172202272202372202472202572202672202772202872202972202a72202b72202c72202d72202e72202f72203072203172203272203372203472203572203672203772203872203972203a72203b72203c72203d72203e72203f7241ff0171450d01027e204441406a22442400204441186a4200370300204442003703102044420037030820444203370300204441206a20003a0000204441216a20013a0000204441226a20023a0000204441236a20033a0000204441246a20043a0000204441256a20053a0000204441266a20063a0000204441276a20073a0000204441286a20083a0000204441296a20093a00002044412a6a200a3a00002044412b6a200b3a00002044412c6a200c3a00002044412d6a200d3a00002044412e6a200e3a00002044412f6a200f3a0000204441306a20103a0000204441316a20113a0000204441326a20123a0000204441336a20133a0000204441346a20143a0000204441356a20153a0000204441366a20163a0000204441376a20173a0000204441386a20183a0000204441396a20193a00002044413a6a201a3a00002044413b6a201b3a00002044413c6a201c3a00002044413d6a201d3a00002044413e6a201e3a00002044413f6a201f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214e204541206b22442400204441186a204e3703002044204d3703102044204c3703082044204b37030041f80441203602002044412041800541f804100304404200214c4200214d42000c010b419005290300214d418805290300214c418005290300214f4198052903000b214b027e02402040204f5622482041204c562041204c511b22472042204d5622492043204b562043204b511b2042204d852043204b8584501b450440204441406a22442400204441186a4200370300204442003703102044420037030820444203370300204441206a20003a0000204441216a20013a0000204441226a20023a0000204441236a20033a0000204441246a20043a0000204441256a20053a0000204441266a20063a0000204441276a20073a0000204441286a20083a0000204441296a20093a00002044412a6a200a3a00002044412b6a200b3a00002044412c6a200c3a00002044412d6a200d3a00002044412e6a200e3a00002044412f6a200f3a0000204441306a20103a0000204441316a20113a0000204441326a20123a0000204441336a20133a0000204441346a20143a0000204441356a20153a0000204441366a20163a0000204441376a20173a0000204441386a20183a0000204441396a20193a00002044413a6a201a3a00002044413b6a201b3a00002044413c6a201c3a00002044413d6a201d3a00002044413e6a201e3a00002044413f6a201f3a0000204441206b22452400204441c000204510022045290300214e204541086a2903002150204541106a2903002151204541186a2903002152204541206b22442400204641186a204b20437d2049ad7d204d20427d224b2047ad224d54ad7d370300204441186a205237030020442051370310204420503703082044204e3703002046204b204d7d3703102046204c20417d2048ad7d3703082046204f20407d370300204441202046412010011a204441406a22442400204441186a4200370300204442003703102044420037030820444203370300204441206a20203a0000204441216a20213a0000204441226a20223a0000204441236a20233a0000204441246a20243a0000204441256a20253a0000204441266a20263a0000204441276a20273a0000204441286a20283a0000204441296a20293a00002044412a6a202a3a00002044412b6a202b3a00002044412c6a202c3a00002044412d6a202d3a00002044412e6a202e3a00002044412f6a202f3a0000204441306a20303a0000204441316a20313a0000204441326a20323a0000204441336a20333a0000204441346a20343a0000204441356a20353a0000204441366a20363a0000204441376a20373a0000204441386a20383a0000204441396a20393a00002044413a6a203a3a00002044413b6a203b3a00002044413c6a203c3a00002044413d6a203d3a00002044413e6a203e3a00002044413f6a203f3a0000204441206b22452400204441c000204510022045290300214b204541086a290300214c204541106a290300214d204541186a290300214f204541206b22442400204441186a204f3703002044204d3703102044204c3703082044204b37030041f80441203602002044412041800541f8041003450d014200214c4200214d4200214f42000c020b000b419805290300214f419005290300214d418005290300214c4188052903000b214b204441406a22442400204441186a4200370300204442003703102044420037030820444203370300204441206a20203a0000204441216a20213a0000204441226a20223a0000204441236a20233a0000204441246a20243a0000204441256a20253a0000204441266a20263a0000204441276a20273a0000204441286a20283a0000204441296a20293a00002044412a6a202a3a00002044412b6a202b3a00002044412c6a202c3a00002044412d6a202d3a00002044412e6a202e3a00002044412f6a202f3a0000204441306a20303a0000204441316a20313a0000204441326a20323a0000204441336a20333a0000204441346a20343a0000204441356a20353a0000204441366a20363a0000204441376a20373a0000204441386a20383a0000204441396a20393a00002044413a6a203a3a00002044413b6a203b3a00002044413c6a203c3a00002044413d6a203d3a00002044413e6a203e3a00002044413f6a203f3a0000204441206b22452400204441c000204510022045290300214e204541086a2903002150204541106a2903002151204541186a2903002152204541206b224422452400204441186a205237030020442051370310204420503703082044204e37030020462040204c7c224e3703202046204c204e562248ad2041204b7c7c224c37032820462042204d7c224e2048204b204c56204b204c511bad7c224b370330204641386a204b204e54ad204d204e56ad2043204f7c7c7c37030020444120204641206a412010011a4120417f1012224441276a201f3a0000204441266a201e3a0000204441256a201d3a0000204441246a201c3a0000204441236a201b3a0000204441226a201a3a0000204441216a20193a0000204441206a20183a00002044411f6a20173a00002044411e6a20163a00002044411d6a20153a00002044411c6a20143a00002044411b6a20133a00002044411a6a20123a0000204441196a20113a0000204441186a20103a0000204441176a200f3a0000204441166a200e3a0000204441156a200d3a0000204441146a200c3a0000204441136a200b3a0000204441126a200a3a0000204441116a20093a0000204441106a20083a00002044410f6a20073a00002044410e6a20063a00002044410d6a20053a00002044410c6a20043a00002044410b6a20033a00002044410a6a20023a0000204441096a20013a0000204441086a224820003a00004100411720482044280200410020441b10142248280200410020481b41214f044020482802002144204541206b224722452400204841086a22492044410020481b20471005204541206b224422452400204720441010204641d8006a204441186a2903003703002046204441106a2903003703502046204441086a29030037034820462044290300370340204641406b2049412010110b4120417f10122244410a6a20223a0000204441096a20213a0000204441086a224720203a00002044410b6a20233a00002044410c6a20243a00002044410d6a20253a00002044410e6a20263a00002044410f6a20273a0000204441106a20283a0000204441116a20293a0000204441126a202a3a0000204441136a202b3a0000204441146a202c3a0000204441156a202d3a0000204441166a202e3a0000204441176a202f3a0000204441186a20303a0000204441196a20313a00002044411a6a20323a00002044411b6a20333a00002044411c6a20343a00002044411d6a20353a00002044411e6a20363a00002044411f6a20373a0000204441206a20383a0000204441216a20393a0000204441226a203a3a0000204441236a203b3a0000204441246a203c3a0000204441256a203d3a0000204441266a203e3a0000204441276a203f3a00004120411520472044280200410020441b10142247280200410020471b41214f044020472802002144204541206b224922452400204741086a224a2044410020471b20491005204541206b224422452400204920441010204641f8006a204441186a2903003703002046204441106a2903003703702046204441086a29030037036820462044290300370360204641e0006a204a412010110b41e100417f1012224441096a20003a0000204441086a224941003a00002044410a6a20013a00002044410b6a20023a00002044410c6a20033a00002044410d6a20043a00002044410e6a20053a00002044410f6a20063a0000204441106a20073a0000204441116a20083a0000204441126a20093a0000204441136a200a3a0000204441146a200b3a0000204441156a200c3a0000204441166a200d3a0000204441176a200e3a0000204441186a200f3a0000204441196a20103a00002044411a6a20113a00002044411b6a20123a00002044411c6a20133a00002044411d6a20143a00002044411e6a20153a00002044411f6a20163a0000204441206a20173a0000204441216a20183a0000204441226a20193a0000204441236a201a3a0000204441246a201b3a0000204441256a201c3a0000204441266a201d3a0000204441276a201e3a0000204441286a201f3a0000204441c8006a203f3a0000204441c7006a203e3a0000204441c6006a203d3a0000204441c5006a203c3a0000204441c4006a203b3a0000204441c3006a203a3a0000204441c2006a20393a0000204441c1006a20383a0000204441406b20373a00002044413f6a20363a00002044413e6a20353a00002044413d6a20343a00002044413c6a20333a00002044413b6a20323a00002044413a6a20313a0000204441396a20303a0000204441386a202f3a0000204441376a202e3a0000204441366a202d3a0000204441356a202c3a0000204441346a202b3a0000204441336a202a3a0000204441326a20293a0000204441316a20283a0000204441306a20273a00002044412f6a20263a00002044412e6a20253a00002044412d6a20243a00002044412c6a20233a00002044412b6a20223a00002044412a6a20213a0000204441296a20203a0000204441e1006a2043370300204441d9006a2042370300204441d1006a2041370300204441c9006a2040370300204541f0006b220024002000410c3a0000204541ef006b2201410c100f200141c0004120100e204541cf006b204841086a2048280200410020481b100e2045412f6b204741086a2047280200410020471b100e200041e10020492044280200410020441b10060c020b000b000b20464180016a240041000b9a1502077f087e23004180016b222421262024240002402000200172200272200372200472200572200672200772200872200972200a72200b72200c72200d72200e72200f72201072201172201272201372201472201572201672201772201872201972201a72201b72201c72201d72201e72201f7241ff01710440027e202441406a22242400202441186a4200370300202442003703102024420037030820244203370300202441206a20003a0000202441216a20013a0000202441226a20023a0000202441236a20033a0000202441246a20043a0000202441256a20053a0000202441266a20063a0000202441276a20073a0000202441286a20083a0000202441296a20093a00002024412a6a200a3a00002024412b6a200b3a00002024412c6a200c3a00002024412d6a200d3a00002024412e6a200e3a00002024412f6a200f3a0000202441306a20103a0000202441316a20113a0000202441326a20123a0000202441336a20133a0000202441346a20143a0000202441356a20153a0000202441366a20163a0000202441376a20173a0000202441386a20183a0000202441396a20193a00002024413a6a201a3a00002024413b6a201b3a00002024413c6a201c3a00002024413d6a201d3a00002024413e6a201e3a00002024413f6a201f3a0000202441206b22252400202441c000202510022025290300212c202541086a290300212d202541106a290300212b202541186a290300212f202541206b22242400202441186a202f3703002024202b3703102024202d3703082024202c37030041f80441203602002024412041800541f804100304404200212d4200212b42000c010b419005290300212b418805290300212d418005290300212e4198052903000b212c027e02402020202e5622282021202d562021202d511b22272022202b5622292023202c562023202c511b2022202b852023202c8584501b450440202441406a22242400202441186a4200370300202442003703102024420037030820244203370300202441206a20003a0000202441216a20013a0000202441226a20023a0000202441236a20033a0000202441246a20043a0000202441256a20053a0000202441266a20063a0000202441276a20073a0000202441286a20083a0000202441296a20093a00002024412a6a200a3a00002024412b6a200b3a00002024412c6a200c3a00002024412d6a200d3a00002024412e6a200e3a00002024412f6a200f3a0000202441306a20103a0000202441316a20113a0000202441326a20123a0000202441336a20133a0000202441346a20143a0000202441356a20153a0000202441366a20163a0000202441376a20173a0000202441386a20183a0000202441396a20193a00002024413a6a201a3a00002024413b6a201b3a00002024413c6a201c3a00002024413d6a201d3a00002024413e6a201e3a00002024413f6a201f3a0000202441206b22252400202441c000202510022025290300212f202541086a2903002130202541106a2903002131202541186a2903002132202541206b22242400202641186a202c20237d2029ad7d202b20227d222c2027ad222b54ad7d370300202441186a203237030020242031370310202420303703082024202f3703002026202c202b7d3703102026202d20217d2028ad7d3703082026202e20207d370300202441202026412010011a202441206b22242400202441186a420037030020244200370310202442003703082024420537030041f80441203602002024412041800541f8041003450d014200212d4200212b4200212e42000c020b000b419805290300212e419005290300212b418005290300212d4188052903000b212c202441206b222422252400202441186a4200370300202442003703102024420037030820244205370300202641386a202e20237d2022202b56ad7d202b20227d222b2020202d5622282021202c562021202c511bad222e54ad7d3703002026202c20217d2028ad7d3703282026202d20207d3703202026202b202e7d37033020244120202641206a412010011a4120417f1012222441136a200b3a0000202441126a200a3a0000202441116a20093a0000202441106a20083a00002024410f6a20073a00002024410e6a20063a00002024410d6a20053a00002024410c6a20043a00002024410b6a20033a00002024410a6a20023a0000202441096a20013a0000202441086a222820003a0000202441146a200c3a0000202441156a200d3a0000202441166a200e3a0000202441176a200f3a0000202441186a20103a0000202441196a20113a00002024411a6a20123a00002024411b6a20133a00002024411c6a20143a00002024411d6a20153a00002024411e6a20163a00002024411f6a20173a0000202441206a20183a0000202441216a20193a0000202441226a201a3a0000202441236a201b3a0000202441246a201c3a0000202441256a201d3a0000202441266a201e3a0000202441276a201f3a00004100411720282024280200410020241b10142228280200410020281b41214f044020282802002124202541206b222722252400202841086a22292024410020281b20271005202541206b222422252400202720241010202641d8006a202441186a2903003703002026202441106a2903003703502026202441086a29030037034820262024290300370340202641406b2029412010110b4120417f1012222441206a4200370000202441186a4200370000202441106a4200370000202441086a222742003700004120411520272024280200410020241b10142227280200410020271b41214f044020272802002124202541206b222922252400202741086a222a2024410020271b20291005202541206b222422252400202920241010202641f8006a202441186a2903003703002026202441106a2903003703702026202441086a29030037036820262024290300370360202641e0006a202a412010110b41e100417f1012222441096a20003a0000202441086a222941003a00002024410a6a20013a00002024410b6a20023a00002024410c6a20033a00002024410d6a20043a00002024410e6a20053a00002024410f6a20063a0000202441106a20073a0000202441116a20083a0000202441126a20093a0000202441136a200a3a0000202441146a200b3a0000202441156a200c3a0000202441166a200d3a0000202441176a200e3a0000202441186a200f3a0000202441196a20103a00002024411a6a20113a00002024411b6a20123a00002024411c6a20133a00002024411d6a20143a00002024411e6a20153a00002024411f6a20163a0000202441206a20173a0000202441216a20183a0000202441226a20193a0000202441236a201a3a0000202441246a201b3a0000202441256a201c3a0000202441266a201d3a0000202441276a201e3a0000202441286a201f3a0000202441e1006a2023370300202441d9006a2022370300202441d1006a2021370300202441c9006a2020370300202441c1006a4200370000202441396a4200370000202441316a4200370000202441296a4200370000202541f0006b220024002000410c3a0000202541ef006b2201410c100f200141c0004120100e202541cf006b202841086a2028280200410020281b100e2025412f6b202741086a2027280200410020271b100e200041e10020292024280200410020241b10060c010b000b20264180016a240041000bdf0102027f047e230041406a2200240041f8044120360200200041186a4200370300200042003703102000420037030820004201370300027e2000412041800541f8041003044042000c010b4190052903002104418805290300210341800529030021024198052903000b2105200242028520048420032005848450450440200041206b22012400200041386a4200370300200141186a420037030020014200370310200142003703082001420137030020004200370330200042003703282000420237032020014120200041206a412010011a200041406b240041000f0b000bb60a01227f230041406a2200240041f8044120360200200041386a4200370300200042003703302000420037032820004200370320200041206a412041800541f804100321024180052d000021034181052d000021044182052d000021054183052d000021064184052d000021074185052d000021084186052d000021094187052d0000210a4188052d0000210b4189052d0000210c418a052d0000210d418b052d0000210e418c052d0000210f418d052d00002110418e052d00002111418f052d000021124190052d000021134191052d000021144192052d000021154193052d000021164194052d000021174195052d000021184196052d000021194197052d0000211a4198052d0000211b4199052d0000211c419a052d0000211d419b052d0000211e419c052d0000211f419d052d00002120419e052d0000212120004100419f052d000020021b3a001f20004100202120021b3a001e20004100202020021b3a001d20004100201f20021b3a001c20004100201e20021b3a001b20004100201d20021b3a001a20004100201c20021b3a001920004100201b20021b3a001820004100201a20021b3a001720004100201920021b3a001620004100201820021b3a001520004100201720021b3a001420004100201620021b3a001320004100201520021b3a001220004100201420021b3a001120004100201320021b3a001020004100201220021b3a000f20004100201120021b3a000e20004100201020021b3a000d20004100200f20021b3a000c20004100200e20021b3a000b20004100200d20021b3a000a20004100200c20021b3a000920004100200b20021b3a000820004100200a20021b3a000720004100200920021b3a000620004100200820021b3a000520004100200720021b3a000420004100200620021b3a000320004100200520021b3a000220004100200420021b3a000120004100200320021b3a000020002d001f210220002d001e210320002d001d210420002d001c210520002d001b210620002d001a210720002d0019210820002d0018210920002d0017210a20002d0016210b20002d0015210c20002d0014210d20002d0013210e20002d0012210f20002d0011211020002d0010211120002d000f211220002d000e211320002d000d211420002d000c211520002d000b211620002d000a211720002d0009211820002d0008211920002d0007211a20002d0006211b20002d0005211c20002d0004211d20002d0003211e20002d0002211f20002d0001212020002d00002121200041206b2201240041f804412036020041800541f8041004200141800529030037000020014188052903003700082001419005290300370010200141980529030037001802400240202120012d0000470d00202020012d0001470d00201f20012d0002470d00201e20012d0003470d00201d20012d0004470d00201c20012d0005470d00201b20012d0006470d00201a20012d0007470d00201920012d0008470d00201820012d0009470d00201720012d000a470d00201620012d000b470d00201520012d000c470d00201420012d000d470d00201320012d000e470d00201220012d000f470d00201120012d0010470d00201020012d0011470d00200f20012d0012470d00200e20012d0013470d00200d20012d0014470d00200c20012d0015470d00200b20012d0016470d00200a20012d0017470d00200920012d0018470d00200820012d0019470d00200720012d001a470d00200620012d001b470d00200520012d001c470d00200420012d001d470d00200320012d001e470d00200220012d001f460d010b000b200041406b240041000b821401277f230041a0016b2223240041f80441203602002023222141d8006a4200370300202142003703502021420037034820214200370340202141406b412041800541f804100321224180052d000021244181052d000021264182052d000021274183052d000021284184052d000021294185052d0000212a4186052d0000212b4187052d0000212c4188052d0000212d4189052d0000212e418a052d0000212f418b052d00002130418c052d00002131418d052d00002132418e052d00002133418f052d000021344190052d000021354191052d000021364192052d000021374193052d000021384194052d000021394195052d0000213a4196052d0000213b4197052d0000213c4198052d0000213d4199052d0000213e419a052d0000213f419b052d00002140419c052d00002141419d052d00002142419e052d00002143419f052d000021442021201f3a001f2021201e3a001e2021201d3a001d2021201c3a001c2021201b3a001b2021201a3a001a202120193a0019202120183a0018202120173a0017202120163a0016202120153a0015202120143a0014202120133a0013202120123a0012202120113a0011202120103a00102021200f3a000f2021200e3a000e2021200d3a000d2021200c3a000c2021200b3a000b2021200a3a000a202120093a0009202120083a0008202120073a0007202120063a0006202120053a0005202120043a0004202120033a0003202120023a0002202120013a0001202120003a0000202141386a4200370300202142003703302021420037032820214200370320202141206a41202021412010011a4120417f1012222041276a4100204420221b22443a0000202041266a4100204320221b22433a0000202041256a4100204220221b22423a0000202041246a4100204120221b22413a0000202041236a4100204020221b22403a0000202041226a4100203f20221b223f3a0000202041216a4100203e20221b223e3a0000202041206a4100203d20221b223d3a00002020411f6a4100203c20221b223c3a00002020411e6a4100203b20221b223b3a00002020411d6a4100203a20221b223a3a00002020411c6a4100203920221b22393a00002020411b6a4100203820221b22383a00002020411a6a4100203720221b22373a0000202041196a4100203620221b22363a0000202041186a4100203520221b22353a0000202041176a4100203420221b22343a0000202041166a4100203320221b22333a0000202041156a4100203220221b22323a0000202041146a4100203120221b22313a0000202041136a4100203020221b22303a0000202041126a4100202f20221b222f3a0000202041116a4100202e20221b222e3a0000202041106a4100202d20221b222d3a00002020410f6a4100202c20221b222c3a00002020410e6a4100202b20221b222b3a00002020410d6a4100202a20221b222a3a00002020410c6a4100202920221b22293a00002020410b6a4100202820221b22283a00002020410a6a4100202720221b22273a0000202041096a4100202620221b22263a0000202041086a22254100202420221b22453a000041c001412d20252020280200410020201b10142222280200410020221b41214f044020222802002124202341206b222022232400202241086a22252024410020221b20201005202341206b22232400202020231010202141f8006a202341186a2903003703002021202341106a2903003703702021202341086a29030037036820212023290300370360202141e0006a2025412010110b4120417f10122220410a6a20023a0000202041096a20013a0000202041086a222420003a00002020410b6a20033a00002020410c6a20043a00002020410d6a20053a00002020410e6a20063a00002020410f6a20073a0000202041106a20083a0000202041116a20093a0000202041126a200a3a0000202041136a200b3a0000202041146a200c3a0000202041156a200d3a0000202041166a200e3a0000202041176a200f3a0000202041186a20103a0000202041196a20113a00002020411a6a20123a00002020411b6a20133a00002020411c6a20143a00002020411d6a20153a00002020411e6a20163a00002020411f6a20173a0000202041206a20183a0000202041216a20193a0000202041226a201a3a0000202041236a201b3a0000202041246a201c3a0000202041256a201d3a0000202041266a201e3a0000202041276a201f3a000041f001412820242020280200410020201b10142224280200410020241b41214f044020242802002125202341206b222022232400202441086a22462025410020241b20201005202341206b2223240020202023101020214198016a202341186a2903003703002021202341106a290300370390012021202341086a29030037038801202120232903003703800120214180016a2046412010110b41c100417f1012222041096a20453a0000202041086a222541043a00002020410a6a20263a00002020410b6a20273a00002020410c6a20283a00002020410d6a20293a00002020410e6a202a3a00002020410f6a202b3a0000202041106a202c3a0000202041116a202d3a0000202041126a202e3a0000202041136a202f3a0000202041146a20303a0000202041156a20313a0000202041166a20323a0000202041176a20333a0000202041186a20343a0000202041196a20353a00002020411a6a20363a00002020411b6a20373a00002020411c6a20383a00002020411d6a20393a00002020411e6a203a3a00002020411f6a203b3a0000202041206a203c3a0000202041216a203d3a0000202041226a203e3a0000202041236a203f3a0000202041246a20403a0000202041256a20413a0000202041266a20423a0000202041276a20433a0000202041286a20443a0000202041c8006a201f3a0000202041c7006a201e3a0000202041c6006a201d3a0000202041c5006a201c3a0000202041c4006a201b3a0000202041c3006a201a3a0000202041c2006a20193a0000202041c1006a20183a0000202041406b20173a00002020413f6a20163a00002020413e6a20153a00002020413d6a20143a00002020413c6a20133a00002020413b6a20123a00002020413a6a20113a0000202041396a20103a0000202041386a200f3a0000202041376a200e3a0000202041366a200d3a0000202041356a200c3a0000202041346a200b3a0000202041336a200a3a0000202041326a20093a0000202041316a20083a0000202041306a20073a00002020412f6a20063a00002020412e6a20053a00002020412d6a20043a00002020412c6a20033a00002020412b6a20023a00002020412a6a20013a0000202041296a20003a0000202341f0006b220024002000410c3a0000202341ef006b2201410c100f200141a0024120100e202341cf006b202241086a2022280200410020221b100e2023412f6b202441086a2024280200410020241b100e200041e10020252020280200410020201b1006202141a0016a240041000bd00802017f017e230041206b2223240041f804411036020041800541f80410070240024002400240024041800529030042005441880529030022244200542024501b2024423f872224420054202450712024501b450440202320003a0000202320013a0001202320023a0002202320033a0003202320043a0004202320053a0005202320063a0006202320073a0007202320083a0008202320093a00092023200a3a000a2023200b3a000b2023200c3a000c2023200d3a000d2023200e3a000e2023200f3a000f202320103a0010202320113a0011202320123a0012202320133a0013202320143a0014202320153a0015202320163a0016202320173a0017202320183a0018202320193a00192023201a3a001a2023201b3a001b2023201c3a001c2023201d3a001d2023201e3a001e2023201f3a001f20202802002101202341106b220022022400200042003703082000420037030041f804418080023602004100202342002000202041086a2001410020201b41800541f804100841f80428020041800510122100200241106b220124000440024002400240024002400240024002400240024002400240024002402000280200410020001b044041012100410d41e00210122201280200410020011b41ffffffff034b0d110240410d41e00210122201280200410020011b413f4d0d0041042100410d41e00210122201280200410020011b41ffff004b0d00410221000b20002000410d41e00210122201280200410020011b6a22014b0d012001200141046a22004b0d022000417f1012220241086a41a0f38dc600360200410d41e00210122200280200410020001b220041ffffffff034d0d05000b2021280200410020211b41ffffffff034b0d14027f41012021280200410020211b413f4d0d001a41042021280200410020211b41ffff004b0d001a41020b220020002021280200410020211b6a22004b0d022000200041046a22014b0d032001417f1012220241086a41a0f38dc6003602002021280200410020211b220041ffffffff034d0d05000b000b000b000b000b2000413f4b0d01200041ffffffff03712000470d022002410c6a2000410274360200410121010c0e0b2000413f4b0d02200041ffffffff03712000470d032002410c6a2000410274360200410121010c0c0b200041ffff004b0d03200041ffffffff03712000470d04410221012002410c6a20004102744101723602000c0c0b000b200041ffff004b0d03200041ffffffff03712000470d04410221012002410c6a20004102744101723602000c090b000b2000200041ffffffff03714604402002410c6a2000410274410272360200410421010c090b000b000b2000200041ffffffff03714604402002410c6a2000410274410272360200410421010c060b000b000b200120003602000c020b000b000b20222001280200360200202341206a240041000f0b200120026a410c6a202141086a2000100e000b200120026a410c6a410d41e002101241086a2000100e000b000bd20302037f057e230041e0016b2202240041f8044120360200200241206a420037030020024200370318200242003703102002420a370308200241086a412041800541f804100345044041800529030021050b200241206b2203240041f8044120360200200241d8016a4200370300200242003703d001200242003703c801200242053703c001027e200241c0016a412041800541f8041003044042000c010b4190052903002107418805290300210641800529030021084198052903000b2109200320083703002003200637030820032007370310200341186a22042009370300200220003703282002200537033020042903002100200341106a2903002106200341086a2903002107200329030021050240200241286a200241306a200241386a4102101645044020022903382108200241d8006a4200370300200241f8006a2000370300200220053703602002420037035020024200370348200220083703402002200737036820022006370370200241406b200241e0006a20024180016a200241a0016a1019450d01000b000b200120022903a001370300200141186a200241b8016a2903003703002001200241b0016a2903003703102001200241a8016a290300370308200241e0016a240041000b1600200020012002200320042005418f84aaa778102a0b8d0c02047f0f7e230041c0056b22082400410c10132109200841186a220b420037030041f804410436020020084200370310200842003703082008421237030020092008412041800541f8041003047f4100054180052802000b360200200b420037030041f8044104360200200842003703102008420037030820084213370300200941046a2008412041800541f8041003047f4100054180052802000b360200200841186a420037030041f80441043602002008420037031020084200370308200842143703002008412041800541f8041003450440418005280200210a0b200841d8006a4200370300200941086a200a360200200841386a200337030020082000370320200842003703502008420037034820082001370328200820093502003703402008200237033002400240024002400240024002400240200841206a200841406b200841e0006a41081016450440200841f8006a290300210c200841f0006a2903002110200841e8006a290300210f20082903602111200841b8016a420037030020084198016a200c370300200842003703b001200842003703a80120084290ce003703a00120082011370380012008200f37038801200820103703900120084180016a200841a0016a200841c0016a200841e0016a10190d01200841b8026a420037030020084198026a20033703002008200037038002200842003703b002200842003703a8022008200137038802200820093502043703a0022008200237039002200841f8016a2903002116200841f0016a2903002111200841e8016a290300211020082903e001211520084180026a200841a0026a200841c0026a410810160d02200841d8026a290300210c200841d0026a290300210f200841c8026a290300211220082903c002211320084198036a4200370300200841f8026a200c3703002008420037039003200842003703880320084290ce0037038003200820133703e002200820123703e8022008200f3703f002200841e0026a20084180036a200841a0036a200841c0036a10190d0320084198046a4200370300200841f8036a2003370300200820003703e00320084200370390042008420037038804200820013703e8032008200935020837038004200820023703f003200841d8036a2903002117200841d0036a2903002112200841c8036a290300210f20082903c0032113200841e0036a20084180046a200841a0046a410810160d04200841b8046a290300210c200841b0046a290300210d200841a8046a290300210e20082903a0042114200841f8046a4200370300200841d8046a200c370300200842003703f004200842003703e80420084290ce003703e004200820143703c0042008200e3703c8042008200d3703d004200841c0046a200841e0046a20084180056a200841a0056a10190d05200020157d220d200056200120107d20002015542209ad7d220020015620002001511b200220117d220e2009200120105420012010511bad22017d220c200256200320167d2002201154ad7d2001200e56ad7d220120035620012003511b2002200c85200120038584501b0d06200d20137d220e200d562000200f7d200d2013542209ad7d220220005620002002511b200c20127d220d20092000200f542000200f511bad22007d2203200c56200120177d200c201254ad7d2000200d56ad7d220020015620002001511b2003200c85200020018584501b0d07200e20082903a005220c7d2218200e562002200841a8056a29030022017d200c200e562209ad7d220d2002562002200d511b2003200841b0056a290300220e7d22192009200120025620012002511bad22027d22142003562000200841b8056a290300221a7d2003200e54ad7d2002201956ad7d220220005620002002511b2003201485200020028584501b450d08000b000b000b000b000b000b000b000b000b200420183703002004200d37030820042014370310200441186a2002370300200541186a2016370300200520153703002005201037030820052011370310200641186a2017370300200620133703002006200f370308200620123703102007200e370310200741186a201a3703002007200c37030020072001370308200841c0056a240041000b160020002001200220032004200541b8f9f29106102a0b8dcc0302a9017f1e7e230041e0006b22072400024002400240024002400240027f0240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200041034d0d0041f00441800528020022043602000240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240024002400240200441efc08a8c034c044020044197acb4e87d4c0440200441dbaeeada7b4c0440200441eac5aff3794c0440200441f2fb8fdf78460d0d200441cf998fe978470d6b2001200284500d32000b200441ebc5aff379460d14200441f1a0e1b07a460d0b20044189bc9d9d7b470d6a2001200284500d25000b200441e3bfdde97b4c0440200441dcaeeada7b460d09200441a98bf0dc7b470d6a2001200284500d22000b200441e4bfdde97b460d162004418df4fca37d460d0f200441a4af89be7d470d692001200284500d28000b200441ed9faaf3004c0440200441c197d7f07d4c044020044198acb4e87d460d05200441a3f0caeb7d470d6a2001200284500d26000b200441c297d7f07d460d1720044186fafb1e460d02200441e4b1acc900470d692001200284500d0e000b200441fcd4e3b8014c0440200441ee9faaf300460d1b200441b8aabbf900470d692001200284500d2b000b200441fdd4e3b801460d10200441b999cbef01460d1c200441b6ebfeaa02470d682001200284500d2e000b200441bba8cac2044c0440200441f78faa87044c0440200441be96a1d5034c0440200441f0c08a8c03460d06200441d8ebd4af03470d6a2001200284500d32000b200441bf96a1d503460d1a200441ddc5b5f703460d06200441cd9ca2fd03470d692001200284500d39000b20044194848f96044c0440200441f88faa8704460d1220044195b1ef8c04470d692001200284500d03000b20044195848f9604460d13200441cc89dcaa04460d0c20044187eb88b604470d682001200284500d3e000b20044183adadce054c0440200441def2d1fe044c0440200441bca8cac204460d1c200441eb878df204470d692001200284500d32000b200441dff2d1fe04460d17200441b9a0cd8c05460d06200441b9a9f1be05470d682001200284500d0b000b200441fffae4ed064c044020044184adadce05460d182004418dcbaede05460d08200441b1f894bf06470d682001200284500d1d000b20044180fbe4ed06460d0e200441c4b4f88107460d13200441dcde89ca07470d672001200284500d3a000b20012002844200520d9201200741106b2200240041f80441808002360200200741d8006a42003703002007420037035020074200370348200742063703402000200741406b412041800541f8041003047f41000541f80428020041800510120b36020020002802002204280200410020041b41ffffffff034d0d3d000b200741106b2200240041f80441808002360200200741d8006a42003703002007420037035020074200370348200742073703402000200741406b412041800541f8041003047f41000541f80428020041800510120b36020020002802002204280200410020041b41ffffffff034d0d3d000b20012002844200520d8f01200741206b2204240041f8044120360200200741d8006a42003703002007420037035020074200370348200742053703400c92010b20012002844200520d8d012000200041046b2204490d1920044120490d1a200441204d0d48000b20012002844200520d8b012000200041046b2204490d1b200441c000490d1c200441c0004d0d49000b20012002844200520d89012000200041046b2204490d1e200441c000490d1f200441c0004d0d4b000b20012002844200520d8701200741106b2200240041f8044101360200200741d8006a42003703002007420037035020074200370348200742023703402000200741406b412041800541f8041003047f4100054180052d00000b4101713a00000c8f010b20012002844200520d8501200741206b2204240041f8044120360200200741d8006a42003703002007420037035020074200370348200742003703400c94010b20012002844200520d83010240102022040d00410021044100210041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100410041004100102122030440200321000b2000450d00200021040b20040d98010c8e010b20012002844200520d81012000200041046b2204490d1d20044120490d1e200441204d0d39000b200741206b2204240041f8044120360200200741d8006a42003703002007420037035020074200370348200742093703400c8a010b20012002844200520d7e2000200041046b2204490d1e20044120490d1f200441204d0d47000b200741206b2204240041f8044120360200200741d8006a420037030020074200370350200742003703482007420b3703400c88010b20012002844200520d7b200741206b2204240041f8044120360200200741d8006a420037030020074200370350200742003703482007420c3703400c87010b20012002844200520d79200741206b2204240041f8044120360200200741d8006a420037030020074200370350200742003703482007420d3703400c8d010b20012002844200520d77200741206b2204240041f8044120360200200741d8006a420037030020074200370350200742003703482007420e3703400c8c010b20012002844200520d75200741206b2204240041f8044120360200200741d8006a420037030020074200370350200742003703482007420f3703400c8b010b20012002844200520d73200741206b2204240041f8044120360200200741d8006a42003703002007420037035020074200370348200742103703400c8a010b200041046b225420004b0d55205441a0014f044041a3052d000021ab0141a2052d0000215541a1052d0000215641a0052d00002157419f052d00002158419e052d00002159419d052d0000215a419c052d0000215b419b052d0000215c419a052d0000215d4199052d0000215e4198052d0000215f4197052d000021604196052d000021614195052d000021624194052d000021634193052d000021644192052d000021654191052d000021664190052d00002167418f052d00002168418e052d00002137418d052d00002138418c052d0000211b418b052d00002110418a052d000021194189052d000021334188052d000021344187052d000021394186052d0000211a4185052d000021134184052d0000211c41c3052d0000213241c2052d0000213a41c1052d0000213b41c0052d0000213c41bf052d0000213d41be052d0000213e41bd052d0000213f41bc052d0000214041bb052d0000214141ba052d0000214241b9052d0000214341b8052d0000214441b7052d0000214541b6052d0000214641b5052d0000214741b4052d0000214841b3052d0000214941b2052d0000214a41b1052d0000214b41b0052d0000214c41af052d0000214d41ae052d0000214e41ad052d0000214f41ac052d0000215041ab052d0000215141aa052d0000213541a9052d0000213641a8052d0000211141a7052d0000210641a6052d0000210941a5052d0000210f41a4052d0000210841e3052d0000216b41e2052d0000216c41e1052d0000216d41e0052d0000216e41df052d0000216f41de052d0000217041dd052d0000217141dc052d0000217241db052d0000217341da052d0000217441d9052d0000217541d8052d0000217641d7052d0000217741d6052d0000217841d5052d0000217941d4052d0000217a41d3052d0000217b41d2052d0000217c41d1052d0000217d41d0052d0000217e41cf052d0000217f41ce052d000021800141cd052d000021810141cc052d000021820141cb052d000021830141ca052d000021840141c9052d000021850141c8052d000021860141c7052d000021870141c6052d000021880141c5052d000021890141c4052d0000218a014183062d0000218b014182062d0000218c014181062d0000218d014180062d0000218e0141ff052d0000218f0141fe052d000021900141fd052d000021910141fc052d000021920141fb052d000021930141fa052d000021940141f9052d000021950141f8052d000021960141f7052d000021970141f6052d000021980141f5052d000021990141f4052d0000219a0141f3052d0000219b0141f2052d0000219c0141f1052d0000219d0141f0052d0000219e0141ef052d0000219f0141ee052d000021a00141ed052d000021a10141ec052d000021a20141eb052d000021a30141ea052d000021a40141e9052d000021a50141e8052d000021a60141e7052d000021a70141e6052d000021a80141e5052d000021a90141e4052d000021aa0141a3062d0000210c41a2062d0000210b41a1062d0000210d41a0062d0000211d419f062d0000211e419e062d0000211f419d062d00002120419c062d00002121419b062d00002122419a062d000021234199062d000021244198062d000021254197062d000021264196062d000021274195062d000021284194062d000021294193062d0000212a4192062d0000212b4191062d0000212c4190062d0000212d418f062d0000212e418e062d0000212f418d062d00002130418c062d00002131418b062d00002114418a062d000021184189062d000021164188062d000021174187062d000021154186062d0000210e4185062d0000210a4184062d0000210541a4062d000022004103710e033233341a0b000b20012002844200520d702000200041046b2204490d1d200441c000490d1e200441c0004d0d41000b20012002844200520d6e2000200041046b2204490d1e200441c000490d1f200441c0004d0d41000b20012002844200520d6c2000200041046b2204490d1f200441c000490d20200441c0004d0d34000b20012002844200520d6a2000200041046b2204490d2120044120490d22200441204d0d41000b20012002844200520d6810202200047f20000541f8044101360200200741d8006a42003703002007420037035020074200370348200742023703402007200741406b412041800541f8041003047f4100054180052d00000b41017122003a002020000d52230041d0006b22082400200841406b4200370300200842003703382008420037033020084202370328200841013a004f200841286a4120200841cf006a410110011a41f804412036020041800541f8041004200841800529030037000820084188052903003700102008419005290300370018200841980529030037002020082d0027211d20082d0026211e20082d0025211f20082d0024212020082d0023212120082d0022212220082d0021212320082d0020212420082d001f212520082d001e212620082d001d212720082d001c212820082d001b212920082d001a212a20082d0019212b20082d0018212c20082d0017212d20082d0016212e20082d0015212f20082d0014213020082d0013213120082d0012211420082d0011211820082d0010211620082d000f211720082d000e211520082d000d210e20082d000c210a20082d000b210520082d000a210320082d0009210420082d000821004121417f1012220b41086a220d41023a0000200d41016a220c20043a0001200c20003a0000200c20033a0002200c20053a0003200c200a3a0004200c200e3a0005200c20153a0006200c20173a0007200c20163a0008200c20183a0009200c20143a000a200c20313a000b200c20303a000c200c202f3a000d200c202e3a000e200c202d3a000f200c202c3a0010200c202b3a0011200c202a3a0012200c20293a0013200c20283a0014200c20273a0015200c20263a0016200c20253a0017200c20243a0018200c20233a0019200c20223a001a200c20213a001b200c20203a001c200c201f3a001d200c201e3a001e200c201d3a001f200841306b22042400200441043a00002008412f6b22004104100f200041f0024120100e20044121200d200b2802004100200b1b1006200841d0006a240041000b0d89010c7f0b20012002844200520d6610202200047f20000541f8044101360200200741d8006a42003703002007420037035020074200370348200742023703402007200741406b412041800541f8041003047f4100054180052d00000b41017122003a00202000450d52230041d0006b22082400200841406b4200370300200842003703382008420037033020084202370328200841003a004f200841286a4120200841cf006a410110011a41f804412036020041800541f8041004200841800529030037000820084188052903003700102008419005290300370018200841980529030037002020082d0027211d20082d0026211e20082d0025211f20082d0024212020082d0023212120082d0022212220082d0021212320082d0020212420082d001f212520082d001e212620082d001d212720082d001c212820082d001b212920082d001a212a20082d0019212b20082d0018212c20082d0017212d20082d0016212e20082d0015212f20082d0014213020082d0013213120082d0012211420082d0011211820082d0010211620082d000f211720082d000e211520082d000d210e20082d000c210a20082d000b210520082d000a210320082d0009210420082d000821004121417f1012220b41086a220d41033a0000200d41016a220c20043a0001200c20003a0000200c20033a0002200c20053a0003200c200a3a0004200c200e3a0005200c20153a0006200c20173a0007200c20163a0008200c20183a0009200c20143a000a200c20313a000b200c20303a000c200c202f3a000d200c202e3a000e200c202d3a000f200c202c3a0010200c202b3a0011200c202a3a0012200c20293a0013200c20283a0014200c20273a0015200c20263a0016200c20253a0017200c20243a0018200c20233a0019200c20223a001a200c20213a001b200c20203a001c200c201f3a001d200c201e3a001e200c201d3a001f200841306b22042400200441043a00002008412f6b22004104100f20004190034120100e20044121200d200b2802004100200b1b1006200841d0006a240041000b0d88010c7e0b20012002844200520d64200741206b22002400200041206b22042400027f4200210142002102230041d0006b2206240041f8044120360200200641206a420037030020064200370318200642003703102006420a370308200641086a412041800541f8041003047e42000541900529030021b401418805290300210241800529030021014198052903000b21ad01200641206b220322082400200341186a420037030020034200370310200342003703082003420837030041f80441203602002003412041800541f804100321094180052d0000210c4181052d0000210b4182052d0000210d4183052d0000211d4184052d0000211e4185052d0000211f4186052d000021204187052d000021214188052d000021224189052d00002123418a052d00002124418b052d00002125418c052d00002126418d052d00002127418e052d00002128418f052d000021294190052d0000212a4191052d0000212b4192052d0000212c4193052d0000212d4194052d0000212e4195052d0000212f4196052d000021304197052d000021314198052d000021144199052d00002118419a052d00002116419b052d00002117419c052d00002115419d052d0000210e419e052d0000210a419f052d000021034124417f1012210f200641b18482850736022c2006412c6a200f41086a22054104101141f804412036020041800541f804100941800529030021ac0141880529030021ae0141900529030021b001200f41246a419805290300370000200f411c6a20b001370000200f41146a20ae01370000200f410c6a20ac0137000020064100200320091b3a004f20064100200a20091b3a004e20064100200e20091b3a004d20064100201520091b3a004c20064100201720091b3a004b20064100201620091b3a004a20064100201820091b3a004920064100201420091b3a004820064100203120091b3a004720064100203020091b3a004620064100202f20091b3a004520064100202e20091b3a004420064100202d20091b3a004320064100202c20091b3a004220064100202b20091b3a004120064100202a20091b3a004020064100202920091b3a003f20064100202820091b3a003e20064100202720091b3a003d20064100202620091b3a003c20064100202520091b3a003b20064100202420091b3a003a20064100202320091b3a003920064100202220091b3a003820064100202120091b3a003720064100202020091b3a003620064100201f20091b3a003520064100201e20091b3a003420064100201d20091b3a003320064100200d20091b3a003220064100200b20091b3a003120064100200c20091b3a0030200f2802002103200841106b220a2400200a4200370308200a420037030041f80441808002360200024002404100200641306a4200200a200520034100200f1b41800541f804100845044041f80428020041800510122203280200410020031b2203411f4d0d0141f80428020041800510122105200341204b0d02200541206a29030021ac01200541186a29030021ae01200541106a29030021b0012000200541086a290300370300200020b001370308200020ae01370310200041186a20ac01370300200420b401370310200441186a20ad013703002004200137030020042002370308200641d0006a240041000c030b000b000b000b0d87010c7e0b20012002844200520d622000200041046b2204490d2020044120490d21200441204d0d30000b20012002844200520d60200741206b22152400201541206b220e2400200e41206b220a2400410c10132105200741d8006a2200420037030041f80441043602002007420037035020074200370348200742123703402005200741406b412041800541f8041003047f4100054180052802000b3602002000420037030041f8044104360200200742003703502007420037034820074213370340200541046a200741406b412041800541f8041003047f4100054180052802000b360200200741d8006a420037030041f8044104360200200742003703502007420037034820074214370340200741406b412041800541f804100345044041800528020021520b2015420037031020154200370308200e4200370310200e4200370308200a4200370310200a4200370308201541186a2203420037030020152005350200370300200e41186a22044200370300200e2005350204370300200a41186a22004200370300200a2052ad370300200541086a2052360200200029030021b501200a41106a29030021b401200a41086a29030021b201200429030021b301200e41106a29030021b101200e41086a29030021af01200329030021ad01201541106a29030021ac01201541086a29030021ae01200a29030021b001200e29030021022015290300210141e000417f1012220041186a20ac01370300200041106a20ae01370300200041086a22042001370300200041206a20ad01370300200441206a220020af0137030820002002370300200020b101370310200041186a20b301370300200441406b220020b201370308200020b001370300200020b401370310200041186a20b5013703004100200441e000100b0c85010b200741106b22002400200041123a00000c5e0b000b000b2000200041046b2204490d4b200441c0004f0440200441c0004d0d21000b000b000b000b2000200041046b2204490d49200441c0004f0440200441c0004d0d1f000b000b2000200041046b2204490d49200441e0004f0440200441e0004d0d1f000b000b000b000b2000200041046b2204490d47200441c0004f0440200441c0004d0d2c000b000b000b000b200741206b2204240041f8044120360200200741d8006a42003703002007420037035020074200370348200742083703400c720b000b000b000b2000200041046b2204490d41200441204f0440200441204d0d27000b000b2000200041046b2204490d41200441204f0440200441204d0d19000b000b2000200041046b2204490d41200441204f0440200441204d0d19000b000b2000200041046b2204490d41200441e0004f0440200441e0004d0d19000b000b000b000b000b000b000b000b2000200041046b2204490d3b200441204f0440200441204d0d20000b000b000b000b2000200041046b2204490d39200441204f0440200441204d0d1f000b000b000b000b2000200041046b2204490d37200441204f0440200441204d0d1d000b000b027f41012004280200410020041b413f4d0d001a41042004280200410020041b41ffff004b0d001a41020b220020002004280200410020041b6a22034b0d1c2003417f101221032004280200410020041b220541ffffffff034d0d1e000b027f41012004280200410020041b413f4d0d001a41042004280200410020041b41ffff004b0d001a41020b220020002004280200410020041b6a22034b0d1c2003417f101221032004280200410020041b220541ffffffff034d0d1e000b41a3052d0000210d41a2052d0000211d41a1052d0000211e41a0052d0000211f419f052d00002120419e052d00002121419d052d00002122419c052d00002123419b052d00002124419a052d000021254199052d000021264198052d000021274197052d000021284196052d000021294195052d0000212a4194052d0000212b4193052d0000212c4192052d0000212d4191052d0000212e4190052d0000212f418f052d00002130418e052d00002131418d052d00002114418c052d00002118418b052d00002116418a052d000021174189052d000021154188052d0000210e4187052d0000210a4186052d000021054185052d000021034184052d0000210441a40529030021b10141bc0529030021af0141b40529030021ad0141ac0529030021ac01200741106b2200240041f804412036020041800541f8041004200741980529030022ae01370038200741900529030022b00137003020074188052903002202370028200741800529030022013700202001a720072d002120072d002220072d002320072d002420072d002520072d002620072d00272002a720072d002920072d002a20072d002b20072d002c20072d002d20072d002e20072d002f20b001a720072d003120072d003220072d003320072d003420072d003520072d003620072d003720ae01a720072d003920072d003a20072d003b20072d003c20072d003d20072d003e20072d003f200420032005200a200e2015201720162018201420312030202f202e202d202c202b202a2029202820272026202520242023202220212020201f201e201d200d20b10120ac0120ad0120af01101d22040d0c200041013a00000c550b41a3052d0000210d41a2052d0000211d41a1052d0000211e41a0052d0000211f419f052d00002120419e052d00002121419d052d00002122419c052d00002123419b052d00002124419a052d000021254199052d000021264198052d000021274197052d000021284196052d000021294195052d0000212a4194052d0000212b4193052d0000212c4192052d0000212d4191052d0000212e4190052d0000212f418f052d00002130418e052d00002131418d052d00002114418c052d00002118418b052d00002116418a052d000021174189052d000021154188052d0000210e4187052d0000210a4186052d000021054185052d000021034184052d0000210441a40529030021b10141bc0529030021af0141b40529030021ad0141ac0529030021ac01200741106b2200240041f804412036020041800541f8041004200741980529030022ae01370038200741900529030022b00137003020074188052903002202370028200741800529030022013700202001a720072d002120072d002220072d002320072d002420072d002520072d002620072d00272002a720072d002920072d002a20072d002b20072d002c20072d002d20072d002e20072d002f20b001a720072d003120072d003220072d003320072d003420072d003520072d003620072d003720ae01a720072d003920072d003a20072d003b20072d003c20072d003d20072d003e20072d003f200420032005200a200e2015201720162018201420312030202f202e202d202c202b202a2029202820272026202520242023202220212020201f201e201d200d20b10120ac0120ad0120af01101c22040d0d200041013a00000c540b41a3052d0000215541a2052d0000215641a1052d0000215741a0052d00002158419f052d00002159419e052d0000215a419d052d0000215b419c052d0000215c419b052d0000215d419a052d0000215e4199052d0000215f4198052d000021604197052d000021614196052d000021624195052d000021634194052d000021644193052d000021654192052d000021664191052d000021674190052d00002168418f052d00002137418e052d00002138418d052d0000211b418c052d00002110418b052d00002119418a052d000021334189052d000021344188052d000021394187052d0000211a4186052d000021134185052d0000211c4184052d0000213241c3052d0000213b41c2052d0000213c41c1052d0000213d41c0052d0000213e41bf052d0000213f41be052d0000214041bd052d0000214141bc052d0000214241bb052d0000214341ba052d0000214441b9052d0000214541b8052d0000214641b7052d0000214741b6052d0000214841b5052d0000214941b4052d0000214a41b3052d0000214b41b2052d0000214c41b1052d0000214d41b0052d0000214e41af052d0000214f41ae052d0000215041ad052d0000215141ac052d0000213541ab052d0000213641aa052d0000211141a9052d0000210641a8052d0000210941a7052d0000210f41a6052d0000210841a5052d0000210c41a4052d0000210b41c40529030021ad0141dc0529030021b30141d40529030021b10141cc0529030021af01200741106b223a240041f804412036020041800541f8041004200741980529030022ae01370038200741900529030022b001370030200741880529030022023700282007418005290300220137002002402032201c2013201a20392034203320192010201b20382037206820672066206520642063206220612060205f205e205d205c205b205a205920582057205620552001a7220d20072d0021221d20072d0022221e20072d0023221f20072d0024222020072d0025222120072d0026222220072d002722232002a7222420072d0029222520072d002a222620072d002b222720072d002c222820072d002d222920072d002e222a20072d002f222b20b001a7222c20072d0031222d20072d0032222e20072d0033222f20072d0034223020072d0035223120072d0036221420072d0037221820ae01a7221620072d0039221720072d003a221520072d003b220e20072d003c220a20072d003d220520072d003e220320072d003f2200200741406b101b22040d0020072903402201200741d0006a29030022ac0183200741c8006a29030022ae01200741d8006a29030022b0018383427f520440200120ad015a20ae0120af015a20ae0120af015122041b20ac0120b1015a20b00120b3015a20b00120b301511b20ac0120b1018520b00120b3018584501b450d372032201c2013201a20392034203320192010201b20382037206820672066206520642063206220612060205f205e205d205c205b205a20592058205720562055200d201d201e201f2020202120222023202420252026202720282029202a202b202c202d202e202f2030203120142018201620172015200e200a200520032000200120ad017d20ae0120af017d200120ad01542200ad7d20ac0120b1017d2202200020ae0120af015420041bad22017d20b00120b3017d20ac0120b10154ad7d2001200256ad7d101c22040d010b410021040b20040d0d2032201c2013201a20392034203320192010201b20382037206820672066206520642063206220612060205f205e205d205c205b205a20592058205720562055200b200c2008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b20ad0120af0120b10120b301101d2200047f200005203a41013a000041000b0d5e0c370b41a3052d0000210b41a2052d0000210d41a1052d0000211d41a0052d0000211e419f052d0000211f419e052d00002120419d052d00002121419c052d00002122419b052d00002123419a052d000021244199052d000021254198052d000021264197052d000021274196052d000021284195052d000021294194052d0000212a4193052d0000212b4192052d0000212c4191052d0000212d4190052d0000212e418f052d0000212f418e052d00002130418d052d00002131418c052d00002114418b052d00002118418a052d000021164189052d000021174188052d000021154187052d0000210e4186052d0000210a4185052d000021054184052d000021030240102022040d00200b2003200572200a72200e72201572201772201672201872201472203172203072202f72202e72202d72202c72202b72202a72202972202872202772202672202572202472202372202272202172202072201f72201e72201d72200d7272450d33410021044100210020032005200a200e2015201720162018201420312030202f202e202d202c202b202a2029202820272026202520242023202220212020201f201e201d200d200b102122030440200321000b2000450d00200021040b20040d5d0c530b20004102762100410121520c340b4102215241a4062f010041027621000c330b41a4062802004102762100410421520c320b419c0529030021ae0141940529030021b001418c05290300210241840529030021010240102022040d00027f230041206b22042400200120b00184200220ae01848450450440200441206b22002400200441186a20ae01370300200041186a420037030020004200370310200042003703082000420c370300200420b0013703102004200237030820042001370300200041202004412010011a200441206a240041000c010b000b22040d00410021040b20040d590c4f0b419c0529030021ae0141940529030021b001418c052903002102418405290300210110202200047f200005200741386a4200370300200741d8006a20ae013703002007200137034020072002370348200742003703302007420037032820074209370320200720b001370350200741206a4120200741406b412010011a41000b0d580c4e0b419c0529030021bb0141940529030021bd01418c0529030021b90141840529030021b80141a40529030021b50141bc0529030021b30141b40529030021b10141ac0529030021af0141c40529030021b40141dc0529030021ad0141d40529030021ac0141cc0529030021ae010240102022040d002300220402400240024002400240024020b50120b8017c220220b8015422002000ad20af0120b9017c7c22b20120b9015420b20120b901511b220020b10120bd017c22012000ad7c22ba0120bd0154200120ba0156ad200120bd0154ad20b30120bb017c7c7c22bc0120bb015420bb0120bc01511b20ba0120bd018520bb0120bc018584501b450440200220b4017c220120025422002000ad20ae0120b2017c7c22b00120b2015420b00120b201511b220020ac0120ba017c22022000ad7c22b20120ba0154200220b20156ad200220ba0154ad20ad0120bc017c7c7c220220bc0154200220bc01511b20b20120ba0185200220bc018584501b0d01200220b201845020b00150200142b817547171450d03200441106b2204240020bb0120bd01845020b9015020b801428080808010547171450d02200420b8013e0200200441106b2200240020b10120b301845020af015020b501428080808010547171450d0420042802002104200020b5013e0200200041106b220e240020ac0120ad01845020ae015020b401428080808010547171450d0520002802002103200e20b4013e02000c060b000b000b000b000b000b000b200e2802002100410c1013220a2004360200200a41086a22042000360200200a41046a22002003360200200e41206b220e2400200e41186a22034200370300200e4200370310200e4200370308200e4212370300200e4120200a410410011a20034200370300200e4200370310200e4200370308200e4213370300200e41202000410410011a20034200370300200e4200370310200e4200370308200e4214370300200e41202004410410011a2400410022040d000b20040d570c4d0b419c0529030021b10141940529030021af01418c0529030021ad0141840529030021ac0141c3052d0000213a41c2052d0000213b41c1052d0000213c41c0052d0000213d41bf052d0000213e41be052d0000213f41bd052d0000214041bc052d0000214141bb052d0000214241ba052d0000214341b9052d0000214441b8052d0000214541b7052d0000214641b6052d0000214741b5052d0000214841b4052d0000214941b3052d0000214a41b2052d0000214b41b1052d0000214c41b0052d0000214d41af052d0000214e41ae052d0000214f41ad052d0000215041ac052d0000215141ab052d0000213541aa052d0000213641a9052d0000211141a8052d0000210641a7052d0000210941a6052d0000210f41a5052d0000210841a4052d0000210c41f8044120360200200741186a420037030020074200370310200742003703082007420e3703002007412041800541f8041003210d4180052d0000211d4181052d0000211e4182052d0000211f4183052d000021204184052d000021214185052d000021224186052d000021234187052d000021244188052d000021254189052d00002126418a052d00002127418b052d00002128418c052d00002129418d052d0000212a418e052d0000212b418f052d0000212c4190052d0000212d4191052d0000212e4192052d0000212f4193052d000021304194052d000021314195052d000021144196052d000021184197052d000021164198052d000021174199052d00002115419a052d0000210e419b052d0000210a419c052d00002105419d052d00002103419e052d00002104419f052d0000210041f804412036020041800541f80410044180052d00004100201d200d1b41ff0171470d2c4181052d00004100201e200d1b41ff0171470d2c4182052d00004100201f200d1b41ff0171470d2c4183052d000041002020200d1b41ff0171470d2c4184052d000041002021200d1b41ff0171470d2c4185052d000041002022200d1b41ff0171470d2c4186052d000041002023200d1b41ff0171470d2c4187052d000041002024200d1b41ff0171470d2c4188052d000041002025200d1b41ff0171470d2c4189052d000041002026200d1b41ff0171470d2c418a052d000041002027200d1b41ff0171470d2c418b052d000041002028200d1b41ff0171470d2c418c052d000041002029200d1b41ff0171470d2c418d052d00004100202a200d1b41ff0171470d2c418e052d00004100202b200d1b41ff0171470d2c418f052d00004100202c200d1b41ff0171470d2c4190052d00004100202d200d1b41ff0171470d2c4191052d00004100202e200d1b41ff0171470d2c4192052d00004100202f200d1b41ff0171470d2c4193052d000041002030200d1b41ff0171470d2c4194052d000041002031200d1b41ff0171470d2c4195052d000041002014200d1b41ff0171470d2c4196052d000041002018200d1b41ff0171470d2c4197052d000041002016200d1b41ff0171470d2c4198052d000041002017200d1b41ff0171470d2c4199052d000041002015200d1b41ff0171470d2c419a052d00004100200e200d1b41ff0171470d2c419b052d00004100200a200d1b41ff0171470d2c419c052d000041002005200d1b41ff0171470d2c419d052d000041002003200d1b41ff0171470d2c419e052d000041002004200d1b41ff0171470d2c419f052d000041002000200d1b41ff0171470d2c0240101f22040d00027f230041d0006b221a240041f8044120360200201a41186a4200370300201a4200370310201a4200370308201a4208370300201a412041800541f8041003210d4180052d0000211d4181052d0000211e4182052d0000211f4183052d000021204184052d000021214185052d000021224186052d000021234187052d000021244188052d000021254189052d00002126418a052d00002127418b052d00002128418c052d00002129418d052d0000212a418e052d0000212b418f052d0000212c4190052d0000212d4191052d0000212e4192052d0000212f4193052d000021304194052d000021314195052d000021144196052d000021184197052d000021164198052d000021174199052d00002115419a052d0000210e419b052d0000210a419c052d00002105419d052d00002103419e052d00002104419f052d0000210041c400417f1012210b201a41bbb996c87a360248201a41c8006a200b41086a41041011200b412b6a203a3a0000200b412a6a203b3a0000200b41296a203c3a0000200b41286a203d3a0000200b41276a203e3a0000200b41266a203f3a0000200b41256a20403a0000200b41246a20413a0000200b41236a20423a0000200b41226a20433a0000200b41216a20443a0000200b41206a20453a0000200b411f6a20463a0000200b411e6a20473a0000200b411d6a20483a0000200b411c6a20493a0000200b411b6a204a3a0000200b411a6a204b3a0000200b41196a204c3a0000200b41186a204d3a0000200b41176a204e3a0000200b41166a204f3a0000200b41156a20503a0000200b41146a20513a0000200b41136a20353a0000200b41126a20363a0000200b41116a20113a0000200b41106a20063a0000200b410f6a20093a0000200b410e6a200f3a0000200b410d6a20083a0000200b410c6a200c3a0000200b41c4006a20b101370300200b413c6a20af01370300200b41346a20ad01370300200b412c6a20ac013703000240024002400240024002400240024002404100201d200d1b4100201e200d1b4100201f200d1b41002020200d1b41002021200d1b41002022200d1b41002023200d1b41002024200d1b41002025200d1b41002026200d1b41002027200d1b41002028200d1b41002029200d1b4100202a200d1b4100202b200d1b4100202c200d1b4100202d200d1b4100202e200d1b4100202f200d1b41002030200d1b41002031200d1b41002014200d1b41002018200d1b41002016200d1b41002017200d1b41002015200d1b4100200e200d1b4100200a200d1b41002005200d1b41002003200d1b41002004200d1b41002000200d1b200b412041c0021012201a41cc006a10222200450440201a28024c2204280200410020041b04402004280200410020041b2200450d02200041014b0d03200441086a2d0000410171450d040b410021000b2000450440410021000b20000d03201a41206b2200220d2400200041186a420037030020004200370310200042003703082000420837030041f80441203602002000412041800541f80410032113419f052d0000211d419e052d0000211e419d052d0000211f419c052d00002120419b052d00002121419a052d000021224199052d000021234198052d000021244197052d000021254196052d000021264195052d000021274194052d000021284193052d000021294192052d0000212a4191052d0000212b4190052d0000212c418f052d0000212d418e052d0000212e418d052d0000212f418c052d00002130418b052d00002131418a052d000021144189052d000021184188052d000021164187052d000021174186052d000021154185052d0000210e4184052d0000210a4183052d000021054182052d000021034181052d000021044180052d000021004124417f1012211c201a41b184828507360224201a41246a201c41086a220b4104101141f804412036020041800541f804100941800529030021b00141880529030021024190052903002101200b41046a22324198052903003700182032200137001020322002370008203220b001370000201a4100200a20131b3a002c201a4100200520131b3a002b201a4100200320131b3a002a201a4100200420131b3a0029201a4100200020131b3a0028201a4100200e20131b3a002d201a4100201520131b3a002e201a4100201720131b3a002f201a4100201620131b3a0030201a4100201820131b3a0031201a4100201420131b3a0032201a4100203120131b3a0033201a4100203020131b3a0034201a4100202f20131b3a0035201a4100202e20131b3a0036201a4100202d20131b3a0037201a4100202c20131b3a0038201a4100202b20131b3a0039201a4100202a20131b3a003a201a4100202920131b3a003b201a4100202820131b3a003c201a4100202720131b3a003d201a4100202620131b3a003e201a4100202520131b3a003f201a4100202420131b3a0040201a4100202320131b3a0041201a4100202220131b3a0042201a4100202120131b3a0043201a4100202020131b3a0044201a4100201f20131b3a0045201a4100201e20131b3a0046201a4100201d20131b3a0047201c2802002100200d41106b22032400200342003703082003420037030041f804418080023602004100201a41286a42002003200b20004100201c1b41800541f80410080d0441f80428020041800510122200280200410020001b22004120490d0541f80428020041800510122104200041204b0d06200441206a29030021b301200441186a29030021ae01200441106a29030021b001200441086a290300200341206b220022032400200041186a420037030020004200370310200042003703082000420a37030041f80441203602002000412041800541f8041003047e42000541980529030021b20141880529030021ba0141800529030021c3014190052903000b210220c3015420b00120ba015420b00120ba01511b200220ae015620b20120b3015620b20120b301511b200220ae018520b20120b3018584501b0d0741c100417f1012220541086a220041073a0000200041016a220420083a00012004200c3a00002004200f3a0002200420093a0003200420063a0004200420113a0005200420363a0006200420353a0007200420513a0008200420503a00092004204f3a000a2004204e3a000b2004204d3a000c2004204c3a000d2004204b3a000e2004204a3a000f200420493a0010200420483a0011200420473a0012200420463a0013200420453a0014200420443a0015200420433a0016200420423a0017200420413a0018200420403a00192004203f3a001a2004203e3a001b2004203d3a001c2004203c3a001d2004203b3a001e2004203a3a001f0c080b000b000b000b201a41d0006a240020000c050b000b000b000b000b200041216a220020ad01370308200020ac01370300200020af01370310200041186a20b101370300200341306b22042400200441043a00002003412f6b22004104100f200041b0044120100e20044121200541086a2005280200410020051b1006201a41d0006a240041000b22040d00200741d8006a4200370300200741386a4200370300200742003703502007420037034820074201370340200742003703302007420037032820074201370320200741206a4120200741406b412010011a410021040b20040d560c4c0b419c0529030021ae0141940529030021b001418c052903002102418405290300200741206b22042400200220b00120ae01200741406b200741206a10262200047f20000520042007290340370300200441186a200741d8006a2903003703002004200741d0006a2903003703102004200741c8006a29030037030841000b0d540c4d0b41a3052d0000210d41a2052d0000211d41a1052d0000211e41a0052d0000211f419f052d00002120419e052d00002121419d052d00002122419c052d00002123419b052d00002124419a052d000021254199052d000021264198052d000021274197052d000021284196052d000021294195052d0000212a4194052d0000212b4193052d0000212c4192052d0000212d4191052d0000212e4190052d0000212f418f052d00002130418e052d00002131418d052d00002114418c052d00002118418b052d00002116418a052d000021174189052d000021154188052d0000210e4187052d0000210a4186052d000021054185052d000021034184052d0000200741206b2204240020032005200a200e2015201720162018201420312030202f202e202d202c202b202a2029202820272026202520242023202220212020201f201e201d200d2004101a450d4c0c530b2004450d480c530b41a3052d0000213b41a2052d0000213c41a1052d0000213d41a0052d0000213e419f052d0000213f419e052d00002140419d052d00002141419c052d00002142419b052d00002143419a052d000021444199052d000021454198052d000021464197052d000021474196052d000021484195052d000021494194052d0000214a4193052d0000214b4192052d0000214c4191052d0000214d4190052d0000214e418f052d0000214f418e052d00002150418d052d00002151418c052d00002135418b052d00002136418a052d000021114189052d000021064188052d000021094187052d0000210f4186052d000021084185052d0000210c4184052d000041c3052d0000210d41c2052d0000211d41c1052d0000211e41c0052d0000211f41bf052d0000212041be052d0000212141bd052d0000212241bc052d0000212341bb052d0000212441ba052d0000212541b9052d0000212641b8052d0000212741b7052d0000212841b6052d0000212941b5052d0000212a41b4052d0000212b41b3052d0000212c41b2052d0000212d41b1052d0000212e41b0052d0000212f41af052d0000213041ae052d0000213141ad052d0000211441ac052d0000211841ab052d0000211641aa052d0000211741a9052d0000211541a8052d0000210e41a7052d0000210a41a6052d0000210541a5052d0000210341a4052d00002100200741206b22042400200c2008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b200020032005200a200e2015201720162018201420312030202f202e202d202c202b202a2029202820272026202520242023202220212020201f201e201d200d2004101b450d4a0c510b2004450d460c510b2004450d290c500b41a3052d0000213a41a2052d0000213b41a1052d0000213c41a0052d0000213d419f052d0000213e419e052d0000213f419d052d00002140419c052d00002141419b052d00002142419a052d000021434199052d000021444198052d000021454197052d000021464196052d000021474195052d000021484194052d000021494193052d0000214a4192052d0000214b4191052d0000214c4190052d0000214d418f052d0000214e418e052d0000214f418d052d00002150418c052d00002151418b052d00002135418a052d000021364189052d000021114188052d000021064187052d000021094186052d0000210f4185052d000021084184052d0000210c41a405290300210141bc0529030021ac0141b40529030021ae0141ac0529030021b001200741106b22042400027f230041206b221c240041f804412036020041800541f8041004201c418005290300370000201c418805290300370008201c419005290300370010201c419805290300370018201c2d001f210b201c2d001e210d201c2d001d211d201c2d001c211e201c2d001b211f201c2d001a2120201c2d00192121201c2d00182122201c2d00172123201c2d00162124201c2d00152125201c2d00142126201c2d00132127201c2d00122128201c2d00112129201c2d0010212a201c2d000f212b201c2d000e212c201c2d000d212d201c2d000c212e201c2d000b212f201c2d000a2130201c2d00092131201c2d00082114201c2d00072118201c2d00062116201c2d00052117201c2d00042115201c2d0003210e201c2d0002210a201c2d00012105201c2d00002103201c41206b223224000240024020032005200a200e2015201720162018201420312030202f202e202d202c202b202a2029202820272026202520242023202220212020201f201e201d200d200b200c2008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b203a2032101b22004504402001203229030022027c220120025422002000ad20b001203241086a29030022027c7c22b001200254200220b001511b2200203241106a29030022af0120ae017c22022000ad7c22ad0120af0154200220ad0156ad200220af0154ad20ac01203241186a29030022ae017c7c7c220220ae0154200220ae01511b20ad0120af0185200220ae018584501b0d0120032005200a200e2015201720162018201420312030202f202e202d202c202b202a2029202820272026202520242023202220212020201f201e201d200d200b200c2008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b203a200120b00120ad012002101c2200450d02201c41206a240020000c030b201c41206a240020000c020b000b200441013a0000201c41206a240041000b450d480c4e0b41a3052d0000213241a2052d0000213a41a1052d0000213b41a0052d0000213c419f052d0000213d419e052d0000213e419d052d0000213f419c052d00002140419b052d00002141419a052d000021424199052d000021434198052d000021444197052d000021454196052d000021464195052d000021474194052d000021484193052d000021494192052d0000214a4191052d0000214b4190052d0000214c418f052d0000214d418e052d0000214e418d052d0000214f418c052d00002150418b052d00002151418a052d000021354189052d000021364188052d000021114187052d000021064186052d000021094185052d0000210f4184052d0000210841a405290300210241bc0529030021b10141b40529030021af0141ac0529030021ad01200741106b22042400027f230041206b2213240041f804412036020041800541f8041004201341800529030037000020134188052903003700082013419005290300370010201341980529030037001820132d001f210c20132d001e210b20132d001d210d20132d001c211d20132d001b211e20132d001a211f20132d0019212020132d0018212120132d0017212220132d0016212320132d0015212420132d0014212520132d0013212620132d0012212720132d0011212820132d0010212920132d000f212a20132d000e212b20132d000d212c20132d000c212d20132d000b212e20132d000a212f20132d0009213020132d0008213120132d0007211420132d0006211820132d0005211620132d0004211720132d0003211520132d0002210e20132d0001210a20132d00002105201341206b221c2400024002402005200a200e2015201720162018201420312030202f202e202d202c202b202a2029202820272026202520242023202220212020201f201e201d200d200b200c2008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b203a2032201c101b2200450440201c290300220120025a201c41086a29030022ac0120ad015a20ac0120ad015122031b201c41106a29030022ae0120af015a201c41186a29030022b00120b1015a20b00120b101511b20ae0120af018520b00120b1018584501b450d012005200a200e2015201720162018201420312030202f202e202d202c202b202a2029202820272026202520242023202220212020201f201e201d200d200b200c2008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b203a2032200120027d20ac0120ad017d20012002542200ad7d20ae0120af017d2202200020ac0120ad015420031bad22017d20b00120b1017d20ae0120af0154ad7d2001200256ad7d101c2200450d02201341206a240020000c030b201341206a240020000c020b000b200441013a0000201341206a240041000b450d470c4d0b419c052903001a4194052903001a418c052903001a418405290300200741206b2204240020041023450d450c4c0b419c0529030021ae0141940529030021b001418c0529030021024184052903002101200741206b22002400200041206b22042400027f230041306b2219240041f8044101360200201941286a42003703002019420037032020194200370318201942023703102019201941106a412041800541f8041003047f4100054180052d00000b41017122033a000f02402003450440201941206b22332400203341206b221a2400027f230041406a2210240002400240101f2203450440201041206b22342400203441206b22132400027f230041e0016b2238240041f804410436020041800541f804100a41f804412036020041800535020021b30141800541f804100441980529030021b10141900529030021af0141880529030021ad0141800529030021ac01203841406a2203220f2400200341186a4200370300200342003703102003420037030820034211370300200341206a20ac01370000200341286a20ad01370000200341306a20af01370000200341386a20b101370000200341c000203841406b1002203841f8006a4200370300203841386a203841d8006a2903003703002038420037037020384200370368203820b3013703602038203841d0006a2903003703302038203841c8006a29030037032820382038290340370320203841206a4120203841e0006a412010011a230041f0006b221124000240024002400240024002400240024020ae014200590440201141206a220320ae013703002011200137030820112002370310201120b001370318200329030021bb01201141186a29030021b801201141106a29030021bd01201129030821b501201141206b220322082400200341186a420037030020034200370310200342003703082003420837030041f80441203602002003412041800541f804100321064180052d0000210c4181052d0000210b4182052d0000210d4183052d0000211d4184052d0000211e4185052d0000211f4186052d000021204187052d000021214188052d000021224189052d00002123418a052d00002124418b052d00002125418c052d00002126418d052d00002127418e052d00002128418f052d000021294190052d0000212a4191052d0000212b4192052d0000212c4193052d0000212d4194052d0000212e4195052d0000212f4196052d000021304197052d000021314198052d000021144199052d00002118419a052d00002116419b052d00002117419c052d00002115419d052d0000210e419e052d00002105419f052d000021034124417f10122109201141b184828507360228201141286a200941086a220a4104101141f804412036020041800541f804100941800529030021af0141880529030021ad0141900529030021ac01200941246a4198052903003700002009411c6a20ac01370000200941146a20ad013700002009410c6a20af0137000020114100200320061b3a004b20114100200520061b3a004a20114100200e20061b3a004920114100201520061b3a004820114100201720061b3a004720114100201620061b3a004620114100201820061b3a004520114100201420061b3a004420114100203120061b3a004320114100203020061b3a004220114100202f20061b3a004120114100202e20061b3a004020114100202d20061b3a003f20114100202c20061b3a003e20114100202b20061b3a003d20114100202a20061b3a003c20114100202920061b3a003b20114100202820061b3a003a20114100202720061b3a003920114100202620061b3a003820114100202520061b3a003720114100202420061b3a003620114100202320061b3a003520114100202220061b3a003420114100202120061b3a003320114100202020061b3a003220114100201f20061b3a003120114100201e20061b3a003020114100201d20061b3a002f20114100200d20061b3a002e20114100200b20061b3a002d20114100200c20061b3a002c20092802002103200841106b22052400200542003703082005420037030041f8044180800236020041002011412c6a42002005200a2003410020091b41800541f80410080d0141f80428020041800510122203280200410020031b2203411f4d0d0241f8042802004180051012210a200341204b0d03200a41206a29030021b201200a41186a29030021b301200a41106a29030021b101200a41086a29030021af01200541206b22032400200341186a420037030020034200370310200342003703082003420a37030041f8044120360200027e2003412041800541f8041003044042000c010b41980529030021c00141900529030021b90141880529030021b6014180052903000b21ad01200341206b22032400200341186a420037030020034200370310200342003703082003420b37030041f80441203602002003412041800541f8041003047e42000541980529030021be0141900529030021b70141800529030021b4014188052903000b21ac01200341206b220322082400200341186a420037030020034200370310200342003703082003421037030041f80441203602002003412041800541f804100321064180052d0000210c4181052d0000210b4182052d0000210d4183052d0000211d4184052d0000211e4185052d0000211f4186052d000021204187052d000021214188052d000021224189052d00002123418a052d00002124418b052d00002125418c052d00002126418d052d00002127418e052d00002128418f052d000021294190052d0000212a4191052d0000212b4192052d0000212c4193052d0000212d4194052d0000212e4195052d0000212f4196052d000021304197052d000021314198052d000021144199052d00002118419a052d00002116419b052d00002117419c052d00002115419d052d0000210e419e052d0000210a419f052d00002103418401417f10122109201141eba490d40736024c201141cc006a200941086a22054104101120094184016a20ae01370300200941fc006a20b001370300200941f4006a2002370300200941ec006a2001370300200941e4006a20be01370300200941dc006a20b701370300200941d4006a20ac01370300200941cc006a20b401370300200941c4006a20c0013703002009413c6a20b901370300200941346a20b6013703002009412c6a20ad01370300200941246a20b2013703002009411c6a20b301370300200941146a20b1013703002009410c6a20af0137030020114100200320061b3a006f20114100200a20061b3a006e20114100200e20061b3a006d20114100201520061b3a006c20114100201720061b3a006b20114100201620061b3a006a20114100201820061b3a006920114100201420061b3a006820114100203120061b3a006720114100203020061b3a006620114100202f20061b3a006520114100202e20061b3a006420114100202d20061b3a006320114100202c20061b3a006220114100202b20061b3a006120114100202a20061b3a006020114100202920061b3a005f20114100202820061b3a005e20114100202720061b3a005d20114100202620061b3a005c20114100202520061b3a005b20114100202420061b3a005a20114100202320061b3a005920114100202220061b3a005820114100202120061b3a005720114100202020061b3a005620114100201f20061b3a005520114100201e20061b3a005420114100201d20061b3a005320114100200d20061b3a005220114100200b20061b3a005120114100200c20061b3a005020092802002103200841106b220a2400200a4200370308200a420037030041f804418080023602004100201141d0006a4200200a20052003410020091b41800541f80410080d0441f80428020041800510122203280200410020031b2203411f4d0d0541f80428020041800510122105200341204b0d06200541206a29030021af01200a41206b220a240020af014200530d07200541186a29030021ad01200541106a29030021ac01200a200541086a290300370300200a20ac01370308200a20ad01370310200a41186a220320af0137030020bb01200329030022ac018520bb0120bb0120ac017d20b801200a41106a29030022ac0154ad7d20b80120ac017d22b10120b501200a29030022af0154220320bd01200a41086a29030022b3015420b30120bd01511bad22ad0154ad7d22ac0185834200590d08000b000b000b000b000b000b000b000b000b203820b50120af017d370300203820bd0120b3017d2003ad7d370308203820b10120ad017d370310203841186a220320ac01370300201141f0006a240041f8044120360200200329030021bf01203841106a29030021ba01203841086a29030021c101203829030021bc0141800541f8041004419f052d0000211c419e052d00002132419d052d0000213a419c052d0000213b419b052d0000213c419a052d0000213d4199052d0000213e4198052d0000213f4197052d000021404196052d000021414195052d000021424194052d000021434193052d000021444192052d000021454191052d000021464190052d00002147418f052d00002148418e052d00002149418d052d0000214a418c052d0000214b418b052d0000214c418a052d0000214d4189052d0000214e4188052d0000214f4187052d000021504186052d000021514185052d000021354184052d000021364183052d000021114182052d000021064181052d000021094180052d00002108200f41206b2239240002400240027f420021b701420021be01420021b601230041a0016b220e240041f8044120360200200e4198016a4200370300200e420037039001200e420037038801200e420537038001200e41186a2203200e4180016a412041800541f8041003047e42000541900529030021b60141880529030021be0141800529030021b7014198052903000b370300200e20b701370300200e20be01370308200e20b601370310200329030021b901200e41106a29030021b801200e41086a29030021b501200e29030021b401200e41206b22032400420021b701200341186a420037030020034200370310200342003703082003420a37030041f80441203602002003412041800541f804100345044041800529030021b7010b203841c0016a2105200341206b220a240002400240024020ae014200590440200a2001370300200a2002370308200a20b001370310200a41186a220320ae01370300200329030022b20120bf018520b20120b20120bf017d200a41106a29030022ac0120ba0154ad7d20ac0120ba017d22af01200a29030022ad0120bc01542203200a41086a29030022b30120c1015420b30120c101511bad22ac0154ad7d22b10185834200530d02200a41206b220a240020b1014200530d01200a20ad0120bc017d370300200a20b30120c1017d2003ad7d370308200a20af0120ac017d370310200a41186a220320b101370300200329030021be01200a41106a29030021b601200a41086a29030021ad01200a29030021ac01200520b40120b8018420b50120b901848450047e20ac0105200e41d8006a20b901370300200e41386a20be01370300200e20b401370340200e20ac01370320200e20b501370348200e20ad01370328200e20b801370350200e20b601370330200e41206a200e41406b200e41e0006a410810160d04420021ad01420021b601420021be01200e29036020b701800b370300200520ad01370308200520b601370310200541186a20be01370300200e41a0016a240041000c040b000b000b000b000b2203450440027f20382903c00121bb01203841c8016a29030021bd01203841d0016a29030021b901203841d8016a29030021b801420021b601420021c001420021b101230041e0006b2237240041f8044120360200203741306a4200370300203742003703282037420037032020374208370318203741186a412041800541f8041003211b4180052d0000210c4181052d0000210b4182052d0000210d4183052d0000211d4184052d0000211e4185052d0000211f4186052d000021204187052d000021214188052d000021224189052d00002123418a052d00002124418b052d00002125418c052d00002126418d052d00002127418e052d00002128418f052d000021294190052d0000212a4191052d0000212b4192052d0000212c4193052d0000212d4194052d0000212e4195052d0000212f4196052d000021304197052d000021314198052d000021144199052d00002118419a052d00002116419b052d00002117419c052d00002115419d052d0000210e419e052d0000210a419f052d000021034124417f1012210f203741b18482850736023c2037413c6a200f41086a22054104101141f804412036020041800541f804100941800529030021af0141880529030021ad0141900529030021ac01200f41246a419805290300370000200f411c6a20ac01370000200f41146a20ad01370000200f410c6a20af01370000203741002003201b1b3a005f20374100200a201b1b3a005e20374100200e201b1b3a005d203741002015201b1b3a005c203741002017201b1b3a005b203741002016201b1b3a005a203741002018201b1b3a0059203741002014201b1b3a0058203741002031201b1b3a0057203741002030201b1b3a005620374100202f201b1b3a005520374100202e201b1b3a005420374100202d201b1b3a005320374100202c201b1b3a005220374100202b201b1b3a005120374100202a201b1b3a0050203741002029201b1b3a004f203741002028201b1b3a004e203741002027201b1b3a004d203741002026201b1b3a004c203741002025201b1b3a004b203741002024201b1b3a004a203741002023201b1b3a0049203741002022201b1b3a0048203741002021201b1b3a0047203741002020201b1b3a004620374100201f201b1b3a004520374100201e201b1b3a004420374100201d201b1b3a004320374100200d201b1b3a004220374100200b201b1b3a004120374100200c201b1b3a0040200f280200210341f804418080023602002037420037031020374200370308024002400240024002404100203741406b4200203741086a200520034100200f1b41800541f804100845044041f80428020041800510122203280200410020031b2203411f4d0d0141f80428020041800510122105200341204b0d02200541206a29030021b501200541186a29030021b401200541106a29030021b201200541086a29030021ad01203741206b22032400200341186a420037030020034200370310200342003703082003420937030041f80441203602002003412041800541f8041003047e42000541980529030021b60141880529030021c00141800529030021b1014190052903000b21af0120ad01200120ad017c22ac015622032003ad200220b2017c7c22b30120b2015420b20120b301511b220320b00120b4017c22ad012003ad7c22b20120b4015420ad0120b20156ad20ad0120b40154ad20ae0120b5017c7c7c22ad0120b5015420ad0120b501511b20b20120b4018520ad0120b5018584501b0d0320ac0120b1015820b30120c0015820b30120c001511b20af0120b2015a20ad0120b6015820ad0120b601511b20af0120b2018520ad0120b6018584501b450d04027f420021b701420021b601420021b401230041306b2203210c20032400027e024020b90120bb018420b80120bd01848450450440200341206b22032400200341186a420037030020034200370310200342003703082003420a37030041f80441203602002003412041800541f8041003450d0142000c020b000b41980529030021b70141880529030021b60141800529030021b4014190052903000b21b501200341206b22052400024002400240024002400240024020ae0142005904402005200137030020052002370308200520b001370310200541186a220320ae01370300200329030022b20120bf018520b20120b20120bf017d200541106a29030022ac0120ba0154ad7d20ac0120ba017d22af01200529030022ad0120bc01542203200541086a29030022b30120c1015420b30120c101511bad22ac0154ad7d22b10185834200530d02200541206b220a240020b1014200530d01200a20ad0120bc017d370300200a20b30120c1017d2003ad7d370308200a20af0120ac017d370310200a41186a220520b10137030020b401200a2903007c22ac0120b4015422032003ad20b601200a41086a2903007c7c22af0120b6015420af0120b601511b220320b501200a41106a2903007c22ad012003ad7c22b10120b5015420ad0120b10156ad20ad0120b50154ad20b70120052903007c7c7c22ad0120b7015420ad0120b701511b20b10120b5018520ad0120b7018584501b0d03200a41206b220e2400200c41206a20ad01370300200e41186a4200370300200e4200370310200e4200370308200e420a370300200c20b101370318200c20af01370310200c20ac01370308200e4120200c41086a412010011a420021be01420021b601420021b70123004180016b22032118200324000240201c2008200972200672201172203672203572205172205072204f72204e72204d72204c72204b72204a72204972204872204772204672204572204472204372204272204172204072203f72203e72203d72203c72203b72203a72203272720440027e200341206b22052400200541186a420037030020054200370310200542003703082005420537030041f804412036020042002005412041800541f80410030d001a41980529030021b70141880529030021b60141800529030021be014190052903000b21b301027e024020bb0120be017c22ac0120be015422032003ad20b60120bd017c7c22af0120b6015420af0120b601511b220320b30120b9017c22ad012003ad7c22b10120b3015420ad0120b10156ad20ad0120b30154ad20b70120b8017c7c7c22ad0120b7015420ad0120b701511b20b10120b3018520ad0120b7018584501b450440200541206b22032400201841186a20ad01370300200341186a4200370300200342003703102003420037030820034205370300201820b101370310201820af01370308201820ac01370300200341202018412010011a200341406a22052400200541186a4200370300200542003703102005420037030820054203370300200541206a20083a0000200541216a20093a0000200541226a20063a0000200541236a20113a0000200541246a20363a0000200541256a20353a0000200541266a20513a0000200541276a20503a0000200541286a204f3a0000200541296a204e3a00002005412a6a204d3a00002005412b6a204c3a00002005412c6a204b3a00002005412d6a204a3a00002005412e6a20493a00002005412f6a20483a0000200541306a20473a0000200541316a20463a0000200541326a20453a0000200541336a20443a0000200541346a20433a0000200541356a20423a0000200541366a20413a0000200541376a20403a0000200541386a203f3a0000200541396a203e3a00002005413a6a203d3a00002005413b6a203c3a00002005413c6a203b3a00002005413d6a203a3a00002005413e6a20323a00002005413f6a201c3a0000200541206b22032400200541c00020031002200329030021b101200341086a29030021af01200341106a29030021ad01200341186a29030021ac01200341206b22032400200341186a20ac01370300200320ad01370310200320af01370308200320b10137030041f80441203602002003412041800541f8041003450d01420021b701420021b601420021be0142000c020b000b41980529030021be0141900529030021b60141800529030021b7014188052903000b21b301200341406a22052400200541186a4200370300200542003703102005420037030820054203370300200541206a20083a0000200541216a20093a0000200541226a20063a0000200541236a20113a0000200541246a20363a0000200541256a20353a0000200541266a20513a0000200541276a20503a0000200541286a204f3a0000200541296a204e3a00002005412a6a204d3a00002005412b6a204c3a00002005412c6a204b3a00002005412d6a204a3a00002005412e6a20493a00002005412f6a20483a0000200541306a20473a0000200541316a20463a0000200541326a20453a0000200541336a20443a0000200541346a20433a0000200541356a20423a0000200541366a20413a0000200541376a20403a0000200541386a203f3a0000200541396a203e3a00002005413a6a203d3a00002005413b6a203c3a00002005413c6a203b3a00002005413d6a203a3a00002005413e6a20323a00002005413f6a201c3a0000200541206b22032400200541c00020031002200329030021b101200341086a29030021af01200341106a29030021ad01200341186a29030021ac01200341206b220522162400200541186a20ac01370300200520ad01370310200520af01370308200520b101370300201820b70120bb017c22ac01370320201820ac0120b701542203ad20b30120bd017c7c22ac01370328201820b60120b9017c22ad01200320ac0120b3015420ac0120b301511bad7c22ac01370330201841386a20ac0120ad0154ad20ad0120b60154ad20b80120be017c7c7c37030020054120201841206a412010011a4120417f1012220541206a4200370000200541186a4200370000200541106a4200370000200541086a220342003700004100411720032005280200410020051b10142217280200410020171b41214f04402017280200210a201641206b22052400201741086a2203200a410020171b20051005200541206b220a221624002005200a1010201841d8006a200a41186a2903003703002018200a41106a2903003703502018200a41086a2903003703482018200a290300370340201841406b2003412010110b4120417f10122205410a6a20063a0000200541096a20093a0000200541086a220320083a00002005410b6a20113a00002005410c6a20363a00002005410d6a20353a00002005410e6a20513a00002005410f6a20503a0000200541106a204f3a0000200541116a204e3a0000200541126a204d3a0000200541136a204c3a0000200541146a204b3a0000200541156a204a3a0000200541166a20493a0000200541176a20483a0000200541186a20473a0000200541196a20463a00002005411a6a20453a00002005411b6a20443a00002005411c6a20433a00002005411d6a20423a00002005411e6a20413a00002005411f6a20403a0000200541206a203f3a0000200541216a203e3a0000200541226a203d3a0000200541236a203c3a0000200541246a203b3a0000200541256a203a3a0000200541266a20323a0000200541276a201c3a00004120411520032005280200410020051b10142215280200410020151b41214f04402015280200210a201641206b22052400201541086a2203200a410020151b20051005200541206b220a221624002005200a1010201841f8006a200a41186a2903003703002018200a41106a2903003703702018200a41086a2903003703682018200a290300370360201841e0006a2003412010110b41e100417f1012221441086a22054200370000201441106a4200370000201441186a4200370000201441206a4200370000201441286a41003a0000201441296a20083a00002014412a6a20093a00002014412b6a20063a00002014412c6a20113a00002014412d6a20363a00002014412e6a20353a00002014412f6a20513a0000201441306a20503a0000201441316a204f3a0000201441326a204e3a0000201441336a204d3a0000201441346a204c3a0000201441356a204b3a0000201441366a204a3a0000201441376a20493a0000201441386a20483a0000201441396a20473a00002014413a6a20463a00002014413b6a20453a00002014413c6a20443a00002014413d6a20433a00002014413e6a20423a00002014413f6a20413a0000201441406b20403a0000201441c1006a203f3a0000201441c2006a203e3a0000201441c3006a203d3a0000201441c4006a203c3a0000201441c5006a203b3a0000201441c6006a203a3a0000201441c7006a20323a0000201441c8006a201c3a0000201441e1006a20b801370300201441d9006a20b901370300201441d1006a20bd01370300201441c9006a20bb01370300201641f0006b220a2400200a410c3a0000201641ef006b2203410c100f200341c0004120100e201641cf006b201741086a2017280200410020171b100e2016412f6b201541086a2015280200410020151b100e200a41e10020052014280200410020141b10060c010b000b20184180016a2400200e41206b22032400200341186a420037030020034200370310200342003703082003420837030041f80441203602002003412041800541f8041003210f4180052d0000210b4181052d0000210d4182052d0000211d4183052d0000211e4184052d0000211f4185052d000021204186052d000021214187052d000021224188052d000021234189052d00002124418a052d00002125418b052d00002126418c052d00002127418d052d00002128418e052d00002129418f052d0000212a4190052d0000212b4191052d0000212c4192052d0000212d4193052d0000212e4194052d0000212f4195052d000021304196052d000021314197052d000021144198052d000021184199052d00002116419a052d00002117419b052d00002115419c052d0000210e419d052d0000210a419e052d00002105419f052d0000210341f804412036020041800541f804100941800529030021b10141880529030021af0141900529030021ad0141980529030021ac0141e400417f1012211b200c41dde5e19d02360228200c41286a201b41086a41041011201b411a6a20493a0000201b41196a204a3a0000201b41186a204b3a0000201b41176a204c3a0000201b41166a204d3a0000201b41156a204e3a0000201b41146a204f3a0000201b41136a20503a0000201b41126a20513a0000201b41116a20353a0000201b41106a20363a0000201b410f6a20113a0000201b410e6a20063a0000201b410d6a20093a0000201b410c6a20083a0000201b411b6a20483a0000201b411c6a20473a0000201b411d6a20463a0000201b411e6a20453a0000201b411f6a20443a0000201b41206a20433a0000201b41216a20423a0000201b41226a20413a0000201b41236a20403a0000201b41246a203f3a0000201b41256a203e3a0000201b41266a203d3a0000201b41276a203c3a0000201b41286a203b3a0000201b41296a203a3a0000201b412a6a20323a0000201b412b6a201c3a0000201b41e4006a20ae01370300201b41dc006a20b001370300201b41d4006a2002370300201b41cc006a2001370300201b41c4006a20ac01370000201b413c6a20ad01370000201b41346a20af01370000201b412c6a20b1013700004100200b200f1b4100200d200f1b4100201d200f1b4100201e200f1b4100201f200f1b41002020200f1b41002021200f1b41002022200f1b41002023200f1b41002024200f1b41002025200f1b41002026200f1b41002027200f1b41002028200f1b41002029200f1b4100202a200f1b4100202b200f1b4100202c200f1b4100202d200f1b4100202e200f1b4100202f200f1b41002030200f1b41002031200f1b41002014200f1b41002018200f1b41002016200f1b41002017200f1b41002015200f1b4100200e200f1b4100200a200f1b41002005200f1b41002003200f1b201b412041c0021012200c412c6a10222203450440200c28022c2205280200410020051b04402005280200410020051b2203450d06200341014b0d07200541086a2d0000410171450d080b410021030b2003450440410021030b2003450d07200c41306a240020030c080b000b000b000b000b000b000b000b200c41306a240041000b2203450d05203741e0006a240020030c060b000b000b000b000b000b203741e0006a240041000b2203450440203920bb01370300203920bd01370308203920b901370310203941186a20b801370300410021030b20030d010c020b2003450d010b203841e0016a240020030c010b203941186a29030021b801203941106a29030021b501203941086a29030021b401203929030021b201203941206b22032400420021b601200341186a420037030020034200370310200342003703082003420b37030041f8044120360200027e2003412041800541f80410030440420021ad01420021b70142000c010b41980529030021b70141880529030021ad0141800529030021b6014190052903000b21ac01200341206b2205240002400240024020b7014200590440200520b601370300200520ad01370308200520ac01370310200541186a220320b701370300200329030022b30120bf0185427f8520b301200541106a29030022ac0120ba017c22af0120ac0154ad20b30120bf017c7c20af01200529030022ac0120bc017c22ad0120ac015422032003ad200541086a29030022ac0120c1017c7c22b10120ac015420ac0120b101511bad7c22ac0120af0154ad7c22af0185834200530d02200541206b2205240020af014200530d01200520ad01370300200520b101370308200520ac01370310200541186a220320af01370300200541086a29030021b101200541106a29030021af01200329030021ad01200529030021ac01200541206b22032209240020384198016a20ad01370300200341186a420037030020034200370310200342003703082003420b370300203820af0137039001203820b10137038801203820ac01370380012003412020384180016a412010011a41f804412036020041800541f80410044180052d000021084181052d0000210c4182052d0000210b4183052d0000210d4184052d0000211d4185052d0000211e4186052d0000211f4187052d000021204188052d000021214189052d00002122418a052d00002123418b052d00002124418c052d00002125418d052d00002126418e052d00002127418f052d000021284190052d000021294191052d0000212a4192052d0000212b4193052d0000212c4194052d0000212d4195052d0000212e4196052d0000212f4197052d000021304198052d000021314199052d00002114419a052d00002118419b052d00002116419c052d00002117419d052d00002115419e052d0000210e419f052d0000210a4120417f1012220541276a200a3a0000200541266a200e3a0000200541256a20153a0000200541246a20173a0000200541236a20163a0000200541226a20183a0000200541216a20143a0000200541206a20313a00002005411f6a20303a00002005411e6a202f3a00002005411d6a202e3a00002005411c6a202d3a00002005411b6a202c3a00002005411a6a202b3a0000200541196a202a3a0000200541186a20293a0000200541176a20283a0000200541166a20273a0000200541156a20263a0000200541146a20253a0000200541136a20243a0000200541126a20233a0000200541116a20223a0000200541106a20213a00002005410f6a20203a00002005410e6a201f3a00002005410d6a201e3a00002005410c6a201d3a00002005410b6a200d3a00002005410a6a200b3a0000200541096a200c3a0000200541086a220320083a000041b003411820032005280200410020051b10142206280200410020061b41204b044020062802002105200941206b220f2400200641086a22032005410020061b200f1005200f41206b220522092400200f20051010203841b8016a200541186a2903003703002038200541106a2903003703b0012038200541086a2903003703a801203820052903003703a001203841a0016a2003412010110b41e100417f1012220f41086a220341053a0000200341016a2205200c3a0001200520083a00002005200b3a00022005200d3a00032005201d3a00042005201e3a00052005201f3a0006200520203a0007200520213a0008200520223a0009200520233a000a200520243a000b200520253a000c200520263a000d200520273a000e200520283a000f200520293a00102005202a3a00112005202b3a00122005202c3a00132005202d3a00142005202e3a00152005202f3a0016200520303a0017200520313a0018200520143a0019200520183a001a200520163a001b200520173a001c200520153a001d2005200e3a001e2005200a3a001f200341216a220320b401370308200320b201370300200320b501370310200341186a20b8013703000c030b000b000b000b200f41c9006a2203200237030820032001370300200320b001370310200341186a20ae01370300200941d0006b22052400200541083a0000200941cf006b22034108100f200341d0034120100e2009412f6b200641086a2006280200410020061b100e200541c100200f41086a200f2802004100200f1b1006203441186a20b801370300203420b501370310203420b401370308203420b201370300201320ba01370310201341186a20bf01370300201320bc01370300201320c101370308203841e0016a240041000b22030d01201341186a29030021b101201341106a29030021af01201341086a29030021ad01203441186a29030021ac01203441106a29030021ae01203441086a29030021b0012013290300210220342903002101201041386a4200370300201041186a420037030020104200370330201042003703282010420137032020104200370310201042003703082010420137030020104120201041206a412010011a0c020b201041406b240020030c020b201041406b240020030c010b20332001370300203320b001370308203320ae01370310203341186a20ac01370300201a20af01370310201a41186a20b101370300201a2002370300201a20ad01370308201041406b240041000b2203450d01201941306a240020030c020b000b20002033290300370300200041186a203341186a2903003703002000203341106a2903003703102000203341086a2903003703082004201a41106a290300370310200441186a201a41186a2903003703002004201a2903003703002004201a41086a290300370308201941306a240041000b0d4c0c430b419c0529030021b60141940529030021b701418c0529030021b00141840529030021be0141a405290300210241bc0529030021c10141b40529030021ba0141ac0529030021bc01200741206b22002400200041206b22042400027f230041406a2239240002400240101f2205450440203941206b221a2400201a41206b221c2400027f230041e0006b2233240002400240024002400240024020be01203310232203450440203341186a29030021c401203341106a29030021c801203341086a29030021c501203329030021c901203341206b22132400230041f0006b220624000240024002400240024002400240024020c4014200590440200641206a220320c401370300200620c901370308200620c501370310200620c801370318200329030021bf01200641186a29030021bb01200641106a29030021c001200629030821bd01200641206b220322082400200341186a420037030020034200370310200342003703082003420837030041f80441203602002003412041800541f804100321094180052d0000210c4181052d0000210b4182052d0000210d4183052d0000211d4184052d0000211e4185052d0000211f4186052d000021204187052d000021214188052d000021224189052d00002123418a052d00002124418b052d00002125418c052d00002126418d052d00002127418e052d00002128418f052d000021294190052d0000212a4191052d0000212b4192052d0000212c4193052d0000212d4194052d0000212e4195052d0000212f4196052d000021304197052d000021314198052d000021144199052d00002118419a052d00002116419b052d00002117419c052d00002115419d052d0000210e419e052d0000210a419f052d000021034124417f1012210f200641b184828507360228200641286a200f41086a22054104101141f804412036020041800541f804100941800529030021b40141880529030021b3014190052903002101200f41246a419805290300370000200f411c6a2001370000200f41146a20b301370000200f410c6a20b40137000020064100200320091b3a004b20064100200a20091b3a004a20064100200e20091b3a004920064100201520091b3a004820064100201720091b3a004720064100201620091b3a004620064100201820091b3a004520064100201420091b3a004420064100203120091b3a004320064100203020091b3a004220064100202f20091b3a004120064100202e20091b3a004020064100202d20091b3a003f20064100202c20091b3a003e20064100202b20091b3a003d20064100202a20091b3a003c20064100202920091b3a003b20064100202820091b3a003a20064100202720091b3a003920064100202620091b3a003820064100202520091b3a003720064100202420091b3a003620064100202320091b3a003520064100202220091b3a003420064100202120091b3a003320064100202020091b3a003220064100201f20091b3a003120064100201e20091b3a003020064100201d20091b3a002f20064100200d20091b3a002e20064100200b20091b3a002d20064100200c20091b3a002c200f2802002103200841106b220a2400200a4200370308200a420037030041f8044180800236020041002006412c6a4200200a200520034100200f1b41800541f80410080d0141f80428020041800510122203280200410020031b2203411f4d0d0241f80428020041800510122105200341204b0d03200541206a29030021b901200541186a29030021b801200541106a29030021b501200541086a29030021b401200a41206b22032400200341186a420037030020034200370310200342003703082003420a37030041f80441203602002003412041800541f8041003047e42000541980529030021c30141900529030021c60141880529030021b2014180052903000b21b301200341206b22032400200341186a420037030020034200370310200342003703082003420b37030041f80441203602002003412041800541f8041003047e42000541980529030021b10141900529030021c20141800529030021af014188052903000b2101200341206b220322082400200341186a420037030020034200370310200342003703082003421037030041f80441203602002003412041800541f804100321094180052d0000210c4181052d0000210b4182052d0000210d4183052d0000211d4184052d0000211e4185052d0000211f4186052d000021204187052d000021214188052d000021224189052d00002123418a052d00002124418b052d00002125418c052d00002126418d052d00002127418e052d00002128418f052d000021294190052d0000212a4191052d0000212b4192052d0000212c4193052d0000212d4194052d0000212e4195052d0000212f4196052d000021304197052d000021314198052d000021144199052d00002118419a052d00002116419b052d00002117419c052d00002115419d052d0000210e419e052d0000210a419f052d00002103418401417f1012210f200641e587b1c37936024c200641cc006a200f41086a220541041011200f4184016a20c401370300200f41fc006a20c801370300200f41f4006a20c501370300200f41ec006a20c901370300200f41e4006a20b101370300200f41dc006a20c201370300200f41d4006a2001370300200f41cc006a20af01370300200f41c4006a20c301370300200f413c6a20c601370300200f41346a20b201370300200f412c6a20b301370300200f41246a20b901370300200f411c6a20b801370300200f41146a20b501370300200f410c6a20b40137030020064100200320091b3a006f20064100200a20091b3a006e20064100200e20091b3a006d20064100201520091b3a006c20064100201720091b3a006b20064100201620091b3a006a20064100201820091b3a006920064100201420091b3a006820064100203120091b3a006720064100203020091b3a006620064100202f20091b3a006520064100202e20091b3a006420064100202d20091b3a006320064100202c20091b3a006220064100202b20091b3a006120064100202a20091b3a006020064100202920091b3a005f20064100202820091b3a005e20064100202720091b3a005d20064100202620091b3a005c20064100202520091b3a005b20064100202420091b3a005a20064100202320091b3a005920064100202220091b3a005820064100202120091b3a005720064100202020091b3a005620064100201f20091b3a005520064100201e20091b3a005420064100201d20091b3a005320064100200d20091b3a005220064100200b20091b3a005120064100200c20091b3a0050200f2802002103200841106b220a2400200a4200370308200a420037030041f804418080023602004100200641d0006a4200200a200520034100200f1b41800541f80410080d0441f80428020041800510122203280200410020031b2203411f4d0d0541f80428020041800510122105200341204b0d06200541206a29030021b101200a41206b220a240020b1014200530d07200541186a29030021af01200541106a2903002101200a200541086a290300370300200a2001370308200a20af01370310200a41186a220320b10137030020bf01200329030022018520bf0120bf0120017d20bb01200a41106a290300220154ad7d20bb0120017d22b30120bd01200a29030022b10154220320c001200a41086a29030022b2015420b20120c001511bad22af0154ad7d220185834200590d08000b000b000b000b000b000b000b000b000b201320bd0120b1017d370300201320c00120b2017d2003ad7d370308201320b30120af017d370310201341186a2001370300200641f0006a2400410022050d0641f8044120360200201341186a29030021c701201341106a29030021c001201341086a29030021bf012013290300210141800541f8041004419f052d00002132419e052d0000213a419d052d0000213b419c052d0000213c419b052d0000213d419a052d0000213e4199052d0000213f4198052d000021404197052d000021414196052d000021424195052d000021434194052d000021444193052d000021454192052d000021464191052d000021474190052d00002148418f052d00002149418e052d0000214a418d052d0000214b418c052d0000214c418b052d0000214d418a052d0000214e4189052d0000214f4188052d000021504187052d000021514186052d000021354185052d000021364184052d000021114183052d000021064182052d000021094181052d0000210f4180052d00002108201341206b22132400027e0240027f230041d0006b2234240002400240024002400240024002400240024002402008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b203a2032203441086a101a2203450440203429030820be015a203441106a29030022af0120b0015a20af0120b001511b203441186a29030022af0120b7015a203441206a29030022b10120b6015a20b10120b601511b20af0120b7018520b10120b6018584501b450d01200120c9015420bf0120c5015420bf0120c501511b20c00120c8015420c40120c7015520c40120c701511b20c00120c8018520c40120c7018584501b450d03203441206b2205240020c4014200530d02200520c901370300200520c501370308200520c801370310200541186a220320c401370300200329030022b50120c7018520b50120b50120c7017d200541106a29030022af0120c00154ad7d20af0120c0017d22b301200529030022b1012001542203200541086a29030022b40120bf015420b40120bf01511bad22af0154ad7d22b20185834200530d05200541206b2205240020b2014200530d04200520b10120017d370300200520b40120bf017d2003ad7d370308200520b30120af017d370310200541186a220320b201370300200329030021bd01200541106a29030021b901200541086a29030021b801200529030021b5012008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b203a203220be0120b00120b70120b601101e22030d09200541206b2203220c2400200341186a420037030020034200370310200342003703082003420837030041f80441203602002003412041800541f804100321194180052d0000210b4181052d0000210d4182052d0000211d4183052d0000211e4184052d0000211f4185052d000021204186052d000021214187052d000021224188052d000021234189052d00002124418a052d00002125418b052d00002126418c052d00002127418d052d00002128418e052d00002129418f052d0000212a4190052d0000212b4191052d0000212c4192052d0000212d4193052d0000212e4194052d0000212f4195052d000021304196052d000021314197052d000021144198052d000021184199052d00002116419a052d00002117419b052d00002115419c052d0000210e419d052d0000210a419e052d00002105419f052d0000210341c400417f10122110203441bbb996c87a360248203441c8006a201041086a41041011201041176a204d3a0000201041166a204e3a0000201041156a204f3a0000201041146a20503a0000201041136a20513a0000201041126a20353a0000201041116a20363a0000201041106a20113a00002010410f6a20063a00002010410e6a20093a00002010410d6a200f3a00002010410c6a20083a0000201041186a204c3a0000201041196a204b3a00002010411a6a204a3a00002010411b6a20493a00002010411c6a20483a00002010411d6a20473a00002010411e6a20463a00002010411f6a20453a0000201041206a20443a0000201041216a20433a0000201041226a20423a0000201041236a20413a0000201041246a20403a0000201041256a203f3a0000201041266a203e3a0000201041276a203d3a0000201041286a203c3a0000201041296a203b3a00002010412a6a203a3a00002010412b6a20323a0000201041c4006a20bd013703002010413c6a20b901370300201041346a20b8013703002010412c6a20b501370300027e4100200b20191b4100200d20191b4100201d20191b4100201e20191b4100201f20191b4100202020191b4100202120191b4100202220191b4100202320191b4100202420191b4100202520191b4100202620191b4100202720191b4100202820191b4100202920191b4100202a20191b4100202b20191b4100202c20191b4100202d20191b4100202e20191b4100202f20191b4100203020191b4100203120191b4100201420191b4100201820191b4100201620191b4100201720191b4100201520191b4100200e20191b4100200a20191b4100200520191b4100200320191b2010412041c0021012203441cc006a10222205450440203428024c2205280200410020051b04402005280200410020051b2203450d09200341014b0d0a200541086a2d0000410171450d0b0b410021050b2005450440410021050b02402005450440200c41206b22052400420021c201200541186a420037030020054200370310200542003703082005420a37030041f80441203602002005412041800541f8041003450d01420021c601420021c30142000c020b203441d0006a240020050c0d0b41900529030021c30141880529030021c60141800529030021c2014198052903000b21bb0120c20120c9017d22b30120c2015620c60120c5017d20c20120c901542203ad7d22b40120c6015620b40120c601511b20c30120c8017d22b101200320c50120c6015620c50120c601511bad22af017d22b20120c3015620bb0120c4017d20c30120c80154ad7d20af0120b10156ad7d22af0120bb015620af0120bb01511b20b20120c3018520af0120bb018584501b450d0a000b203441d0006a240020030c0a0b000b000b000b000b000b000b000b000b203441d0006a240020030c010b200541206b22032400203441406b20af01370300200341186a420037030020034200370310200342003703082003420a370300203420b201370338203420b401370330203420b30137032820034120203441286a412010011a201341186a20bd01370300201320b901370310201320b801370308201320b501370300203441d0006a240041000b2205450440201341186a29030021b501201341106a29030021b401201341086a29030021b201201329030021b301201341206b22032400200341186a420037030020034200370310200342003703082003420b37030041f80441203602002003412041800541f8041003450d0142000c020b0c080b41900529030021ad0141880529030021ac0141800529030021ae014198052903000b21af01200341206b2205240020af014200530d01200520ae01370300200520ac01370308200520ad01370310200541186a220320af01370300200329030022b10120c70185427f8520b101200541106a29030022ae0120c0017c22ad0120ae0154ad20b10120c7017c7c20ad01200529030022ae0120017c22ac0120ae015422032003ad200541086a29030022ae0120bf017c7c22af0120ae015420ae0120af01511bad7c22ae0120ad0154ad7c22ad0185834200530d03200541206b2205240020ad014200530d02200520ac01370300200520af01370308200520ae01370310200541186a220320ad01370300200541086a29030021af01200541106a29030021ad01200329030021ac01200529030021ae01200541206b220322092400203341386a20ac01370300200341186a420037030020034200370310200342003703082003420b370300203320ad01370330203320af01370328203320ae0137032020034120203341206a412010011a200220b3015820b20120bc015a20b20120bc01511b20b40120ba015a20b50120c1015a20b50120c101511b20b40120ba018520b50120c1018584501b450d0441f804412036020041800541f80410044180052d000021084181052d0000210c4182052d0000210b4183052d0000210d4184052d0000211d4185052d0000211e4186052d0000211f4187052d000021204188052d000021214189052d00002122418a052d00002123418b052d00002124418c052d00002125418d052d00002126418e052d00002127418f052d000021284190052d000021294191052d0000212a4192052d0000212b4193052d0000212c4194052d0000212d4195052d0000212e4196052d0000212f4197052d000021304198052d000021314199052d00002114419a052d00002118419b052d00002116419c052d00002117419d052d00002115419e052d0000210e419f052d0000210a4120417f1012220541276a200a3a0000200541266a200e3a0000200541256a20153a0000200541246a20173a0000200541236a20163a0000200541226a20183a0000200541216a20143a0000200541206a20313a00002005411f6a20303a00002005411e6a202f3a00002005411d6a202e3a00002005411c6a202d3a00002005411b6a202c3a00002005411a6a202b3a0000200541196a202a3a0000200541186a20293a0000200541176a20283a0000200541166a20273a0000200541156a20263a0000200541146a20253a0000200541136a20243a0000200541126a20233a0000200541116a20223a0000200541106a20213a00002005410f6a20203a00002005410e6a201f3a00002005410d6a201e3a00002005410c6a201d3a00002005410b6a200d3a00002005410a6a200b3a0000200541096a200c3a0000200541086a220320083a000041f003411820032005280200410020051b10142206280200410020061b41204b044020062802002105200941206b220f2400200641086a22032005410020061b200f1005200f41206b220522092400200f20051010203341d8006a200541186a2903003703002033200541106a2903003703502033200541086a29030037034820332005290300370340203341406b2003412010110b41e100417f1012220f41086a220341063a0000200341016a2205200c3a0001200520083a00002005200b3a00022005200d3a00032005201d3a00042005201e3a00052005201f3a0006200520203a0007200520213a0008200520223a0009200520233a000a200520243a000b200520253a000c200520263a000d200520273a000e200520283a000f200520293a00102005202a3a00112005202b3a00122005202c3a00132005202d3a00142005202e3a00152005202f3a0016200520303a0017200520313a0018200520143a0019200520183a001a200520163a001b200520173a001c200520153a001d2005200e3a001e2005200a3a001f200341216a220320b001370308200320be01370300200320b701370310200341186a20b6013703000c050b203341e0006a240020030c060b000b000b000b000b200f41c9006a220320b201370308200320b301370300200320b401370310200341186a20b501370300200941d0006b22052400200541083a0000200941cf006b22034108100f20034190044120100e2009412f6b200641086a2006280200410020061b100e200541c100200f41086a200f2802004100200f1b1006201a41186a20b501370300201a20b401370310201a20b201370308201a20b301370300201c20c001370310201c41186a20c701370300201c2001370300201c20bf01370308203341e0006a240041000c010b203341e0006a240020050b22050d02201c41186a29030021b101201c41106a29030021af01201c41086a29030021ad01201a41186a29030021ac01201a41106a29030021ae01201a41086a29030021b001201c2903002102201a2903002101203941386a4200370300203941186a420037030020394200370330203942003703282039420137032020394200370310203942003703082039420137030020394120203941206a412010011a0c010b0c010b20002001370300200020b001370308200020ae01370310200041186a20ac01370300200420af01370310200441186a20b10137030020042002370300200420ad01370308203941406b240041000c010b203941406b240020050b0d4b0c420b41a3052d0000213b41a2052d0000213c41a1052d0000213d41a0052d0000213e419f052d0000213f419e052d00002140419d052d00002141419c052d00002142419b052d00002143419a052d000021444199052d000021454198052d000021464197052d000021474196052d000021484195052d000021494194052d0000214a4193052d0000214b4192052d0000214c4191052d0000214d4190052d0000214e418f052d0000214f418e052d00002150418d052d00002151418c052d00002135418b052d00002136418a052d000021114189052d000021064188052d000021094187052d0000210f4186052d000021084185052d0000210c4184052d0000210b41a40529030021b50141bc0529030021b90141b40529030021b40141ac0529030021b201200741206b22042400027f230041206b223a240041f8044120360200203a41186a4200370300203a4200370310203a4200370308203a420e370300203a412041800541f804100321324180052d0000210d4181052d0000211d4182052d0000211e4183052d0000211f4184052d000021204185052d000021214186052d000021224187052d000021234188052d000021244189052d00002125418a052d00002126418b052d00002127418c052d00002128418d052d00002129418e052d0000212a418f052d0000212b4190052d0000212c4191052d0000212d4192052d0000212e4193052d0000212f4194052d000021304195052d000021314196052d000021144197052d000021184198052d000021164199052d00002117419a052d00002115419b052d0000210e419c052d0000210a419d052d00002105419e052d00002103419f052d0000210041f804412036020041800541f8041004024002404180052d00004100200d20321b41ff0171470d004181052d00004100201d20321b41ff0171470d004182052d00004100201e20321b41ff0171470d004183052d00004100201f20321b41ff0171470d004184052d00004100202020321b41ff0171470d004185052d00004100202120321b41ff0171470d004186052d00004100202220321b41ff0171470d004187052d00004100202320321b41ff0171470d004188052d00004100202420321b41ff0171470d004189052d00004100202520321b41ff0171470d00418a052d00004100202620321b41ff0171470d00418b052d00004100202720321b41ff0171470d00418c052d00004100202820321b41ff0171470d00418d052d00004100202920321b41ff0171470d00418e052d00004100202a20321b41ff0171470d00418f052d00004100202b20321b41ff0171470d004190052d00004100202c20321b41ff0171470d004191052d00004100202d20321b41ff0171470d004192052d00004100202e20321b41ff0171470d004193052d00004100202f20321b41ff0171470d004194052d00004100203020321b41ff0171470d004195052d00004100203120321b41ff0171470d004196052d00004100201420321b41ff0171470d004197052d00004100201820321b41ff0171470d004198052d00004100201620321b41ff0171470d004199052d00004100201720321b41ff0171470d00419a052d00004100201520321b41ff0171470d00419b052d00004100200e20321b41ff0171470d00419c052d00004100200a20321b41ff0171470d00419d052d00004100200520321b41ff0171470d00419e052d00004100200320321b41ff0171470d00419f052d00004100200020321b41ff0171470d00203a41206b220e2400027f230041406a2217240002400240101f2200450440201741206b220a2400027f230041306b2215240041f8044101360200201541286a42003703002015420037032020154200370318201542023703102015201541106a412041800541f8041003047f4100054180052d00000b41017122003a000f02402000450440201541206b22052400027f230041406a2216240002400240024002400240200b200c2008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b2016101a2200450440201629030020b5015a201641086a290300220120b2015a200120b201511b201641106a290300220120b4015a201641186a290300220220b9015a200220b901511b200120b40185200220b9018584501b450d01201641206b22002400200041186a420037030020004200370310200042003703082000420a37030041f80441203602002000412041800541f80410031a027e200041406a22032400200341186a4200370300200342003703102003420037030820034211370300200341206a200b3a0000200341216a200c3a0000200341226a20083a0000200341236a200f3a0000200341246a20093a0000200341256a20063a0000200341266a20113a0000200341276a20363a0000200341286a20353a0000200341296a20513a00002003412a6a20503a00002003412b6a204f3a00002003412c6a204e3a00002003412d6a204d3a00002003412e6a204c3a00002003412f6a204b3a0000200341306a204a3a0000200341316a20493a0000200341326a20483a0000200341336a20473a0000200341346a20463a0000200341356a20453a0000200341366a20443a0000200341376a20433a0000200341386a20423a0000200341396a20413a00002003413a6a20403a00002003413b6a203f3a00002003413c6a203e3a00002003413d6a203d3a00002003413e6a203c3a00002003413f6a203b3a0000200341206b22002400200341c00020001002200029030021ac01200041086a29030021b001200041106a2903002102200041186a2903002101200041206b22002400200041186a200137030020002002370310200020b001370308200020ac0137030041f80441203602002000412041800541f8041003044042000c010b41980529030021ae0141900529030021b10141800529030021ba014188052903000b21ac01200041206b22032400200341186a420037030020034200370310200342003703082003420c37030041f80441203602002003412041800541f8041003047e42000541900529030021c20141880529030021bc0141800529030021c3014198052903000b21af0141f804410436020041800541f804100a418005350200220120ba017d22b001200156420020ac01200120ba01542200ad7c7d22ad0142005220ad01501b420020b1017d2202200020ac0142005220ac01501bad22017d22ac0142005242002001200256ad20ae0120b101420052ad7c7c7d22014200522001501b200120ac0184501b0d0220b00120c3015a20ad0120bc015a20ad0120bc01511b20ac0120c2015a200120af015a200120af01511b20ac0120c20185200120af018584501b450d03200341206b2203240020b5012003102322000d04200341186a29030021af01200341106a29030021b301200341086a29030021b801200329030021b101027e0240200b200c2008200f2009200620112036203520512050204f204e204d204c204b204a2049204820472046204520442043204220412040203f203e203d203c203b20b50120b20120b40120b901101e2200450440200341206b22032400420021b401200341186a420037030020034200370310200342003703082003420a37030041f80441203602002003412041800541f8041003450d01420021014200210242000c020b201641406b240020000c080b4190052903002102418805290300210141800529030021b4014198052903000b21b20120b40120b1017d22ae0120b40156200120b8017d20b10120b401562200ad7d22ad01200156200120ad01511b200220b3017d22b0012000200120b80154200120b801511bad22017d22ac0120025620b20120af017d200220b30154ad7d200120b00156ad7d220120b20156200120b201511b200220ac0185200120b2018584501b450d05000b201641406b240020000c050b000b000b000b201641406b240020000c010b200341206b22002400201641386a2001370300200041186a420037030020004200370310200042003703082000420a370300201620ac01370330201620ad01370328201620ae0137032020004120201641206a412010011a200541186a20af01370300200520b301370310200520b801370308200520b101370300201641406b240041000b2200450d01201541306a240020000c020b000b200a2005290300370300200a41186a200541186a290300370300200a200541106a290300370310200a200541086a290300370308201541306a240041000b22000d01200a41186a29030021ae01200a41106a29030021b001200a41086a2903002102200a2903002101201741386a4200370300201741186a420037030020174200370330201742003703282017420137032020174200370310201742003703082017420137030020174120201741206a412010011a0c020b201741406b240020000c020b201741406b240020000c010b200e2001370300200e2002370308200e20b001370310200e41186a20ae01370300201741406b240041000b2200450d01203a41206a240020000c020b000b2004200e290300370300200441186a200e41186a2903003703002004200e41106a2903003703102004200e41086a290300370308203a41206a240041000b450d420c490b419c0529030021bb0141940529030021bd01418c0529030021b90141840529030021b801200741206b22042400027f230041206b220f240041f8044120360200200f41186a4200370300200f4200370310200f4200370308200f420f370300200f412041800541f8041003210b4180052d0000210d4181052d0000211d4182052d0000211e4183052d0000211f4184052d000021204185052d000021214186052d000021224187052d000021234188052d000021244189052d00002125418a052d00002126418b052d00002127418c052d00002128418d052d00002129418e052d0000212a418f052d0000212b4190052d0000212c4191052d0000212d4192052d0000212e4193052d0000212f4194052d000021304195052d000021314196052d000021144197052d000021184198052d000021164199052d00002117419a052d00002115419b052d0000210e419c052d0000210a419d052d00002105419e052d00002103419f052d0000210041f804412036020041800541f8041004024002404180052d00004100200d200b1b41ff0171470d004181052d00004100201d200b1b41ff0171470d004182052d00004100201e200b1b41ff0171470d004183052d00004100201f200b1b41ff0171470d004184052d000041002020200b1b41ff0171470d004185052d000041002021200b1b41ff0171470d004186052d000041002022200b1b41ff0171470d004187052d000041002023200b1b41ff0171470d004188052d000041002024200b1b41ff0171470d004189052d000041002025200b1b41ff0171470d00418a052d000041002026200b1b41ff0171470d00418b052d000041002027200b1b41ff0171470d00418c052d000041002028200b1b41ff0171470d00418d052d000041002029200b1b41ff0171470d00418e052d00004100202a200b1b41ff0171470d00418f052d00004100202b200b1b41ff0171470d004190052d00004100202c200b1b41ff0171470d004191052d00004100202d200b1b41ff0171470d004192052d00004100202e200b1b41ff0171470d004193052d00004100202f200b1b41ff0171470d004194052d000041002030200b1b41ff0171470d004195052d000041002031200b1b41ff0171470d004196052d000041002014200b1b41ff0171470d004197052d000041002018200b1b41ff0171470d004198052d000041002016200b1b41ff0171470d004199052d000041002017200b1b41ff0171470d00419a052d000041002015200b1b41ff0171470d00419b052d00004100200e200b1b41ff0171470d00419c052d00004100200a200b1b41ff0171470d00419d052d000041002005200b1b41ff0171470d00419e052d000041002003200b1b41ff0171470d00419f052d000041002000200b1b41ff0171470d00200f41206b22082400027f230041306b2209240041f8044101360200200941286a42003703002009420037032020094200370318200942023703102009200941106a412041800541f8041003047f4100054180052d00000b41017122003a000f02402000450440200941206b220c2400027f230041406a2211240002400240101f2200450440201141206b220b2400027f230041f0006b223624000240027e024020b80120b90120bd0120bb01203641286a203641086a10262200450440203641206a29030021af01203641186a2903002101203641106a29030021b001203641406b29030021b501203641386a29030021b401203641306a29030021b20120362903082102203629032821b301203641206b22002400200041186a420037030020004200370310200042003703082000420b37030041f80441203602002000412041800541f8041003450d0142000c020b0c020b41900529030021c20141880529030021bc0141800529030021ba014198052903000b21ae01200041206b2203240002400240024002400240024020ae014200590440200320ba01370300200320bc01370308200320c201370310200341186a220020ae01370300200029030022ad0120af0185427f8520ad012001200341106a29030022017c22ac01200154ad20ad0120af017c7c20ac0120ac012003290300220120027c220220015422002000ad200341086a290300220120b0017c7c22ae01200154200120ae01511bad7c220156ad7c22b00185834200530d02200341206b2203240020b0014200530d0120032002370300200320ae0137030820032001370310200341186a220020b001370300200341086a29030021ae01200341106a29030021b0012000290300210220032903002101200341206b22002400203641e0006a2002370300200041186a420037030020004200370310200042003703082000420b370300203620b001370358203620ae013703502036200137034820004120203641c8006a412010011a200041206b22002400200041186a420037030020004200370310200042003703082000420837030041f80441203602002000412041800541f804100321354180052d0000210d4181052d0000211d4182052d0000211e4183052d0000211f4184052d000021204185052d000021214186052d000021224187052d000021234188052d000021244189052d00002125418a052d00002126418b052d00002127418c052d00002128418d052d00002129418e052d0000212a418f052d0000212b4190052d0000212c4191052d0000212d4192052d0000212e4193052d0000212f4194052d000021304195052d000021314196052d000021144197052d000021184198052d000021164199052d00002117419a052d00002115419b052d0000210e419c052d0000210a419d052d00002105419e052d00002103419f052d0000210041f804412036020041800541f804100441f804412036020041800529030021b10141880529030021af0141900529030021ad0141980529030021ac0141800541f804100941980529030021ae0141900529030021b0014188052903002102418005290300210141e400417f10122106203641dde5e19d02360268203641e8006a200641086a41041011200641e4006a20bb01370300200641dc006a20bd01370300200641d4006a20b901370300200641cc006a20b801370300200641246a20ac013700002006411c6a20ad01370000200641146a20af013700002006410c6a20b1013700002006412c6a2001370000200641346a20023700002006413c6a20b001370000200641c4006a20ae013700004100200d20351b4100201d20351b4100201e20351b4100201f20351b4100202020351b4100202120351b4100202220351b4100202320351b4100202420351b4100202520351b4100202620351b4100202720351b4100202820351b4100202920351b4100202a20351b4100202b20351b4100202c20351b4100202d20351b4100202e20351b4100202f20351b4100203020351b4100203120351b4100201420351b4100201820351b4100201620351b4100201720351b4100201520351b4100200e20351b4100200a20351b4100200520351b4100200320351b4100200020351b2006412041c0021012203641ec006a10222200450440203628026c2203280200410020031b04402003280200410020031b2200450d05200041014b0d06200341086a2d0000410171450d070b410021000b2000450440410021000b2000450d060c070b000b000b000b000b000b000b200b20b301370300200b20b201370308200b20b401370310200b41186a20b501370300203641f0006a240041000c010b203641f0006a240020000b22000d01200b41186a29030021ae01200b41106a29030021b001200b41086a2903002102200b2903002101201141386a4200370300201141186a420037030020114200370330201142003703282011420137032020114200370310201142003703082011420137030020114120201141206a412010011a0c020b201141406b240020000c020b201141406b240020000c010b200c2001370300200c2002370308200c20b001370310200c41186a20ae01370300201141406b240041000b2200450d01200941306a240020000c020b000b2008200c290300370300200841186a200c41186a2903003703002008200c41106a2903003703102008200c41086a290300370308200941306a240041000b2200450d01200f41206a240020000c020b000b20042008290300370300200441186a200841186a2903003703002004200841106a2903003703102004200841086a290300370308200f41206a240041000b450d410c480b419c0529030021ae0141940529030021b001418c0529030021024184052903002101200741206b22042400027f230041206b2213240041f8044120360200201341186a420037030020134200370310201342003703082013420f3703002013412041800541f8041003210b4180052d0000210d4181052d0000211d4182052d0000211e4183052d0000211f4184052d000021204185052d000021214186052d000021224187052d000021234188052d000021244189052d00002125418a052d00002126418b052d00002127418c052d00002128418d052d00002129418e052d0000212a418f052d0000212b4190052d0000212c4191052d0000212d4192052d0000212e4193052d0000212f4194052d000021304195052d000021314196052d000021144197052d000021184198052d000021164199052d00002117419a052d00002115419b052d0000210e419c052d0000210a419d052d00002105419e052d00002103419f052d0000210041f804412036020041800541f8041004024002404180052d00004100200d200b1b41ff0171470d004181052d00004100201d200b1b41ff0171470d004182052d00004100201e200b1b41ff0171470d004183052d00004100201f200b1b41ff0171470d004184052d000041002020200b1b41ff0171470d004185052d000041002021200b1b41ff0171470d004186052d000041002022200b1b41ff0171470d004187052d000041002023200b1b41ff0171470d004188052d000041002024200b1b41ff0171470d004189052d000041002025200b1b41ff0171470d00418a052d000041002026200b1b41ff0171470d00418b052d000041002027200b1b41ff0171470d00418c052d000041002028200b1b41ff0171470d00418d052d000041002029200b1b41ff0171470d00418e052d00004100202a200b1b41ff0171470d00418f052d00004100202b200b1b41ff0171470d004190052d00004100202c200b1b41ff0171470d004191052d00004100202d200b1b41ff0171470d004192052d00004100202e200b1b41ff0171470d004193052d00004100202f200b1b41ff0171470d004194052d000041002030200b1b41ff0171470d004195052d000041002031200b1b41ff0171470d004196052d000041002014200b1b41ff0171470d004197052d000041002018200b1b41ff0171470d004198052d000041002016200b1b41ff0171470d004199052d000041002017200b1b41ff0171470d00419a052d000041002015200b1b41ff0171470d00419b052d00004100200e200b1b41ff0171470d00419c052d00004100200a200b1b41ff0171470d00419d052d000041002005200b1b41ff0171470d00419e052d000041002003200b1b41ff0171470d00419f052d000041002000200b1b41ff0171470d00201341206b221c2400027f230041306b221a240041f8044101360200201a41286a4200370300201a4200370320201a4200370318201a4202370310201a201a41106a412041800541f8041003047f4100054180052d00000b41017122003a000f02402000450440201a41206b22322400027f230041406a2239240002400240101f2200450440203941206b223a2400027f230041b0016b2210240002400240024002400240024002400240024002400240024002400240024002402001200220b00120ae01201041206a201010242200450440201041186a29030021bb01201041106a29030021b201201041086a29030021b301201041386a29030021ac01201041306a29030021b001201041286a2903002102201029030021ae012010290320201041206b220a22002400200041206b220522002400200041206b220322002400200041206b220e2400200220b00120ac01200a20052003200e102522000d10200e41186a29030021c101200e41106a29030021bf01200e41086a29030021c001200341186a29030021b101200341106a29030021af01200341086a29030021ad01200541186a29030021bd01200541106a29030021b901200541086a29030021b801200a41186a29030021b601200a41106a29030021b701200a41086a29030021be01200e29030021ba01200329030021ac01200529030021b501200a29030021bc01200e41206b2200220b2400200041186a420037030020004200370310200042003703082000420837030041f80441203602002000412041800541f80410032109419f052d0000210d419e052d0000211d419d052d0000211e419c052d0000211f419b052d00002120419a052d000021214199052d000021224198052d000021234197052d000021244196052d000021254195052d000021264194052d000021274193052d000021284192052d000021294191052d0000212a4190052d0000212b418f052d0000212c418e052d0000212d418d052d0000212e418c052d0000212f418b052d00002130418a052d000021314189052d000021144188052d000021184187052d000021164186052d000021174185052d000021154184052d0000210e4183052d0000210a4182052d000021054181052d000021034180052d000021004124417f1012210f201041b184828507360244201041c4006a200f41086a220c4104101141f804412036020041800541f804100941800529030021b00141880529030021024190052903002101200c41046a22084198052903003700182008200137001020082002370008200820b00137000020104100200e20091b3a004c20104100200a20091b3a004b20104100200520091b3a004a20104100200320091b3a004920104100200020091b3a004820104100201520091b3a004d20104100201720091b3a004e20104100201620091b3a004f20104100201820091b3a005020104100201420091b3a005120104100203120091b3a005220104100203020091b3a005320104100202f20091b3a005420104100202e20091b3a005520104100202d20091b3a005620104100202c20091b3a005720104100202b20091b3a005820104100202a20091b3a005920104100202920091b3a005a20104100202820091b3a005b20104100202720091b3a005c20104100202620091b3a005d20104100202520091b3a005e20104100202420091b3a005f20104100202320091b3a006020104100202220091b3a006120104100202120091b3a006220104100202020091b3a006320104100201f20091b3a006420104100201e20091b3a006520104100201d20091b3a006620104100200d20091b3a0067200f2802002100200b41106b22052400200542003703082005420037030041f804418080023602004100201041c8006a42002005200c20004100200f1b41800541f80410080d0141f80428020041800510122200280200410020001b22004120490d0241f80428020041800510122103200041204b0d03027e024020bc01200341086a2903005620be01200341106a290300220156200120be01511b20b701200341186a29030022015620b601200341206a290300220256200220b601511b200120b70185200220b6018584501b450440200541206b22002400200041186a420037030020004200370310200042003703082000420b37030041f80441203602002000412041800541f8041003450d01420021014200210242000c020b000b4190052903002102418805290300210141800529030021c2014198052903000b21b001200041206b2203240020b0014200530d04200320c2013703002003200137030820032002370310200341186a220020b001370300200029030022b40120bb0185427f8520b401200341106a290300220120b2017c22b001200154ad20b40120bb017c7c20b0012003290300220120ae017c220220015422002000ad200341086a290300220120b3017c7c22ae01200154200120ae01511bad7c220120b00154ad7c22b00185834200530d06200341206b2203240020b0014200530d0520032002370300200320ae0137030820032001370310200341186a220020b001370300027e200341086a29030021ae01200341106a29030021b0012000290300210220032903002101200341206b2200240020104180016a200237030042002102200041186a420037030020004200370310200042003703082000420b370300201020b001370378201020ae013703702010200137036820004120201041e8006a412010011a200041206b22032400200341186a420037030020034200370310200342003703082003420a37030041f80441203602002003412041800541f8041003044042002101420021b20142000c010b41980529030021b201418805290300210141800529030021024190052903000b21b3012002200220b5017c22b0015622002000ad200120b8017c7c220220015420012002511b220020b30120b9017c22012000ad7c22ae0120b30154200120ae0156ad200120b30154ad20b20120bd017c7c7c220120b20154200120b201511b20ae0120b30185200120b2018584501b0d07200341206b220022032400201041a0016a2001370300200041186a420037030020004200370310200042003703082000420a370300201020ae01370398012010200237039001201020b001370388012000412020104188016a412010011a41e100417f1012220a41086a220041083a0000200041016a220520b801370308200520b501370300200520b901370310200541186a20bd01370300200041216a220020ad01370308200020ac01370300200020af01370310200041186a20b101370300200a41c9006a220020c001370308200020ba01370300200020bf01370310200041186a20c101370300200341306b22052400200541043a00002003412f6b22004104100f200041d0044120100e20054121200a41086a200a2802004100200a1b1006200541206b2200220b2400200041186a420037030020004200370310200042003703082000420837030041f80441203602002000412041800541f804100321084180052d0000210d4181052d0000211d4182052d0000211e4183052d0000211f4184052d000021204185052d000021214186052d000021224187052d000021234188052d000021244189052d00002125418a052d00002126418b052d00002127418c052d00002128418d052d00002129418e052d0000212a418f052d0000212b4190052d0000212c4191052d0000212d4192052d0000212e4193052d0000212f4194052d000021304195052d000021314196052d000021144197052d000021184198052d000021164199052d00002117419a052d00002115419b052d0000210e419c052d0000210a419d052d00002105419e052d00002103419f052d0000210041f804412036020041800541f804100441800529030021ae0141880529030021b0014190052903002102419805290300210141c400417f1012210c201041bbb996c87a3602a801201041a8016a200c41086a41041011200c41c4006a20b601370300200c413c6a20b701370300200c41346a20be01370300200c412c6a20bc01370300200c41246a2001370000200c411c6a2002370000200c41146a20b001370000200c410c6a20ae0137000002404100200d20081b4100201d20081b4100201e20081b4100201f20081b4100202020081b4100202120081b4100202220081b4100202320081b4100202420081b4100202520081b4100202620081b4100202720081b4100202820081b4100202920081b4100202a20081b4100202b20081b4100202c20081b4100202d20081b4100202e20081b4100202f20081b4100203020081b4100203120081b4100201420081b4100201820081b4100201620081b4100201720081b4100201520081b4100200e20081b4100200a20081b4100200520081b4100200320081b4100200020081b200c412041c0021012201041ac016a102222050d004100210520102802ac012203280200410020031b450d002003280200410020031b2200450d09200041014b0d0a200341086a2d0000410171450d0b0b20050d0f20ba0120bf018420c00120c1018484500d0e200b41206b22002400200041186a420037030020004200370310200042003703082000420837030041f80441203602002000412041800541f804100321334180052d0000213b4181052d0000213c4182052d0000213d4183052d0000213e4184052d0000213f4185052d000021404186052d000021414187052d000021424188052d000021434189052d00002144418a052d00002145418b052d00002146418c052d00002147418d052d00002148418e052d00002149418f052d0000214a4190052d0000214b4191052d0000214c4192052d0000214d4193052d0000214e4194052d0000214f4195052d000021504196052d000021514197052d000021354198052d000021364199052d00002111419a052d00002106419b052d00002109419c052d0000210f419d052d00002108419e052d0000210c419f052d0000210b200041206b22002400200041186a420037030020004200370310200042003703082000420d37030041f80441203602002000412041800541f804100321344180052d0000210d4181052d0000211d4182052d0000211e4183052d0000211f4184052d000021204185052d000021214186052d000021224187052d000021234188052d000021244189052d00002125418a052d00002126418b052d00002127418c052d00002128418d052d00002129418e052d0000212a418f052d0000212b4190052d0000212c4191052d0000212d4192052d0000212e4193052d0000212f4194052d000021304195052d000021314196052d000021144197052d000021184198052d000021164199052d00002117419a052d00002115419b052d0000210e419c052d0000210a419d052d00002105419e052d00002103419f052d0000210041c400417f10122119201041bbb996c87a3602a801201041a8016a201941086a410410112019412b6a4100200020341b3a00002019412a6a4100200320341b3a0000201941296a4100200520341b3a0000201941286a4100200a20341b3a0000201941276a4100200e20341b3a0000201941266a4100201520341b3a0000201941256a4100201720341b3a0000201941246a4100201620341b3a0000201941236a4100201820341b3a0000201941226a4100201420341b3a0000201941216a4100203120341b3a0000201941206a4100203020341b3a00002019411f6a4100202f20341b3a00002019411e6a4100202e20341b3a00002019411d6a4100202d20341b3a00002019411c6a4100202c20341b3a00002019411b6a4100202b20341b3a00002019411a6a4100202a20341b3a0000201941196a4100202920341b3a0000201941186a4100202820341b3a0000201941176a4100202720341b3a0000201941166a4100202620341b3a0000201941156a4100202520341b3a0000201941146a4100202420341b3a0000201941136a4100202320341b3a0000201941126a4100202220341b3a0000201941116a4100202120341b3a0000201941106a4100202020341b3a00002019410f6a4100201f20341b3a00002019410e6a4100201e20341b3a00002019410d6a4100201d20341b3a00002019410c6a4100200d20341b3a0000201941c4006a20c1013703002019413c6a20bf01370300201941346a20c0013703002019412c6a20ba013703004100203b20331b4100203c20331b4100203d20331b4100203e20331b4100203f20331b4100204020331b4100204120331b4100204220331b4100204320331b4100204420331b4100204520331b4100204620331b4100204720331b4100204820331b4100204920331b4100204a20331b4100204b20331b4100204c20331b4100204d20331b4100204e20331b4100204f20331b4100205020331b4100205120331b4100203520331b4100203620331b4100201120331b4100200620331b4100200920331b4100200f20331b4100200820331b4100200c20331b4100200b20331b2019412041c0021012201041ac016a1022220545044020102802ac012203280200410020031b04402003280200410020031b2200450d0d200041014b0d0e200341086a2d0000410171450d0f0b410021050b2005450440410021050b2005450d0e0c0f0b0c0f0b000b000b000b000b000b000b000b000b000b000b000b000b000b203a20bc01370300203a20be01370308203a20b701370310203a41186a20b601370300201041b0016a240041000c020b201041b0016a240020050c010b201041b0016a240020000b22000d01203a41186a29030021ae01203a41106a29030021b001203a41086a2903002102203a2903002101203941386a4200370300203941186a420037030020394200370330203942003703282039420137032020394200370310203942003703082039420137030020394120203941206a412010011a0c020b203941406b240020000c020b203941406b240020000c010b2032200137030020322002370308203220b001370310203241186a20ae01370300203941406b240041000b2200450d01201a41306a240020000c020b000b201c2032290300370300201c41186a203241186a290300370300201c203241106a290300370310201c203241086a290300370308201a41306a240041000b2200450d01201341206a240020000c020b000b2004201c290300370300200441186a201c41186a2903003703002004201c41106a2903003703102004201c41086a290300370308201341206a240041000b450d400c470b41a3052d0000210d41a2052d0000211d41a1052d0000211e41a0052d0000211f419f052d00002120419e052d00002121419d052d00002122419c052d00002123419b052d00002124419a052d000021254199052d000021264198052d000021274197052d000021284196052d000021294195052d0000212a4194052d0000212b4193052d0000212c4192052d0000212d4191052d0000212e4190052d0000212f418f052d00002130418e052d00002131418d052d00002114418c052d00002118418b052d00002116418a052d000021174189052d000021154188052d0000210e4187052d0000210a4186052d000021054185052d000021034184052d00002100200741206b22042400027f4200210142002102230041406a220b2400200b41406a220c2400200c41186a4200370300200c4200370310200c4200370308200c4211370300200c41206a20003a0000200c41216a20033a0000200c41226a20053a0000200c41236a200a3a0000200c41246a200e3a0000200c41256a20153a0000200c41266a20173a0000200c41276a20163a0000200c41286a20183a0000200c41296a20143a0000200c412a6a20313a0000200c412b6a20303a0000200c412c6a202f3a0000200c412d6a202e3a0000200c412e6a202d3a0000200c412f6a202c3a0000200c41306a202b3a0000200c41316a202a3a0000200c41326a20293a0000200c41336a20283a0000200c41346a20273a0000200c41356a20263a0000200c41366a20253a0000200c41376a20243a0000200c41386a20233a0000200c41396a20223a0000200c413a6a20213a0000200c413b6a20203a0000200c413c6a201f3a0000200c413d6a201e3a0000200c413e6a201d3a0000200c413f6a200d3a0000200c41c000200b41206a100241f8044120360200200b41186a200b41386a290300370300200b200b41306a290300370310200b200b41286a290300370308200b200b290320370300200b412041800541f8041003047e4200054198052903002102419005290300210141880529030021b4014180052903000b21ac01200c41206b22002400200041186a420037030020004200370310200042003703082000420c37030041f80441203602002000412041800541f8041003047e42000541980529030021ba0141880529030021bc0141800529030021b2014190052903000b21ae0120ac0120ac0120b2017c22b0015622002000ad20b40120bc017c7c22ac0120b4015420ac0120b401511b2200200120ae017c22ae012000ad7c22ad0120015420ad0120ae0154ad200120ae0156ad200220ba017c7c7c22ae01200254200220ae01511b200120ad0185200220ae018584501b450440200420b001370300200420ac01370308200420ad01370310200441186a20ae01370300200b41406b240041000c010b000b450d3f0c460b419c0529030021ae0141940529030021b001418c0529030021024184052903002101200741206b22042400027f230041406a220e2400024002402001200220b00120ae01200e41206a200e10242252450440200e41386a29030021ae01200e41306a29030021b001200e41286a2903002102200e290320200e41206b220a2400200a41206b22052400200541206b22032400200341206b22002400200220b00120ae01200a20052003200010252252450d010c020b0c010b2004200a290300370300200441186a200a41186a2903003703002004200a41106a2903003703102004200a41086a290300370308200e41406b240041000c010b200e41406b240020520b450d3e0c450b000b000b2005413f4b0d01200541ffffffff03712005470d02200341086a2005410274360200410121520c360b2005413f4b0d02200541ffffffff03712005470d03200341086a2005410274360200410121520c350b200541ffff004b0d03200541ffffffff03712005470d0441022152200341086a20054102744101723602000c340b000b200541ffff004b0d03200541ffffffff03712005470d0441022152200341086a20054102744101723602000c320b000b2005200541ffffffff0371460440200341086a2005410274410272360200410421520c310b000b000b2005200541ffffffff0371460440200341086a2005410274410272360200410421520c2f0b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b027f024002400240024002402054205241a0016a4f0440200020526a225341a0016a20544b0d012000417f1012226a41086a205241a4066a2000100e205341a4066a2d000022004103710e03030405020b000b000b000b4101215220004102760c020b41022152205341a4066a2f01004102760c010b41042152205341a4066a2802004102760b2112024002400240024002400240205341a0016a220420526a220020044f0440200020544b0d01205341a0016a2204201220526a22036a22002004490d02200020544b0d032012417f101221692052205341a0016a22046a22002004490d04206941086a20004184056a2012100e205341a0016a220420036a22002004490d05200020544f0d06000b000b000b000b000b000b000b027f41002100230041f0006b2212240041f804412036020041800541f8041004201241980529030022ae01370048201241900529030022b00137004020124188052903002202370038201241800529030022013700302001a720122d003120122d003220122d003320122d003420122d003520122d003620122d00372002a720122d003920122d003a20122d003b20122d003c20122d003d20122d003e20122d003f20b001a720122d004120122d004220122d004320122d004420122d004520122d004620122d004720ae01a720122d004920122d004a20122d004b20122d004c20122d004d20122d004e20122d004f102122040440200421000b02400240024002402000450440201241e8006a22034200370300201241c8006a4200370300201242003703602012420037035820124201370350201242003703402012420037033820124201370330201241306a22044120201241d0006a2200412010011a20034200370300201241003a0030201242003703602012420037035820124202370350200041202004410110011a230041206b22032400200341186a42003703002003420037031020034200370308200342063703000240206a2802004100206a1b22004504402003412010001a0c010b20034120206a41086a200010011a0b200341206b22042400200441186a420037030020044200370310200442003703082004420737030002402069280200410020691b22004504402004412010001a0c010b20044120206941086a200010011a0b200341206a2400201220133a00312012201c3a00302012201a3a0032201220393a0033201220343a0034201220333a0035201220193a0036201220103a00372012201b3a0038201220383a0039201220373a003a201220683a003b201220673a003c201220663a003d201220653a003e201220643a003f201220633a0040201220623a0041201220613a0042201220603a00432012205f3a00442012205e3a00452012205d3a00462012205c3a00472012205b3a00482012205a3a0049201220593a004a201220583a004b201220573a004c201220563a004d201220553a004e201220ab013a004f201241e8006a4200370300201242003703602012420037035820124208370350201241d0006a4120201241306a412010011a201241206b22002400200041206b22042400200420a1013a0009200420a2013a0008200420a3013a0007200420a4013a0006200420a5013a0005200420a6013a0004200420a7013a0003200420a8013a0002200420a9013a0001200420aa013a0000200420a0013a000a2004209f013a000b2004209e013a000c2004209d013a000d2004209c013a000e2004209b013a000f2004209a013a001020042099013a001120042098013a001220042097013a001320042096013a001420042095013a001520042094013a001620042093013a001720042092013a001820042091013a001920042090013a001a2004208f013a001b2004208e013a001c2004208d013a001d2004208c013a001e2004208b013a001f200041186a420037030020004200370310200042003703082000420e370300200041202004412010011a200441206b22002400200041206b220424002004206b3a001f2004206c3a001e2004206d3a001d2004206e3a001c2004206f3a001b200420703a001a200420713a0019200420723a0018200420733a0017200420743a0016200420753a0015200420763a0014200420773a0013200420783a0012200420793a00112004207a3a00102004207b3a000f2004207c3a000e2004207d3a000d2004207e3a000c2004207f3a000b20042080013a000a20042081013a000920042082013a000820042083013a000720042084013a000620042085013a000520042086013a000420042087013a000320042088013a000220042089013a00012004208a013a0000200041186a420037030020004200370310200042003703082000420f370300200041202004412010011a200441206b22002400200041206b220424002004200c3a001f2004200b3a001e2004200d3a001d2004201d3a001c2004201e3a001b2004201f3a001a200420203a0019200420213a0018200420223a0017200420233a0016200420243a0015200420253a0014200420263a0013200420273a0012200420283a0011200420293a00102004202a3a000f2004202b3a000e2004202c3a000d2004202d3a000c2004202e3a000b2004202f3a000a200420303a0009200420313a0008200420143a0007200420183a0006200420163a0005200420173a0004200420153a00032004200e3a00022004200a3a0001200420053a0000200041186a420037030020004200370310200042003703082000420d370300200041202004412010011a200441206b22002400200041206b22042400200420323a001f2004203a3a001e2004203b3a001d2004203c3a001c2004203d3a001b2004203e3a001a2004203f3a0019200420403a0018200420413a0017200420423a0016200420433a0015200420443a0014200420453a0013200420463a0012200420473a0011200420483a0010200420493a000f2004204a3a000e2004204b3a000d2004204c3a000c2004204d3a000b2004204e3a000a2004204f3a0009200420503a0008200420513a0007200420353a0006200420363a0005200420113a0004200420063a0003200420093a00022004200f3a0001200420083a0000200041186a4200370300200042003703102000420037030820004210370300200041202004412010011a208b0120a90120aa017220a8017220a7017220a6017220a5017220a4017220a3017220a2017220a1017220a00172209f0172209e0172209d0172209c0172209b0172209a017220990172209801722097017220960172209501722094017220930172209201722091017220900172208f0172208e0172208d0172208c017272450d04200441206b2200220b2400200041186a420037030020004200370310200042003703082000420e37030041f80441203602002000412041800541f804100321084180052d0000210d4181052d0000211d4182052d0000211e4183052d0000211f4184052d000021204185052d000021214186052d000021224187052d000021234188052d000021244189052d00002125418a052d00002126418b052d00002127418c052d00002128418d052d00002129418e052d0000212a418f052d0000212b4190052d0000212c4191052d0000212d4192052d0000212e4193052d0000212f4194052d000021304195052d000021314196052d000021144197052d000021184198052d000021164199052d00002117419a052d00002115419b052d0000210e419c052d0000210a419d052d00002105419e052d00002103419f052d000021004104417f1012210c201241c0d49f4436020c2012410c6a200c41086a22044104101120124100200020081b3a002f20124100200320081b3a002e20124100200520081b3a002d20124100200a20081b3a002c20124100200e20081b3a002b20124100201520081b3a002a20124100201720081b3a002920124100201620081b3a002820124100201820081b3a002720124100201420081b3a002620124100203120081b3a002520124100203020081b3a002420124100202f20081b3a002320124100202e20081b3a002220124100202d20081b3a002120124100202c20081b3a002020124100202b20081b3a001f20124100202a20081b3a001e20124100202920081b3a001d20124100202820081b3a001c20124100202720081b3a001b20124100202620081b3a001a20124100202520081b3a001920124100202420081b3a001820124100202320081b3a001720124100202220081b3a001620124100202120081b3a001520124100202020081b3a001420124100201f20081b3a001320124100201e20081b3a001220124100201d20081b3a001120124100200d20081b3a0010200c2802002100200b41106b22032400200342003703082003420037030041f804418080023602004100201241106a42002003200420004100200c1b41800541f80410080d0141f80428020041800510122200280200410020001b2200411f4d0d0241f80428020041800510122104200041204b0d030240208a01200441086a2d0000470d00208901200441096a2d0000470d002088012004410a6a2d0000470d002087012004410b6a2d0000470d002086012004410c6a2d0000470d002085012004410d6a2d0000470d002084012004410e6a2d0000470d002083012004410f6a2d0000470d00208201200441106a2d0000470d00208101200441116a2d0000470d00208001200441126a2d0000470d00207f200441136a2d0000470d00207e200441146a2d0000470d00207d200441156a2d0000470d00207c200441166a2d0000470d00207b200441176a2d0000470d00207a200441186a2d0000470d002079200441196a2d0000470d0020782004411a6a2d0000470d0020772004411b6a2d0000470d0020762004411c6a2d0000470d0020752004411d6a2d0000470d0020742004411e6a2d0000470d0020732004411f6a2d0000470d002072200441206a2d0000470d002071200441216a2d0000470d002070200441226a2d0000470d00206f200441236a2d0000470d00206e200441246a2d0000470d00206d200441256a2d0000470d00206c200441266a2d0000470d00206b200441276a2d0000460d050b000b201241f0006a240020000c040b000b000b000b201241f0006a240041000b0d270c1d0b203a2d00000c200b20002d000021044101417f101241086a220020043a00000c210b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b000b2052200341086a22036a200441086a2005100e200020002004280200410020041b6a22044d0440410020032004100b0c0d0b000b027e200741406b412041800541f804100304404200210242000c010b41980529030021bc01418805290300210241800529030021b4014190052903000b2101200420b4013703002004200237030820042001370310200441186a220020bc01370300200441086a2903002101200441106a2903002102200029030021b4010c080b20002d00000c040b41004100417f101241086a4100100b0c090b200441186a29030021b101200441106a29030021af01200441086a29030021ad01200041186a29030021ac01200041106a29030021ae01200041086a29030021b001200429030021022000290300210141c000417f1012220441186a20ae01370300200441106a20b001370300200441086a22002001370300200441206a20ac01370300200041206a220020ad0137030820002002370300200020af01370310200041186a20b1013703004100200441086a41c000100b0c080b200441086a2903002101200441106a2903002102200441186a29030021b4010c040b20042d00000b21044101417f101241086a220020044101713a00000c010b200741406b412041800541f8041003210d4180052d0000211d4181052d0000211e4182052d0000211f4183052d000021204184052d000021214185052d000021224186052d000021234187052d000021244188052d000021254189052d00002126418a052d00002127418b052d00002128418c052d00002129418d052d0000212a418e052d0000212b418f052d0000212c4190052d0000212d4191052d0000212e4192052d0000212f4193052d000021304194052d000021314195052d000021144196052d000021184197052d000021164198052d000021174199052d00002115419a052d0000210e419b052d0000210a419c052d00002105419d052d00002103419e052d0000210020044100419f052d0000200d1b3a001f200441002000200d1b3a001e200441002003200d1b3a001d200441002005200d1b3a001c20044100200a200d1b3a001b20044100200e200d1b3a001a200441002015200d1b3a0019200441002017200d1b3a0018200441002016200d1b3a0017200441002018200d1b3a0016200441002014200d1b3a0015200441002031200d1b3a0014200441002030200d1b3a001320044100202f200d1b3a001220044100202e200d1b3a001120044100202d200d1b3a001020044100202c200d1b3a000f20044100202b200d1b3a000e20044100202a200d1b3a000d200441002029200d1b3a000c200441002028200d1b3a000b200441002027200d1b3a000a200441002026200d1b3a0009200441002025200d1b3a0008200441002024200d1b3a0007200441002023200d1b3a0006200441002022200d1b3a0005200441002021200d1b3a0004200441002020200d1b3a000320044100201f200d1b3a000220044100201e200d1b3a000120044100201d200d1b3a0000200429000021ae01200429000821b00120042900102102200429001821014120417f1012220041206a2001370000200041186a2002370000200041106a20b001370000200041086a220420ae013700000c020b410020004101100b0c030b200429030021b0014120417f1012220041206a20b401370300200041186a2002370300200041106a2001370300200041086a220420b0013703000b410020044120100b0c010b200741e0006a24000f0b200741e0006a24000bb70301037f230041206b22012400101541f8044180800236020041800541f804100c41f40441f804280200220236020023004180026b2200240020004198016a427f370300200041f8006a42003703002000427f370390012000427f370388012000427f37038001200042003703702000420037036820004209370360200041e0006a412020004180016a412010011a200041b8016a4200370300200041d8006a4200370300200042003703b001200042003703a801200042003703a00120004200370350200042003703482000420a370340200041406b4120200041a0016a412010011a200041d8016a4200370300200041386a4200370300200042003703d001200042003703c801200042003703c00120004200370330200042003703282000420b370320200041206a4120200041c0016a412010011a200041f8016a4200370300200041186a4200370300200042003703f001200042003703e801200042e8073703e00120004200370310200042003703082000420c37030020004120200041e0016a412010011a20004180026a24002001411036020c200141106a2001410c6a100d20022001290310200141186a2903001027000b5401027f230041206b22002400101541f8044180800236020041800541f804100c41f40441f80428020022013602002000411036020c200041106a2000410c6a100d20012000290310200041186a2903001027000b9f1402257f0c7e23004180016b2207240041f8044120360200200741306a4200370300200742003703282007420037032020074208370318200741186a412041800541f804100321084180052d0000210f4181052d000021104182052d000021114183052d000021124184052d000021134185052d000021144186052d000021154187052d000021164188052d000021174189052d00002118418a052d00002119418b052d0000211a418c052d0000211b418d052d0000211c418e052d0000211d418f052d0000211e4190052d0000211f4191052d000021204192052d000021214193052d000021224194052d000021234195052d000021244196052d000021254197052d000021264198052d000021274199052d00002128419a052d00002129419b052d0000212a419c052d0000212b419d052d0000210c419e052d0000210e419f052d000021094124417f1012210d200741b184828507360238200741386a200d41086a220b4104101141f804412036020041800541f8041009418005290300212c418805290300212d419005290300212e200d41246a419805290300370000200d411c6a202e370000200d41146a202d370000200d410c6a202c37000020074100200920081b3a005b20074100200e20081b3a005a20074100200c20081b3a005920074100202b20081b3a005820074100202a20081b3a005720074100202920081b3a005620074100202820081b3a005520074100202720081b3a005420074100202620081b3a005320074100202520081b3a005220074100202420081b3a005120074100202320081b3a005020074100202220081b3a004f20074100202120081b3a004e20074100202020081b3a004d20074100201f20081b3a004c20074100201e20081b3a004b20074100201d20081b3a004a20074100201c20081b3a004920074100201b20081b3a004820074100201a20081b3a004720074100201920081b3a004620074100201820081b3a004520074100201720081b3a004420074100201620081b3a004320074100201520081b3a004220074100201420081b3a004120074100201320081b3a004020074100201220081b3a003f20074100201120081b3a003e20074100201020081b3a003d20074100200f20081b3a003c200d280200210941f8044180800236020020074200370310200742003703080240024002400240024002400240024041002007413c6a4200200741086a200b20094100200d1b41800541f804100845044041f80428020041800510122209280200410020091b2209411f4d0d0141f8042802004180051012210b200941204b0d02200b41206a2903002132200b41186a290300212c200b41106a290300212d200b41086a290300212e200741206b22092400200941186a420037030020094200370310200942003703082009420a37030041f8044120360200027e2009412041800541f8041003044042000c010b4190052903002137418805290300213641800529030021354198052903000b2131200941206b22092400200941186a420037030020094200370310200942003703082009420b37030041f8044120360200027e2009412041800541f8041003044042000c010b4190052903002130418805290300212f41800529030021344198052903000b2133200941206b2209220d2400200941186a420037030020094200370310200942003703082009421037030041f80441203602002009412041800541f8041003210a4180052d0000210f4181052d000021104182052d000021114183052d000021124184052d000021134185052d000021144186052d000021154187052d000021164188052d000021174189052d00002118418a052d00002119418b052d0000211a418c052d0000211b418d052d0000211c418e052d0000211d418f052d0000211e4190052d0000211f4191052d000021204192052d000021214193052d000021224194052d000021234195052d000021244196052d000021254197052d000021264198052d000021274199052d00002128419a052d00002129419b052d0000212a419c052d0000212b419d052d0000210c419e052d0000210b419f052d00002109418401417f101221082007200636025c200741dc006a200841086a220e4104101120084184016a2003370300200841fc006a2002370300200841f4006a2001370300200841ec006a2000370300200841e4006a2033370300200841dc006a2030370300200841d4006a202f370300200841cc006a2034370300200841c4006a20313703002008413c6a2037370300200841346a20363703002008412c6a2035370300200841246a20323703002008411c6a202c370300200841146a202d3703002008410c6a202e370300200741002009200a1b3a007f20074100200b200a1b3a007e20074100200c200a1b3a007d20074100202b200a1b3a007c20074100202a200a1b3a007b200741002029200a1b3a007a200741002028200a1b3a0079200741002027200a1b3a0078200741002026200a1b3a0077200741002025200a1b3a0076200741002024200a1b3a0075200741002023200a1b3a0074200741002022200a1b3a0073200741002021200a1b3a0072200741002020200a1b3a007120074100201f200a1b3a007020074100201e200a1b3a006f20074100201d200a1b3a006e20074100201c200a1b3a006d20074100201b200a1b3a006c20074100201a200a1b3a006b200741002019200a1b3a006a200741002018200a1b3a0069200741002017200a1b3a0068200741002016200a1b3a0067200741002015200a1b3a0066200741002014200a1b3a0065200741002013200a1b3a0064200741002012200a1b3a0063200741002011200a1b3a0062200741002010200a1b3a006120074100200f200a1b3a006020082802002109200d41106b220b2400200b4200370308200b420037030041f804418080023602004100200741e0006a4200200b200e2009410020081b41800541f80410080d0341f80428020041800510122209280200410020091b2209411f4d0d0441f8042802004180051012210e200941204b0d05200b41206b220c220b240020034200530d06200e41206a2903002131200e41186a2903002133200e41106a2903002132200e41086a290300212c200c2000370300200c2001370308200c2002370310200c41186a22092003370300200b41206b220b240020314200530d072009290300212f200c41106a2903002101200c41086a2903002130200c290300212d200b202c370300200b2032370308200b2033370310200b41186a22092031370300202f2009290300220085202f202f20007d2001200b41106a290300220054ad7d200120007d2203202d200b29030022025422092030200b41086a290300222e54202e2030511bad220154ad7d220085834200590d08000b000b000b000b000b000b000b000b000b2004202c3703002004203237030820042033370310200441186a20313703002005200320017d370310200541186a20003703002005202d20027d37030020052030202e7d2009ad7d37030820074180016a240041000b0ba7040c0041000b17584945524332303a3a5472616e736665723a3a66726f6d0041200b15504945524332303a3a5472616e736665723a3a746f0041c1000b104945524332303a3a5472616e736665720041e0000b515c4945524332303a3a417070726f76616c3a3a6f776e65720000000000000000644945524332303a3a417070726f76616c3a3a7370656e646572000000000000004945524332303a3a417070726f76616c0041c0010b58b04f776e61626c653a3a4f776e6572736869705472616e736665727265643a3a70726576696f75734f776e65720000009c4f776e61626c653a3a4f776e6572736869705472616e736665727265643a3a6e65774f776e65720041a1020b604f776e61626c653a3a4f776e6572736869705472616e7366657272656400005361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656443616c6c207265766572746564000000005061757361626c653a3a506175736564004191030b125061757361626c653a3a556e7061757365640041b0030b185c4953776170506f6f6c3a3a4d696e743a3a73656e6465720041d1030b0f4953776170506f6f6c3a3a4d696e740041f0030b185c4953776170506f6f6c3a3a4275726e3a3a73656e646572004191040b0f4953776170506f6f6c3a3a4275726e0041b0040b3bea3518ca01838b91fdf63753e320e0d5264e697d4f957bcfe1e38d447d92c44e004953776170506f6f6c3a3a436861726765645377617046656573008e010970726f64756365727302086c616e6775616765010143000c70726f6365737365642d62790105636c616e676131352e302e34202868747470733a2f2f6769746875622e636f6d2f736f6c616e612d6c6162732f6c6c766d2d70726f6a6563742e676974203333633336323963616135396235396438663538353733366134613531393461613965393337376429', + compiler: 'solang 0.3.2', + hash: '0x480a1345d46a94f8d4a41c5f443c00de2f6d784e8ae1ebc3ea8a8a585990872a', + language: 'Solidity 0.3.2', }, spec: { constructors: [ @@ -19,35 +18,35 @@ export const swapPoolAbi = { { label: '_asset', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_slippageCurve', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_router', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_backstop', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: '_protocolTreasury', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -66,6 +65,7 @@ export const swapPoolAbi = { }, }, ], + default: false, docs: [''], label: 'new', payable: false, @@ -74,8 +74,35 @@ export const swapPoolAbi = { }, ], docs: [ - 'Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool:\nThe owner can either pause the pool, disabling deposits, swaps & backstop,\nor the owner can set the pool cap to zero which only prevents deposits.\nThe former is for security incidents, the latter for phasing out a pool.\n\n', + 'Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool.', ], + environment: { + accountId: { + displayName: ['AccountId'], + type: 2, + }, + balance: { + displayName: ['Balance'], + type: 13, + }, + blockNumber: { + displayName: ['BlockNumber'], + type: 14, + }, + chainExtension: { + displayName: [], + type: 0, + }, + hash: { + displayName: ['Hash'], + type: 15, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 14, + }, + }, events: [ { args: [ @@ -84,7 +111,7 @@ export const swapPoolAbi = { indexed: true, label: 'from', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -93,7 +120,7 @@ export const swapPoolAbi = { indexed: true, label: 'to', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -102,7 +129,7 @@ export const swapPoolAbi = { indexed: false, label: 'value', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -117,7 +144,7 @@ export const swapPoolAbi = { indexed: true, label: 'owner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -126,7 +153,7 @@ export const swapPoolAbi = { indexed: true, label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -135,7 +162,7 @@ export const swapPoolAbi = { indexed: false, label: 'value', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -150,7 +177,7 @@ export const swapPoolAbi = { indexed: false, label: 'account', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -165,7 +192,7 @@ export const swapPoolAbi = { indexed: false, label: 'account', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -180,7 +207,7 @@ export const swapPoolAbi = { indexed: true, label: 'previousOwner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -189,7 +216,7 @@ export const swapPoolAbi = { indexed: true, label: 'newOwner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -204,7 +231,7 @@ export const swapPoolAbi = { indexed: true, label: 'sender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -213,7 +240,7 @@ export const swapPoolAbi = { indexed: false, label: 'poolSharesMinted', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -222,12 +249,12 @@ export const swapPoolAbi = { indexed: false, label: 'amountPrincipleDeposited', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['emitted on every deposit\n\n'], + docs: ['emitted on every deposit'], label: 'Mint', }, { @@ -237,7 +264,7 @@ export const swapPoolAbi = { indexed: true, label: 'sender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -246,7 +273,7 @@ export const swapPoolAbi = { indexed: false, label: 'poolSharesBurned', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -255,13 +282,13 @@ export const swapPoolAbi = { indexed: false, label: 'amountPrincipleWithdrawn', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], docs: [ - 'emitted on every withdrawal special case withdrawal using backstop liquidiity: amountPrincipleWithdrawn = 0\n\n', + 'emitted on every withdrawal special case withdrawal using backstop liquidiity: amountPrincipleWithdrawn = 0', ], label: 'Burn', }, @@ -272,7 +299,7 @@ export const swapPoolAbi = { indexed: false, label: 'recipient', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, @@ -281,13 +308,13 @@ export const swapPoolAbi = { indexed: false, label: 'amountSwapTokens', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], docs: [ - 'emitted when a backstop pool LP withdraws liquidity from swap pool only possible if swap pool coverage ratio remains >= 100%\n\n', + 'emitted when a backstop pool LP withdraws liquidity from swap pool only possible if swap pool coverage ratio remains >= 100%', ], label: 'BackstopDrain', }, @@ -298,7 +325,7 @@ export const swapPoolAbi = { indexed: false, label: 'lpFees', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -307,7 +334,7 @@ export const swapPoolAbi = { indexed: false, label: 'backstopFees', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, @@ -316,22 +343,23 @@ export const swapPoolAbi = { indexed: false, label: 'protocolFees', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['Tracks the exact amounts of individual fees paid during a swap\n\n'], + docs: ['Tracks the exact amounts of individual fees paid during a swap'], label: 'ChargedSwapFees', }, ], lang_error: { - displayName: [], - type: 0, + displayName: ['SolidityError'], + type: 18, }, messages: [ { args: [], + default: false, docs: [''], label: 'name', mutates: false, @@ -344,6 +372,7 @@ export const swapPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'symbol', mutates: false, @@ -356,24 +385,26 @@ export const swapPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'decimals', mutates: false, payable: false, returnType: { - displayName: ['u8'], + displayName: ['uint8'], type: 0, }, selector: '0x313ce567', }, { args: [], + default: false, docs: [''], label: 'totalSupply', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0x18160ddd', @@ -383,17 +414,18 @@ export const swapPoolAbi = { { label: 'account', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [''], label: 'balanceOf', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0x70a08231', @@ -403,18 +435,19 @@ export const swapPoolAbi = { { label: 'to', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'amount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'transfer', mutates: true, @@ -430,24 +463,25 @@ export const swapPoolAbi = { { label: 'owner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [''], label: 'allowance', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0xdd62ed3e', @@ -457,18 +491,19 @@ export const swapPoolAbi = { { label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'amount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'approve', mutates: true, @@ -484,25 +519,26 @@ export const swapPoolAbi = { { label: 'from', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'to', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'amount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'transferFrom', mutates: true, @@ -518,18 +554,19 @@ export const swapPoolAbi = { { label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'addedValue', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'increaseAllowance', mutates: true, @@ -545,18 +582,19 @@ export const swapPoolAbi = { { label: 'spender', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { label: 'subtractedValue', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [''], label: 'decreaseAllowance', mutates: true, @@ -569,6 +607,7 @@ export const swapPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'paused', mutates: false, @@ -581,18 +620,20 @@ export const swapPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'owner', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0x8da5cb5b', }, { args: [], + default: false, docs: [''], label: 'renounceOwnership', mutates: true, @@ -605,11 +646,12 @@ export const swapPoolAbi = { { label: 'newOwner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [''], label: 'transferOwnership', mutates: true, @@ -619,151 +661,159 @@ export const swapPoolAbi = { }, { args: [], + default: false, docs: [''], label: 'poolCap', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0xb954dc57', }, { args: [], - docs: ["Returns the pooled token's address\n\n"], + default: false, + docs: ["Returns the pooled token's address"], label: 'asset', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0x38d52e0f', }, { - args: [ - { - label: '_shares', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: ['Returns the worth of an amount of pool shares (LP tokens) in underlying principle\n\n'], - label: 'sharesTargetWorth', + args: [], + default: false, + docs: ['Returns the decimals of the pool asset'], + label: 'assetDecimals', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint8'], + type: 0, + }, + selector: '0xc2d41601', + }, + { + args: [], + default: false, + docs: [''], + label: 'totalLiabilities', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], type: 3, }, - selector: '0xcc045745', + selector: '0xf73579a9', + }, + { + args: [], + default: false, + docs: [''], + label: 'reserve', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0xcd3293de', }, { args: [], + default: false, docs: [''], - label: 'accumulatedSlippage', + label: 'reserveWithSlippage', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, - selector: '0xe4182b09', + selector: '0x0b09d91e', }, { args: [], + default: false, docs: [''], label: 'insuranceWithdrawalTimelock', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0x0d3a7fd4', }, { args: [], + default: false, docs: [''], label: 'protocolTreasury', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0x803db96d', }, { args: [], + default: false, docs: [''], label: 'backstop', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0x7dea1817', }, { args: [], + default: false, docs: [''], label: 'router', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0xf887ea40', }, { args: [], + default: false, docs: [''], label: 'slippageCurve', mutates: false, payable: false, returnType: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, selector: '0xebe26b9e', }, - { - args: [ - { - label: '_amount', - type: { - displayName: ['u256'], - type: 3, - }, - }, - ], - docs: ['Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0\n\n'], - label: 'deposit', - mutates: true, - payable: false, - returnType: { - displayName: ['SwapPool', 'deposit', 'return_type'], - type: 9, - }, - selector: '0xb6b55f25', - }, { args: [ { label: '_durationInBlocks', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['Set new insurance withdrawal time lock. Can only be called by the owner\n\n'], + default: false, + docs: ['Set new insurance withdrawal time lock. Can only be called by the owner'], label: 'setInsuranceWithdrawalTimelock', mutates: true, payable: false, @@ -775,13 +825,14 @@ export const swapPoolAbi = { { label: '_maxTokens', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [ - 'Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits.\n\n', + 'Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits.', ], label: 'setPoolCap', mutates: true, @@ -794,56 +845,92 @@ export const swapPoolAbi = { { label: '_lpFeeBps', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, { label: '_backstopFeeBps', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, { label: '_protocolFeeBps', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['Set swap fees (applied when swapping funds out of the pool)\n\n'], + default: false, + docs: ['Set swap fees (applied when swapping funds out of the pool)'], label: 'setSwapFees', mutates: true, payable: false, returnType: null, selector: '0xeb43434e', }, + { + args: [], + default: false, + docs: ['Return the configured swap fees for this pool'], + label: 'swapFees', + mutates: false, + payable: false, + returnType: { + displayName: ['SwapPool', 'swapFees', 'return_type'], + type: 8, + }, + selector: '0xb9ccf21d', + }, + { + args: [ + { + label: '_depositAmount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + ], + default: false, + docs: ['Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0'], + label: 'deposit', + mutates: true, + payable: false, + returnType: { + displayName: ['SwapPool', 'deposit', 'return_type'], + type: 10, + }, + selector: '0xb6b55f25', + }, { args: [ { - label: '_shares', + label: '_sharesToBurn', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, { label: '_minimumAmount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['Withdraws liquidity amount of asset ensuring minimum amount required\n\n'], + default: false, + docs: ['Withdraws liquidity amount of asset ensuring minimum amount required'], label: 'withdraw', mutates: true, payable: false, returnType: { displayName: ['SwapPool', 'withdraw', 'return_type'], - type: 10, + type: 11, }, selector: '0x441a3e70', }, @@ -852,26 +939,27 @@ export const swapPoolAbi = { { label: '_owner', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, { - label: '_shares', + label: '_sharesToBurn', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], + default: false, docs: [ - 'Burns LP tokens of owner, will get compensated using backstop liquidity Can only be invoked by backstop pool, disabled when pool is paused\n\n', + 'Burns LP tokens of owner, will get compensated using backstop liquidity Can only be invoked by backstop pool, disabled when pool is paused', ], label: 'backstopBurn', mutates: true, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0xe45f37bd', @@ -881,25 +969,29 @@ export const swapPoolAbi = { { label: '_amount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, { label: '_recipient', type: { - displayName: ['ink_env', 'types', 'AccountId'], + displayName: ['ink_primitives', 'types', 'AccountId'], type: 2, }, }, ], + default: false, docs: [ - "For backstop pool to withdraw liquidity if swap pool's coverage ratio > 100% Can only be invoked by backstop pool\n\n", + "For backstop pool to withdraw liquidity if swap pool's coverage ratio > 100% Can only be invoked by backstop pool", ], label: 'backstopDrain', mutates: true, payable: false, - returnType: null, + returnType: { + displayName: ['uint256'], + type: 3, + }, selector: '0xc2cb15de', }, { @@ -907,17 +999,18 @@ export const swapPoolAbi = { { label: '_amount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['Get called by Router to deposit an amount of pool asset Can only be called by Router\n\n'], + default: false, + docs: ['Get called by Router to deposit an amount of pool asset Can only be called by Router'], label: 'swapIntoFromRouter', mutates: true, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0x4d8ea83f', @@ -927,24 +1020,68 @@ export const swapPoolAbi = { { label: '_amount', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['get called by Router to withdraw amount of pool asset Can only be called by Router\n\n'], + default: false, + docs: ['Get a quote for the effective amount of tokens for a swap into'], + label: 'quoteSwapInto', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x3c945248', + }, + { + args: [ + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + ], + default: false, + docs: ['get called by Router to withdraw amount of pool asset Can only be called by Router'], label: 'swapOutFromRouter', mutates: true, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, selector: '0x5f79d44f', }, + { + args: [ + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + ], + default: false, + docs: ['Get a quote for the effective amount of tokens, incl. slippage and fees'], + label: 'quoteSwapOut', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x8735c246', + }, { args: [], - docs: ['Pause deposits and swaps\n\n'], + default: false, + docs: ['Pause deposits and swaps'], label: 'pause', mutates: true, payable: false, @@ -953,7 +1090,8 @@ export const swapPoolAbi = { }, { args: [], - docs: ['Resume deposits and swaps\n\n'], + default: false, + docs: ['Resume deposits and swaps'], label: 'unpause', mutates: true, payable: false, @@ -962,87 +1100,73 @@ export const swapPoolAbi = { }, { args: [], - docs: ['returns pool coverage ratio\n\n'], + default: false, + docs: ['returns pool coverage ratio'], label: 'coverage', mutates: false, payable: false, returnType: { displayName: ['SwapPool', 'coverage', 'return_type'], - type: 11, + type: 12, }, selector: '0xee8f6a0e', }, { - args: [ - { - label: '_liquidityProvider', - type: { - displayName: ['ink_env', 'types', 'AccountId'], - type: 2, - }, - }, + args: [], + default: false, + docs: [ + 'Computes the excess liquidity that forms that valuation of the backstop pool is defined as b + C - B - L where - b is reserve - C is the amount of pool tokens in the pool - B is reserveWithSlippage - L is totalLiabilities', ], - docs: ['Return the earliest block no that insurance withdrawals are possible.\n\n'], - label: 'insuranceWithdrawalUnlock', + label: 'getExcessLiquidity', mutates: false, payable: false, returnType: { - displayName: ['u256'], - type: 3, + displayName: ['int256'], + type: 9, }, - selector: '0x5c6f4279', + selector: '0xace0f0d5', }, { args: [ { - label: '_amount', + label: '_liquidityProvider', type: { - displayName: ['u256'], - type: 3, + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, }, ], - docs: ['Get a quote for the effective amount of tokens, incl. slippage and fees\n\n'], - label: 'quoteSwapInto', + default: false, + docs: ['Return the earliest block no that insurance withdrawals are possible.'], + label: 'insuranceWithdrawalUnlock', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, - selector: '0x3c945248', + selector: '0x5c6f4279', }, { args: [ { - label: '_amount', + label: '_sharesToBurn', type: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, }, ], - docs: ['Get a quote for the effective amount of tokens, incl. slippage and fees\n\n'], - label: 'quoteSwapOut', + default: false, + docs: ['Returns the worth of an amount of pool shares (LP tokens) in underlying principle'], + label: 'sharesTargetWorth', mutates: false, payable: false, returnType: { - displayName: ['u256'], + displayName: ['uint256'], type: 3, }, - selector: '0x8735c246', - }, - { - args: [], - docs: ['Return the configured swap fees for this pool\n\n'], - label: 'swapFees', - mutates: false, - payable: false, - returnType: { - displayName: ['SwapPool', 'swapFees', 'return_type'], - type: 12, - }, - selector: '0xb9ccf21d', + selector: '0xcc045745', }, ], }, @@ -1201,13 +1325,13 @@ export const swapPoolAbi = { layout: { leaf: { key: '0x00000009', - ty: 3, + ty: 0, }, }, root_key: '0x00000009', }, }, - name: 'poolCap', + name: 'poolAssetDecimals', }, { layout: { @@ -1221,7 +1345,7 @@ export const swapPoolAbi = { root_key: '0x0000000a', }, }, - name: 'totalLiabilities', + name: 'poolCap', }, { layout: { @@ -1235,7 +1359,7 @@ export const swapPoolAbi = { root_key: '0x0000000b', }, }, - name: 'accumulatedSlippage', + name: 'totalLiabilities', }, { layout: { @@ -1249,6 +1373,34 @@ export const swapPoolAbi = { root_key: '0x0000000c', }, }, + name: 'reserve', + }, + { + layout: { + root: { + layout: { + leaf: { + key: '0x0000000d', + ty: 3, + }, + }, + root_key: '0x0000000d', + }, + }, + name: 'reserveWithSlippage', + }, + { + layout: { + root: { + layout: { + leaf: { + key: '0x0000000e', + ty: 3, + }, + }, + root_key: '0x0000000e', + }, + }, name: 'insuranceWithdrawalTimelock', }, { @@ -1260,7 +1412,7 @@ export const swapPoolAbi = { { layout: { leaf: { - key: '0x0000000d', + key: '0x0000000f', ty: 1, }, }, @@ -1270,7 +1422,7 @@ export const swapPoolAbi = { name: 'AccountId', }, }, - root_key: '0x0000000d', + root_key: '0x0000000f', }, }, name: 'protocolTreasury', @@ -1284,7 +1436,7 @@ export const swapPoolAbi = { { layout: { leaf: { - key: '0x0000000e', + key: '0x00000010', ty: 1, }, }, @@ -1294,7 +1446,7 @@ export const swapPoolAbi = { name: 'AccountId', }, }, - root_key: '0x0000000e', + root_key: '0x00000010', }, }, name: 'backstop', @@ -1308,7 +1460,7 @@ export const swapPoolAbi = { { layout: { leaf: { - key: '0x0000000f', + key: '0x00000011', ty: 1, }, }, @@ -1318,7 +1470,7 @@ export const swapPoolAbi = { name: 'AccountId', }, }, - root_key: '0x0000000f', + root_key: '0x00000011', }, }, name: 'router', @@ -1332,7 +1484,7 @@ export const swapPoolAbi = { { layout: { leaf: { - key: '0x00000010', + key: '0x00000012', ty: 1, }, }, @@ -1342,7 +1494,7 @@ export const swapPoolAbi = { name: 'AccountId', }, }, - root_key: '0x00000010', + root_key: '0x00000012', }, }, name: 'slippageCurve', @@ -1352,11 +1504,11 @@ export const swapPoolAbi = { root: { layout: { leaf: { - key: '0x00000011', + key: '0x00000013', ty: 3, }, }, - root_key: '0x00000011', + root_key: '0x00000013', }, }, name: 'latestDepositAtBlockNo', @@ -1370,7 +1522,7 @@ export const swapPoolAbi = { { layout: { leaf: { - key: '0x00000012', + key: '0x00000014', ty: 6, }, }, @@ -1379,7 +1531,7 @@ export const swapPoolAbi = { { layout: { leaf: { - key: '0x00000012', + key: '0x00000014', ty: 6, }, }, @@ -1388,7 +1540,7 @@ export const swapPoolAbi = { { layout: { leaf: { - key: '0x00000012', + key: '0x00000014', ty: 6, }, }, @@ -1398,7 +1550,7 @@ export const swapPoolAbi = { name: 'SwapFees', }, }, - root_key: '0x00000012', + root_key: '0x00000014', }, }, name: 'swapFeeConfig', @@ -1414,7 +1566,7 @@ export const swapPoolAbi = { def: { primitive: 'u8', }, - path: ['u8'], + path: ['uint8'], }, }, { @@ -1440,7 +1592,7 @@ export const swapPoolAbi = { ], }, }, - path: ['ink_env', 'types', 'AccountId'], + path: ['ink_primitives', 'types', 'AccountId'], }, }, { @@ -1449,7 +1601,7 @@ export const swapPoolAbi = { def: { primitive: 'u256', }, - path: ['u256'], + path: ['uint256'], }, }, { @@ -1476,7 +1628,7 @@ export const swapPoolAbi = { def: { primitive: 'u32', }, - path: ['u32'], + path: ['uint32'], }, }, { @@ -1507,31 +1659,40 @@ export const swapPoolAbi = { id: 8, type: { def: { - primitive: 'i256', + tuple: [3, 3, 3], }, - path: ['i256'], + path: ['SwapPool', 'swapFees', 'return_type'], }, }, { id: 9, type: { def: { - tuple: [3, 8], + primitive: 'i256', }, - path: ['SwapPool', 'deposit', 'return_type'], + path: ['int256'], }, }, { id: 10, type: { def: { - tuple: [3, 8], + tuple: [3, 9], }, - path: ['SwapPool', 'withdraw', 'return_type'], + path: ['SwapPool', 'deposit', 'return_type'], }, }, { id: 11, + type: { + def: { + tuple: [3, 9], + }, + path: ['SwapPool', 'withdraw', 'return_type'], + }, + }, + { + id: 12, type: { def: { tuple: [3, 3], @@ -1540,12 +1701,96 @@ export const swapPoolAbi = { }, }, { - id: 12, + id: 13, type: { def: { - tuple: [3, 3, 3], + primitive: 'u128', }, - path: ['SwapPool', 'swapFees', 'return_type'], + path: ['uint128'], + }, + }, + { + id: 14, + type: { + def: { + primitive: 'u64', + }, + path: ['uint64'], + }, + }, + { + id: 15, + type: { + def: { + composite: { + fields: [ + { + type: 1, + }, + ], + }, + }, + path: ['ink_primitives', 'types', 'Hash'], + }, + }, + { + id: 16, + type: { + def: { + composite: { + fields: [ + { + type: 5, + }, + ], + }, + }, + path: ['0x08c379a0'], + }, + }, + { + id: 17, + type: { + def: { + composite: { + fields: [ + { + type: 3, + }, + ], + }, + }, + path: ['0x4e487b71'], + }, + }, + { + id: 18, + type: { + def: { + variant: { + variants: [ + { + fields: [ + { + type: 16, + }, + ], + index: 0, + name: 'Error', + }, + { + fields: [ + { + type: 17, + }, + ], + index: 1, + name: 'Panic', + }, + ], + }, + }, + path: ['SolidityError'], }, }, ], diff --git a/src/pages/nabla/dev/index.tsx b/src/pages/nabla/dev/index.tsx index 2e19fa47..870d052e 100644 --- a/src/pages/nabla/dev/index.tsx +++ b/src/pages/nabla/dev/index.tsx @@ -3,7 +3,7 @@ import { Button, Dropdown } from 'react-daisyui'; import { useNavigate } from 'react-router-dom'; import { Token } from '../../../../gql/graphql'; import { config } from '../../../config'; -import { mockERC20 } from '../../../contracts/nabla/MockERC20'; +import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; import { useGlobalState } from '../../../GlobalStateProvider'; import { useTokens } from '../../../hooks/nabla/useTokens'; import { decimalToNative, FixedU128Decimals } from '../../../shared/parseNumbers'; @@ -12,7 +12,7 @@ import { useContractWrite } from '../../../shared/useContractWrite'; const TokenItem = ({ token }: { token: Token }) => { const { address } = useGlobalState().walletAccount || {}; const { mutate, isLoading } = useContractWrite({ - abi: mockERC20, + abi: erc20WrapperAbi, address: token.id, method: 'mint', onError: console.error, diff --git a/src/shared/useContractBalance.ts b/src/shared/useContractBalance.ts index 5140c2c4..7a95906f 100644 --- a/src/shared/useContractBalance.ts +++ b/src/shared/useContractBalance.ts @@ -2,7 +2,7 @@ import { Abi } from '@polkadot/api-contract'; import { FrameSystemAccountInfo } from '@polkadot/types/lookup'; import { UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; -import { mockERC20 } from '../contracts/nabla/MockERC20'; +import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; import { cacheKeys } from './constants'; import { QueryOptions } from './helpers'; import { nativeToDecimal, prettyNumbers } from './parseNumbers'; @@ -41,7 +41,7 @@ export const useContractBalance = >( refetchOnWindowFocus: false, onError: console.error, ...options, - abi: abi || mockERC20, + abi: abi || erc20WrapperAbi, address: contractAddress, owner: address, method: 'balanceOf', diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index 395d833c..a7c23250 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -5,7 +5,7 @@ import { ApiPromise } from '@polkadot/api'; import { Abi } from '@polkadot/api-contract'; import { DispatchError, ExtrinsicStatus } from '@polkadot/types/interfaces'; import { MutationOptions, useMutation } from '@tanstack/react-query'; -import { useState } from 'preact/compat'; +import { useMemo, useState } from 'preact/compat'; import { createWriteOptions } from '../services/api/helpers'; import { useSharedState } from './Provider'; @@ -16,7 +16,7 @@ export type TransactionsStatus = { status?: ExtrinsicStatus['type'] | 'Pending'; }; -export type UseContractWriteProps = Record> = Partial< +export type UseContractWriteProps> = Partial< MutationOptions > & { abi: TAbi; @@ -34,7 +34,7 @@ const defaultLimits: Limits = { storageDeposit: undefined, }; -export const useContractWrite = >({ +export const useContractWrite = >({ abi, address, method, @@ -44,43 +44,21 @@ export const useContractWrite = >({ }: UseContractWriteProps) => { const { api, signer, address: walletAddress } = useSharedState(); const [transaction, setTransaction] = useState(); + const contractAbi = useMemo( + () => (abi && api?.registry ? new Abi(abi, api.registry.getChainProperties()) : undefined), + [abi, api?.registry], + ); - const isReady = !!abi && !!address && !!api && !!walletAddress && !!signer; + console.log(contractAbi, { address, method, args }); + + const isReady = !!contractAbi && !!address && !!api && !!walletAddress && !!signer; const submit = async (submitArgs?: any[] | void): Promise => { if (!isReady) throw 'Missing data'; setTransaction({ status: 'Pending' }); const fnArgs = submitArgs || args || []; const contractOptions = (typeof options === 'function' ? options(api) : options) || createWriteOptions(api); - - /** - * return new Promise((resolve, reject) => { - const unsubPromise = contract.tx[method](contractOptions || {}, ...fnArgs) - .signAndSend(walletAddress, { signer }, (result: SubmittableResultValue) => { - const tx = { - hex: result.txHash.toHex(), - status: result.status.type, - }; - setTransaction(tx); - if (result.dispatchError) { - parseTransactionError(result, api); - reject(result); - } - if (result.status.isFinalized) { - if (unsubPromise) { - unsubPromise.then((unsub) => (typeof unsub === 'function' ? unsub() : undefined)); - } - resolve(tx); - } - }) - .catch((err: Error) => { - console.error(err); - setTransaction(undefined); - reject(err); - }); - }); - */ return messageCall({ - abi: abi as Abi, + abi: contractAbi, api, callerAddress: walletAddress, contractDeploymentAddress: address, diff --git a/src/shared/useTokenAllowance.ts b/src/shared/useTokenAllowance.ts index 52b33cf0..3c871f6d 100644 --- a/src/shared/useTokenAllowance.ts +++ b/src/shared/useTokenAllowance.ts @@ -1,5 +1,5 @@ import { Abi } from '@polkadot/api-contract'; -import { mockERC20 } from '../contracts/nabla/MockERC20'; +import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; import { cacheKeys } from './constants'; import { QueryOptions } from './helpers'; import { useContract } from './useContract'; @@ -27,7 +27,7 @@ export const useTokenAllowance = ( refetchOnReconnect: false, refetchOnWindowFocus: false, ...options, - abi: abi || mockERC20, + abi: abi || erc20WrapperAbi, address: token, owner, method: 'allowance', diff --git a/src/shared/useTokenApproval.ts b/src/shared/useTokenApproval.ts index 79db9649..12d06fee 100644 --- a/src/shared/useTokenApproval.ts +++ b/src/shared/useTokenApproval.ts @@ -1,6 +1,6 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ import { useMemo, useState } from 'preact/compat'; -import { mockERC20 } from '../contracts/nabla/MockERC20'; +import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; import { gasDefaults } from './helpers'; import { decimalToNative, nativeToDecimal } from './parseNumbers'; import { useSharedState } from './Provider'; @@ -55,7 +55,7 @@ export const useTokenApproval = ({ ); const mutation = useContractWrite({ - abi: mockERC20, + abi: erc20WrapperAbi, address: token, method: 'approve', args: [spender, approveMax ? maxInt : amountBI.toString()], diff --git a/tailwind.config.cjs b/tailwind.config.cjs index a0b81b02..0f346e3a 100644 --- a/tailwind.config.cjs +++ b/tailwind.config.cjs @@ -61,7 +61,7 @@ module.exports = { 'base-400': '#E7E7E7', 'base-content': '#fff', '--text': '#fff', - '--bg-modal': '#191D24', + '--bg-modal': '#292a2b', '--rounded-btn': '9px', '--btn-text-case': 'none', }, From b604222b1589fe3baf1c302d7a27c26d18ec931a Mon Sep 17 00:00:00 2001 From: Nejc Date: Tue, 2 Jan 2024 12:35:06 +0100 Subject: [PATCH 06/58] fix: contract execution --- .prettierignore | 2 + package.json | 71 +- src/components/Transaction/Progress/index.tsx | 40 +- src/components/nabla/Pools/Swap/columns.tsx | 2 +- src/components/nabla/Pools/index.tsx | 6 +- src/pages/collators/CollatorsTable.tsx | 12 +- src/shared/useContractWrite.ts | 22 +- src/shared/useTokenApproval.ts | 2 +- yarn.lock | 3787 +++++++---------- 9 files changed, 1578 insertions(+), 2366 deletions(-) diff --git a/.prettierignore b/.prettierignore index 58a4c385..ee6d21ae 100644 --- a/.prettierignore +++ b/.prettierignore @@ -5,6 +5,7 @@ build/ preact/ internals/ docs/ +gql/ .lighthouseci/ *.yml @@ -13,4 +14,5 @@ package-lock.json package.json yarn.lock + CHANGELOG.md diff --git a/package.json b/package.json index 0ee7071e..3bc0a712 100644 --- a/package.json +++ b/package.json @@ -19,10 +19,10 @@ "verify": "yarn lint && yarn lint:ts && yarn test" }, "dependencies": { - "@heroicons/react": "^2.0.18", + "@heroicons/react": "^2.1.1", "@hookform/resolvers": "^2.9.11", "@pendulum-chain/api": "^0.3.1", - "@pendulum-chain/api-solang": "^0.0.6", + "@pendulum-chain/api-solang": "~0.1.1", "@polkadot/api": "^9.9.1", "@polkadot/api-base": "^9.9.1", "@polkadot/api-contract": "^9.9.1", @@ -40,18 +40,18 @@ "@tanstack/query-sync-storage-persister": "~4.32.6", "@tanstack/react-query": "~4.32.6", "@tanstack/react-query-persist-client": "~4.32.6", - "@tanstack/react-table": "^8.10.7", - "@walletconnect/modal": "^2.4.7", - "@walletconnect/universal-provider": "^2.8.1", + "@tanstack/react-table": "^8.11.2", + "@walletconnect/modal": "^2.6.2", + "@walletconnect/universal-provider": "^2.11.0", "big.js": "^6.2.1", "bn.js": "^5.2.1", "bs58": "^5.0.0", "graphql": "~16.6.0", "graphql-request": "~6.1.0", "lodash": "^4.17.21", - "luxon": "^3.2.1", + "luxon": "^3.4.4", "match-sorter": "^6.3.1", - "preact": "^10.12.1", + "preact": "^10.19.3", "react-daisyui": "^3.1.2", "react-device-detect": "^2.2.3", "react-hook-form": "^7.43.2", @@ -59,19 +59,19 @@ "react-table": "^7.8.0", "react-toastify": "^9.1.3", "stellar-sdk": "^10.4.1", - "ts-node": "^10.9.1", - "yup": "^1.3.2" + "ts-node": "^10.9.2", + "yup": "^1.3.3" }, "devDependencies": { - "@babel/core": "^7.20.12", + "@babel/core": "^7.23.7", "@babel/plugin-proposal-class-properties": "^7.18.6", - "@babel/preset-env": "^7.20.2", - "@babel/preset-typescript": "^7.18.6", + "@babel/preset-env": "^7.23.7", + "@babel/preset-typescript": "^7.23.3", "@esbuild-plugins/node-globals-polyfill": "^0.1.1", "@esbuild-plugins/node-modules-polyfill": "^0.1.4", "@graphql-codegen/cli": "~5.0.0", "@graphql-codegen/client-preset": "~4.1.0", - "@pendulum-chain/types": "^0.2.3", + "@pendulum-chain/types": "^0.2.4", "@polkadot/types-augment": "^9.9.1", "@polkadot/types-codec": "^9.9.1", "@polkadot/types-create": "^9.9.1", @@ -80,38 +80,39 @@ "@semantic-release/changelog": "^6.0.3", "@semantic-release/commit-analyzer": "^11.1.0", "@semantic-release/git": "^10.0.1", - "@semantic-release/github": "^9.2.4", + "@semantic-release/github": "^9.2.6", "@semantic-release/npm": "^11.0.1", "@semantic-release/release-notes-generator": "^12.1.0", - "@testing-library/jest-dom": "^5.16.5", + "@testing-library/jest-dom": "^6.1.6", "@testing-library/preact": "^3.2.3", "@testing-library/preact-hooks": "^1.1.0", - "@types/big.js": "^6.1.6", - "@types/jest": "^29.4.0", - "@types/lodash": "^4", - "@types/luxon": "^3.2.0", - "@types/node": "^18.14.1", - "@types/react": "^18.0.28", - "@types/react-table": "^7.7.12", - "@types/testing-library__jest-dom": "^5.14.5", - "@typescript-eslint/eslint-plugin": "^5.53.0", - "@typescript-eslint/parser": "^5.53.0", - "autoprefixer": "^10.4.13", + "@types/big.js": "^6.2.2", + "@types/jest": "^29.5.11", + "@types/lodash": "^4.14.202", + "@types/luxon": "^3.3.7", + "@types/node": "^18.19.4", + "@types/react": "^18.2.46", + "@types/react-table": "^7.7.18", + "@types/testing-library__jest-dom": "^6.0.0", + "@typescript-eslint/eslint-plugin": "^6.17.0", + "@typescript-eslint/parser": "^6.17.0", + "autoprefixer": "^10.4.16", "daisyui": "^2.52.0", - "eslint": "^8.34.0", - "eslint-plugin-jest": "^27.2.1", - "eslint-plugin-react": "^7.32.2", + "eslint": "^8.56.0", + "eslint-plugin-jest": "^27.6.1", + "eslint-plugin-react": "^7.33.2", "eslint-plugin-react-hooks": "^4.6.0", - "jest": "^29.4.3", - "jest-environment-jsdom": "^29.4.3", + "jest": "^29.7.0", + "jest-environment-jsdom": "^29.7.0", "postcss": "^8.4.21", - "prettier": "^2.8.4", + "postcss-import": "^15.1.0", + "prettier": "^3.1.1", "react-table": "^7.8.0", "sass": "^1.58.3", - "semantic-release": "^20.1.3", - "tailwindcss": "^3.2.7", + "semantic-release": "^22.0.12", + "tailwindcss": "^3.4.0", "typescript": "^4.9.5", - "vite": "^3.2.5" + "vite": "^3.2.7" }, "engines": { "npm": "please-use-yarn", diff --git a/src/components/Transaction/Progress/index.tsx b/src/components/Transaction/Progress/index.tsx index e5e58d6e..1793715f 100644 --- a/src/components/Transaction/Progress/index.tsx +++ b/src/components/Transaction/Progress/index.tsx @@ -1,27 +1,42 @@ import { CheckCircleIcon, ExclamationCircleIcon } from '@heroicons/react/24/outline'; -import { UseMutationResult } from '@tanstack/react-query'; +import { MessageCallResult } from '@pendulum-chain/api-solang'; import { ComponentChildren } from 'preact'; import { Button } from 'react-daisyui'; import Spinner from '../../../assets/spinner'; import { useGetTenantConfig } from '../../../hooks/useGetTenantConfig'; -import { TransactionsStatus } from '../../../shared/useContractWrite'; +import { UseContractWriteResponse } from '../../../shared/useContractWrite'; export interface TransactionProgressProps { mutation: Pick< - // eslint-disable-next-line @typescript-eslint/no-explicit-any - UseMutationResult, - 'isIdle' | 'isLoading' | 'isSuccess' | 'isError' | 'data' + UseContractWriteResponse, + 'isIdle' | 'isLoading' | 'isSuccess' | 'isError' | 'data' | 'status' | 'transaction' >; children?: ComponentChildren; onClose: () => void; } +const getErrorMsg = (data?: MessageCallResult['result']) => { + if (!data) return undefined; + switch (data.type) { + case 'error': + return data.error; + case 'panic': + return data.explanation; + case 'reverted': + return data.description; + default: + return undefined; + } +}; + const TransactionProgress = ({ mutation, children, onClose }: TransactionProgressProps): JSX.Element | null => { const { explorer } = useGetTenantConfig(); if (mutation.isIdle) return null; + const status = mutation.data?.result?.type; + const isSuccess = status === 'success'; + const errorMsg = getErrorMsg(mutation.data?.result); if (mutation.isLoading) { - const status = mutation.data?.status; - const isPending = !status || status === 'Pending'; + const isPending = false; // TODO: currently there is not status for this (waiting confirmation in wallet) return ( <>
@@ -40,26 +55,25 @@ const TransactionProgress = ({ mutation, children, onClose }: TransactionProgres return ( <>
- {mutation.isSuccess ? ( + {isSuccess ? ( ) : ( )}
-

- {mutation.isSuccess ? 'Transaction successful' : 'Transaction failed'} -

+

{isSuccess ? 'Transaction successful' : 'Transaction failed'}

+ {!isSuccess && !!errorMsg &&

{errorMsg}

} {!!onClose && ( )} - {!!mutation.data?.hex && ( + {!!mutation.transaction?.hex && ( = { accessorKey: 'apr', accessorFn: (_row) => 0, cell: (props): JSX.Element | null => ( - + {props.renderValue()}% ), diff --git a/src/components/nabla/Pools/index.tsx b/src/components/nabla/Pools/index.tsx index d1f81f35..eada14ba 100644 --- a/src/components/nabla/Pools/index.tsx +++ b/src/components/nabla/Pools/index.tsx @@ -7,12 +7,14 @@ export type PoolProgressProps = { export const PoolProgress = ({ symbol, amount, className = '' }: PoolProgressProps) => { return (
{symbol}
-
{amount}
+
+ {amount} +
); }; diff --git a/src/pages/collators/CollatorsTable.tsx b/src/pages/collators/CollatorsTable.tsx index 0b32b8d9..bc17f5cb 100644 --- a/src/pages/collators/CollatorsTable.tsx +++ b/src/pages/collators/CollatorsTable.tsx @@ -1,21 +1,21 @@ import { ColumnDef } from '@tanstack/react-table'; import { useEffect, useMemo, useState } from 'preact/hooks'; -import { useGlobalState } from '../../GlobalStateProvider'; -import { useNodeInfoState } from '../../NodeInfoProvider'; import Table, { SortingOrder } from '../../components/Table'; +import { useGlobalState } from '../../GlobalStateProvider'; import { getAddressForFormat } from '../../helpers/addressFormatter'; import { ParachainStakingCandidate, useStakingPallet } from '../../hooks/staking/staking'; import { PalletIdentityInfo, useIdentityPallet } from '../../hooks/useIdentityPallet'; +import { useNodeInfoState } from '../../NodeInfoProvider'; import { nativeToFormat } from '../../shared/parseNumbers'; import { - TCollator, - UserStaking, actionsColumn, - apyColumn, + aprColumn, delegatorsColumn, myStakedColumn, nameColumn, stakedColumn, + TCollator, + UserStaking, } from './columns'; import ExecuteDelegationDialogs from './dialogs/ExecuteDelegationDialogs'; @@ -103,7 +103,7 @@ function CollatorsTable() { nameColumn, stakedColumn, delegatorsColumn, - apyColumn, + aprColumn, stakedCol, actionsColumn({ userAccountAddress, diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index a7c23250..396f16a0 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -1,6 +1,6 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ /* eslint-disable @typescript-eslint/ban-types */ -import { Limits, messageCall } from '@pendulum-chain/api-solang'; +import { Limits, messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; import { ApiPromise } from '@polkadot/api'; import { Abi } from '@polkadot/api-contract'; import { DispatchError, ExtrinsicStatus } from '@polkadot/types/interfaces'; @@ -9,15 +9,14 @@ import { useMemo, useState } from 'preact/compat'; import { createWriteOptions } from '../services/api/helpers'; import { useSharedState } from './Provider'; -// TODO: fix/improve types -// - parse abi file +// TODO: fix/improve types - parse abi file export type TransactionsStatus = { hex?: string; status?: ExtrinsicStatus['type'] | 'Pending'; }; export type UseContractWriteProps> = Partial< - MutationOptions + MutationOptions > & { abi: TAbi; address?: string; @@ -28,8 +27,8 @@ export type UseContractWriteProps> = Partia const defaultLimits: Limits = { gas: { - refTime: '18000000000', - proofSize: '1750000', + refTime: '30000000000', + proofSize: '2400000', }, storageDeposit: undefined, }; @@ -43,18 +42,16 @@ export const useContractWrite = >({ ...rest }: UseContractWriteProps) => { const { api, signer, address: walletAddress } = useSharedState(); - const [transaction, setTransaction] = useState(); + const [transaction /* setTransaction */] = useState(); const contractAbi = useMemo( () => (abi && api?.registry ? new Abi(abi, api.registry.getChainProperties()) : undefined), [abi, api?.registry], ); - console.log(contractAbi, { address, method, args }); - const isReady = !!contractAbi && !!address && !!api && !!walletAddress && !!signer; const submit = async (submitArgs?: any[] | void): Promise => { if (!isReady) throw 'Missing data'; - setTransaction({ status: 'Pending' }); + //setTransaction({ status: 'Pending' }); const fnArgs = submitArgs || args || []; const contractOptions = (typeof options === 'function' ? options(api) : options) || createWriteOptions(api); return messageCall({ @@ -74,6 +71,7 @@ export const useContractWrite = >({ }); }; const mutation = useMutation(submit, rest); - console.log('test', mutation.data); - return { ...mutation, data: transaction, isReady }; + return { ...mutation, transaction, isReady }; }; + +export type UseContractWriteResponse = ReturnType; diff --git a/src/shared/useTokenApproval.ts b/src/shared/useTokenApproval.ts index 12d06fee..16f09079 100644 --- a/src/shared/useTokenApproval.ts +++ b/src/shared/useTokenApproval.ts @@ -23,7 +23,7 @@ interface UseTokenApprovalParams { enabled?: boolean; decimals?: number; onError?: (err: any) => void; - onSuccess?: UseContractWriteProps['onSuccess']; + onSuccess?: UseContractWriteProps['onSuccess']; } export const useTokenApproval = ({ diff --git a/yarn.lock b/yarn.lock index 72942b49..3392b302 100644 --- a/yarn.lock +++ b/yarn.lock @@ -12,10 +12,10 @@ __metadata: languageName: node linkType: hard -"@adobe/css-tools@npm:^4.0.1": - version: 4.3.1 - resolution: "@adobe/css-tools@npm:4.3.1" - checksum: 05672719b544cc0c21ae3ed0eb6349bf458e9d09457578eeeb07cf0f696469ac6417e9c9be1b129e5d6a18098a061c1db55b2275591760ef30a79822436fcbfa +"@adobe/css-tools@npm:^4.3.2": + version: 4.3.2 + resolution: "@adobe/css-tools@npm:4.3.2" + checksum: 296a03dd29f227c60500d2da8c7f64991fecf1d8b456ce2b4adb8cec7363d9c08b5b03f1463673fc8cbfe54b538745588e7a13c736d2dd14a80c01a20f127f39 languageName: node linkType: hard @@ -84,6 +84,16 @@ __metadata: languageName: node linkType: hard +"@babel/code-frame@npm:^7.23.5": + version: 7.23.5 + resolution: "@babel/code-frame@npm:7.23.5" + dependencies: + "@babel/highlight": "npm:^7.23.4" + chalk: "npm:^2.4.2" + checksum: a10e843595ddd9f97faa99917414813c06214f4d9205294013e20c70fbdf4f943760da37dec1d998bf3e6fc20fa2918a47c0e987a7e458663feb7698063ad7c6 + languageName: node + linkType: hard + "@babel/compat-data@npm:^7.20.5, @babel/compat-data@npm:^7.22.6, @babel/compat-data@npm:^7.22.9, @babel/compat-data@npm:^7.23.3": version: 7.23.3 resolution: "@babel/compat-data@npm:7.23.3" @@ -91,7 +101,14 @@ __metadata: languageName: node linkType: hard -"@babel/core@npm:^7.11.6, @babel/core@npm:^7.12.3, @babel/core@npm:^7.14.0, @babel/core@npm:^7.20.12, @babel/core@npm:^7.22.1, @babel/core@npm:^7.22.9": +"@babel/compat-data@npm:^7.23.5": + version: 7.23.5 + resolution: "@babel/compat-data@npm:7.23.5" + checksum: 081278ed46131a890ad566a59c61600a5f9557bd8ee5e535890c8548192532ea92590742fd74bd9db83d74c669ef8a04a7e1c85cdea27f960233e3b83c3a957c + languageName: node + linkType: hard + +"@babel/core@npm:^7.11.6, @babel/core@npm:^7.12.3, @babel/core@npm:^7.14.0, @babel/core@npm:^7.22.1, @babel/core@npm:^7.22.9": version: 7.23.3 resolution: "@babel/core@npm:7.23.3" dependencies: @@ -114,6 +131,29 @@ __metadata: languageName: node linkType: hard +"@babel/core@npm:^7.23.7": + version: 7.23.7 + resolution: "@babel/core@npm:7.23.7" + dependencies: + "@ampproject/remapping": "npm:^2.2.0" + "@babel/code-frame": "npm:^7.23.5" + "@babel/generator": "npm:^7.23.6" + "@babel/helper-compilation-targets": "npm:^7.23.6" + "@babel/helper-module-transforms": "npm:^7.23.3" + "@babel/helpers": "npm:^7.23.7" + "@babel/parser": "npm:^7.23.6" + "@babel/template": "npm:^7.22.15" + "@babel/traverse": "npm:^7.23.7" + "@babel/types": "npm:^7.23.6" + convert-source-map: "npm:^2.0.0" + debug: "npm:^4.1.0" + gensync: "npm:^1.0.0-beta.2" + json5: "npm:^2.2.3" + semver: "npm:^6.3.1" + checksum: 38c9934973d384ed83369712978453eac91dc3f22167404dbdb272b64f602e74728a6f37012c53ee57e521b8ae2da60097f050497d9b6a212d28b59cdfb2cd1d + languageName: node + linkType: hard + "@babel/generator@npm:^7.14.0, @babel/generator@npm:^7.18.13, @babel/generator@npm:^7.23.3, @babel/generator@npm:^7.7.2": version: 7.23.3 resolution: "@babel/generator@npm:7.23.3" @@ -126,6 +166,18 @@ __metadata: languageName: node linkType: hard +"@babel/generator@npm:^7.23.6": + version: 7.23.6 + resolution: "@babel/generator@npm:7.23.6" + dependencies: + "@babel/types": "npm:^7.23.6" + "@jridgewell/gen-mapping": "npm:^0.3.2" + "@jridgewell/trace-mapping": "npm:^0.3.17" + jsesc: "npm:^2.5.1" + checksum: 53540e905cd10db05d9aee0a5304e36927f455ce66f95d1253bb8a179f286b88fa7062ea0db354c566fe27f8bb96567566084ffd259f8feaae1de5eccc8afbda + languageName: node + linkType: hard + "@babel/helper-annotate-as-pure@npm:^7.22.5": version: 7.22.5 resolution: "@babel/helper-annotate-as-pure@npm:7.22.5" @@ -157,6 +209,19 @@ __metadata: languageName: node linkType: hard +"@babel/helper-compilation-targets@npm:^7.23.6": + version: 7.23.6 + resolution: "@babel/helper-compilation-targets@npm:7.23.6" + dependencies: + "@babel/compat-data": "npm:^7.23.5" + "@babel/helper-validator-option": "npm:^7.23.5" + browserslist: "npm:^4.22.2" + lru-cache: "npm:^5.1.1" + semver: "npm:^6.3.1" + checksum: ba38506d11185f48b79abf439462ece271d3eead1673dd8814519c8c903c708523428806f05f2ec5efd0c56e4e278698fac967e5a4b5ee842c32415da54bc6fa + languageName: node + linkType: hard + "@babel/helper-create-class-features-plugin@npm:^7.18.6, @babel/helper-create-class-features-plugin@npm:^7.22.15": version: 7.22.15 resolution: "@babel/helper-create-class-features-plugin@npm:7.22.15" @@ -189,9 +254,9 @@ __metadata: languageName: node linkType: hard -"@babel/helper-define-polyfill-provider@npm:^0.4.3": - version: 0.4.3 - resolution: "@babel/helper-define-polyfill-provider@npm:0.4.3" +"@babel/helper-define-polyfill-provider@npm:^0.4.4": + version: 0.4.4 + resolution: "@babel/helper-define-polyfill-provider@npm:0.4.4" dependencies: "@babel/helper-compilation-targets": "npm:^7.22.6" "@babel/helper-plugin-utils": "npm:^7.22.5" @@ -200,7 +265,7 @@ __metadata: resolve: "npm:^1.14.2" peerDependencies: "@babel/core": ^7.4.0 || ^8.0.0-0 <8.0.0 - checksum: 0007035157e0d32ee9cb4ca319b89d6f3705523383efe52a59eb3d4dfa2ed08c5147e49c10a6e6d69c15221d89c76c8e5875475d6710fb44a5c37b8e69388e40 + checksum: 60126f5f719b9e2114df62e3bf3ac0797b71d8dc733db60192eb169b004fde72ee309fa5848c5fdfe98b8e8863c46f55e16da5aa8a4e420b4d2670cd0c5dd708 languageName: node linkType: hard @@ -339,6 +404,13 @@ __metadata: languageName: node linkType: hard +"@babel/helper-string-parser@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/helper-string-parser@npm:7.23.4" + checksum: f348d5637ad70b6b54b026d6544bd9040f78d24e7ec245a0fc42293968181f6ae9879c22d89744730d246ce8ec53588f716f102addd4df8bbc79b73ea10004ac + languageName: node + linkType: hard + "@babel/helper-validator-identifier@npm:^7.22.20": version: 7.22.20 resolution: "@babel/helper-validator-identifier@npm:7.22.20" @@ -353,6 +425,13 @@ __metadata: languageName: node linkType: hard +"@babel/helper-validator-option@npm:^7.23.5": + version: 7.23.5 + resolution: "@babel/helper-validator-option@npm:7.23.5" + checksum: af45d5c0defb292ba6fd38979e8f13d7da63f9623d8ab9ededc394f67eb45857d2601278d151ae9affb6e03d5d608485806cd45af08b4468a0515cf506510e94 + languageName: node + linkType: hard + "@babel/helper-wrap-function@npm:^7.22.20": version: 7.22.20 resolution: "@babel/helper-wrap-function@npm:7.22.20" @@ -375,6 +454,17 @@ __metadata: languageName: node linkType: hard +"@babel/helpers@npm:^7.23.7": + version: 7.23.7 + resolution: "@babel/helpers@npm:7.23.7" + dependencies: + "@babel/template": "npm:^7.22.15" + "@babel/traverse": "npm:^7.23.7" + "@babel/types": "npm:^7.23.6" + checksum: f74a61ad28a1bc1fdd9133ad571c07787b66d6db017c707b87c203b0cd06879cea8b33e9c6a8585765a4949efa5df3cc9e19b710fe867f11be38ee29fd4a0488 + languageName: node + linkType: hard + "@babel/highlight@npm:^7.22.13": version: 7.22.20 resolution: "@babel/highlight@npm:7.22.20" @@ -386,6 +476,17 @@ __metadata: languageName: node linkType: hard +"@babel/highlight@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/highlight@npm:7.23.4" + dependencies: + "@babel/helper-validator-identifier": "npm:^7.22.20" + chalk: "npm:^2.4.2" + js-tokens: "npm:^4.0.0" + checksum: fbff9fcb2f5539289c3c097d130e852afd10d89a3a08ac0b5ebebbc055cc84a4bcc3dcfed463d488cde12dd0902ef1858279e31d7349b2e8cee43913744bda33 + languageName: node + linkType: hard + "@babel/parser@npm:^7.1.0, @babel/parser@npm:^7.14.0, @babel/parser@npm:^7.14.7, @babel/parser@npm:^7.16.8, @babel/parser@npm:^7.20.7, @babel/parser@npm:^7.22.15, @babel/parser@npm:^7.23.3": version: 7.23.3 resolution: "@babel/parser@npm:7.23.3" @@ -395,6 +496,15 @@ __metadata: languageName: node linkType: hard +"@babel/parser@npm:^7.23.6": + version: 7.23.6 + resolution: "@babel/parser@npm:7.23.6" + bin: + parser: ./bin/babel-parser.js + checksum: 6f76cd5ccae1fa9bcab3525b0865c6222e9c1d22f87abc69f28c5c7b2c8816a13361f5bd06bddbd5faf903f7320a8feba02545c981468acec45d12a03db7755e + languageName: node + linkType: hard + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@npm:^7.23.3": version: 7.23.3 resolution: "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@npm:7.23.3" @@ -419,15 +529,15 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@npm:7.23.3" +"@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@npm:^7.23.7": + version: 7.23.7 + resolution: "@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@npm:7.23.7" dependencies: "@babel/helper-environment-visitor": "npm:^7.22.20" "@babel/helper-plugin-utils": "npm:^7.22.5" peerDependencies: "@babel/core": ^7.0.0 - checksum: 0f43b74741d50e637ba4dcef2786621126fe4da6ccf4ee2e94423ee23f6a04ecd91d458e59764c43e4968be139e5197ee43be8a2fea2c09f0b202a3391e548cc + checksum: 355746e21ad7f43e4f4daef54cfe2ef461ecd19446b2afedd53c39df1bf9aa2eeeeaabee2279b1321de89a97c9360e4f76e9ba950fee50ff1676c25f6929d625 languageName: node linkType: hard @@ -721,9 +831,9 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-async-generator-functions@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-async-generator-functions@npm:7.23.3" +"@babel/plugin-transform-async-generator-functions@npm:^7.23.7": + version: 7.23.7 + resolution: "@babel/plugin-transform-async-generator-functions@npm:7.23.7" dependencies: "@babel/helper-environment-visitor": "npm:^7.22.20" "@babel/helper-plugin-utils": "npm:^7.22.5" @@ -731,7 +841,7 @@ __metadata: "@babel/plugin-syntax-async-generators": "npm:^7.8.4" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: e846f282658e097fce4fccf3ee29289bf05f0654846a5994727a36f0cdc2e47abdffd4be4fa65787e94aa975824fae894c90afbfdc8caacd46c12c7f43e99d7f + checksum: 63d314edc9fbeaf2700745ca0e19bf9840e87f2d7d1f6c5638e06d2aec3e7418d0d7493ed09087e2fe369cc15e9d96c113fb2cd367cb5e3ff922e3712c27b7d4 languageName: node linkType: hard @@ -759,7 +869,7 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-block-scoping@npm:^7.0.0, @babel/plugin-transform-block-scoping@npm:^7.23.3": +"@babel/plugin-transform-block-scoping@npm:^7.0.0": version: 7.23.3 resolution: "@babel/plugin-transform-block-scoping@npm:7.23.3" dependencies: @@ -770,6 +880,17 @@ __metadata: languageName: node linkType: hard +"@babel/plugin-transform-block-scoping@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-block-scoping@npm:7.23.4" + dependencies: + "@babel/helper-plugin-utils": "npm:^7.22.5" + peerDependencies: + "@babel/core": ^7.0.0-0 + checksum: 83006804dddf980ab1bcd6d67bc381e24b58c776507c34f990468f820d0da71dba3697355ca4856532fa2eeb2a1e3e73c780f03760b5507a511cbedb0308e276 + languageName: node + linkType: hard + "@babel/plugin-transform-class-properties@npm:^7.23.3": version: 7.23.3 resolution: "@babel/plugin-transform-class-properties@npm:7.23.3" @@ -782,20 +903,20 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-class-static-block@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-class-static-block@npm:7.23.3" +"@babel/plugin-transform-class-static-block@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-class-static-block@npm:7.23.4" dependencies: "@babel/helper-create-class-features-plugin": "npm:^7.22.15" "@babel/helper-plugin-utils": "npm:^7.22.5" "@babel/plugin-syntax-class-static-block": "npm:^7.14.5" peerDependencies: "@babel/core": ^7.12.0 - checksum: 89cdb66d7bc834cd51659eb7286a6bee23add0bc114943d68c4b6c0c834178cf0d55183df0cf508fec9c55ed4155641360e6f55a91c16fe826ccaf1adf381922 + checksum: fdca96640ef29d8641a7f8de106f65f18871b38cc01c0f7b696d2b49c76b77816b30a812c08e759d06dd10b4d9b3af6b5e4ac22a2017a88c4077972224b77ab0 languageName: node linkType: hard -"@babel/plugin-transform-classes@npm:^7.0.0, @babel/plugin-transform-classes@npm:^7.23.3": +"@babel/plugin-transform-classes@npm:^7.0.0": version: 7.23.3 resolution: "@babel/plugin-transform-classes@npm:7.23.3" dependencies: @@ -814,6 +935,25 @@ __metadata: languageName: node linkType: hard +"@babel/plugin-transform-classes@npm:^7.23.5": + version: 7.23.5 + resolution: "@babel/plugin-transform-classes@npm:7.23.5" + dependencies: + "@babel/helper-annotate-as-pure": "npm:^7.22.5" + "@babel/helper-compilation-targets": "npm:^7.22.15" + "@babel/helper-environment-visitor": "npm:^7.22.20" + "@babel/helper-function-name": "npm:^7.23.0" + "@babel/helper-optimise-call-expression": "npm:^7.22.5" + "@babel/helper-plugin-utils": "npm:^7.22.5" + "@babel/helper-replace-supers": "npm:^7.22.20" + "@babel/helper-split-export-declaration": "npm:^7.22.6" + globals: "npm:^11.1.0" + peerDependencies: + "@babel/core": ^7.0.0-0 + checksum: 07988f52b4893151887d1ea6ff79e5fe834078c5731bd09babd5659edbbae21ea4e2de326a02443a63fd776b4c945da6177f07875b56fe66e0b7899e830a9e92 + languageName: node + linkType: hard + "@babel/plugin-transform-computed-properties@npm:^7.0.0, @babel/plugin-transform-computed-properties@npm:^7.23.3": version: 7.23.3 resolution: "@babel/plugin-transform-computed-properties@npm:7.23.3" @@ -860,15 +1000,15 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-dynamic-import@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-dynamic-import@npm:7.23.3" +"@babel/plugin-transform-dynamic-import@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-dynamic-import@npm:7.23.4" dependencies: "@babel/helper-plugin-utils": "npm:^7.22.5" "@babel/plugin-syntax-dynamic-import": "npm:^7.8.3" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: df3fd130312dc53d068fa76333991dce5e86987b023af8c3b502bd7d36a8e67da6f718e61dc838576a9fbacd06628e29607ee22d9bae30705485c14130eab201 + checksum: 19ae4a4a2ca86d35224734c41c48b2aa6a13139f3cfa1cbd18c0e65e461de8b65687dec7e52b7a72bb49db04465394c776aa1b13a2af5dc975b2a0cde3dcab67 languageName: node linkType: hard @@ -884,15 +1024,15 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-export-namespace-from@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-export-namespace-from@npm:7.23.3" +"@babel/plugin-transform-export-namespace-from@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-export-namespace-from@npm:7.23.4" dependencies: "@babel/helper-plugin-utils": "npm:^7.22.5" "@babel/plugin-syntax-export-namespace-from": "npm:^7.8.3" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: 390c6626dcda99023629049d92090242b4575351a4a7b47f97febabd2381f2cd0f624de661d8de8d1f715fedd63753cfd1feddead19e5960c27b88e447465b81 + checksum: 38bf04f851e36240bbe83ace4169da626524f4107bfb91f05b4ad93a5fb6a36d5b3d30b8883c1ba575ccfc1bac7938e90ca2e3cb227f7b3f4a9424beec6fd4a7 languageName: node linkType: hard @@ -908,7 +1048,7 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-for-of@npm:^7.0.0, @babel/plugin-transform-for-of@npm:^7.23.3": +"@babel/plugin-transform-for-of@npm:^7.0.0": version: 7.23.3 resolution: "@babel/plugin-transform-for-of@npm:7.23.3" dependencies: @@ -919,6 +1059,18 @@ __metadata: languageName: node linkType: hard +"@babel/plugin-transform-for-of@npm:^7.23.6": + version: 7.23.6 + resolution: "@babel/plugin-transform-for-of@npm:7.23.6" + dependencies: + "@babel/helper-plugin-utils": "npm:^7.22.5" + "@babel/helper-skip-transparent-expression-wrappers": "npm:^7.22.5" + peerDependencies: + "@babel/core": ^7.0.0-0 + checksum: 46681b6ab10f3ca2d961f50d4096b62ab5d551e1adad84e64be1ee23e72eb2f26a1e30e617e853c74f1349fffe4af68d33921a128543b6f24b6d46c09a3e2aec + languageName: node + linkType: hard + "@babel/plugin-transform-function-name@npm:^7.0.0, @babel/plugin-transform-function-name@npm:^7.23.3": version: 7.23.3 resolution: "@babel/plugin-transform-function-name@npm:7.23.3" @@ -932,15 +1084,15 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-json-strings@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-json-strings@npm:7.23.3" +"@babel/plugin-transform-json-strings@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-json-strings@npm:7.23.4" dependencies: "@babel/helper-plugin-utils": "npm:^7.22.5" "@babel/plugin-syntax-json-strings": "npm:^7.8.3" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: e1cef6a485b9da32aba9449fb459dac062dfc401f3d6ad48e7fbdcb73bbe470c995cc15ce5c421b95efe1e9a90d5507eb606360fe10b6d8cb869dd5dae7a2562 + checksum: 39e82223992a9ad857722ae051291935403852ad24b0dd64c645ca1c10517b6bf9822377d88643fed8b3e61a4e3f7e5ae41cf90eb07c40a786505d47d5970e54 languageName: node linkType: hard @@ -955,15 +1107,15 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-logical-assignment-operators@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-logical-assignment-operators@npm:7.23.3" +"@babel/plugin-transform-logical-assignment-operators@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-logical-assignment-operators@npm:7.23.4" dependencies: "@babel/helper-plugin-utils": "npm:^7.22.5" "@babel/plugin-syntax-logical-assignment-operators": "npm:^7.10.4" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: 23b7588b26d420c8b132bd08916d49871ca0c8db892f6b58637b10e2a0d918163d413c505db880a9157fc2e61d089040f139298a60d837ccbd0efca0474ac7ca + checksum: 87b034dd13143904e405887e6125d76c27902563486efc66b7d9a9d8f9406b76c6ac42d7b37224014af5783d7edb465db0cdecd659fa3227baad0b3a6a35deff languageName: node linkType: hard @@ -1052,33 +1204,33 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-nullish-coalescing-operator@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-nullish-coalescing-operator@npm:7.23.3" +"@babel/plugin-transform-nullish-coalescing-operator@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-nullish-coalescing-operator@npm:7.23.4" dependencies: "@babel/helper-plugin-utils": "npm:^7.22.5" "@babel/plugin-syntax-nullish-coalescing-operator": "npm:^7.8.3" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: f960faed3975c8454c52d2b5d85daf0c9a27677b248d7933882e59b10202ade2a98c7b925ce0bae2b8eb4d66eb5d63a5588c1090d54eaa4cd235533d71228ff3 + checksum: bce490d22da5c87ff27fffaff6ad5a4d4979b8d7b72e30857f191e9c1e1824ba73bb8d7081166289369e388f94f0ce5383a593b1fc84d09464a062c75f824b0b languageName: node linkType: hard -"@babel/plugin-transform-numeric-separator@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-numeric-separator@npm:7.23.3" +"@babel/plugin-transform-numeric-separator@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-numeric-separator@npm:7.23.4" dependencies: "@babel/helper-plugin-utils": "npm:^7.22.5" "@babel/plugin-syntax-numeric-separator": "npm:^7.10.4" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: d3748cce20e8752e61dfda55e275c699459a3ff8d0bb46585da813136e04066b1ce70b71beef504fcdc8d4cca3c955112cea96d5e9fd5a42a5bc8956d05236c2 + checksum: e34902da4f5588dc4812c92cb1f6a5e3e3647baf7b4623e30942f551bf1297621abec4e322ebfa50b320c987c0f34d9eb4355b3d289961d9035e2126e3119c12 languageName: node linkType: hard -"@babel/plugin-transform-object-rest-spread@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-object-rest-spread@npm:7.23.3" +"@babel/plugin-transform-object-rest-spread@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-object-rest-spread@npm:7.23.4" dependencies: "@babel/compat-data": "npm:^7.23.3" "@babel/helper-compilation-targets": "npm:^7.22.15" @@ -1087,7 +1239,7 @@ __metadata: "@babel/plugin-transform-parameters": "npm:^7.23.3" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: 31ab631aaba945c118662943e5f1f54a21f07d64f06e06b25d55871168c460f3eeeccdf7b05aa74a1340e2cfbe781ad3c7ceccd0c2585d39f7b73ba11ebaa9d0 + checksum: b56017992ffe7fcd1dd9a9da67c39995a141820316266bcf7d77dc912980d228ccbd3f36191d234f5cc389b09157b5d2a955e33e8fb368319534affd1c72b262 languageName: node linkType: hard @@ -1103,15 +1255,15 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-optional-catch-binding@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-optional-catch-binding@npm:7.23.3" +"@babel/plugin-transform-optional-catch-binding@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-optional-catch-binding@npm:7.23.4" dependencies: "@babel/helper-plugin-utils": "npm:^7.22.5" "@babel/plugin-syntax-optional-catch-binding": "npm:^7.8.3" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: 85ac1e94ee8f21648816151628ff931cc16143ec8c904649a1ecfd8960160290eccc5a197b4ae3ee7a1c7a27a7c4189e61b4de24483d5bad4040784afe2d206f + checksum: 4ef61812af0e4928485e28301226ce61139a8b8cea9e9a919215ebec4891b9fea2eb7a83dc3090e2679b7d7b2c8653da601fbc297d2addc54a908b315173991e languageName: node linkType: hard @@ -1128,6 +1280,19 @@ __metadata: languageName: node linkType: hard +"@babel/plugin-transform-optional-chaining@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-optional-chaining@npm:7.23.4" + dependencies: + "@babel/helper-plugin-utils": "npm:^7.22.5" + "@babel/helper-skip-transparent-expression-wrappers": "npm:^7.22.5" + "@babel/plugin-syntax-optional-chaining": "npm:^7.8.3" + peerDependencies: + "@babel/core": ^7.0.0-0 + checksum: 305b773c29ad61255b0e83ec1e92b2f7af6aa58be4cba1e3852bddaa14f7d2afd7b4438f41c28b179d6faac7eb8d4fb5530a17920294f25d459b8f84406bfbfb + languageName: node + linkType: hard + "@babel/plugin-transform-parameters@npm:^7.0.0, @babel/plugin-transform-parameters@npm:^7.20.7, @babel/plugin-transform-parameters@npm:^7.23.3": version: 7.23.3 resolution: "@babel/plugin-transform-parameters@npm:7.23.3" @@ -1151,9 +1316,9 @@ __metadata: languageName: node linkType: hard -"@babel/plugin-transform-private-property-in-object@npm:^7.23.3": - version: 7.23.3 - resolution: "@babel/plugin-transform-private-property-in-object@npm:7.23.3" +"@babel/plugin-transform-private-property-in-object@npm:^7.23.4": + version: 7.23.4 + resolution: "@babel/plugin-transform-private-property-in-object@npm:7.23.4" dependencies: "@babel/helper-annotate-as-pure": "npm:^7.22.5" "@babel/helper-create-class-features-plugin": "npm:^7.22.15" @@ -1161,7 +1326,7 @@ __metadata: "@babel/plugin-syntax-private-property-in-object": "npm:^7.14.5" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: 9211dd25a6e87a01535f2d97a663fa6de3472b963c8dcfaacce229a2e3fa6500f2e9fc690bc100a540fc7b66c8364faf7ef19b32e9c9b9791e4561b742c15ed3 + checksum: 8d31b28f24204b4d13514cd3a8f3033abf575b1a6039759ddd6e1d82dd33ba7281f9bc85c9f38072a665d69bfa26dc40737eefaf9d397b024654a483d2357bf5 languageName: node linkType: hard @@ -1353,17 +1518,17 @@ __metadata: languageName: node linkType: hard -"@babel/preset-env@npm:^7.20.2": - version: 7.23.3 - resolution: "@babel/preset-env@npm:7.23.3" +"@babel/preset-env@npm:^7.23.7": + version: 7.23.7 + resolution: "@babel/preset-env@npm:7.23.7" dependencies: - "@babel/compat-data": "npm:^7.23.3" - "@babel/helper-compilation-targets": "npm:^7.22.15" + "@babel/compat-data": "npm:^7.23.5" + "@babel/helper-compilation-targets": "npm:^7.23.6" "@babel/helper-plugin-utils": "npm:^7.22.5" - "@babel/helper-validator-option": "npm:^7.22.15" + "@babel/helper-validator-option": "npm:^7.23.5" "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": "npm:^7.23.3" "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": "npm:^7.23.3" - "@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly": "npm:^7.23.3" + "@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly": "npm:^7.23.7" "@babel/plugin-proposal-private-property-in-object": "npm:7.21.0-placeholder-for-preset-env.2" "@babel/plugin-syntax-async-generators": "npm:^7.8.4" "@babel/plugin-syntax-class-properties": "npm:^7.12.13" @@ -1384,25 +1549,25 @@ __metadata: "@babel/plugin-syntax-top-level-await": "npm:^7.14.5" "@babel/plugin-syntax-unicode-sets-regex": "npm:^7.18.6" "@babel/plugin-transform-arrow-functions": "npm:^7.23.3" - "@babel/plugin-transform-async-generator-functions": "npm:^7.23.3" + "@babel/plugin-transform-async-generator-functions": "npm:^7.23.7" "@babel/plugin-transform-async-to-generator": "npm:^7.23.3" "@babel/plugin-transform-block-scoped-functions": "npm:^7.23.3" - "@babel/plugin-transform-block-scoping": "npm:^7.23.3" + "@babel/plugin-transform-block-scoping": "npm:^7.23.4" "@babel/plugin-transform-class-properties": "npm:^7.23.3" - "@babel/plugin-transform-class-static-block": "npm:^7.23.3" - "@babel/plugin-transform-classes": "npm:^7.23.3" + "@babel/plugin-transform-class-static-block": "npm:^7.23.4" + "@babel/plugin-transform-classes": "npm:^7.23.5" "@babel/plugin-transform-computed-properties": "npm:^7.23.3" "@babel/plugin-transform-destructuring": "npm:^7.23.3" "@babel/plugin-transform-dotall-regex": "npm:^7.23.3" "@babel/plugin-transform-duplicate-keys": "npm:^7.23.3" - "@babel/plugin-transform-dynamic-import": "npm:^7.23.3" + "@babel/plugin-transform-dynamic-import": "npm:^7.23.4" "@babel/plugin-transform-exponentiation-operator": "npm:^7.23.3" - "@babel/plugin-transform-export-namespace-from": "npm:^7.23.3" - "@babel/plugin-transform-for-of": "npm:^7.23.3" + "@babel/plugin-transform-export-namespace-from": "npm:^7.23.4" + "@babel/plugin-transform-for-of": "npm:^7.23.6" "@babel/plugin-transform-function-name": "npm:^7.23.3" - "@babel/plugin-transform-json-strings": "npm:^7.23.3" + "@babel/plugin-transform-json-strings": "npm:^7.23.4" "@babel/plugin-transform-literals": "npm:^7.23.3" - "@babel/plugin-transform-logical-assignment-operators": "npm:^7.23.3" + "@babel/plugin-transform-logical-assignment-operators": "npm:^7.23.4" "@babel/plugin-transform-member-expression-literals": "npm:^7.23.3" "@babel/plugin-transform-modules-amd": "npm:^7.23.3" "@babel/plugin-transform-modules-commonjs": "npm:^7.23.3" @@ -1410,15 +1575,15 @@ __metadata: "@babel/plugin-transform-modules-umd": "npm:^7.23.3" "@babel/plugin-transform-named-capturing-groups-regex": "npm:^7.22.5" "@babel/plugin-transform-new-target": "npm:^7.23.3" - "@babel/plugin-transform-nullish-coalescing-operator": "npm:^7.23.3" - "@babel/plugin-transform-numeric-separator": "npm:^7.23.3" - "@babel/plugin-transform-object-rest-spread": "npm:^7.23.3" + "@babel/plugin-transform-nullish-coalescing-operator": "npm:^7.23.4" + "@babel/plugin-transform-numeric-separator": "npm:^7.23.4" + "@babel/plugin-transform-object-rest-spread": "npm:^7.23.4" "@babel/plugin-transform-object-super": "npm:^7.23.3" - "@babel/plugin-transform-optional-catch-binding": "npm:^7.23.3" - "@babel/plugin-transform-optional-chaining": "npm:^7.23.3" + "@babel/plugin-transform-optional-catch-binding": "npm:^7.23.4" + "@babel/plugin-transform-optional-chaining": "npm:^7.23.4" "@babel/plugin-transform-parameters": "npm:^7.23.3" "@babel/plugin-transform-private-methods": "npm:^7.23.3" - "@babel/plugin-transform-private-property-in-object": "npm:^7.23.3" + "@babel/plugin-transform-private-property-in-object": "npm:^7.23.4" "@babel/plugin-transform-property-literals": "npm:^7.23.3" "@babel/plugin-transform-regenerator": "npm:^7.23.3" "@babel/plugin-transform-reserved-words": "npm:^7.23.3" @@ -1432,14 +1597,14 @@ __metadata: "@babel/plugin-transform-unicode-regex": "npm:^7.23.3" "@babel/plugin-transform-unicode-sets-regex": "npm:^7.23.3" "@babel/preset-modules": "npm:0.1.6-no-external-plugins" - babel-plugin-polyfill-corejs2: "npm:^0.4.6" - babel-plugin-polyfill-corejs3: "npm:^0.8.5" - babel-plugin-polyfill-regenerator: "npm:^0.5.3" + babel-plugin-polyfill-corejs2: "npm:^0.4.7" + babel-plugin-polyfill-corejs3: "npm:^0.8.7" + babel-plugin-polyfill-regenerator: "npm:^0.5.4" core-js-compat: "npm:^3.31.0" semver: "npm:^6.3.1" peerDependencies: "@babel/core": ^7.0.0-0 - checksum: 36b02a86817ab5474bb74a8d62a110723b0b05904a52ddc5627cf89457525b8d5ac0739b8e435a6ae12ef8b90cd5fc191169898c3dc2ac9d2c84026b02f2580a + checksum: ac9def873cec52ee02a550bde6e22eced16d1ae331bb8ebc82c03e4c91c12ac17e3e4027647e61612937bcc25ac46e71370aaf99dc2e85dbd11f7777ffeed54e languageName: node linkType: hard @@ -1456,7 +1621,7 @@ __metadata: languageName: node linkType: hard -"@babel/preset-typescript@npm:^7.18.6": +"@babel/preset-typescript@npm:^7.23.3": version: 7.23.3 resolution: "@babel/preset-typescript@npm:7.23.3" dependencies: @@ -1516,6 +1681,24 @@ __metadata: languageName: node linkType: hard +"@babel/traverse@npm:^7.23.7": + version: 7.23.7 + resolution: "@babel/traverse@npm:7.23.7" + dependencies: + "@babel/code-frame": "npm:^7.23.5" + "@babel/generator": "npm:^7.23.6" + "@babel/helper-environment-visitor": "npm:^7.22.20" + "@babel/helper-function-name": "npm:^7.23.0" + "@babel/helper-hoist-variables": "npm:^7.22.5" + "@babel/helper-split-export-declaration": "npm:^7.22.6" + "@babel/parser": "npm:^7.23.6" + "@babel/types": "npm:^7.23.6" + debug: "npm:^4.3.1" + globals: "npm:^11.1.0" + checksum: e32fceb4249beec2bde83968ddffe17444221c1ee5cd18c543a2feaf94e3ca83f2a4dfbc2dcca87cf226e0105973e0fe3717063a21e982a9de9945615ab3f3f5 + languageName: node + linkType: hard + "@babel/types@npm:^7.0.0, @babel/types@npm:^7.16.8, @babel/types@npm:^7.18.13, @babel/types@npm:^7.20.7, @babel/types@npm:^7.22.15, @babel/types@npm:^7.22.19, @babel/types@npm:^7.22.5, @babel/types@npm:^7.23.0, @babel/types@npm:^7.23.3, @babel/types@npm:^7.3.3, @babel/types@npm:^7.4.4, @babel/types@npm:^7.8.3": version: 7.23.3 resolution: "@babel/types@npm:7.23.3" @@ -1527,6 +1710,17 @@ __metadata: languageName: node linkType: hard +"@babel/types@npm:^7.23.6": + version: 7.23.6 + resolution: "@babel/types@npm:7.23.6" + dependencies: + "@babel/helper-string-parser": "npm:^7.23.4" + "@babel/helper-validator-identifier": "npm:^7.22.20" + to-fast-properties: "npm:^2.0.0" + checksum: 42cefce8a68bd09bb5828b4764aa5586c53c60128ac2ac012e23858e1c179347a4aac9c66fc577994fbf57595227611c5ec8270bf0cfc94ff033bbfac0550b70 + languageName: node + linkType: hard + "@bcoe/v8-coverage@npm:^0.2.3": version: 0.2.3 resolution: "@bcoe/v8-coverage@npm:0.2.3" @@ -1585,7 +1779,7 @@ __metadata: languageName: node linkType: hard -"@eslint-community/eslint-utils@npm:^4.2.0": +"@eslint-community/eslint-utils@npm:^4.2.0, @eslint-community/eslint-utils@npm:^4.4.0": version: 4.4.0 resolution: "@eslint-community/eslint-utils@npm:4.4.0" dependencies: @@ -1596,16 +1790,16 @@ __metadata: languageName: node linkType: hard -"@eslint-community/regexpp@npm:^4.4.0, @eslint-community/regexpp@npm:^4.6.1": +"@eslint-community/regexpp@npm:^4.5.1, @eslint-community/regexpp@npm:^4.6.1": version: 4.10.0 resolution: "@eslint-community/regexpp@npm:4.10.0" checksum: c5f60ef1f1ea7649fa7af0e80a5a79f64b55a8a8fa5086de4727eb4c86c652aedee407a9c143b8995d2c0b2d75c1222bec9ba5d73dbfc1f314550554f0979ef4 languageName: node linkType: hard -"@eslint/eslintrc@npm:^2.1.3": - version: 2.1.3 - resolution: "@eslint/eslintrc@npm:2.1.3" +"@eslint/eslintrc@npm:^2.1.4": + version: 2.1.4 + resolution: "@eslint/eslintrc@npm:2.1.4" dependencies: ajv: "npm:^6.12.4" debug: "npm:^4.3.2" @@ -1616,21 +1810,14 @@ __metadata: js-yaml: "npm:^4.1.0" minimatch: "npm:^3.1.2" strip-json-comments: "npm:^3.1.1" - checksum: f4103f4346126292eb15581c5a1d12bef03410fd3719dedbdb92e1f7031d46a5a2d60de8566790445d5d4b70b75ba050876799a11f5fff8265a91ee3fa77dab0 - languageName: node - linkType: hard - -"@eslint/js@npm:8.53.0": - version: 8.53.0 - resolution: "@eslint/js@npm:8.53.0" - checksum: d29f6c207b2f6dc4ef174d16a3c07b0d3a17ca3d805680496ff267edd773e3bac41db4e7dcab622ca1970d892535bd19671e2a756d4eac75e96fd8c8dcdb619b + checksum: 32f67052b81768ae876c84569ffd562491ec5a5091b0c1e1ca1e0f3c24fb42f804952fdd0a137873bc64303ba368a71ba079a6f691cee25beee9722d94cc8573 languageName: node linkType: hard -"@gar/promisify@npm:^1.1.3": - version: 1.1.3 - resolution: "@gar/promisify@npm:1.1.3" - checksum: 0b3c9958d3cd17f4add3574975e3115ae05dc7f1298a60810414b16f6f558c137b5fb3cd3905df380bacfd955ec13f67c1e6710cbb5c246a7e8d65a8289b2bff +"@eslint/js@npm:8.56.0": + version: 8.56.0 + resolution: "@eslint/js@npm:8.56.0" + checksum: 60b3a1cf240e2479cec9742424224465dc50e46d781da1b7f5ef240501b2d1202c225bd456207faac4b34a64f4765833345bc4ddffd00395e1db40fa8c426f5a languageName: node linkType: hard @@ -2224,12 +2411,12 @@ __metadata: languageName: node linkType: hard -"@heroicons/react@npm:^2.0.18": - version: 2.0.18 - resolution: "@heroicons/react@npm:2.0.18" +"@heroicons/react@npm:^2.1.1": + version: 2.1.1 + resolution: "@heroicons/react@npm:2.1.1" peerDependencies: react: ">= 16" - checksum: 3cef7f67c65f8b00dc4f23788e468e661a24bd805f80e3b5514a986d69c91ef05407cf50078691573eced47147db87a9bd00cc165e4fecd2a9657cbaf3eaafb5 + checksum: c85f76d4ccb5bdad9e6ffaa62bfdcde1c1f9ebaf3287908a7be0994c2d0f6151b9017f6e41d0a1ec9ba1eb1c53ab88f30704b0d25c72adc59896882b0a60147e languageName: node linkType: hard @@ -2267,6 +2454,13 @@ __metadata: languageName: node linkType: hard +"@ioredis/commands@npm:^1.1.1": + version: 1.2.0 + resolution: "@ioredis/commands@npm:1.2.0" + checksum: a5d3c29dd84d8a28b7c67a441ac1715cbd7337a7b88649c0f17c345d89aa218578d2b360760017c48149ef8a70f44b051af9ac0921a0622c2b479614c4f65b36 + languageName: node + linkType: hard + "@isaacs/cliui@npm:^8.0.2": version: 8.0.2 resolution: "@isaacs/cliui@npm:8.0.2" @@ -2761,53 +2955,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/arborist@npm:^5.6.3": - version: 5.6.3 - resolution: "@npmcli/arborist@npm:5.6.3" - dependencies: - "@isaacs/string-locale-compare": "npm:^1.1.0" - "@npmcli/installed-package-contents": "npm:^1.0.7" - "@npmcli/map-workspaces": "npm:^2.0.3" - "@npmcli/metavuln-calculator": "npm:^3.0.1" - "@npmcli/move-file": "npm:^2.0.0" - "@npmcli/name-from-folder": "npm:^1.0.1" - "@npmcli/node-gyp": "npm:^2.0.0" - "@npmcli/package-json": "npm:^2.0.0" - "@npmcli/query": "npm:^1.2.0" - "@npmcli/run-script": "npm:^4.1.3" - bin-links: "npm:^3.0.3" - cacache: "npm:^16.1.3" - common-ancestor-path: "npm:^1.0.1" - hosted-git-info: "npm:^5.2.1" - json-parse-even-better-errors: "npm:^2.3.1" - json-stringify-nice: "npm:^1.1.4" - minimatch: "npm:^5.1.0" - mkdirp: "npm:^1.0.4" - mkdirp-infer-owner: "npm:^2.0.0" - nopt: "npm:^6.0.0" - npm-install-checks: "npm:^5.0.0" - npm-package-arg: "npm:^9.0.0" - npm-pick-manifest: "npm:^7.0.2" - npm-registry-fetch: "npm:^13.0.0" - npmlog: "npm:^6.0.2" - pacote: "npm:^13.6.1" - parse-conflict-json: "npm:^2.0.1" - proc-log: "npm:^2.0.0" - promise-all-reject-late: "npm:^1.0.0" - promise-call-limit: "npm:^1.0.1" - read-package-json-fast: "npm:^2.0.2" - readdir-scoped-modules: "npm:^1.1.0" - rimraf: "npm:^3.0.2" - semver: "npm:^7.3.7" - ssri: "npm:^9.0.0" - treeverse: "npm:^2.0.0" - walk-up-path: "npm:^1.0.0" - bin: - arborist: bin/index.js - checksum: 5647e68e8726f633d43e2d6a89c11568555aec2cd68035bf6b92f78a00e66e364e2b562f089e92b89a7c61abd5efca25f25347f00ce4bc6bc10133225b60c284 - languageName: node - linkType: hard - "@npmcli/arborist@npm:^7.2.1": version: 7.2.1 resolution: "@npmcli/arborist@npm:7.2.1" @@ -2851,29 +2998,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/ci-detect@npm:^2.0.0": - version: 2.0.0 - resolution: "@npmcli/ci-detect@npm:2.0.0" - checksum: a5871158bc2a6bb7a2d313fa56d4d1747486b1e7531da6b4f39e9a6e8188bb2faef212b5927bf13413a6f0a9ecebbaa849c26f5147eb1593e918c37a2c349634 - languageName: node - linkType: hard - -"@npmcli/config@npm:^4.2.1": - version: 4.2.2 - resolution: "@npmcli/config@npm:4.2.2" - dependencies: - "@npmcli/map-workspaces": "npm:^2.0.2" - ini: "npm:^3.0.0" - mkdirp-infer-owner: "npm:^2.0.0" - nopt: "npm:^6.0.0" - proc-log: "npm:^2.0.0" - read-package-json-fast: "npm:^2.0.3" - semver: "npm:^7.3.5" - walk-up-path: "npm:^1.0.0" - checksum: d13f64301e06efe8c6fc4c5aaebc573f86092925564cb9eeaec077d121afca66c73f781d7e74b18d432694f44a86f7d86eb22925eb82e3c2ff57cd6d6948e59f - languageName: node - linkType: hard - "@npmcli/config@npm:^8.0.1": version: 8.0.1 resolution: "@npmcli/config@npm:8.0.1" @@ -2890,15 +3014,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/disparity-colors@npm:^2.0.0": - version: 2.0.0 - resolution: "@npmcli/disparity-colors@npm:2.0.0" - dependencies: - ansi-styles: "npm:^4.3.0" - checksum: a4aabb55fad40056b1101c2ab8bb761e0fb2733b8ad33248327f6840e5b4364b80d8aea3d3bd7f066b9ee709abc2ac87077a611c1803107a5a3b9b51ba49e7a1 - languageName: node - linkType: hard - "@npmcli/disparity-colors@npm:^3.0.0": version: 3.0.0 resolution: "@npmcli/disparity-colors@npm:3.0.0" @@ -2908,16 +3023,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/fs@npm:^2.1.0, @npmcli/fs@npm:^2.1.1": - version: 2.1.2 - resolution: "@npmcli/fs@npm:2.1.2" - dependencies: - "@gar/promisify": "npm:^1.1.3" - semver: "npm:^7.3.5" - checksum: c50d087733d0d8df23be24f700f104b19922a28677aa66fdbe06ff6af6431cc4a5bb1e27683cbc661a5dafa9bafdc603e6a0378121506dfcd394b2b6dd76a187 - languageName: node - linkType: hard - "@npmcli/fs@npm:^3.1.0": version: 3.1.0 resolution: "@npmcli/fs@npm:3.1.0" @@ -2927,23 +3032,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/git@npm:^3.0.0": - version: 3.0.2 - resolution: "@npmcli/git@npm:3.0.2" - dependencies: - "@npmcli/promise-spawn": "npm:^3.0.0" - lru-cache: "npm:^7.4.4" - mkdirp: "npm:^1.0.4" - npm-pick-manifest: "npm:^7.0.0" - proc-log: "npm:^2.0.0" - promise-inflight: "npm:^1.0.1" - promise-retry: "npm:^2.0.1" - semver: "npm:^7.3.5" - which: "npm:^2.0.2" - checksum: 26c18d98d0bf060b82692f41919847d55c00224861abbd972f47b4ecbf2494ec3afddafb8dbf98442d972e8217e3a909f95d27d040feadc061f3e8f7ccc2e2bd - languageName: node - linkType: hard - "@npmcli/git@npm:^5.0.0, @npmcli/git@npm:^5.0.3": version: 5.0.3 resolution: "@npmcli/git@npm:5.0.3" @@ -2960,18 +3048,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/installed-package-contents@npm:^1.0.7": - version: 1.0.7 - resolution: "@npmcli/installed-package-contents@npm:1.0.7" - dependencies: - npm-bundled: "npm:^1.1.1" - npm-normalize-package-bin: "npm:^1.0.1" - bin: - installed-package-contents: index.js - checksum: 69c23b489ebfc90a28f6ee5293256bf6dae656292c8e13d52cd770fee2db2c9ecbeb7586387cd9006bc1968439edd5c75aeeb7d39ba0c8eb58905c3073bee067 - languageName: node - linkType: hard - "@npmcli/installed-package-contents@npm:^2.0.1, @npmcli/installed-package-contents@npm:^2.0.2": version: 2.0.2 resolution: "@npmcli/installed-package-contents@npm:2.0.2" @@ -2984,18 +3060,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/map-workspaces@npm:^2.0.2, @npmcli/map-workspaces@npm:^2.0.3": - version: 2.0.4 - resolution: "@npmcli/map-workspaces@npm:2.0.4" - dependencies: - "@npmcli/name-from-folder": "npm:^1.0.1" - glob: "npm:^8.0.1" - minimatch: "npm:^5.0.1" - read-package-json-fast: "npm:^2.0.3" - checksum: 11ab7b357dbe7a06067405619b5c2f50e6176b1d392e97d715ebbb4e51357c7b3683fb59be273e3e689893d158362c050a4c358405af91d2243de6b0cf6129d6 - languageName: node - linkType: hard - "@npmcli/map-workspaces@npm:^3.0.2, @npmcli/map-workspaces@npm:^3.0.4": version: 3.0.4 resolution: "@npmcli/map-workspaces@npm:3.0.4" @@ -3008,18 +3072,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/metavuln-calculator@npm:^3.0.1": - version: 3.1.1 - resolution: "@npmcli/metavuln-calculator@npm:3.1.1" - dependencies: - cacache: "npm:^16.0.0" - json-parse-even-better-errors: "npm:^2.3.1" - pacote: "npm:^13.0.3" - semver: "npm:^7.3.5" - checksum: 92bd9e5f221639cc9f9580736898a30a7acfb21eb67f0c6c3cc63ff77cb25df18f2b359b47bee8b66afff871640eac693d8ba6779eab7f8977befc7ca09833cd - languageName: node - linkType: hard - "@npmcli/metavuln-calculator@npm:^7.0.0": version: 7.0.0 resolution: "@npmcli/metavuln-calculator@npm:7.0.0" @@ -3032,23 +3084,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/move-file@npm:^2.0.0": - version: 2.0.1 - resolution: "@npmcli/move-file@npm:2.0.1" - dependencies: - mkdirp: "npm:^1.0.4" - rimraf: "npm:^3.0.2" - checksum: 11b2151e6d1de6f6eb23128de5aa8a429fd9097d839a5190cb77aa47a6b627022c42d50fa7c47a00f1c9f8f0c1560092b09b061855d293fa0741a2a94cfb174d - languageName: node - linkType: hard - -"@npmcli/name-from-folder@npm:^1.0.1": - version: 1.0.1 - resolution: "@npmcli/name-from-folder@npm:1.0.1" - checksum: 6dbedf7c678ed1034e9905d75d3493459771bb4c4eeda147e1ab0f6a5c56d5ccc597ca9230741f2884e3f0e5fbf94e66ba6e7776d713d2a109427056bd10ae02 - languageName: node - linkType: hard - "@npmcli/name-from-folder@npm:^2.0.0": version: 2.0.0 resolution: "@npmcli/name-from-folder@npm:2.0.0" @@ -3056,13 +3091,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/node-gyp@npm:^2.0.0": - version: 2.0.0 - resolution: "@npmcli/node-gyp@npm:2.0.0" - checksum: 8de88f4a602e8f868f10c660250429d34a51aaa10cb4d0f1f919d7920632be22cc47ad0e4d75097cd68e07fec5b93e41803ae3f03c1a3370badd865461e6b486 - languageName: node - linkType: hard - "@npmcli/node-gyp@npm:^3.0.0": version: 3.0.0 resolution: "@npmcli/node-gyp@npm:3.0.0" @@ -3070,15 +3098,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/package-json@npm:^2.0.0": - version: 2.0.0 - resolution: "@npmcli/package-json@npm:2.0.0" - dependencies: - json-parse-even-better-errors: "npm:^2.3.1" - checksum: 67aa80bb75e2f8d328c5225caf31d63499b01dd8b094e739b84de442b5411ba1040374cea113ccbcd3f0dda8b872a243e74d937b584c9040e8af6a90d42a564e - languageName: node - linkType: hard - "@npmcli/package-json@npm:^5.0.0": version: 5.0.0 resolution: "@npmcli/package-json@npm:5.0.0" @@ -3094,15 +3113,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/promise-spawn@npm:^3.0.0": - version: 3.0.0 - resolution: "@npmcli/promise-spawn@npm:3.0.0" - dependencies: - infer-owner: "npm:^1.0.4" - checksum: 934225972d7b3e456e76b2eae40b3ece2478a361d99aa56c79f65ef7c66aa83cd55330ee44daf43174b76649b25d722b9f85120a4591cac53d884423f315465c - languageName: node - linkType: hard - "@npmcli/promise-spawn@npm:^7.0.0": version: 7.0.0 resolution: "@npmcli/promise-spawn@npm:7.0.0" @@ -3112,17 +3122,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/query@npm:^1.2.0": - version: 1.2.0 - resolution: "@npmcli/query@npm:1.2.0" - dependencies: - npm-package-arg: "npm:^9.1.0" - postcss-selector-parser: "npm:^6.0.10" - semver: "npm:^7.3.7" - checksum: f0fbc9ae07b437c0ebed20811c46ca22f654240a75223c7819510abbc7791af5c6d9e99b6bc37ecf3842a1b6457abff8deb7232ac00403c07c65df87be651311 - languageName: node - linkType: hard - "@npmcli/query@npm:^3.0.1": version: 3.0.1 resolution: "@npmcli/query@npm:3.0.1" @@ -3132,19 +3131,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/run-script@npm:^4.1.0, @npmcli/run-script@npm:^4.1.3, @npmcli/run-script@npm:^4.2.0, @npmcli/run-script@npm:^4.2.1": - version: 4.2.1 - resolution: "@npmcli/run-script@npm:4.2.1" - dependencies: - "@npmcli/node-gyp": "npm:^2.0.0" - "@npmcli/promise-spawn": "npm:^3.0.0" - node-gyp: "npm:^9.0.0" - read-package-json-fast: "npm:^2.0.3" - which: "npm:^2.0.2" - checksum: b658b239a0132d3b7262ab94e16ca1bf4abe2987557015086c94768bd0cfdf7cded9a6c04f2efb58d63ae4f3bbb794caffaedc00b3d64ad7136bcf8c181b9b10 - languageName: node - linkType: hard - "@npmcli/run-script@npm:^7.0.0, @npmcli/run-script@npm:^7.0.2": version: 7.0.2 resolution: "@npmcli/run-script@npm:7.0.2" @@ -3158,13 +3144,6 @@ __metadata: languageName: node linkType: hard -"@octokit/auth-token@npm:^3.0.0": - version: 3.0.4 - resolution: "@octokit/auth-token@npm:3.0.4" - checksum: abdf5e2da36344de9727c70ba782d58004f5ae1da0f65fa9bc9216af596ef23c0e4675f386df2f6886806612558091d603564051b693b0ad1986aa6160b7a231 - languageName: node - linkType: hard - "@octokit/auth-token@npm:^4.0.0": version: 4.0.0 resolution: "@octokit/auth-token@npm:4.0.0" @@ -3172,21 +3151,6 @@ __metadata: languageName: node linkType: hard -"@octokit/core@npm:^4.2.1": - version: 4.2.4 - resolution: "@octokit/core@npm:4.2.4" - dependencies: - "@octokit/auth-token": "npm:^3.0.0" - "@octokit/graphql": "npm:^5.0.0" - "@octokit/request": "npm:^6.0.0" - "@octokit/request-error": "npm:^3.0.0" - "@octokit/types": "npm:^9.0.0" - before-after-hook: "npm:^2.2.0" - universal-user-agent: "npm:^6.0.0" - checksum: e54081a56884e628d1804837fddcd48c10d516117bb891551c8dc9d8e3dad449aeb9b4677ca71e8f0e76268c2b7656c953099506679aaa4666765228474a3ce6 - languageName: node - linkType: hard - "@octokit/core@npm:^5.0.0": version: 5.0.1 resolution: "@octokit/core@npm:5.0.1" @@ -3202,17 +3166,6 @@ __metadata: languageName: node linkType: hard -"@octokit/endpoint@npm:^7.0.0": - version: 7.0.6 - resolution: "@octokit/endpoint@npm:7.0.6" - dependencies: - "@octokit/types": "npm:^9.0.0" - is-plain-object: "npm:^5.0.0" - universal-user-agent: "npm:^6.0.0" - checksum: fd147a55010b54af7567bf90791359f7096a1c9916a2b7c72f8afd0c53141338b3d78da3a4ab3e3bdfeb26218a1b73735432d8987ccc04996b1019219299f115 - languageName: node - linkType: hard - "@octokit/endpoint@npm:^9.0.0": version: 9.0.2 resolution: "@octokit/endpoint@npm:9.0.2" @@ -3224,17 +3177,6 @@ __metadata: languageName: node linkType: hard -"@octokit/graphql@npm:^5.0.0": - version: 5.0.6 - resolution: "@octokit/graphql@npm:5.0.6" - dependencies: - "@octokit/request": "npm:^6.0.0" - "@octokit/types": "npm:^9.0.0" - universal-user-agent: "npm:^6.0.0" - checksum: de1d839d97fe6d96179925f6714bf96e7af6f77929892596bb4211adab14add3291fc5872b269a3d0e91a4dcf248d16096c82606c4a43538cf241b815c2e2a36 - languageName: node - linkType: hard - "@octokit/graphql@npm:^7.0.0": version: 7.0.2 resolution: "@octokit/graphql@npm:7.0.2" @@ -3246,13 +3188,6 @@ __metadata: languageName: node linkType: hard -"@octokit/openapi-types@npm:^18.0.0": - version: 18.1.1 - resolution: "@octokit/openapi-types@npm:18.1.1" - checksum: 856d3bb9f8c666e837dd5e8b8c216ee4342b9ed63ff8da922ca4ce5883ed1dfbec73390eb13d69fbcb4703a4c8b8b6a586df3b0e675ff93bf3d46b5b4fe0968e - languageName: node - linkType: hard - "@octokit/openapi-types@npm:^19.0.2": version: 19.0.2 resolution: "@octokit/openapi-types@npm:19.0.2" @@ -3260,18 +3195,6 @@ __metadata: languageName: node linkType: hard -"@octokit/plugin-paginate-rest@npm:^6.1.2": - version: 6.1.2 - resolution: "@octokit/plugin-paginate-rest@npm:6.1.2" - dependencies: - "@octokit/tsconfig": "npm:^1.0.2" - "@octokit/types": "npm:^9.2.3" - peerDependencies: - "@octokit/core": ">=4" - checksum: def241c4f00b864822ab6414eaadd8679a6d332004c7e77467cfc1e6d5bdcc453c76bd185710ee942e4df201f9dd2170d960f46af5b14ef6f261a0068f656364 - languageName: node - linkType: hard - "@octokit/plugin-paginate-rest@npm:^9.0.0": version: 9.1.3 resolution: "@octokit/plugin-paginate-rest@npm:9.1.3" @@ -3283,18 +3206,6 @@ __metadata: languageName: node linkType: hard -"@octokit/plugin-retry@npm:^4.1.3": - version: 4.1.6 - resolution: "@octokit/plugin-retry@npm:4.1.6" - dependencies: - "@octokit/types": "npm:^9.0.0" - bottleneck: "npm:^2.15.3" - peerDependencies: - "@octokit/core": ">=3" - checksum: becda71309b8fde99b2daa6c5ab7c9774adfabc2c950da53741bb911c6cd4db1b4d9cc878498580f8b8e881f491450a57bfaa50b6ad749aea421766675dbebdb - languageName: node - linkType: hard - "@octokit/plugin-retry@npm:^6.0.0": version: 6.0.1 resolution: "@octokit/plugin-retry@npm:6.0.1" @@ -3308,18 +3219,6 @@ __metadata: languageName: node linkType: hard -"@octokit/plugin-throttling@npm:^5.2.3": - version: 5.2.3 - resolution: "@octokit/plugin-throttling@npm:5.2.3" - dependencies: - "@octokit/types": "npm:^9.0.0" - bottleneck: "npm:^2.15.3" - peerDependencies: - "@octokit/core": ^4.0.0 - checksum: dd43da3e49c7e92aa6f513aae80702a13899cd9265d9538443063bd9c56e250177b4672bda0894843915b6424c01350647366af2763479f43d6dfe9983d43325 - languageName: node - linkType: hard - "@octokit/plugin-throttling@npm:^8.0.0": version: 8.1.2 resolution: "@octokit/plugin-throttling@npm:8.1.2" @@ -3332,17 +3231,6 @@ __metadata: languageName: node linkType: hard -"@octokit/request-error@npm:^3.0.0": - version: 3.0.3 - resolution: "@octokit/request-error@npm:3.0.3" - dependencies: - "@octokit/types": "npm:^9.0.0" - deprecation: "npm:^2.0.0" - once: "npm:^1.4.0" - checksum: 1e252ac193c8af23b709909911aa327ed5372cbafcba09e4aff41e0f640a7c152579ab0a60311a92e37b4e7936392d59ee4c2feae5cdc387ee8587a33d8afa60 - languageName: node - linkType: hard - "@octokit/request-error@npm:^5.0.0": version: 5.0.1 resolution: "@octokit/request-error@npm:5.0.1" @@ -3354,20 +3242,6 @@ __metadata: languageName: node linkType: hard -"@octokit/request@npm:^6.0.0": - version: 6.2.8 - resolution: "@octokit/request@npm:6.2.8" - dependencies: - "@octokit/endpoint": "npm:^7.0.0" - "@octokit/request-error": "npm:^3.0.0" - "@octokit/types": "npm:^9.0.0" - is-plain-object: "npm:^5.0.0" - node-fetch: "npm:^2.6.7" - universal-user-agent: "npm:^6.0.0" - checksum: 6b6079ed45bac44c4579b40990bfd1905b03d4bc4e5255f3d5a10cf5182171578ebe19abeab32ebb11a806f1131947f2a06b7a077bd7e77ade7b15fe2882174b - languageName: node - linkType: hard - "@octokit/request@npm:^8.0.1, @octokit/request@npm:^8.0.2": version: 8.1.5 resolution: "@octokit/request@npm:8.1.5" @@ -3381,13 +3255,6 @@ __metadata: languageName: node linkType: hard -"@octokit/tsconfig@npm:^1.0.2": - version: 1.0.2 - resolution: "@octokit/tsconfig@npm:1.0.2" - checksum: 84db70b495beeed69259dd4def14cdfb600edeb65ef32811558c99413ee2b414ed10bff9c4dcc7a43451d0fd36b4925ada9ef7d4272b5eae38cb005cc2f459ac - languageName: node - linkType: hard - "@octokit/types@npm:^12.0.0, @octokit/types@npm:^12.2.0": version: 12.2.0 resolution: "@octokit/types@npm:12.2.0" @@ -3397,15 +3264,6 @@ __metadata: languageName: node linkType: hard -"@octokit/types@npm:^9.0.0, @octokit/types@npm:^9.2.3": - version: 9.3.2 - resolution: "@octokit/types@npm:9.3.2" - dependencies: - "@octokit/openapi-types": "npm:^18.0.0" - checksum: 2925479aa378a4491762b4fcf381bdc7daca39b4e0b2dd7062bce5d74a32ed7d79d20d3c65ceaca6d105cf4b1f7417fea634219bf90f79a57d03e2dac629ec45 - languageName: node - linkType: hard - "@open-web3/api-mobx@npm:^1.1.4": version: 1.1.4 resolution: "@open-web3/api-mobx@npm:1.1.4" @@ -3450,6 +3308,151 @@ __metadata: languageName: node linkType: hard +"@parcel/watcher-android-arm64@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-android-arm64@npm:2.3.0" + conditions: os=android & cpu=arm64 + languageName: node + linkType: hard + +"@parcel/watcher-darwin-arm64@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-darwin-arm64@npm:2.3.0" + conditions: os=darwin & cpu=arm64 + languageName: node + linkType: hard + +"@parcel/watcher-darwin-x64@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-darwin-x64@npm:2.3.0" + conditions: os=darwin & cpu=x64 + languageName: node + linkType: hard + +"@parcel/watcher-freebsd-x64@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-freebsd-x64@npm:2.3.0" + conditions: os=freebsd & cpu=x64 + languageName: node + linkType: hard + +"@parcel/watcher-linux-arm-glibc@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-linux-arm-glibc@npm:2.3.0" + conditions: os=linux & cpu=arm & libc=glibc + languageName: node + linkType: hard + +"@parcel/watcher-linux-arm64-glibc@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-linux-arm64-glibc@npm:2.3.0" + conditions: os=linux & cpu=arm64 & libc=glibc + languageName: node + linkType: hard + +"@parcel/watcher-linux-arm64-musl@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-linux-arm64-musl@npm:2.3.0" + conditions: os=linux & cpu=arm64 & libc=musl + languageName: node + linkType: hard + +"@parcel/watcher-linux-x64-glibc@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-linux-x64-glibc@npm:2.3.0" + conditions: os=linux & cpu=x64 & libc=glibc + languageName: node + linkType: hard + +"@parcel/watcher-linux-x64-musl@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-linux-x64-musl@npm:2.3.0" + conditions: os=linux & cpu=x64 & libc=musl + languageName: node + linkType: hard + +"@parcel/watcher-wasm@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-wasm@npm:2.3.0" + dependencies: + is-glob: "npm:^4.0.3" + micromatch: "npm:^4.0.5" + napi-wasm: "npm:^1.1.0" + checksum: 7f38b50d3b9d42a3ea4590889f586bc32ad0d7fecc4b6133d2c49f9a3c5abfee18a8a22a0c5a82e446de4e1e3d97e51e318bd911720672913da4e9ae5eff7915 + languageName: node + linkType: hard + +"@parcel/watcher-win32-arm64@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-win32-arm64@npm:2.3.0" + conditions: os=win32 & cpu=arm64 + languageName: node + linkType: hard + +"@parcel/watcher-win32-ia32@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-win32-ia32@npm:2.3.0" + conditions: os=win32 & cpu=ia32 + languageName: node + linkType: hard + +"@parcel/watcher-win32-x64@npm:2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher-win32-x64@npm:2.3.0" + conditions: os=win32 & cpu=x64 + languageName: node + linkType: hard + +"@parcel/watcher@npm:^2.3.0": + version: 2.3.0 + resolution: "@parcel/watcher@npm:2.3.0" + dependencies: + "@parcel/watcher-android-arm64": "npm:2.3.0" + "@parcel/watcher-darwin-arm64": "npm:2.3.0" + "@parcel/watcher-darwin-x64": "npm:2.3.0" + "@parcel/watcher-freebsd-x64": "npm:2.3.0" + "@parcel/watcher-linux-arm-glibc": "npm:2.3.0" + "@parcel/watcher-linux-arm64-glibc": "npm:2.3.0" + "@parcel/watcher-linux-arm64-musl": "npm:2.3.0" + "@parcel/watcher-linux-x64-glibc": "npm:2.3.0" + "@parcel/watcher-linux-x64-musl": "npm:2.3.0" + "@parcel/watcher-win32-arm64": "npm:2.3.0" + "@parcel/watcher-win32-ia32": "npm:2.3.0" + "@parcel/watcher-win32-x64": "npm:2.3.0" + detect-libc: "npm:^1.0.3" + is-glob: "npm:^4.0.3" + micromatch: "npm:^4.0.5" + node-addon-api: "npm:^7.0.0" + node-gyp: "npm:latest" + dependenciesMeta: + "@parcel/watcher-android-arm64": + optional: true + "@parcel/watcher-darwin-arm64": + optional: true + "@parcel/watcher-darwin-x64": + optional: true + "@parcel/watcher-freebsd-x64": + optional: true + "@parcel/watcher-linux-arm-glibc": + optional: true + "@parcel/watcher-linux-arm64-glibc": + optional: true + "@parcel/watcher-linux-arm64-musl": + optional: true + "@parcel/watcher-linux-x64-glibc": + optional: true + "@parcel/watcher-linux-x64-musl": + optional: true + "@parcel/watcher-win32-arm64": + optional: true + "@parcel/watcher-win32-ia32": + optional: true + "@parcel/watcher-win32-x64": + optional: true + checksum: f223a6d5c56071c5f466725b93a83d0066ef01837fdae12ce86c9127586ad8138fe52f18de18c2752e3d8ca350b582ea4b55d16a51bd0584428d20698ace17a0 + languageName: node + linkType: hard + "@peculiar/asn1-schema@npm:^2.3.6": version: 2.3.8 resolution: "@peculiar/asn1-schema@npm:2.3.8" @@ -3495,9 +3498,9 @@ __metadata: languageName: node linkType: hard -"@pendulum-chain/api-solang@npm:^0.0.6": - version: 0.0.6 - resolution: "@pendulum-chain/api-solang@npm:0.0.6" +"@pendulum-chain/api-solang@npm:~0.1.1": + version: 0.1.1 + resolution: "@pendulum-chain/api-solang@npm:0.1.1" peerDependencies: "@polkadot/api": ^10.9.1 "@polkadot/api-contract": ^10.9.1 @@ -3506,7 +3509,7 @@ __metadata: "@polkadot/types-codec": ^10.9.1 "@polkadot/util": ^12.3.2 "@polkadot/util-crypto": ^12.3.2 - checksum: 2c2d2b9d6360e9b867f0d3ae902ebb55d57780d9529306259fd6590aae70dfcd2d89aca7233412b93c7b1238d9557bf369ff8e2537cf724a0813cb381754d00a + checksum: 18e9502374c4ca35e79ac13f97bf450cbd7b372d9238906b5bf91fba50839cf9a10a4af6a00532468405f0a5eae9801d91eca0ec3db078c5f686d6717c47afd9 languageName: node linkType: hard @@ -3560,7 +3563,7 @@ __metadata: languageName: node linkType: hard -"@pendulum-chain/types@npm:^0.2.3": +"@pendulum-chain/types@npm:^0.2.4": version: 0.2.4 resolution: "@pendulum-chain/types@npm:0.2.4" dependencies: @@ -4586,7 +4589,7 @@ __metadata: languageName: node linkType: hard -"@semantic-release/commit-analyzer@npm:^11.1.0": +"@semantic-release/commit-analyzer@npm:^11.0.0, @semantic-release/commit-analyzer@npm:^11.1.0": version: 11.1.0 resolution: "@semantic-release/commit-analyzer@npm:11.1.0" dependencies: @@ -4603,23 +4606,6 @@ __metadata: languageName: node linkType: hard -"@semantic-release/commit-analyzer@npm:^9.0.2": - version: 9.0.2 - resolution: "@semantic-release/commit-analyzer@npm:9.0.2" - dependencies: - conventional-changelog-angular: "npm:^5.0.0" - conventional-commits-filter: "npm:^2.0.0" - conventional-commits-parser: "npm:^3.2.3" - debug: "npm:^4.0.0" - import-from: "npm:^4.0.0" - lodash: "npm:^4.17.4" - micromatch: "npm:^4.0.2" - peerDependencies: - semantic-release: ">=18.0.0-beta.1" - checksum: bcb50712d1b13e9439e08046817e3a3b22e015754df44c55cf88334d8c3922455cb50d0c9b06896bdc2282ab0e95d132d04a48583a835cecf7457a9d39776f01 - languageName: node - linkType: hard - "@semantic-release/error@npm:^3.0.0": version: 3.0.0 resolution: "@semantic-release/error@npm:3.0.0" @@ -4652,36 +4638,9 @@ __metadata: languageName: node linkType: hard -"@semantic-release/github@npm:^8.0.0": - version: 8.1.0 - resolution: "@semantic-release/github@npm:8.1.0" - dependencies: - "@octokit/core": "npm:^4.2.1" - "@octokit/plugin-paginate-rest": "npm:^6.1.2" - "@octokit/plugin-retry": "npm:^4.1.3" - "@octokit/plugin-throttling": "npm:^5.2.3" - "@semantic-release/error": "npm:^3.0.0" - aggregate-error: "npm:^3.0.0" - debug: "npm:^4.0.0" - dir-glob: "npm:^3.0.0" - fs-extra: "npm:^11.0.0" - globby: "npm:^11.0.0" - http-proxy-agent: "npm:^7.0.0" - https-proxy-agent: "npm:^7.0.0" - issue-parser: "npm:^6.0.0" - lodash: "npm:^4.17.4" - mime: "npm:^3.0.0" - p-filter: "npm:^2.0.0" - url-join: "npm:^4.0.0" - peerDependencies: - semantic-release: ">=18.0.0-beta.1" - checksum: 2a1bb1e7eb04c7a7dfcb6bd95c36371c71a80c158515f4e2ef946e31a4c698818150c1ac6cdaf63704fe6c91586ad5b5b28e7dc58ababe8c255418e0cea1c492 - languageName: node - linkType: hard - -"@semantic-release/github@npm:^9.2.4": - version: 9.2.4 - resolution: "@semantic-release/github@npm:9.2.4" +"@semantic-release/github@npm:^9.0.0, @semantic-release/github@npm:^9.2.6": + version: 9.2.6 + resolution: "@semantic-release/github@npm:9.2.6" dependencies: "@octokit/core": "npm:^5.0.0" "@octokit/plugin-paginate-rest": "npm:^9.0.0" @@ -4697,17 +4656,17 @@ __metadata: issue-parser: "npm:^6.0.0" lodash-es: "npm:^4.17.21" mime: "npm:^4.0.0" - p-filter: "npm:^3.0.0" + p-filter: "npm:^4.0.0" url-join: "npm:^5.0.0" peerDependencies: semantic-release: ">=20.1.0" - checksum: 3a2dde2556c9efe8728db42c8cf178149e152e7bfb888b005d6821f4b267e2e66ecd5e809d507d454b416136ccd953af7c57db11856b41763015281f29b19aad + checksum: 1fd4777d70139c4bf05b59c8585f42df0900f1d257ca532992b317e3876df0855443b65edd9eb8cb9f08affad8a08503c7e616a712507b8310ec5c6aa47c23f7 languageName: node linkType: hard -"@semantic-release/npm@npm:^11.0.1": - version: 11.0.1 - resolution: "@semantic-release/npm@npm:11.0.1" +"@semantic-release/npm@npm:^11.0.0": + version: 11.0.2 + resolution: "@semantic-release/npm@npm:11.0.2" dependencies: "@semantic-release/error": "npm:^4.0.0" aggregate-error: "npm:^5.0.0" @@ -4724,54 +4683,34 @@ __metadata: tempy: "npm:^3.0.0" peerDependencies: semantic-release: ">=20.1.0" - checksum: 62b37a80cc79af1b608e3982da0f4972b3fd97ca24af4ed528e7b316bf5f3bd22a5f74677cd38f354a02127c3df887d3207f12de821e935067aa2a927530797a + checksum: ffd29adf44b051c1e0973b7fc5b99996ae4c5f2dd80079d50787eb1a4cdbbbd4c5b609c7b00dab4c566678ed2c620118014044f5e2f5b19c9d7d6961dfd57bc4 languageName: node linkType: hard -"@semantic-release/npm@npm:^9.0.0": - version: 9.0.2 - resolution: "@semantic-release/npm@npm:9.0.2" +"@semantic-release/npm@npm:^11.0.1": + version: 11.0.1 + resolution: "@semantic-release/npm@npm:11.0.1" dependencies: - "@semantic-release/error": "npm:^3.0.0" - aggregate-error: "npm:^3.0.0" - execa: "npm:^5.0.0" + "@semantic-release/error": "npm:^4.0.0" + aggregate-error: "npm:^5.0.0" + execa: "npm:^8.0.0" fs-extra: "npm:^11.0.0" - lodash: "npm:^4.17.15" + lodash-es: "npm:^4.17.21" nerf-dart: "npm:^1.0.0" - normalize-url: "npm:^6.0.0" - npm: "npm:^8.3.0" + normalize-url: "npm:^8.0.0" + npm: "npm:^10.0.0" rc: "npm:^1.2.8" - read-pkg: "npm:^5.0.0" + read-pkg: "npm:^9.0.0" registry-auth-token: "npm:^5.0.0" semver: "npm:^7.1.2" - tempy: "npm:^1.0.0" - peerDependencies: - semantic-release: ">=19.0.0" - checksum: 4efa3b2b859d461b499f7800429e1a7986bd45f0a2a47cd1ce0b51f6e575984b25583444ffd7aa993a3cbc625b85df482917c94d1513b5e3a882cfdda56c6eef - languageName: node - linkType: hard - -"@semantic-release/release-notes-generator@npm:^10.0.0": - version: 10.0.3 - resolution: "@semantic-release/release-notes-generator@npm:10.0.3" - dependencies: - conventional-changelog-angular: "npm:^5.0.0" - conventional-changelog-writer: "npm:^5.0.0" - conventional-commits-filter: "npm:^2.0.0" - conventional-commits-parser: "npm:^3.2.3" - debug: "npm:^4.0.0" - get-stream: "npm:^6.0.0" - import-from: "npm:^4.0.0" - into-stream: "npm:^6.0.0" - lodash: "npm:^4.17.4" - read-pkg-up: "npm:^7.0.0" + tempy: "npm:^3.0.0" peerDependencies: - semantic-release: ">=18.0.0-beta.1" - checksum: bf1a5244d7df353afbb68cf0e5f1d40bd4e6472bd75bd0b0c7547a179bce14b6a9ef5529e5fdec5c15566e798acc91991e14914a3083bad828d17bd8d0c0e45b + semantic-release: ">=20.1.0" + checksum: 62b37a80cc79af1b608e3982da0f4972b3fd97ca24af4ed528e7b316bf5f3bd22a5f74677cd38f354a02127c3df887d3207f12de821e935067aa2a927530797a languageName: node linkType: hard -"@semantic-release/release-notes-generator@npm:^12.1.0": +"@semantic-release/release-notes-generator@npm:^12.0.0, @semantic-release/release-notes-generator@npm:^12.1.0": version: 12.1.0 resolution: "@semantic-release/release-notes-generator@npm:12.1.0" dependencies: @@ -4835,6 +4774,13 @@ __metadata: languageName: node linkType: hard +"@sindresorhus/is@npm:^4.6.0": + version: 4.6.0 + resolution: "@sindresorhus/is@npm:4.6.0" + checksum: 33b6fb1d0834ec8dd7689ddc0e2781c2bfd8b9c4e4bacbcb14111e0ae00621f2c264b8a7d36541799d74888b5dccdf422a891a5cb5a709ace26325eedc81e22e + languageName: node + linkType: hard + "@sindresorhus/merge-streams@npm:^1.0.0": version: 1.0.0 resolution: "@sindresorhus/merge-streams@npm:1.0.0" @@ -5178,22 +5124,22 @@ __metadata: languageName: node linkType: hard -"@tanstack/react-table@npm:^8.10.7": - version: 8.10.7 - resolution: "@tanstack/react-table@npm:8.10.7" +"@tanstack/react-table@npm:^8.11.2": + version: 8.11.2 + resolution: "@tanstack/react-table@npm:8.11.2" dependencies: - "@tanstack/table-core": "npm:8.10.7" + "@tanstack/table-core": "npm:8.11.2" peerDependencies: react: ">=16" react-dom: ">=16" - checksum: 2ddf6f90b06e7af069f16dbe5d0dc8c8afab3de88c25e33f6c297beaf2507c2e46fee1f746f7977d48bad2114909bba0016026fc2b6a85bcaee472cdafdc7ffd + checksum: a2e873beca3800add9852a610f82a84d0211b713c3ea3c66ad8cc1b5f87c03019a3982864c32740935782b1305bbbb95223025b82efc8eab2b2d989cc09499e0 languageName: node linkType: hard -"@tanstack/table-core@npm:8.10.7": - version: 8.10.7 - resolution: "@tanstack/table-core@npm:8.10.7" - checksum: 3f671484319094443bb2db86356f408d4246e22bebd7ad444edc919fef131899384c3a27261c5ee01fb18887bc9157c5a0d9db3e32aae940ce5416f6e58b038b +"@tanstack/table-core@npm:8.11.2": + version: 8.11.2 + resolution: "@tanstack/table-core@npm:8.11.2" + checksum: 2b06a431491971ea65ce7e96069266d639f5d57c04f799d9f17a6e277a333e2d43fda3ad11fc2ffa0b99dbd60b6becc77ec455327d45dc218b7246f66bd1bcef languageName: node linkType: hard @@ -5213,20 +5159,33 @@ __metadata: languageName: node linkType: hard -"@testing-library/jest-dom@npm:^5.16.5": - version: 5.17.0 - resolution: "@testing-library/jest-dom@npm:5.17.0" +"@testing-library/jest-dom@npm:*, @testing-library/jest-dom@npm:^6.1.6": + version: 6.1.6 + resolution: "@testing-library/jest-dom@npm:6.1.6" dependencies: - "@adobe/css-tools": "npm:^4.0.1" + "@adobe/css-tools": "npm:^4.3.2" "@babel/runtime": "npm:^7.9.2" - "@types/testing-library__jest-dom": "npm:^5.9.1" aria-query: "npm:^5.0.0" chalk: "npm:^3.0.0" css.escape: "npm:^1.5.1" dom-accessibility-api: "npm:^0.5.6" lodash: "npm:^4.17.15" redent: "npm:^3.0.0" - checksum: 24e09c5779ea44644945ec26f2e4e5f48aecfe57d469decf2317a3253a5db28d865c55ad0ea4818d8d1df7572a6486c45daa06fa09644a833a7dd84563881939 + peerDependencies: + "@jest/globals": ">= 28" + "@types/jest": ">= 28" + jest: ">= 28" + vitest: ">= 0.32" + peerDependenciesMeta: + "@jest/globals": + optional: true + "@types/jest": + optional: true + jest: + optional: true + vitest: + optional: true + checksum: f98f79f3e470517469c86947d0ff1bb83ac2e59fd2a29728ab306eca5fba63c948084ec06b7b531642e6002d1f0211d918c298c628f0d386c0ef63ba881c47ba languageName: node linkType: hard @@ -5394,7 +5353,7 @@ __metadata: languageName: node linkType: hard -"@types/big.js@npm:^6.1.6": +"@types/big.js@npm:^6.2.2": version: 6.2.2 resolution: "@types/big.js@npm:6.2.2" checksum: 8f8472dfc1ef61c492e6841e86f8b9b97e5b024136bf7964e582a6a80ba73d4dbfd6cc23ed3b9d8fea69c7f30834fffd1c88e7fb981811f5c6ca608380b5ad67 @@ -5460,13 +5419,13 @@ __metadata: languageName: node linkType: hard -"@types/jest@npm:*, @types/jest@npm:^29.4.0": - version: 29.5.8 - resolution: "@types/jest@npm:29.5.8" +"@types/jest@npm:^29.5.11": + version: 29.5.11 + resolution: "@types/jest@npm:29.5.11" dependencies: expect: "npm:^29.0.0" pretty-format: "npm:^29.0.0" - checksum: a28e7827ea7e1a2aace6a386868fa6b8402c162d6c71570aed2c29d3745ddc22ceef6899a20643071817905d3c57b670a7992fc8760bff65939351fd4dc481cf + checksum: 524a3394845214581278bf4d75055927261fbeac7e1a89cd621bd0636da37d265fe0a85eac58b5778758faad1cbd7c7c361dfc190c78ebde03a91cce33463261 languageName: node linkType: hard @@ -5488,7 +5447,7 @@ __metadata: languageName: node linkType: hard -"@types/json-schema@npm:^7.0.9": +"@types/json-schema@npm:^7.0.12, @types/json-schema@npm:^7.0.9": version: 7.0.15 resolution: "@types/json-schema@npm:7.0.15" checksum: a996a745e6c5d60292f36731dd41341339d4eeed8180bb09226e5c8d23759067692b1d88e5d91d72ee83dfc00d3aca8e7bd43ea120516c17922cbcb7c3e252db @@ -5502,24 +5461,17 @@ __metadata: languageName: node linkType: hard -"@types/lodash@npm:^4": - version: 4.14.201 - resolution: "@types/lodash@npm:4.14.201" - checksum: 14dc43787296c429433d7d034ed47c5ac24b92217056f80a0e6c990449120b9c9c1058918188945fb88353c0c8333c5c36dccc40c51edbd39b05d2169ab2e0ad - languageName: node - linkType: hard - -"@types/luxon@npm:^3.2.0": - version: 3.3.4 - resolution: "@types/luxon@npm:3.3.4" - checksum: d9ef0bdfa97cce2951107083ed0461ce92f0a12343d8853c44ae976ff153317fcfe76b3ada33abd820f1a124b6ce99e190183ba0267b239e18e5bcaf237e5bf9 +"@types/lodash@npm:^4.14.202": + version: 4.14.202 + resolution: "@types/lodash@npm:4.14.202" + checksum: 6064d43c8f454170841bd67c8266cc9069d9e570a72ca63f06bceb484cb4a3ee60c9c1f305c1b9e3a87826049fd41124b8ef265c4dd08b00f6766609c7fe9973 languageName: node linkType: hard -"@types/minimist@npm:^1.2.0": - version: 1.2.5 - resolution: "@types/minimist@npm:1.2.5" - checksum: 3f791258d8e99a1d7d0ca2bda1ca6ea5a94e5e7b8fc6cde84dd79b0552da6fb68ade750f0e17718f6587783c24254bbca0357648dd59dc3812c150305cabdc46 +"@types/luxon@npm:^3.3.7": + version: 3.3.7 + resolution: "@types/luxon@npm:3.3.7" + checksum: ff6ba3fd83636c23c077fea7b2841ad5365ae22872a250baef2a99885123f0d5e997cfbc1ac0afccf89c70ff24b1517b2cc0ebadb2bee27559c670574620bed1 languageName: node linkType: hard @@ -5542,16 +5494,16 @@ __metadata: languageName: node linkType: hard -"@types/node@npm:^18.14.1": - version: 18.18.12 - resolution: "@types/node@npm:18.18.12" +"@types/node@npm:^18.19.4": + version: 18.19.4 + resolution: "@types/node@npm:18.19.4" dependencies: undici-types: "npm:~5.26.4" - checksum: f7c4b95173f4014841d331da5b005ab613351d61498c8dca373cd4365b721a73fd1161e91c965c0f786132594b46e68c92dc1c92d657a7942816f2ea185ae1ba + checksum: e395bf591e79bd91c0819e7bee39c56e881399da2ca37fba5a59194ff28941fb8ed663c3fb4fba89465842720d916110dee9b774a3e4aecbe08b9e1ada4ab4fe languageName: node linkType: hard -"@types/normalize-package-data@npm:^2.4.0, @types/normalize-package-data@npm:^2.4.1, @types/normalize-package-data@npm:^2.4.3": +"@types/normalize-package-data@npm:^2.4.3": version: 2.4.4 resolution: "@types/normalize-package-data@npm:2.4.4" checksum: aef7bb9b015883d6f4119c423dd28c4bdc17b0e8a0ccf112c78b4fe0e91fbc4af7c6204b04bba0e199a57d2f3fbbd5b4a14bf8739bf9d2a39b2a0aad545e0f86 @@ -5590,7 +5542,7 @@ __metadata: languageName: node linkType: hard -"@types/react-table@npm:^7.7.12": +"@types/react-table@npm:^7.7.18": version: 7.7.18 resolution: "@types/react-table@npm:7.7.18" dependencies: @@ -5599,7 +5551,7 @@ __metadata: languageName: node linkType: hard -"@types/react@npm:*, @types/react@npm:^18.0.18, @types/react@npm:^18.0.28": +"@types/react@npm:*, @types/react@npm:^18.0.18": version: 18.2.37 resolution: "@types/react@npm:18.2.37" dependencies: @@ -5610,6 +5562,17 @@ __metadata: languageName: node linkType: hard +"@types/react@npm:^18.2.46": + version: 18.2.46 + resolution: "@types/react@npm:18.2.46" + dependencies: + "@types/prop-types": "npm:*" + "@types/scheduler": "npm:*" + csstype: "npm:^3.0.2" + checksum: 814cc67107e5e69501d65bfc371cc2c716665d2a3608d395a2f81e24c3a2875db28e2cad717dfb17017eabcffd1d68ee2c9e09ecaba3f7108d5b7fbb9888ebab + languageName: node + linkType: hard + "@types/scheduler@npm:*": version: 0.16.6 resolution: "@types/scheduler@npm:0.16.6" @@ -5624,6 +5587,13 @@ __metadata: languageName: node linkType: hard +"@types/semver@npm:^7.5.0": + version: 7.5.6 + resolution: "@types/semver@npm:7.5.6" + checksum: 196dc32db5f68cbcde2e6a42bb4aa5cbb100fa2b7bd9c8c82faaaf3e03fbe063e205dbb4f03c7cdf53da2edb70a0d34c9f2e601b54281b377eb8dc1743226acd + languageName: node + linkType: hard + "@types/stack-utils@npm:^2.0.0": version: 2.0.3 resolution: "@types/stack-utils@npm:2.0.3" @@ -5631,12 +5601,12 @@ __metadata: languageName: node linkType: hard -"@types/testing-library__jest-dom@npm:^5.14.5, @types/testing-library__jest-dom@npm:^5.9.1": - version: 5.14.9 - resolution: "@types/testing-library__jest-dom@npm:5.14.9" +"@types/testing-library__jest-dom@npm:^6.0.0": + version: 6.0.0 + resolution: "@types/testing-library__jest-dom@npm:6.0.0" dependencies: - "@types/jest": "npm:*" - checksum: 91f7b15e8813b515912c54da44464fb60ecf21162b7cae2272fcb3918074f4e1387dc2beca1f5041667e77b76b34253c39675ea4e0b3f28f102d8cc87fdba9fa + "@testing-library/jest-dom": "npm:*" + checksum: 824950dc82752ddb656fa7ca851bf454804332f7a7a8571231abfc3553902198c6b96de209bb3dd1f1a15ee6a269a1efa56866041f5692ee0129308772e658e0 languageName: node linkType: hard @@ -5695,44 +5665,46 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/eslint-plugin@npm:^5.53.0": - version: 5.62.0 - resolution: "@typescript-eslint/eslint-plugin@npm:5.62.0" +"@typescript-eslint/eslint-plugin@npm:^6.17.0": + version: 6.17.0 + resolution: "@typescript-eslint/eslint-plugin@npm:6.17.0" dependencies: - "@eslint-community/regexpp": "npm:^4.4.0" - "@typescript-eslint/scope-manager": "npm:5.62.0" - "@typescript-eslint/type-utils": "npm:5.62.0" - "@typescript-eslint/utils": "npm:5.62.0" + "@eslint-community/regexpp": "npm:^4.5.1" + "@typescript-eslint/scope-manager": "npm:6.17.0" + "@typescript-eslint/type-utils": "npm:6.17.0" + "@typescript-eslint/utils": "npm:6.17.0" + "@typescript-eslint/visitor-keys": "npm:6.17.0" debug: "npm:^4.3.4" graphemer: "npm:^1.4.0" - ignore: "npm:^5.2.0" - natural-compare-lite: "npm:^1.4.0" - semver: "npm:^7.3.7" - tsutils: "npm:^3.21.0" + ignore: "npm:^5.2.4" + natural-compare: "npm:^1.4.0" + semver: "npm:^7.5.4" + ts-api-utils: "npm:^1.0.1" peerDependencies: - "@typescript-eslint/parser": ^5.0.0 - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + "@typescript-eslint/parser": ^6.0.0 || ^6.0.0-alpha + eslint: ^7.0.0 || ^8.0.0 peerDependenciesMeta: typescript: optional: true - checksum: 3f40cb6bab5a2833c3544e4621b9fdacd8ea53420cadc1c63fac3b89cdf5c62be1e6b7bcf56976dede5db4c43830de298ced3db60b5494a3b961ca1b4bff9f2a + checksum: 44a3c914b72607b12925d07c04be97d325f8795f5d7de8501054a4405accc35b35eaa2aa93983c602d13e842503d49bdbf1f5af5c0a69d700351c005681dcd52 languageName: node linkType: hard -"@typescript-eslint/parser@npm:^5.53.0": - version: 5.62.0 - resolution: "@typescript-eslint/parser@npm:5.62.0" +"@typescript-eslint/parser@npm:^6.17.0": + version: 6.17.0 + resolution: "@typescript-eslint/parser@npm:6.17.0" dependencies: - "@typescript-eslint/scope-manager": "npm:5.62.0" - "@typescript-eslint/types": "npm:5.62.0" - "@typescript-eslint/typescript-estree": "npm:5.62.0" + "@typescript-eslint/scope-manager": "npm:6.17.0" + "@typescript-eslint/types": "npm:6.17.0" + "@typescript-eslint/typescript-estree": "npm:6.17.0" + "@typescript-eslint/visitor-keys": "npm:6.17.0" debug: "npm:^4.3.4" peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + eslint: ^7.0.0 || ^8.0.0 peerDependenciesMeta: typescript: optional: true - checksum: 315194b3bf39beb9bd16c190956c46beec64b8371e18d6bb72002108b250983eb1e186a01d34b77eb4045f4941acbb243b16155fbb46881105f65e37dc9e24d4 + checksum: 66b53159688083eb48259de5b4daf076f3de284ac3b4d2618bda3f7ab2d8ee27b01ae851b08e8487047e33ff3668424f17d677d66413164cb231f1519dcff82f languageName: node linkType: hard @@ -5746,20 +5718,30 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/type-utils@npm:5.62.0": - version: 5.62.0 - resolution: "@typescript-eslint/type-utils@npm:5.62.0" +"@typescript-eslint/scope-manager@npm:6.17.0": + version: 6.17.0 + resolution: "@typescript-eslint/scope-manager@npm:6.17.0" dependencies: - "@typescript-eslint/typescript-estree": "npm:5.62.0" - "@typescript-eslint/utils": "npm:5.62.0" + "@typescript-eslint/types": "npm:6.17.0" + "@typescript-eslint/visitor-keys": "npm:6.17.0" + checksum: b7ac7d9c39515c2a1b3844577fab967bf126ec25ccf28076240748b3f42d60ab3e64131bfffee61f66251bdf2d59e50e39f5cb0bee7987c85c49140c75d26b5f + languageName: node + linkType: hard + +"@typescript-eslint/type-utils@npm:6.17.0": + version: 6.17.0 + resolution: "@typescript-eslint/type-utils@npm:6.17.0" + dependencies: + "@typescript-eslint/typescript-estree": "npm:6.17.0" + "@typescript-eslint/utils": "npm:6.17.0" debug: "npm:^4.3.4" - tsutils: "npm:^3.21.0" + ts-api-utils: "npm:^1.0.1" peerDependencies: - eslint: "*" + eslint: ^7.0.0 || ^8.0.0 peerDependenciesMeta: typescript: optional: true - checksum: 93112e34026069a48f0484b98caca1c89d9707842afe14e08e7390af51cdde87378df29d213d3bbd10a7cfe6f91b228031b56218515ce077bdb62ddea9d9f474 + checksum: 15bc9ba2d7f12c3825eced4e5c2283616496e4bca57914c98e895af23d920f94e47e2081fb4fd59da13d274809e08667ae43a76a2f1494a7043c75f980f21114 languageName: node linkType: hard @@ -5770,6 +5752,13 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/types@npm:6.17.0": + version: 6.17.0 + resolution: "@typescript-eslint/types@npm:6.17.0" + checksum: c458d985b9ab4f369018536bcb88f0aedafb0c8c4b22ffd376e0c0c768a44e3956475c85ebeef40ae44238841c8df268893477b85873aa2621995c37e738e37e + languageName: node + linkType: hard + "@typescript-eslint/typescript-estree@npm:5.62.0": version: 5.62.0 resolution: "@typescript-eslint/typescript-estree@npm:5.62.0" @@ -5788,7 +5777,43 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/utils@npm:5.62.0, @typescript-eslint/utils@npm:^5.10.0": +"@typescript-eslint/typescript-estree@npm:6.17.0": + version: 6.17.0 + resolution: "@typescript-eslint/typescript-estree@npm:6.17.0" + dependencies: + "@typescript-eslint/types": "npm:6.17.0" + "@typescript-eslint/visitor-keys": "npm:6.17.0" + debug: "npm:^4.3.4" + globby: "npm:^11.1.0" + is-glob: "npm:^4.0.3" + minimatch: "npm:9.0.3" + semver: "npm:^7.5.4" + ts-api-utils: "npm:^1.0.1" + peerDependenciesMeta: + typescript: + optional: true + checksum: 5a858288bb05f45a2a45b04394115826ff19f85555144bfb67dc281d4e75fc3a1e1aceb3dee68022e86b91f199d1310c15bda3100a4890004b8e474d86afad51 + languageName: node + linkType: hard + +"@typescript-eslint/utils@npm:6.17.0": + version: 6.17.0 + resolution: "@typescript-eslint/utils@npm:6.17.0" + dependencies: + "@eslint-community/eslint-utils": "npm:^4.4.0" + "@types/json-schema": "npm:^7.0.12" + "@types/semver": "npm:^7.5.0" + "@typescript-eslint/scope-manager": "npm:6.17.0" + "@typescript-eslint/types": "npm:6.17.0" + "@typescript-eslint/typescript-estree": "npm:6.17.0" + semver: "npm:^7.5.4" + peerDependencies: + eslint: ^7.0.0 || ^8.0.0 + checksum: a85907c5fbe0a54944fff25df05bf5b8bbe524bb1907fb54c7c68135cf764aa45344e679965c17e235b328ad32e74b1357057c43035203ce874915c4687daa93 + languageName: node + linkType: hard + +"@typescript-eslint/utils@npm:^5.10.0": version: 5.62.0 resolution: "@typescript-eslint/utils@npm:5.62.0" dependencies: @@ -5816,34 +5841,45 @@ __metadata: languageName: node linkType: hard -"@ungap/structured-clone@npm:^1.2.0": - version: 1.2.0 - resolution: "@ungap/structured-clone@npm:1.2.0" +"@typescript-eslint/visitor-keys@npm:6.17.0": + version: 6.17.0 + resolution: "@typescript-eslint/visitor-keys@npm:6.17.0" + dependencies: + "@typescript-eslint/types": "npm:6.17.0" + eslint-visitor-keys: "npm:^3.4.1" + checksum: 75a48f5810c6a69bc1c082b07d2b840c40895807b1b4ecf9d3ab9eb783176eeb3e7b11eb89d652e8331da79d604f82300f315ffc21cd937819197a8601b48d1d + languageName: node + linkType: hard + +"@ungap/structured-clone@npm:^1.2.0": + version: 1.2.0 + resolution: "@ungap/structured-clone@npm:1.2.0" checksum: 8209c937cb39119f44eb63cf90c0b73e7c754209a6411c707be08e50e29ee81356dca1a848a405c8bdeebfe2f5e4f831ad310ae1689eeef65e7445c090c6657d languageName: node linkType: hard -"@walletconnect/core@npm:2.10.4": - version: 2.10.4 - resolution: "@walletconnect/core@npm:2.10.4" +"@walletconnect/core@npm:2.11.0": + version: 2.11.0 + resolution: "@walletconnect/core@npm:2.11.0" dependencies: "@walletconnect/heartbeat": "npm:1.2.1" "@walletconnect/jsonrpc-provider": "npm:1.0.13" "@walletconnect/jsonrpc-types": "npm:1.0.3" "@walletconnect/jsonrpc-utils": "npm:1.0.8" - "@walletconnect/jsonrpc-ws-connection": "npm:1.0.13" - "@walletconnect/keyvaluestorage": "npm:^1.0.2" + "@walletconnect/jsonrpc-ws-connection": "npm:1.0.14" + "@walletconnect/keyvaluestorage": "npm:^1.1.1" "@walletconnect/logger": "npm:^2.0.1" "@walletconnect/relay-api": "npm:^1.0.9" "@walletconnect/relay-auth": "npm:^1.0.4" "@walletconnect/safe-json": "npm:^1.0.2" "@walletconnect/time": "npm:^1.0.2" - "@walletconnect/types": "npm:2.10.4" - "@walletconnect/utils": "npm:2.10.4" + "@walletconnect/types": "npm:2.11.0" + "@walletconnect/utils": "npm:2.11.0" events: "npm:^3.3.0" + isomorphic-unfetch: "npm:3.1.0" lodash.isequal: "npm:4.5.0" uint8arrays: "npm:^3.1.0" - checksum: dea902800c813d7eff8025f0f0d50c69bc80ed71c5168eb0bcda22f59be32e1db5ce54439f5e4afc97debc47870136570b96e37bad8ed1567f0c480b2f7331a9 + checksum: 673a9f3127a69a03de8de9626365b157ad6ce272b9ee04d3f67802685861f9f3ee748686662122d27212223f66054c49f0bf392f97e2fd18fab74789d0a87246 languageName: node linkType: hard @@ -5921,34 +5957,31 @@ __metadata: languageName: node linkType: hard -"@walletconnect/jsonrpc-ws-connection@npm:1.0.13": - version: 1.0.13 - resolution: "@walletconnect/jsonrpc-ws-connection@npm:1.0.13" +"@walletconnect/jsonrpc-ws-connection@npm:1.0.14": + version: 1.0.14 + resolution: "@walletconnect/jsonrpc-ws-connection@npm:1.0.14" dependencies: "@walletconnect/jsonrpc-utils": "npm:^1.0.6" "@walletconnect/safe-json": "npm:^1.0.2" events: "npm:^3.3.0" - tslib: "npm:1.14.1" ws: "npm:^7.5.1" - checksum: afa2cd5647e97857f07a282d7466d3495e76abd0dfff46cd6fc36ca71c9f5a95ae1fae21fb7f0c49f881246d2b8a0e7dbc29f7fe58dbd34bd74fae9e6760c140 + checksum: a710ecc51f8d3ed819ba6d6e53151ef274473aa8746ffdeaffaa3d4c020405bc694b0d179649fc2510a556eb4daf02f4a9e3dacef69ff95f673939bd67be649e languageName: node linkType: hard -"@walletconnect/keyvaluestorage@npm:^1.0.2": - version: 1.0.2 - resolution: "@walletconnect/keyvaluestorage@npm:1.0.2" +"@walletconnect/keyvaluestorage@npm:^1.1.1": + version: 1.1.1 + resolution: "@walletconnect/keyvaluestorage@npm:1.1.1" dependencies: - safe-json-utils: "npm:^1.1.1" - tslib: "npm:1.14.1" + "@walletconnect/safe-json": "npm:^1.0.1" + idb-keyval: "npm:^6.2.1" + unstorage: "npm:^1.9.0" peerDependencies: "@react-native-async-storage/async-storage": 1.x - lokijs: 1.x peerDependenciesMeta: "@react-native-async-storage/async-storage": optional: true - lokijs: - optional: true - checksum: efe91137856f6c6f8cd3ac41241fef3554618eb034924edf095942bfda983c32496ea402e0e7074d4a1b7b4e358d762c779dc3fdf4233fc9f4b3ac2dc99f0c17 + checksum: de2ec39d09ce99370865f7d7235b93c42b3e4fd3406bdbc644329eff7faea2722618aa88ffc4ee7d20b1d6806a8331261b65568187494cbbcceeedbe79dc30e8 languageName: node linkType: hard @@ -5983,7 +6016,7 @@ __metadata: languageName: node linkType: hard -"@walletconnect/modal@npm:^2.4.7": +"@walletconnect/modal@npm:^2.6.2": version: 2.6.2 resolution: "@walletconnect/modal@npm:2.6.2" dependencies: @@ -6026,20 +6059,20 @@ __metadata: languageName: node linkType: hard -"@walletconnect/sign-client@npm:2.10.4": - version: 2.10.4 - resolution: "@walletconnect/sign-client@npm:2.10.4" +"@walletconnect/sign-client@npm:2.11.0": + version: 2.11.0 + resolution: "@walletconnect/sign-client@npm:2.11.0" dependencies: - "@walletconnect/core": "npm:2.10.4" + "@walletconnect/core": "npm:2.11.0" "@walletconnect/events": "npm:^1.0.1" "@walletconnect/heartbeat": "npm:1.2.1" "@walletconnect/jsonrpc-utils": "npm:1.0.8" "@walletconnect/logger": "npm:^2.0.1" "@walletconnect/time": "npm:^1.0.2" - "@walletconnect/types": "npm:2.10.4" - "@walletconnect/utils": "npm:2.10.4" + "@walletconnect/types": "npm:2.11.0" + "@walletconnect/utils": "npm:2.11.0" events: "npm:^3.3.0" - checksum: dbb21d119c467b8fd5fccfeac037bc0f3c7d32c664337368710ac15a3ffce8286a30dddf372c18fca1aebccfd1405fa21619507e265ec7ad7632cce2965ba193 + checksum: 92b8d66248b805849b70f35adc7f55bd7c9d6f35f5e980b1e90d71a86b008e43527b2dd8e47860d080cf296dcdf9ecfecb604b75ea0a1164c715dce4f66dadd0 languageName: node linkType: hard @@ -6052,40 +6085,40 @@ __metadata: languageName: node linkType: hard -"@walletconnect/types@npm:2.10.4": - version: 2.10.4 - resolution: "@walletconnect/types@npm:2.10.4" +"@walletconnect/types@npm:2.11.0": + version: 2.11.0 + resolution: "@walletconnect/types@npm:2.11.0" dependencies: "@walletconnect/events": "npm:^1.0.1" "@walletconnect/heartbeat": "npm:1.2.1" "@walletconnect/jsonrpc-types": "npm:1.0.3" - "@walletconnect/keyvaluestorage": "npm:^1.0.2" + "@walletconnect/keyvaluestorage": "npm:^1.1.1" "@walletconnect/logger": "npm:^2.0.1" events: "npm:^3.3.0" - checksum: 13a8a827aa3a1a62c467f4004fc569eae4e52cc4146dd015e5c795c5d9f4dcfea7bebba1ecddb888611c487f053523d4c8149c9f22d49997304ebf8de4e0ef00 + checksum: 7fa2493d8a9c938821f5234b4d2a087f903359875925a7abea3a0640aa765886c01b4846bbe5e39923b48883f7fd92c3f4ff8e643c4c894c50e9f715b3a881d8 languageName: node linkType: hard -"@walletconnect/universal-provider@npm:^2.8.1": - version: 2.10.4 - resolution: "@walletconnect/universal-provider@npm:2.10.4" +"@walletconnect/universal-provider@npm:^2.11.0": + version: 2.11.0 + resolution: "@walletconnect/universal-provider@npm:2.11.0" dependencies: "@walletconnect/jsonrpc-http-connection": "npm:^1.0.7" "@walletconnect/jsonrpc-provider": "npm:1.0.13" "@walletconnect/jsonrpc-types": "npm:^1.0.2" "@walletconnect/jsonrpc-utils": "npm:^1.0.7" "@walletconnect/logger": "npm:^2.0.1" - "@walletconnect/sign-client": "npm:2.10.4" - "@walletconnect/types": "npm:2.10.4" - "@walletconnect/utils": "npm:2.10.4" + "@walletconnect/sign-client": "npm:2.11.0" + "@walletconnect/types": "npm:2.11.0" + "@walletconnect/utils": "npm:2.11.0" events: "npm:^3.3.0" - checksum: 3a263900df2935640319d1f86e40a54dbb0485c1405fe39fdb66db34e043cc5d528e6c90c58cfa6bd4165a99baa7ea755347581e797c9f10bc1a58815599e2da + checksum: 78a3a16ef7a539caae0796745d80b211a918570bb2476ae064a56537e6aa1d038f53ed86588afd7f62cb833b2c690d9da3fee859a4a1926a79df79dd1f5176a9 languageName: node linkType: hard -"@walletconnect/utils@npm:2.10.4": - version: 2.10.4 - resolution: "@walletconnect/utils@npm:2.10.4" +"@walletconnect/utils@npm:2.11.0": + version: 2.11.0 + resolution: "@walletconnect/utils@npm:2.11.0" dependencies: "@stablelib/chacha20poly1305": "npm:1.0.1" "@stablelib/hkdf": "npm:1.0.1" @@ -6095,13 +6128,13 @@ __metadata: "@walletconnect/relay-api": "npm:^1.0.9" "@walletconnect/safe-json": "npm:^1.0.2" "@walletconnect/time": "npm:^1.0.2" - "@walletconnect/types": "npm:2.10.4" + "@walletconnect/types": "npm:2.11.0" "@walletconnect/window-getters": "npm:^1.0.1" "@walletconnect/window-metadata": "npm:^1.0.1" detect-browser: "npm:5.3.0" query-string: "npm:7.1.3" uint8arrays: "npm:^3.1.0" - checksum: 0e8eab15294d256e6ab26fd7160a77c0ff0de13d918ecc4bb69caa866621cce4ba7428cbc624a1de063ee404bb72ab35569880d626597954da57220bfb9cbe3e + checksum: 2219408f2a9bbca8d263a89dd54ae3e466f6d4b32b6b25f253d7f84f7e58c5836f4a08ab287c2d9ab5446c727624821597fa16d64d8c5ca748f8e1cba729a929 languageName: node linkType: hard @@ -6187,7 +6220,7 @@ __metadata: languageName: node linkType: hard -"JSONStream@npm:^1.0.4, JSONStream@npm:^1.3.5": +"JSONStream@npm:^1.3.5": version: 1.3.5 resolution: "JSONStream@npm:1.3.5" dependencies: @@ -6206,13 +6239,6 @@ __metadata: languageName: node linkType: hard -"abbrev@npm:^1.0.0, abbrev@npm:~1.1.1": - version: 1.1.1 - resolution: "abbrev@npm:1.1.1" - checksum: 3f762677702acb24f65e813070e306c61fafe25d4b2583f9dfc935131f774863f3addd5741572ed576bd69cabe473c5af18e1e108b829cb7b6b4747884f726e6 - languageName: node - linkType: hard - "abbrev@npm:^2.0.0": version: 2.0.0 resolution: "abbrev@npm:2.0.0" @@ -6264,7 +6290,16 @@ __metadata: languageName: node linkType: hard -"agent-base@npm:6, agent-base@npm:^6.0.2": +"acorn@npm:^8.10.0": + version: 8.11.3 + resolution: "acorn@npm:8.11.3" + bin: + acorn: bin/acorn + checksum: 3ff155f8812e4a746fee8ecff1f227d527c4c45655bb1fad6347c3cb58e46190598217551b1500f18542d2bbe5c87120cb6927f5a074a59166fbdd9468f0a299 + languageName: node + linkType: hard + +"agent-base@npm:6": version: 6.0.2 resolution: "agent-base@npm:6.0.2" dependencies: @@ -6282,15 +6317,6 @@ __metadata: languageName: node linkType: hard -"agentkeepalive@npm:^4.2.1": - version: 4.5.0 - resolution: "agentkeepalive@npm:4.5.0" - dependencies: - humanize-ms: "npm:^1.2.1" - checksum: 394ea19f9710f230722996e156607f48fdf3a345133b0b1823244b7989426c16019a428b56c82d3eabef616e938812981d9009f4792ecc66bd6a59e991c62612 - languageName: node - linkType: hard - "aggregate-error@npm:^3.0.0": version: 3.1.0 resolution: "aggregate-error@npm:3.1.0" @@ -6301,16 +6327,6 @@ __metadata: languageName: node linkType: hard -"aggregate-error@npm:^4.0.0, aggregate-error@npm:^4.0.1": - version: 4.0.1 - resolution: "aggregate-error@npm:4.0.1" - dependencies: - clean-stack: "npm:^4.0.0" - indent-string: "npm:^5.0.0" - checksum: 75fd739f5c4c60a667cce35ccaf0edf135e147ef0be9a029cab75de14ac9421779b15339d562e58d25b233ea0ef2bbd4c916f149fdbcb73c2b9a62209e611343 - languageName: node - linkType: hard - "aggregate-error@npm:^5.0.0": version: 5.0.0 resolution: "aggregate-error@npm:5.0.0" @@ -6411,7 +6427,7 @@ __metadata: languageName: node linkType: hard -"anymatch@npm:^3.0.3, anymatch@npm:~3.1.2": +"anymatch@npm:^3.0.3, anymatch@npm:^3.1.3, anymatch@npm:~3.1.2": version: 3.1.3 resolution: "anymatch@npm:3.1.3" dependencies: @@ -6428,6 +6444,13 @@ __metadata: languageName: node linkType: hard +"arch@npm:^2.2.0": + version: 2.2.0 + resolution: "arch@npm:2.2.0" + checksum: 4ceaf8d8207817c216ebc4469742052cb0a097bc45d9b7fcd60b7507220da545a28562ab5bdd4dfe87921bb56371a0805da4e10d704e01f93a15f83240f1284c + languageName: node + linkType: hard + "archy@npm:~1.0.0": version: 1.0.0 resolution: "archy@npm:1.0.0" @@ -6435,16 +6458,6 @@ __metadata: languageName: node linkType: hard -"are-we-there-yet@npm:^3.0.0": - version: 3.0.1 - resolution: "are-we-there-yet@npm:3.0.1" - dependencies: - delegates: "npm:^1.0.0" - readable-stream: "npm:^3.6.0" - checksum: 8373f289ba42e4b5ec713bb585acdac14b5702c75f2a458dc985b9e4fa5762bc5b46b40a21b72418a3ed0cfb5e35bdc317ef1ae132f3035f633d581dd03168c3 - languageName: node - linkType: hard - "are-we-there-yet@npm:^4.0.0": version: 4.0.1 resolution: "are-we-there-yet@npm:4.0.1" @@ -6599,14 +6612,7 @@ __metadata: languageName: node linkType: hard -"arrify@npm:^1.0.1": - version: 1.0.1 - resolution: "arrify@npm:1.0.1" - checksum: c35c8d1a81bcd5474c0c57fe3f4bad1a4d46a5fa353cedcff7a54da315df60db71829e69104b859dff96c5d68af46bd2be259fe5e50dc6aa9df3b36bea0383ab - languageName: node - linkType: hard - -"asap@npm:^2.0.0, asap@npm:~2.0.3": +"asap@npm:~2.0.3": version: 2.0.6 resolution: "asap@npm:2.0.6" checksum: c6d5e39fe1f15e4b87677460bd66b66050cd14c772269cee6688824c1410a08ab20254bb6784f9afb75af9144a9f9a7692d49547f4d19d715aeb7c0318f3136d @@ -6661,7 +6667,7 @@ __metadata: languageName: node linkType: hard -"autoprefixer@npm:^10.4.13": +"autoprefixer@npm:^10.4.16": version: 10.4.16 resolution: "autoprefixer@npm:10.4.16" dependencies: @@ -6737,39 +6743,39 @@ __metadata: languageName: node linkType: hard -"babel-plugin-polyfill-corejs2@npm:^0.4.6": - version: 0.4.6 - resolution: "babel-plugin-polyfill-corejs2@npm:0.4.6" +"babel-plugin-polyfill-corejs2@npm:^0.4.7": + version: 0.4.7 + resolution: "babel-plugin-polyfill-corejs2@npm:0.4.7" dependencies: "@babel/compat-data": "npm:^7.22.6" - "@babel/helper-define-polyfill-provider": "npm:^0.4.3" + "@babel/helper-define-polyfill-provider": "npm:^0.4.4" semver: "npm:^6.3.1" peerDependencies: "@babel/core": ^7.4.0 || ^8.0.0-0 <8.0.0 - checksum: 64a98811f343492aa6970ab253760194e389c0417e5b830522f944009c1f0c78e1251975fd1b9869cd48cc4623111b20a3389cf6732a1d10ba0d19de6fa5114f + checksum: f80f7284ec72c63e7dd751e0bdf25e9978df195a79e0887470603bfdea13ee518d62573cf360bb1bc01b80819e54915dd5edce9cff14c52d0af5f984aa3d36a3 languageName: node linkType: hard -"babel-plugin-polyfill-corejs3@npm:^0.8.5": - version: 0.8.6 - resolution: "babel-plugin-polyfill-corejs3@npm:0.8.6" +"babel-plugin-polyfill-corejs3@npm:^0.8.7": + version: 0.8.7 + resolution: "babel-plugin-polyfill-corejs3@npm:0.8.7" dependencies: - "@babel/helper-define-polyfill-provider": "npm:^0.4.3" + "@babel/helper-define-polyfill-provider": "npm:^0.4.4" core-js-compat: "npm:^3.33.1" peerDependencies: "@babel/core": ^7.4.0 || ^8.0.0-0 <8.0.0 - checksum: 97d974c1dfbefdf27866e21a1ac757f6ab1626379b544d6f8ddb05f7bfa02173f8347b6140295b0f770394549f9321775d3048e466a9a02b99b88ad5f0346858 + checksum: 094e40f4ab9f131408202063964d63740609fd4fdb70a5b6332b371761921b540ffbcee7a434c0199b8317dfb2ba4675eef674867215fd3b85e24054607c1501 languageName: node linkType: hard -"babel-plugin-polyfill-regenerator@npm:^0.5.3": - version: 0.5.3 - resolution: "babel-plugin-polyfill-regenerator@npm:0.5.3" +"babel-plugin-polyfill-regenerator@npm:^0.5.4": + version: 0.5.4 + resolution: "babel-plugin-polyfill-regenerator@npm:0.5.4" dependencies: - "@babel/helper-define-polyfill-provider": "npm:^0.4.3" + "@babel/helper-define-polyfill-provider": "npm:^0.4.4" peerDependencies: "@babel/core": ^7.4.0 || ^8.0.0-0 <8.0.0 - checksum: cc32313b9ebbf1d7bedc33524a861136b9e5d3b6e9be317ac360a1c2a59ae5ed1b465a6c68b2715cdefb089780ddfb0c11f4a148e49827a947beee76e43da598 + checksum: 0b903f5fe2f8c487b4260935dfe60bd9a95bcaee7ae63958f063045093b16d4e8288c232199d411261300aa21f6b106a3cb83c42cc996de013b337f5825a79fe languageName: node linkType: hard @@ -6909,20 +6915,6 @@ __metadata: languageName: node linkType: hard -"bin-links@npm:^3.0.3": - version: 3.0.3 - resolution: "bin-links@npm:3.0.3" - dependencies: - cmd-shim: "npm:^5.0.0" - mkdirp-infer-owner: "npm:^2.0.0" - npm-normalize-package-bin: "npm:^2.0.0" - read-cmd-shim: "npm:^3.0.0" - rimraf: "npm:^3.0.0" - write-file-atomic: "npm:^4.0.0" - checksum: a7f3ea8663213d14134695b42f66994e11f00f0519617537d80cee3b78b7cbb5a627c0d3aafd9d8c748eee9b1af03dbdddedfbf18be738b50a4c11bdd739a160 - languageName: node - linkType: hard - "bin-links@npm:^4.0.1": version: 4.0.3 resolution: "bin-links@npm:4.0.3" @@ -7016,6 +7008,20 @@ __metadata: languageName: node linkType: hard +"browserslist@npm:^4.22.2": + version: 4.22.2 + resolution: "browserslist@npm:4.22.2" + dependencies: + caniuse-lite: "npm:^1.0.30001565" + electron-to-chromium: "npm:^1.4.601" + node-releases: "npm:^2.0.14" + update-browserslist-db: "npm:^1.0.13" + bin: + browserslist: cli.js + checksum: 2a331aab90503130043ca41dd5d281fa1e89d5e076d07a2d75e76bf4d693bd56e73d5abcd8c4f39119da6328d450578c216cf1cd5c99b82d8a90a2ae6271b465 + languageName: node + linkType: hard + "bs58@npm:^5.0.0": version: 5.0.0 resolution: "bs58@npm:5.0.0" @@ -7089,32 +7095,6 @@ __metadata: languageName: node linkType: hard -"cacache@npm:^16.0.0, cacache@npm:^16.1.0, cacache@npm:^16.1.3": - version: 16.1.3 - resolution: "cacache@npm:16.1.3" - dependencies: - "@npmcli/fs": "npm:^2.1.0" - "@npmcli/move-file": "npm:^2.0.0" - chownr: "npm:^2.0.0" - fs-minipass: "npm:^2.1.0" - glob: "npm:^8.0.1" - infer-owner: "npm:^1.0.4" - lru-cache: "npm:^7.7.1" - minipass: "npm:^3.1.6" - minipass-collect: "npm:^1.0.2" - minipass-flush: "npm:^1.0.5" - minipass-pipeline: "npm:^1.2.4" - mkdirp: "npm:^1.0.4" - p-map: "npm:^4.0.0" - promise-inflight: "npm:^1.0.1" - rimraf: "npm:^3.0.2" - ssri: "npm:^9.0.0" - tar: "npm:^6.1.11" - unique-filename: "npm:^2.0.0" - checksum: cdf6836e1c457d2a5616abcaf5d8240c0346b1f5bd6fdb8866b9d84b6dff0b54e973226dc11e0d099f35394213d24860d1989c8358d2a41b39eb912b3000e749 - languageName: node - linkType: hard - "cacache@npm:^18.0.0": version: 18.0.0 resolution: "cacache@npm:18.0.0" @@ -7170,17 +7150,6 @@ __metadata: languageName: node linkType: hard -"camelcase-keys@npm:^6.2.2": - version: 6.2.2 - resolution: "camelcase-keys@npm:6.2.2" - dependencies: - camelcase: "npm:^5.3.1" - map-obj: "npm:^4.0.0" - quick-lru: "npm:^4.0.1" - checksum: bf1a28348c0f285c6c6f68fb98a9d088d3c0269fed0cdff3ea680d5a42df8a067b4de374e7a33e619eb9d5266a448fe66c2dd1f8e0c9209ebc348632882a3526 - languageName: node - linkType: hard - "camelcase@npm:^5.0.0, camelcase@npm:^5.3.1": version: 5.3.1 resolution: "camelcase@npm:5.3.1" @@ -7221,6 +7190,13 @@ __metadata: languageName: node linkType: hard +"caniuse-lite@npm:^1.0.30001565": + version: 1.0.30001572 + resolution: "caniuse-lite@npm:1.0.30001572" + checksum: 7d02570fa576b158d96739f2c65ea3ad22e90a8b028a343902de1f13b7db8512144870f1d29ec5e9ae7189d96158d9643871b6e902e6680a06b27a9afe556da2 + languageName: node + linkType: hard + "capital-case@npm:^1.0.4": version: 1.0.4 resolution: "capital-case@npm:1.0.4" @@ -7265,7 +7241,7 @@ __metadata: languageName: node linkType: hard -"chalk@npm:^4.0.0, chalk@npm:^4.1.0, chalk@npm:^4.1.1, chalk@npm:^4.1.2": +"chalk@npm:^4.0.0, chalk@npm:^4.1.0, chalk@npm:^4.1.1": version: 4.1.2 resolution: "chalk@npm:4.1.2" dependencies: @@ -7275,7 +7251,7 @@ __metadata: languageName: node linkType: hard -"chalk@npm:^5.2.0, chalk@npm:^5.3.0": +"chalk@npm:^5.3.0": version: 5.3.0 resolution: "chalk@npm:5.3.0" checksum: 8297d436b2c0f95801103ff2ef67268d362021b8210daf8ddbe349695333eb3610a71122172ff3b0272f1ef2cf7cc2c41fdaa4715f52e49ffe04c56340feed09 @@ -7376,6 +7352,15 @@ __metadata: languageName: node linkType: hard +"citty@npm:^0.1.4, citty@npm:^0.1.5": + version: 0.1.5 + resolution: "citty@npm:0.1.5" + dependencies: + consola: "npm:^3.2.3" + checksum: 58b5eea5f45f8711de7ddf4d0514d90e8c8b4ad16837e1c4e3f31224306baa638467acadad011d760abae4753b598402ed3651256bed063d02a76f949efa7b42 + languageName: node + linkType: hard + "cjs-module-lexer@npm:^1.0.0": version: 1.2.3 resolution: "cjs-module-lexer@npm:1.2.3" @@ -7390,15 +7375,6 @@ __metadata: languageName: node linkType: hard -"clean-stack@npm:^4.0.0": - version: 4.2.0 - resolution: "clean-stack@npm:4.2.0" - dependencies: - escape-string-regexp: "npm:5.0.0" - checksum: 2bdf981a0fef0a23c14255df693b30eb9ae27eedf212470d8c400a0c0b6fb82fbf1ff8c5216ccd5721e3670b700389c886b1dce5070776dc9fbcc040957758c0 - languageName: node - linkType: hard - "clean-stack@npm:^5.2.0": version: 5.2.0 resolution: "clean-stack@npm:5.2.0" @@ -7434,7 +7410,7 @@ __metadata: languageName: node linkType: hard -"cli-table3@npm:^0.6.2, cli-table3@npm:^0.6.3": +"cli-table3@npm:^0.6.3": version: 0.6.3 resolution: "cli-table3@npm:0.6.3" dependencies: @@ -7464,6 +7440,17 @@ __metadata: languageName: node linkType: hard +"clipboardy@npm:^3.0.0": + version: 3.0.0 + resolution: "clipboardy@npm:3.0.0" + dependencies: + arch: "npm:^2.2.0" + execa: "npm:^5.1.1" + is-wsl: "npm:^2.2.0" + checksum: 299d66e13fcaccf656306e76d629ce6927eaba8ba58ae5328e3379ae627e469e29df8ef87408cdb234e2ad0e25f0024dd203393f7e59c67ae79772579c4de052 + languageName: node + linkType: hard + "cliui@npm:^6.0.0": version: 6.0.0 resolution: "cliui@npm:6.0.0" @@ -7500,12 +7487,10 @@ __metadata: languageName: node linkType: hard -"cmd-shim@npm:^5.0.0": - version: 5.0.0 - resolution: "cmd-shim@npm:5.0.0" - dependencies: - mkdirp-infer-owner: "npm:^2.0.0" - checksum: 0ce77d641bed74e41b74f07a00cbdc4e8690787d2136e40418ca7c1bfcff9d92c0350e31785c7bb98b6c1fb8ae7dcedcdc872b98c6647c28de45e2dc7a70ae43 +"cluster-key-slot@npm:^1.1.0": + version: 1.1.2 + resolution: "cluster-key-slot@npm:1.1.2" + checksum: d7d39ca28a8786e9e801eeb8c770e3c3236a566625d7299a47bb71113fb2298ce1039596acb82590e598c52dbc9b1f088c8f587803e697cb58e1867a95ff94d3 languageName: node linkType: hard @@ -7688,6 +7673,13 @@ __metadata: languageName: node linkType: hard +"consola@npm:^3.2.3": + version: 3.2.3 + resolution: "consola@npm:3.2.3" + checksum: c606220524ec88a05bb1baf557e9e0e04a0c08a9c35d7a08652d99de195c4ddcb6572040a7df57a18ff38bbc13ce9880ad032d56630cef27bef72768ef0ac078 + languageName: node + linkType: hard + "console-control-strings@npm:^1.1.0": version: 1.1.0 resolution: "console-control-strings@npm:1.1.0" @@ -7706,16 +7698,6 @@ __metadata: languageName: node linkType: hard -"conventional-changelog-angular@npm:^5.0.0": - version: 5.0.13 - resolution: "conventional-changelog-angular@npm:5.0.13" - dependencies: - compare-func: "npm:^2.0.0" - q: "npm:^1.5.1" - checksum: bca711b835fe01d75e3500b738f6525c91a12096218e917e9fd81bf9accf157f904fee16f88c523fd5462fb2a7cb1d060eb79e9bc9a3ccb04491f0c383b43231 - languageName: node - linkType: hard - "conventional-changelog-angular@npm:^7.0.0": version: 7.0.0 resolution: "conventional-changelog-angular@npm:7.0.0" @@ -7725,25 +7707,6 @@ __metadata: languageName: node linkType: hard -"conventional-changelog-writer@npm:^5.0.0": - version: 5.0.1 - resolution: "conventional-changelog-writer@npm:5.0.1" - dependencies: - conventional-commits-filter: "npm:^2.0.7" - dateformat: "npm:^3.0.0" - handlebars: "npm:^4.7.7" - json-stringify-safe: "npm:^5.0.1" - lodash: "npm:^4.17.15" - meow: "npm:^8.0.0" - semver: "npm:^6.0.0" - split: "npm:^1.0.0" - through2: "npm:^4.0.0" - bin: - conventional-changelog-writer: cli.js - checksum: 268b56a3e4db07ad24da7134788c889ecd024cf2e7c0bfe8ca76f83e5db79f057538c45500b052a77b7933c4d0f47e2e807c6e756cbd5ad9db365744c9ce0e7f - languageName: node - linkType: hard - "conventional-changelog-writer@npm:^7.0.0": version: 7.0.1 resolution: "conventional-changelog-writer@npm:7.0.1" @@ -7760,16 +7723,6 @@ __metadata: languageName: node linkType: hard -"conventional-commits-filter@npm:^2.0.0, conventional-commits-filter@npm:^2.0.7": - version: 2.0.7 - resolution: "conventional-commits-filter@npm:2.0.7" - dependencies: - lodash.ismatch: "npm:^4.4.0" - modify-values: "npm:^1.0.0" - checksum: df06fb29285b473614f5094e983d26fcc14cd0f64b2cbb2f65493fc8bd47c077c2310791d26f4b2b719e9585aaade95370e73230bff6647163164a18b9dfaa07 - languageName: node - linkType: hard - "conventional-commits-filter@npm:^4.0.0": version: 4.0.0 resolution: "conventional-commits-filter@npm:4.0.0" @@ -7777,22 +7730,6 @@ __metadata: languageName: node linkType: hard -"conventional-commits-parser@npm:^3.2.3": - version: 3.2.4 - resolution: "conventional-commits-parser@npm:3.2.4" - dependencies: - JSONStream: "npm:^1.0.4" - is-text-path: "npm:^1.0.1" - lodash: "npm:^4.17.15" - meow: "npm:^8.0.0" - split2: "npm:^3.0.0" - through2: "npm:^4.0.0" - bin: - conventional-commits-parser: cli.js - checksum: 122d7d7f991a04c8e3f703c0e4e9a25b2ecb20906f497e4486cb5c2acd9c68f6d9af745f7e79cb407538f50e840b33399274ac427b20971b98b335d1b66d3d17 - languageName: node - linkType: hard - "conventional-commits-parser@npm:^5.0.0": version: 5.0.0 resolution: "conventional-commits-parser@npm:5.0.0" @@ -7814,6 +7751,13 @@ __metadata: languageName: node linkType: hard +"cookie-es@npm:^1.0.0": + version: 1.0.0 + resolution: "cookie-es@npm:1.0.0" + checksum: 49fb5d5d050e34b5b5f6e31b47d28364d149a31322994568a826a8d137f36792f0365cedc587ab880a1826db41f644d349930523d980f2a0ac3608d63db9263b + languageName: node + linkType: hard + "core-js-compat@npm:^3.31.0, core-js-compat@npm:^3.33.1": version: 3.33.2 resolution: "core-js-compat@npm:3.33.2" @@ -7922,13 +7866,6 @@ __metadata: languageName: node linkType: hard -"crypto-random-string@npm:^2.0.0": - version: 2.0.0 - resolution: "crypto-random-string@npm:2.0.0" - checksum: 288589b2484fe787f9e146f56c4be90b940018f17af1b152e4dde12309042ff5a2bf69e949aab8b8ac253948381529cc6f3e5a2427b73643a71ff177fa122b37 - languageName: node - linkType: hard - "crypto-random-string@npm:^4.0.0": version: 4.0.0 resolution: "crypto-random-string@npm:4.0.0" @@ -8153,13 +8090,6 @@ __metadata: languageName: node linkType: hard -"dateformat@npm:^3.0.0": - version: 3.0.3 - resolution: "dateformat@npm:3.0.3" - checksum: 2effb8bef52ff912f87a05e4adbeacff46353e91313ad1ea9ed31412db26849f5a0fcc7e3ce36dbfb84fc6c881a986d5694f84838ad0da7000d5150693e78678 - languageName: node - linkType: hard - "debounce@npm:^1.2.0": version: 1.2.1 resolution: "debounce@npm:1.2.1" @@ -8167,7 +8097,7 @@ __metadata: languageName: node linkType: hard -"debug@npm:4, debug@npm:^4.0.0, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.1, debug@npm:^4.3.2, debug@npm:^4.3.3, debug@npm:^4.3.4": +"debug@npm:4, debug@npm:^4.0.0, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.1, debug@npm:^4.3.2, debug@npm:^4.3.4": version: 4.3.4 resolution: "debug@npm:4.3.4" dependencies: @@ -8188,24 +8118,7 @@ __metadata: languageName: node linkType: hard -"debuglog@npm:^1.0.1": - version: 1.0.1 - resolution: "debuglog@npm:1.0.1" - checksum: d98ac9abe6a528fcbb4d843b1caf5a9116998c76e1263d8ff4db2c086aa96fa7ea4c752a81050fa2e4304129ef330e6e4dc9dd4d47141afd7db80bf699f08219 - languageName: node - linkType: hard - -"decamelize-keys@npm:^1.1.0": - version: 1.1.1 - resolution: "decamelize-keys@npm:1.1.1" - dependencies: - decamelize: "npm:^1.1.0" - map-obj: "npm:^1.0.0" - checksum: 4ca385933127437658338c65fb9aead5f21b28d3dd3ccd7956eb29aab0953b5d3c047fbc207111672220c71ecf7a4d34f36c92851b7bbde6fca1a02c541bdd7d - languageName: node - linkType: hard - -"decamelize@npm:^1.1.0, decamelize@npm:^1.2.0": +"decamelize@npm:^1.2.0": version: 1.2.0 resolution: "decamelize@npm:1.2.0" checksum: 85c39fe8fbf0482d4a1e224ef0119db5c1897f8503bcef8b826adff7a1b11414972f6fef2d7dec2ee0b4be3863cf64ac1439137ae9e6af23a3d8dcbe26a5b4b2 @@ -8316,19 +8229,10 @@ __metadata: languageName: node linkType: hard -"del@npm:^6.0.0": - version: 6.1.1 - resolution: "del@npm:6.1.1" - dependencies: - globby: "npm:^11.0.1" - graceful-fs: "npm:^4.2.4" - is-glob: "npm:^4.0.1" - is-path-cwd: "npm:^2.2.0" - is-path-inside: "npm:^3.0.2" - p-map: "npm:^4.0.0" - rimraf: "npm:^3.0.2" - slash: "npm:^3.0.0" - checksum: 8a095c5ccade42c867a60252914ae485ec90da243d735d1f63ec1e64c1cfbc2b8810ad69a29ab6326d159d4fddaa2f5bad067808c42072351ec458efff86708f +"defu@npm:^6.1.2, defu@npm:^6.1.3": + version: 6.1.3 + resolution: "defu@npm:6.1.3" + checksum: 60d0d9a6e328148d5313fe0239ba3777701291f35570b52562454653d953fec5281b084514540f8d3b60d61bad9e39b52e95b3c0451631ded220ad8fdc893455 languageName: node linkType: hard @@ -8346,6 +8250,13 @@ __metadata: languageName: node linkType: hard +"denque@npm:^2.1.0": + version: 2.1.0 + resolution: "denque@npm:2.1.0" + checksum: f9ef81aa0af9c6c614a727cb3bd13c5d7db2af1abf9e6352045b86e85873e629690f6222f4edd49d10e4ccf8f078bbeec0794fafaf61b659c0589d0c511ec363 + languageName: node + linkType: hard + "dependency-graph@npm:^0.11.0": version: 0.11.0 resolution: "dependency-graph@npm:0.11.0" @@ -8367,6 +8278,13 @@ __metadata: languageName: node linkType: hard +"destr@npm:^2.0.1, destr@npm:^2.0.2": + version: 2.0.2 + resolution: "destr@npm:2.0.2" + checksum: 28bd8793c0507489efeb4b86c471fe9578e25439c1f7e4a4e4db9b69fe37689b68b9b205b7c317ca31590120e9c5364a31fec2eb6ec73bb425ede8f993c771d6 + languageName: node + linkType: hard + "detect-browser@npm:5.3.0": version: 5.3.0 resolution: "detect-browser@npm:5.3.0" @@ -8381,6 +8299,15 @@ __metadata: languageName: node linkType: hard +"detect-libc@npm:^1.0.3": + version: 1.0.3 + resolution: "detect-libc@npm:1.0.3" + bin: + detect-libc: ./bin/detect-libc.js + checksum: 4da0deae9f69e13bc37a0902d78bf7169480004b1fed3c19722d56cff578d16f0e11633b7fbf5fb6249181236c72e90024cbd68f0b9558ae06e281f47326d50d + languageName: node + linkType: hard + "detect-newline@npm:^3.0.0": version: 3.1.0 resolution: "detect-newline@npm:3.1.0" @@ -8395,16 +8322,6 @@ __metadata: languageName: node linkType: hard -"dezalgo@npm:^1.0.0": - version: 1.0.4 - resolution: "dezalgo@npm:1.0.4" - dependencies: - asap: "npm:^2.0.0" - wrappy: "npm:1" - checksum: 8a870ed42eade9a397e6141fe5c025148a59ed52f1f28b1db5de216b4d57f0af7a257070c3af7ce3d5508c1ce9dd5009028a76f4b2cc9370dc56551d2355fad8 - languageName: node - linkType: hard - "didyoumean@npm:^1.2.2": version: 1.2.2 resolution: "didyoumean@npm:1.2.2" @@ -8605,6 +8522,13 @@ __metadata: languageName: node linkType: hard +"electron-to-chromium@npm:^1.4.601": + version: 1.4.616 + resolution: "electron-to-chromium@npm:1.4.616" + checksum: a02416f3293d28120d5132546a6aea614ebd2d820a684f41b1c20138331922ddc672c4a59bfc4b91bb5aee1ba608f6c10cd3f69c344cd434397e7f14a4c97348 + languageName: node + linkType: hard + "emittery@npm:^0.13.1": version: 0.13.1 resolution: "emittery@npm:0.13.1" @@ -8626,6 +8550,13 @@ __metadata: languageName: node linkType: hard +"emojilib@npm:^2.4.0": + version: 2.4.0 + resolution: "emojilib@npm:2.4.0" + checksum: 6e66ba8921175842193f974e18af448bb6adb0cf7aeea75e08b9d4ea8e9baba0e4a5347b46ed901491dcaba277485891c33a8d70b0560ca5cc9672a94c21ab8f + languageName: node + linkType: hard + "encode-utf8@npm:^1.0.3": version: 1.0.3 resolution: "encode-utf8@npm:1.0.3" @@ -8665,13 +8596,13 @@ __metadata: languageName: node linkType: hard -"env-ci@npm:^8.0.0": - version: 8.0.0 - resolution: "env-ci@npm:8.0.0" +"env-ci@npm:^10.0.0": + version: 10.0.0 + resolution: "env-ci@npm:10.0.0" dependencies: - execa: "npm:^6.1.0" + execa: "npm:^8.0.0" java-properties: "npm:^1.0.2" - checksum: 173ce346f8d72f10fce1d813650733d62e3a45858689eca017c81ca44542ba099c5a9682df1680c3d9da1af0934cdb0635a98acf7ebc92f3d2f5055216461699 + checksum: cce92181b8cf269070c4be447784b806f0c9d380469c8c1ee97bbaebe9dd7b2e3a45377ae51b0ac00c732175378ddfb390de50fe44ae6a797415b137ae22522d languageName: node linkType: hard @@ -9090,7 +9021,7 @@ __metadata: languageName: node linkType: hard -"escape-string-regexp@npm:5.0.0, escape-string-regexp@npm:^5.0.0": +"escape-string-regexp@npm:5.0.0": version: 5.0.0 resolution: "escape-string-regexp@npm:5.0.0" checksum: 6366f474c6f37a802800a435232395e04e9885919873e382b157ab7e8f0feb8fed71497f84a6f6a81a49aab41815522f5839112bd38026d203aea0c91622df95 @@ -9136,9 +9067,9 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-jest@npm:^27.2.1": - version: 27.6.0 - resolution: "eslint-plugin-jest@npm:27.6.0" +"eslint-plugin-jest@npm:^27.6.1": + version: 27.6.1 + resolution: "eslint-plugin-jest@npm:27.6.1" dependencies: "@typescript-eslint/utils": "npm:^5.10.0" peerDependencies: @@ -9150,7 +9081,7 @@ __metadata: optional: true jest: optional: true - checksum: f6a61f91c382c82d653632b85749896c0c8c2ac1e17e43cbe242da0eb5ea9f818e796ac65f7e5d7904acea36392218181be4672869b566a756243e9d39737644 + checksum: 61f5f8ba5a40fcc26918a5e5d740b6ab0ffcb7aee96f4e2357dac44217394d7805ba155e6deb5a3575e6dc369505f29aa17a39507c2aaa8fed9a676277bf3dbc languageName: node linkType: hard @@ -9163,7 +9094,7 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-react@npm:^7.32.2": +"eslint-plugin-react@npm:^7.33.2": version: 7.33.2 resolution: "eslint-plugin-react@npm:7.33.2" dependencies: @@ -9216,14 +9147,14 @@ __metadata: languageName: node linkType: hard -"eslint@npm:^8.34.0": - version: 8.53.0 - resolution: "eslint@npm:8.53.0" +"eslint@npm:^8.56.0": + version: 8.56.0 + resolution: "eslint@npm:8.56.0" dependencies: "@eslint-community/eslint-utils": "npm:^4.2.0" "@eslint-community/regexpp": "npm:^4.6.1" - "@eslint/eslintrc": "npm:^2.1.3" - "@eslint/js": "npm:8.53.0" + "@eslint/eslintrc": "npm:^2.1.4" + "@eslint/js": "npm:8.56.0" "@humanwhocodes/config-array": "npm:^0.11.13" "@humanwhocodes/module-importer": "npm:^1.0.1" "@nodelib/fs.walk": "npm:^1.2.8" @@ -9260,7 +9191,7 @@ __metadata: text-table: "npm:^0.2.0" bin: eslint: bin/eslint.js - checksum: c5cd0049488c0463dab7d97466767ca5a1d0b3b59d0a223122683dc8039ecea30b27867fb9e38906b4c1ab9d09ece8a802a6c540d8905016f1cc4b4bb27329af + checksum: 2be598f7da1339d045ad933ffd3d4742bee610515cd2b0d9a2b8b729395a01d4e913552fff555b559fccaefd89d7b37632825789d1b06470608737ae69ab43fb languageName: node linkType: hard @@ -9383,7 +9314,7 @@ __metadata: languageName: node linkType: hard -"execa@npm:^5.0.0": +"execa@npm:^5.0.0, execa@npm:^5.1.1": version: 5.1.1 resolution: "execa@npm:5.1.1" dependencies: @@ -9400,40 +9331,6 @@ __metadata: languageName: node linkType: hard -"execa@npm:^6.1.0": - version: 6.1.0 - resolution: "execa@npm:6.1.0" - dependencies: - cross-spawn: "npm:^7.0.3" - get-stream: "npm:^6.0.1" - human-signals: "npm:^3.0.1" - is-stream: "npm:^3.0.0" - merge-stream: "npm:^2.0.0" - npm-run-path: "npm:^5.1.0" - onetime: "npm:^6.0.0" - signal-exit: "npm:^3.0.7" - strip-final-newline: "npm:^3.0.0" - checksum: 004ee32092af745766a1b0352fdba8701a4001bc3fe08e63101c04276d4c860bbe11bb8ab85f37acdff13d3da83d60e044041dcf24bd7e25e645a543828d9c41 - languageName: node - linkType: hard - -"execa@npm:^7.0.0": - version: 7.2.0 - resolution: "execa@npm:7.2.0" - dependencies: - cross-spawn: "npm:^7.0.3" - get-stream: "npm:^6.0.1" - human-signals: "npm:^4.3.0" - is-stream: "npm:^3.0.0" - merge-stream: "npm:^2.0.0" - npm-run-path: "npm:^5.1.0" - onetime: "npm:^6.0.0" - signal-exit: "npm:^3.0.7" - strip-final-newline: "npm:^3.0.0" - checksum: 098cd6a1bc26d509e5402c43f4971736450b84d058391820c6f237aeec6436963e006fd8423c9722f148c53da86aa50045929c7278b5522197dff802d10f9885 - languageName: node - linkType: hard - "execa@npm:^8.0.0": version: 8.0.1 resolution: "execa@npm:8.0.1" @@ -9571,7 +9468,7 @@ __metadata: languageName: node linkType: hard -"fastest-levenshtein@npm:^1.0.12, fastest-levenshtein@npm:^1.0.16": +"fastest-levenshtein@npm:^1.0.16": version: 1.0.16 resolution: "fastest-levenshtein@npm:1.0.16" checksum: 7e3d8ae812a7f4fdf8cad18e9cde436a39addf266a5986f653ea0d81e0de0900f50c0f27c6d5aff3f686bcb48acbd45be115ae2216f36a6a13a7dbbf5cad878b @@ -9653,13 +9550,12 @@ __metadata: languageName: node linkType: hard -"figures@npm:^5.0.0": - version: 5.0.0 - resolution: "figures@npm:5.0.0" +"figures@npm:^6.0.0": + version: 6.0.1 + resolution: "figures@npm:6.0.1" dependencies: - escape-string-regexp: "npm:^5.0.0" - is-unicode-supported: "npm:^1.2.0" - checksum: ce0f17d4ea8b0fc429c5207c343534a2f5284ecfb22aa08607da7dc84ed9e1cf754f5b97760e8dcb98d3c9d1a1e4d3d578fe3b5b99c426f05d0f06c7ba618e16 + is-unicode-supported: "npm:^2.0.0" + checksum: 1bd53404e49b16dc4c930f8b01d0b97233e2f9e217365e7b7d15db1097d219a3db6739c17853affec034ef6461751b0e426f9fa82e2199b9340358e13eadca93 languageName: node linkType: hard @@ -9724,16 +9620,6 @@ __metadata: languageName: node linkType: hard -"find-up@npm:^6.3.0": - version: 6.3.0 - resolution: "find-up@npm:6.3.0" - dependencies: - locate-path: "npm:^7.1.0" - path-exists: "npm:^5.0.0" - checksum: 07e0314362d316b2b13f7f11ea4692d5191e718ca3f7264110127520f3347996349bf9e16805abae3e196805814bc66ef4bff2b8904dc4a6476085fc9b0eba07 - languageName: node - linkType: hard - "find-versions@npm:^5.1.0": version: 5.1.0 resolution: "find-versions@npm:5.1.0" @@ -9849,7 +9735,7 @@ __metadata: languageName: node linkType: hard -"fs-minipass@npm:^2.0.0, fs-minipass@npm:^2.1.0": +"fs-minipass@npm:^2.0.0": version: 2.1.0 resolution: "fs-minipass@npm:2.1.0" dependencies: @@ -9919,22 +9805,6 @@ __metadata: languageName: node linkType: hard -"gauge@npm:^4.0.3": - version: 4.0.4 - resolution: "gauge@npm:4.0.4" - dependencies: - aproba: "npm:^1.0.3 || ^2.0.0" - color-support: "npm:^1.1.3" - console-control-strings: "npm:^1.1.0" - has-unicode: "npm:^2.0.1" - signal-exit: "npm:^3.0.7" - string-width: "npm:^4.2.3" - strip-ansi: "npm:^6.0.1" - wide-align: "npm:^1.1.5" - checksum: ef10d7981113d69225135f994c9f8c4369d945e64a8fc721d655a3a38421b738c9fe899951721d1b47b73c41fdb5404ac87cc8903b2ecbed95d2800363e7e58c - languageName: node - linkType: hard - "gauge@npm:^5.0.0": version: 5.0.1 resolution: "gauge@npm:5.0.1" @@ -9993,7 +9863,14 @@ __metadata: languageName: node linkType: hard -"get-stream@npm:^6.0.0, get-stream@npm:^6.0.1": +"get-port-please@npm:^3.1.1": + version: 3.1.1 + resolution: "get-port-please@npm:3.1.1" + checksum: d9229fd671cf43ab846bf187aad917e10688f154db467e0dbc423d0ab9f47363f9612bfb9094a89de196873a3966d33c907475a76bbfd7b68d81caf610035958 + languageName: node + linkType: hard + +"get-stream@npm:^6.0.0": version: 6.0.1 resolution: "get-stream@npm:6.0.1" checksum: 49825d57d3fd6964228e6200a58169464b8e8970489b3acdc24906c782fb7f01f9f56f8e6653c4a50713771d6658f7cfe051e5eb8c12e334138c9c918b296341 @@ -10099,19 +9976,6 @@ __metadata: languageName: node linkType: hard -"glob@npm:^8.0.1": - version: 8.1.0 - resolution: "glob@npm:8.1.0" - dependencies: - fs.realpath: "npm:^1.0.0" - inflight: "npm:^1.0.4" - inherits: "npm:2" - minimatch: "npm:^5.0.1" - once: "npm:^1.3.0" - checksum: cb0b5cab17a59c57299376abe5646c7070f8acb89df5595b492dba3bfb43d301a46c01e5695f01154e6553168207cb60d4eaf07d3be4bc3eb9b0457c5c561d0f - languageName: node - linkType: hard - "globals@npm:^11.1.0": version: 11.12.0 resolution: "globals@npm:11.12.0" @@ -10137,7 +10001,7 @@ __metadata: languageName: node linkType: hard -"globby@npm:^11.0.0, globby@npm:^11.0.1, globby@npm:^11.0.3, globby@npm:^11.1.0": +"globby@npm:^11.0.3, globby@npm:^11.1.0": version: 11.1.0 resolution: "globby@npm:11.1.0" dependencies: @@ -10181,7 +10045,7 @@ __metadata: languageName: node linkType: hard -"graceful-fs@npm:^4.1.2, graceful-fs@npm:^4.1.6, graceful-fs@npm:^4.2.0, graceful-fs@npm:^4.2.10, graceful-fs@npm:^4.2.11, graceful-fs@npm:^4.2.4, graceful-fs@npm:^4.2.6, graceful-fs@npm:^4.2.9": +"graceful-fs@npm:^4.1.2, graceful-fs@npm:^4.1.6, graceful-fs@npm:^4.2.0, graceful-fs@npm:^4.2.11, graceful-fs@npm:^4.2.6, graceful-fs@npm:^4.2.9": version: 4.2.11 resolution: "graceful-fs@npm:4.2.11" checksum: 386d011a553e02bc594ac2ca0bd6d9e4c22d7fa8cfbfc448a6d148c59ea881b092db9dbe3547ae4b88e55f1b01f7c4a2ecc53b310c042793e63aa44cf6c257f2 @@ -10259,6 +10123,22 @@ __metadata: languageName: node linkType: hard +"h3@npm:^1.8.1, h3@npm:^1.8.2": + version: 1.9.0 + resolution: "h3@npm:1.9.0" + dependencies: + cookie-es: "npm:^1.0.0" + defu: "npm:^6.1.3" + destr: "npm:^2.0.2" + iron-webcrypto: "npm:^1.0.0" + radix3: "npm:^1.1.0" + ufo: "npm:^1.3.2" + uncrypto: "npm:^0.1.3" + unenv: "npm:^1.7.4" + checksum: 90e80c34c9d0b7bdb24b13865ac27a88ca7724f0d1ce005295ae16408d4527020328a077d6c5df02de9f7ce7a15ab8a110978e1394a31717b07a34f09be91c06 + languageName: node + linkType: hard + "handlebars@npm:^4.7.7": version: 4.7.8 resolution: "handlebars@npm:4.7.8" @@ -10277,13 +10157,6 @@ __metadata: languageName: node linkType: hard -"hard-rejection@npm:^2.1.0": - version: 2.1.0 - resolution: "hard-rejection@npm:2.1.0" - checksum: febc3343a1ad575aedcc112580835b44a89a89e01f400b4eda6e8110869edfdab0b00cd1bd4c3bfec9475a57e79e0b355aecd5be46454b6a62b9a359af60e564 - languageName: node - linkType: hard - "has-bigints@npm:^1.0.1, has-bigints@npm:^1.0.2": version: 1.0.2 resolution: "has-bigints@npm:1.0.2" @@ -10377,40 +10250,6 @@ __metadata: languageName: node linkType: hard -"hosted-git-info@npm:^2.1.4": - version: 2.8.9 - resolution: "hosted-git-info@npm:2.8.9" - checksum: 317cbc6b1bbbe23c2a40ae23f3dafe9fa349ce42a89a36f930e3f9c0530c179a3882d2ef1e4141a4c3674d6faaea862138ec55b43ad6f75e387fda2483a13c70 - languageName: node - linkType: hard - -"hosted-git-info@npm:^4.0.1": - version: 4.1.0 - resolution: "hosted-git-info@npm:4.1.0" - dependencies: - lru-cache: "npm:^6.0.0" - checksum: 150fbcb001600336d17fdbae803264abed013548eea7946c2264c49ebe2ebd8c4441ba71dd23dd8e18c65de79d637f98b22d4760ba5fb2e0b15d62543d0fff07 - languageName: node - linkType: hard - -"hosted-git-info@npm:^5.0.0, hosted-git-info@npm:^5.2.1": - version: 5.2.1 - resolution: "hosted-git-info@npm:5.2.1" - dependencies: - lru-cache: "npm:^7.5.1" - checksum: c6682c2e91d774d79893e2c862d7173450455747fd57f0659337c78d37ddb56c23cb7541b296cbef4a3b47c3be307d8d57f24a6e9aa149cad243c7f126cd42ff - languageName: node - linkType: hard - -"hosted-git-info@npm:^6.0.0": - version: 6.1.1 - resolution: "hosted-git-info@npm:6.1.1" - dependencies: - lru-cache: "npm:^7.5.1" - checksum: ba7158f81ae29c1b5a1e452fa517082f928051da8797a00788a84ff82b434996d34f78a875bbb688aec162bda1d4cf71d2312f44da3c896058803f5efa6ce77f - languageName: node - linkType: hard - "hosted-git-info@npm:^7.0.0, hosted-git-info@npm:^7.0.1": version: 7.0.1 resolution: "hosted-git-info@npm:7.0.1" @@ -10436,7 +10275,7 @@ __metadata: languageName: node linkType: hard -"http-cache-semantics@npm:^4.1.0, http-cache-semantics@npm:^4.1.1": +"http-cache-semantics@npm:^4.1.1": version: 4.1.1 resolution: "http-cache-semantics@npm:4.1.1" checksum: ce1319b8a382eb3cbb4a37c19f6bfe14e5bb5be3d09079e885e8c513ab2d3cd9214902f8a31c9dc4e37022633ceabfc2d697405deeaf1b8f3552bb4ed996fdfc @@ -10464,7 +10303,14 @@ __metadata: languageName: node linkType: hard -"https-proxy-agent@npm:^5.0.0, https-proxy-agent@npm:^5.0.1": +"http-shutdown@npm:^1.2.2": + version: 1.2.2 + resolution: "http-shutdown@npm:1.2.2" + checksum: 1ea04d50d9a84ad6e7d9ee621160ce9515936e32e7f5ba445db48a5d72681858002c934c7f3ae5f474b301c1cd6b418aee3f6a2f109822109e606cc1a6c17c03 + languageName: node + linkType: hard + +"https-proxy-agent@npm:^5.0.1": version: 5.0.1 resolution: "https-proxy-agent@npm:5.0.1" dependencies: @@ -10491,20 +10337,6 @@ __metadata: languageName: node linkType: hard -"human-signals@npm:^3.0.1": - version: 3.0.1 - resolution: "human-signals@npm:3.0.1" - checksum: 0bb27e72aea1666322f69ab9816e05df952ef2160346f2293f98f45d472edb1b62d0f1a596697b50d48d8f8222e6db3b9f9dc0b6bf6113866121001f0a8e48e9 - languageName: node - linkType: hard - -"human-signals@npm:^4.3.0": - version: 4.3.1 - resolution: "human-signals@npm:4.3.1" - checksum: 40498b33fe139f5cc4ef5d2f95eb1803d6318ac1b1c63eaf14eeed5484d26332c828de4a5a05676b6c83d7b9e57727c59addb4b1dea19cb8d71e83689e5b336c - languageName: node - linkType: hard - "human-signals@npm:^5.0.0": version: 5.0.0 resolution: "human-signals@npm:5.0.0" @@ -10512,15 +10344,6 @@ __metadata: languageName: node linkType: hard -"humanize-ms@npm:^1.2.1": - version: 1.2.1 - resolution: "humanize-ms@npm:1.2.1" - dependencies: - ms: "npm:^2.0.0" - checksum: f34a2c20161d02303c2807badec2f3b49cbfbbb409abd4f95a07377ae01cfe6b59e3d15ac609cffcd8f2521f0eb37b7e1091acf65da99aa2a4f1ad63c21e7e7a - languageName: node - linkType: hard - "iconv-lite@npm:0.6.3, iconv-lite@npm:^0.6.2": version: 0.6.3 resolution: "iconv-lite@npm:0.6.3" @@ -10555,6 +10378,13 @@ __metadata: languageName: node linkType: hard +"idb-keyval@npm:^6.2.1": + version: 6.2.1 + resolution: "idb-keyval@npm:6.2.1" + checksum: 9f0c83703a365e00bd0b4ed6380ce509a06dedfc6ec39b2ba5740085069fd2f2ff5c14ba19356488e3612a2f9c49985971982d836460a982a5d0b4019eeba48a + languageName: node + linkType: hard + "ieee754@npm:^1.1.13, ieee754@npm:^1.2.1": version: 1.2.1 resolution: "ieee754@npm:1.2.1" @@ -10562,15 +10392,6 @@ __metadata: languageName: node linkType: hard -"ignore-walk@npm:^5.0.1": - version: 5.0.1 - resolution: "ignore-walk@npm:5.0.1" - dependencies: - minimatch: "npm:^5.0.1" - checksum: 0d157a54d6d11af0c3059fdc7679eef3b074e9a663d110a76c72788e2fb5b22087e08b21ab767718187ac3396aca4d0aa6c6473f925b19a74d9a00480ca7a76e - languageName: node - linkType: hard - "ignore-walk@npm:^6.0.0": version: 6.0.3 resolution: "ignore-walk@npm:6.0.3" @@ -10629,7 +10450,17 @@ __metadata: languageName: node linkType: hard -"import-from@npm:4.0.0, import-from@npm:^4.0.0": +"import-from-esm@npm:^1.3.1": + version: 1.3.3 + resolution: "import-from-esm@npm:1.3.3" + dependencies: + debug: "npm:^4.3.4" + import-meta-resolve: "npm:^4.0.0" + checksum: 4287ff7e7b8ba52f4547a03be44105ad2cdad1d4bf15ba4f629649ece587633b1c1f14784f1e0f5441d5ac8967f59a64d7017d88d09d34624ebf81af9c48b55e + languageName: node + linkType: hard + +"import-from@npm:4.0.0": version: 4.0.0 resolution: "import-from@npm:4.0.0" checksum: 7fd98650d555e418c18341fef49ae11afc833f5ae70b7043e99684187cba6ac6b52e4118a491bd9f856045495bef5bdda7321095e65bcb2ef70ce2adf9f0d8d1 @@ -10692,13 +10523,6 @@ __metadata: languageName: node linkType: hard -"infer-owner@npm:^1.0.4": - version: 1.0.4 - resolution: "infer-owner@npm:1.0.4" - checksum: a7b241e3149c26e37474e3435779487f42f36883711f198c45794703c7556bc38af224088bd4d1a221a45b8208ae2c2bcf86200383621434d0c099304481c5b9 - languageName: node - linkType: hard - "inflight@npm:^1.0.4": version: 1.0.6 resolution: "inflight@npm:1.0.6" @@ -10723,13 +10547,6 @@ __metadata: languageName: node linkType: hard -"ini@npm:^3.0.0, ini@npm:^3.0.1": - version: 3.0.1 - resolution: "ini@npm:3.0.1" - checksum: 4473d8d42d4b0c4fcf8707e5d37a7eacd5a1d2ed2b99f1b6805c76efddf674c3deba6fb26811eeeb883a71d6c6917c3250d336e545b4e2c8d96081bf05e58df6 - languageName: node - linkType: hard - "ini@npm:^4.1.0, ini@npm:^4.1.1": version: 4.1.1 resolution: "ini@npm:4.1.1" @@ -10737,21 +10554,6 @@ __metadata: languageName: node linkType: hard -"init-package-json@npm:^3.0.2": - version: 3.0.2 - resolution: "init-package-json@npm:3.0.2" - dependencies: - npm-package-arg: "npm:^9.0.1" - promzard: "npm:^0.3.0" - read: "npm:^1.0.7" - read-package-json: "npm:^5.0.0" - semver: "npm:^7.3.5" - validate-npm-package-license: "npm:^3.0.4" - validate-npm-package-name: "npm:^4.0.0" - checksum: 6efb57881d31af86006795df1def73fa997729ad57ff2e74346128653a1f21e417d194353b7733fd2edef8a79389ee9c1f56c65ce7b0809c3041229599366e6e - languageName: node - linkType: hard - "init-package-json@npm:^6.0.0": version: 6.0.0 resolution: "init-package-json@npm:6.0.0" @@ -10801,16 +10603,6 @@ __metadata: languageName: node linkType: hard -"into-stream@npm:^6.0.0": - version: 6.0.0 - resolution: "into-stream@npm:6.0.0" - dependencies: - from2: "npm:^2.3.0" - p-is-promise: "npm:^3.0.0" - checksum: 576319a540d0e494f5f6028db364b0e163d58020139d862e5372c51ac35875e4ac2ee49fd821bb9225642de6add2e26dff82e5c41108d638a95930fa83bad750 - languageName: node - linkType: hard - "into-stream@npm:^7.0.0": version: 7.0.0 resolution: "into-stream@npm:7.0.0" @@ -10830,6 +10622,23 @@ __metadata: languageName: node linkType: hard +"ioredis@npm:^5.3.2": + version: 5.3.2 + resolution: "ioredis@npm:5.3.2" + dependencies: + "@ioredis/commands": "npm:^1.1.1" + cluster-key-slot: "npm:^1.1.0" + debug: "npm:^4.3.4" + denque: "npm:^2.1.0" + lodash.defaults: "npm:^4.2.0" + lodash.isarguments: "npm:^3.1.0" + redis-errors: "npm:^1.2.0" + redis-parser: "npm:^3.0.0" + standard-as-callback: "npm:^2.1.0" + checksum: 0dd2b5b8004e891f5b62edf18ac223194f1f5204698ec827c903e789ea05b0b36f73395491749ec63c66470485bdfb228ccdf1714fbf631a0f78f33211f2c883 + languageName: node + linkType: hard + "ip-regex@npm:^4.1.0": version: 4.3.0 resolution: "ip-regex@npm:4.3.0" @@ -10844,6 +10653,13 @@ __metadata: languageName: node linkType: hard +"iron-webcrypto@npm:^1.0.0": + version: 1.0.0 + resolution: "iron-webcrypto@npm:1.0.0" + checksum: 7e9305a7d792c275cba33c770695327c8ad3f7c8021e03f7148a8b92b559ad09468f337433090eb48e195d5fda0fd2e0611afcad843eb917cffcc1c6392e8037 + languageName: node + linkType: hard + "is-absolute@npm:^1.0.0": version: 1.0.0 resolution: "is-absolute@npm:1.0.0" @@ -10942,7 +10758,7 @@ __metadata: languageName: node linkType: hard -"is-core-module@npm:^2.13.0, is-core-module@npm:^2.5.0, is-core-module@npm:^2.8.1": +"is-core-module@npm:^2.13.0, is-core-module@npm:^2.8.1": version: 2.13.1 resolution: "is-core-module@npm:2.13.1" dependencies: @@ -10960,6 +10776,15 @@ __metadata: languageName: node linkType: hard +"is-docker@npm:^2.0.0": + version: 2.2.1 + resolution: "is-docker@npm:2.2.1" + bin: + is-docker: cli.js + checksum: e828365958d155f90c409cdbe958f64051d99e8aedc2c8c4cd7c89dcf35329daed42f7b99346f7828df013e27deb8f721cf9408ba878c76eb9e8290235fbcdcc + languageName: node + linkType: hard + "is-extglob@npm:^2.1.1": version: 2.1.1 resolution: "is-extglob@npm:2.1.1" @@ -11068,27 +10893,13 @@ __metadata: languageName: node linkType: hard -"is-path-cwd@npm:^2.2.0": - version: 2.2.0 - resolution: "is-path-cwd@npm:2.2.0" - checksum: afce71533a427a759cd0329301c18950333d7589533c2c90205bd3fdcf7b91eb92d1940493190567a433134d2128ec9325de2fd281e05be1920fbee9edd22e0a - languageName: node - linkType: hard - -"is-path-inside@npm:^3.0.2, is-path-inside@npm:^3.0.3": +"is-path-inside@npm:^3.0.3": version: 3.0.3 resolution: "is-path-inside@npm:3.0.3" checksum: cf7d4ac35fb96bab6a1d2c3598fe5ebb29aafb52c0aaa482b5a3ed9d8ba3edc11631e3ec2637660c44b3ce0e61a08d54946e8af30dec0b60a7c27296c68ffd05 languageName: node linkType: hard -"is-plain-obj@npm:^1.1.0": - version: 1.1.0 - resolution: "is-plain-obj@npm:1.1.0" - checksum: daaee1805add26f781b413fdf192fc91d52409583be30ace35c82607d440da63cc4cac0ac55136716688d6c0a2c6ef3edb2254fecbd1fe06056d6bd15975ee8c - languageName: node - linkType: hard - "is-plain-object@npm:^5.0.0": version: 5.0.0 resolution: "is-plain-object@npm:5.0.0" @@ -11177,15 +10988,6 @@ __metadata: languageName: node linkType: hard -"is-text-path@npm:^1.0.1": - version: 1.0.1 - resolution: "is-text-path@npm:1.0.1" - dependencies: - text-extensions: "npm:^1.0.0" - checksum: 61c8650c29548febb6bf69e9541fc11abbbb087a0568df7bc471ba264e95fb254def4e610631cbab4ddb0a1a07949d06416f4ebeaf37875023fb184cdb87ee84 - languageName: node - linkType: hard - "is-text-path@npm:^2.0.0": version: 2.0.0 resolution: "is-text-path@npm:2.0.0" @@ -11227,10 +11029,10 @@ __metadata: languageName: node linkType: hard -"is-unicode-supported@npm:^1.2.0": - version: 1.3.0 - resolution: "is-unicode-supported@npm:1.3.0" - checksum: b8674ea95d869f6faabddc6a484767207058b91aea0250803cbf1221345cb0c56f466d4ecea375dc77f6633d248d33c47bd296fb8f4cdba0b4edba8917e83d8a +"is-unicode-supported@npm:^2.0.0": + version: 2.0.0 + resolution: "is-unicode-supported@npm:2.0.0" + checksum: 3013dfb8265fe9f9a0d1e9433fc4e766595631a8d85d60876c457b4bedc066768dab1477c553d02e2f626d88a4e019162706e04263c94d74994ef636a33b5f94 languageName: node linkType: hard @@ -11276,6 +11078,15 @@ __metadata: languageName: node linkType: hard +"is-wsl@npm:^2.2.0": + version: 2.2.0 + resolution: "is-wsl@npm:2.2.0" + dependencies: + is-docker: "npm:^2.0.0" + checksum: a6fa2d370d21be487c0165c7a440d567274fbba1a817f2f0bfa41cc5e3af25041d84267baa22df66696956038a43973e72fca117918c91431920bdef490fa25e + languageName: node + linkType: hard + "isarray@npm:^2.0.5": version: 2.0.5 resolution: "isarray@npm:2.0.5" @@ -11304,6 +11115,16 @@ __metadata: languageName: node linkType: hard +"isomorphic-unfetch@npm:3.1.0": + version: 3.1.0 + resolution: "isomorphic-unfetch@npm:3.1.0" + dependencies: + node-fetch: "npm:^2.6.1" + unfetch: "npm:^4.2.0" + checksum: d3b61fca06304db692b7f76bdfd3a00f410e42cfa7403c3b250546bf71589d18cf2f355922f57198e4cc4a9872d3647b20397a5c3edf1a347c90d57c83cf2a89 + languageName: node + linkType: hard + "isomorphic-ws@npm:5.0.0, isomorphic-ws@npm:^5.0.0": version: 5.0.0 resolution: "isomorphic-ws@npm:5.0.0" @@ -11561,7 +11382,7 @@ __metadata: languageName: node linkType: hard -"jest-environment-jsdom@npm:^29.4.3": +"jest-environment-jsdom@npm:^29.7.0": version: 29.7.0 resolution: "jest-environment-jsdom@npm:29.7.0" dependencies: @@ -11865,7 +11686,7 @@ __metadata: languageName: node linkType: hard -"jest@npm:^29.4.3": +"jest@npm:^29.7.0": version: 29.7.0 resolution: "jest@npm:29.7.0" dependencies: @@ -11884,7 +11705,7 @@ __metadata: languageName: node linkType: hard -"jiti@npm:^1.17.1, jiti@npm:^1.18.2, jiti@npm:^1.19.1": +"jiti@npm:^1.17.1, jiti@npm:^1.18.2, jiti@npm:^1.19.1, jiti@npm:^1.20.0": version: 1.21.0 resolution: "jiti@npm:1.21.0" bin: @@ -12011,7 +11832,7 @@ __metadata: languageName: node linkType: hard -"json-parse-even-better-errors@npm:^2.3.0, json-parse-even-better-errors@npm:^2.3.1": +"json-parse-even-better-errors@npm:^2.3.0": version: 2.3.1 resolution: "json-parse-even-better-errors@npm:2.3.1" checksum: 140932564c8f0b88455432e0f33c4cb4086b8868e37524e07e723f4eaedb9425bdc2bafd71bd1d9765bd15fd1e2d126972bc83990f55c467168c228c24d665f3 @@ -12081,6 +11902,13 @@ __metadata: languageName: node linkType: hard +"jsonc-parser@npm:^3.2.0": + version: 3.2.0 + resolution: "jsonc-parser@npm:3.2.0" + checksum: 5a12d4d04dad381852476872a29dcee03a57439574e4181d91dca71904fcdcc5e8e4706c0a68a2c61ad9810e1e1c5806b5100d52d3e727b78f5cdc595401045b + languageName: node + linkType: hard + "jsonfile@npm:^6.0.1": version: 6.1.0 resolution: "jsonfile@npm:6.1.0" @@ -12127,13 +11955,6 @@ __metadata: languageName: node linkType: hard -"just-diff@npm:^5.0.1": - version: 5.2.0 - resolution: "just-diff@npm:5.2.0" - checksum: a9d0ebc789f70f5200a022059de057a49b7f1a63179f691b79da13c82c3973d58b7f18e5b30ee0874f79ca53d5e9bdff8f089dff6de4c5f7def10a1c1cc5200e - languageName: node - linkType: hard - "just-diff@npm:^6.0.0": version: 6.0.2 resolution: "just-diff@npm:6.0.2" @@ -12157,13 +11978,6 @@ __metadata: languageName: node linkType: hard -"kind-of@npm:^6.0.3": - version: 6.0.3 - resolution: "kind-of@npm:6.0.3" - checksum: 61cdff9623dabf3568b6445e93e31376bee1cdb93f8ba7033d86022c2a9b1791a1d9510e026e6465ebd701a6dd2f7b0808483ad8838341ac52f003f512e0b4c4 - languageName: node - linkType: hard - "kleur@npm:^3.0.3": version: 3.0.3 resolution: "kleur@npm:3.0.3" @@ -12195,18 +12009,6 @@ __metadata: languageName: node linkType: hard -"libnpmaccess@npm:^6.0.4": - version: 6.0.4 - resolution: "libnpmaccess@npm:6.0.4" - dependencies: - aproba: "npm:^2.0.0" - minipass: "npm:^3.1.1" - npm-package-arg: "npm:^9.0.1" - npm-registry-fetch: "npm:^13.0.0" - checksum: d7cee5ae92369a1ac6fb141082b929c853b3b6a140d9878e52ee93abca644fe052e7b5dfc3ac14c4b2f0c0945bd8bf6d5ccff608be8d8928d812df4af28cb43b - languageName: node - linkType: hard - "libnpmaccess@npm:^8.0.1": version: 8.0.1 resolution: "libnpmaccess@npm:8.0.1" @@ -12217,22 +12019,6 @@ __metadata: languageName: node linkType: hard -"libnpmdiff@npm:^4.0.5": - version: 4.0.5 - resolution: "libnpmdiff@npm:4.0.5" - dependencies: - "@npmcli/disparity-colors": "npm:^2.0.0" - "@npmcli/installed-package-contents": "npm:^1.0.7" - binary-extensions: "npm:^2.2.0" - diff: "npm:^5.1.0" - minimatch: "npm:^5.0.1" - npm-package-arg: "npm:^9.0.1" - pacote: "npm:^13.6.1" - tar: "npm:^6.1.0" - checksum: 421d92ce61bfdfa5d9f04a35974d1363525ffaa4a92df6ce9cec46788e5f4e52283137f77e22e3280eb79f52c3b9cdb587ffbbc640012a95d7369abae77a51a1 - languageName: node - linkType: hard - "libnpmdiff@npm:^6.0.3": version: 6.0.3 resolution: "libnpmdiff@npm:6.0.3" @@ -12250,28 +12036,6 @@ __metadata: languageName: node linkType: hard -"libnpmexec@npm:^4.0.14": - version: 4.0.14 - resolution: "libnpmexec@npm:4.0.14" - dependencies: - "@npmcli/arborist": "npm:^5.6.3" - "@npmcli/ci-detect": "npm:^2.0.0" - "@npmcli/fs": "npm:^2.1.1" - "@npmcli/run-script": "npm:^4.2.0" - chalk: "npm:^4.1.0" - mkdirp-infer-owner: "npm:^2.0.0" - npm-package-arg: "npm:^9.0.1" - npmlog: "npm:^6.0.2" - pacote: "npm:^13.6.1" - proc-log: "npm:^2.0.0" - read: "npm:^1.0.7" - read-package-json-fast: "npm:^2.0.2" - semver: "npm:^7.3.7" - walk-up-path: "npm:^1.0.0" - checksum: d5897a873b0755053111978e33944ff6f90682a615fa227043c7e2a10210fce521701d9cce69010ff5609479defaf97f410329a026ba1eed40210ee41d309572 - languageName: node - linkType: hard - "libnpmexec@npm:^7.0.3": version: 7.0.3 resolution: "libnpmexec@npm:7.0.3" @@ -12291,15 +12055,6 @@ __metadata: languageName: node linkType: hard -"libnpmfund@npm:^3.0.5": - version: 3.0.5 - resolution: "libnpmfund@npm:3.0.5" - dependencies: - "@npmcli/arborist": "npm:^5.6.3" - checksum: 8977a4db55d37d991598aaf9507d34cc994aa5b783e2d2f0c2f75ba8fdcded5a81e195fbb77e914de6d577e55f17678c974442e8e559652869b76a02d84283a1 - languageName: node - linkType: hard - "libnpmfund@npm:^5.0.1": version: 5.0.1 resolution: "libnpmfund@npm:5.0.1" @@ -12319,26 +12074,6 @@ __metadata: languageName: node linkType: hard -"libnpmhook@npm:^8.0.4": - version: 8.0.4 - resolution: "libnpmhook@npm:8.0.4" - dependencies: - aproba: "npm:^2.0.0" - npm-registry-fetch: "npm:^13.0.0" - checksum: 64e0fe39053e6bf30c69937f19c06cf555c28eb30539d7caee5db860e85f18d2e4d874235696e1a2b23c9c3e04696bf1afe140a49302aa98a37b0b6c0772fe8b - languageName: node - linkType: hard - -"libnpmorg@npm:^4.0.4": - version: 4.0.4 - resolution: "libnpmorg@npm:4.0.4" - dependencies: - aproba: "npm:^2.0.0" - npm-registry-fetch: "npm:^13.0.0" - checksum: aa6c760efe87183d217af0595dbd992374d33eab94f4bb2ab6548b6dc41d9a986c4d4f93e8fcfab4d9c18640c7ffed73a4219b629f207367f9e1f7fa7140fe0b - languageName: node - linkType: hard - "libnpmorg@npm:^6.0.1": version: 6.0.1 resolution: "libnpmorg@npm:6.0.1" @@ -12349,17 +12084,6 @@ __metadata: languageName: node linkType: hard -"libnpmpack@npm:^4.1.3": - version: 4.1.3 - resolution: "libnpmpack@npm:4.1.3" - dependencies: - "@npmcli/run-script": "npm:^4.1.3" - npm-package-arg: "npm:^9.0.1" - pacote: "npm:^13.6.1" - checksum: 628341371bfb556b8e4649b11be63fe1c11dec85fe5d3018d9cda87cc5f274b6fd4df2751d6b651c8e3cfffb03f055e2e1811c41d94022bd28833236f03479cd - languageName: node - linkType: hard - "libnpmpack@npm:^6.0.3": version: 6.0.3 resolution: "libnpmpack@npm:6.0.3" @@ -12372,19 +12096,6 @@ __metadata: languageName: node linkType: hard -"libnpmpublish@npm:^6.0.5": - version: 6.0.5 - resolution: "libnpmpublish@npm:6.0.5" - dependencies: - normalize-package-data: "npm:^4.0.0" - npm-package-arg: "npm:^9.0.1" - npm-registry-fetch: "npm:^13.0.0" - semver: "npm:^7.3.7" - ssri: "npm:^9.0.0" - checksum: b6238933d792a73a52ddb262aea07a09221dceeaefeb7340f1443d9ab7b2a6997ea8ef5267daaa5c15b1c3be6b7b730cc816f8bf3076a6b346e0a46546828f44 - languageName: node - linkType: hard - "libnpmpublish@npm:^9.0.1": version: 9.0.1 resolution: "libnpmpublish@npm:9.0.1" @@ -12401,15 +12112,6 @@ __metadata: languageName: node linkType: hard -"libnpmsearch@npm:^5.0.4": - version: 5.0.4 - resolution: "libnpmsearch@npm:5.0.4" - dependencies: - npm-registry-fetch: "npm:^13.0.0" - checksum: 21e0e24c571f91a7e3c1f2d4441bdf611dae6f161ca22aea1623bc90582d0d93b9307903facc0eee1758635da2f5b1f274ebd98db68e9ea3054ca8fc8ab2ffe8 - languageName: node - linkType: hard - "libnpmsearch@npm:^7.0.0": version: 7.0.0 resolution: "libnpmsearch@npm:7.0.0" @@ -12419,16 +12121,6 @@ __metadata: languageName: node linkType: hard -"libnpmteam@npm:^4.0.4": - version: 4.0.4 - resolution: "libnpmteam@npm:4.0.4" - dependencies: - aproba: "npm:^2.0.0" - npm-registry-fetch: "npm:^13.0.0" - checksum: ae7311de69936141b8e5b5932aca3bce6eada88b1ef5c5fec12391a26750ccd83e70cffb1cfa7c87d91bfc346d89ce975bfbe4648c3ddc693d3e9a641780537a - languageName: node - linkType: hard - "libnpmteam@npm:^6.0.0": version: 6.0.0 resolution: "libnpmteam@npm:6.0.0" @@ -12439,19 +12131,6 @@ __metadata: languageName: node linkType: hard -"libnpmversion@npm:^3.0.7": - version: 3.0.7 - resolution: "libnpmversion@npm:3.0.7" - dependencies: - "@npmcli/git": "npm:^3.0.0" - "@npmcli/run-script": "npm:^4.1.3" - json-parse-even-better-errors: "npm:^2.3.1" - proc-log: "npm:^2.0.0" - semver: "npm:^7.3.7" - checksum: 07620887a240b4466ce1d7faf967ab5571da0e705c7b87b3aac4581defc9ab1c839e02bee6c1d413321f83b59910f78d770e9b5163e0450799d9eb24ce6e6174 - languageName: node - linkType: hard - "libnpmversion@npm:^5.0.1": version: 5.0.1 resolution: "libnpmversion@npm:5.0.1" @@ -12479,6 +12158,34 @@ __metadata: languageName: node linkType: hard +"listhen@npm:^1.5.5": + version: 1.5.5 + resolution: "listhen@npm:1.5.5" + dependencies: + "@parcel/watcher": "npm:^2.3.0" + "@parcel/watcher-wasm": "npm:2.3.0" + citty: "npm:^0.1.4" + clipboardy: "npm:^3.0.0" + consola: "npm:^3.2.3" + defu: "npm:^6.1.2" + get-port-please: "npm:^3.1.1" + h3: "npm:^1.8.1" + http-shutdown: "npm:^1.2.2" + jiti: "npm:^1.20.0" + mlly: "npm:^1.4.2" + node-forge: "npm:^1.3.1" + pathe: "npm:^1.1.1" + std-env: "npm:^3.4.3" + ufo: "npm:^1.3.0" + untun: "npm:^0.1.2" + uqr: "npm:^0.1.2" + bin: + listen: bin/listhen.mjs + listhen: bin/listhen.mjs + checksum: 84a8a6c0e0d347db3110af3f77aa86fba428fcec1e2cd53e17d0d8daf36edd8833c75a647b718e6cea723d452b0b2a78b2290d03c79315c52eda1f1984384bb2 + languageName: node + linkType: hard + "listr2@npm:^4.0.5": version: 4.0.5 resolution: "listr2@npm:4.0.5" @@ -12578,15 +12285,6 @@ __metadata: languageName: node linkType: hard -"locate-path@npm:^7.1.0": - version: 7.2.0 - resolution: "locate-path@npm:7.2.0" - dependencies: - p-locate: "npm:^6.0.0" - checksum: 139e8a7fe11cfbd7f20db03923cacfa5db9e14fa14887ea121345597472b4a63c1a42a8a5187defeeff6acf98fd568da7382aa39682d38f0af27433953a97751 - languageName: node - linkType: hard - "lodash-es@npm:^4.17.21": version: 4.17.21 resolution: "lodash-es@npm:4.17.21" @@ -12615,6 +12313,13 @@ __metadata: languageName: node linkType: hard +"lodash.defaults@npm:^4.2.0": + version: 4.2.0 + resolution: "lodash.defaults@npm:4.2.0" + checksum: d5b77aeb702caa69b17be1358faece33a84497bcca814897383c58b28a2f8dfc381b1d9edbec239f8b425126a3bbe4916223da2a576bb0411c2cefd67df80707 + languageName: node + linkType: hard + "lodash.escaperegexp@npm:^4.1.2": version: 4.1.2 resolution: "lodash.escaperegexp@npm:4.1.2" @@ -12622,6 +12327,13 @@ __metadata: languageName: node linkType: hard +"lodash.isarguments@npm:^3.1.0": + version: 3.1.0 + resolution: "lodash.isarguments@npm:3.1.0" + checksum: 5e8f95ba10975900a3920fb039a3f89a5a79359a1b5565e4e5b4310ed6ebe64011e31d402e34f577eca983a1fc01ff86c926e3cbe602e1ddfc858fdd353e62d8 + languageName: node + linkType: hard + "lodash.isequal@npm:4.5.0": version: 4.5.0 resolution: "lodash.isequal@npm:4.5.0" @@ -12629,13 +12341,6 @@ __metadata: languageName: node linkType: hard -"lodash.ismatch@npm:^4.4.0": - version: 4.4.0 - resolution: "lodash.ismatch@npm:4.4.0" - checksum: 8f96a5dc4b8d3fc5a033dcb259d0c3148a1044fa4d02b4a0e8dce0fa1f2ef3ec4ac131e20b5cb2c985a4e9bcb1c37c0aa5af2cef70094959389617347b8fc645 - languageName: node - linkType: hard - "lodash.isplainobject@npm:^4.0.6": version: 4.0.6 resolution: "lodash.isplainobject@npm:4.0.6" @@ -12757,6 +12462,13 @@ __metadata: languageName: node linkType: hard +"lru-cache@npm:^10.0.2": + version: 10.1.0 + resolution: "lru-cache@npm:10.1.0" + checksum: 778bc8b2626daccd75f24c4b4d10632496e21ba064b126f526c626fbdbc5b28c472013fccd45d7646b9e1ef052444824854aed617b59cd570d01a8b7d651fc1e + languageName: node + linkType: hard + "lru-cache@npm:^5.1.1": version: 5.1.1 resolution: "lru-cache@npm:5.1.1" @@ -12775,13 +12487,6 @@ __metadata: languageName: node linkType: hard -"lru-cache@npm:^7.4.4, lru-cache@npm:^7.5.1, lru-cache@npm:^7.7.1": - version: 7.18.3 - resolution: "lru-cache@npm:7.18.3" - checksum: b3a452b491433db885beed95041eb104c157ef7794b9c9b4d647be503be91769d11206bb573849a16b4cc0d03cbd15ffd22df7960997788b74c1d399ac7a4fed - languageName: node - linkType: hard - "lru-queue@npm:^0.1.0": version: 0.1.0 resolution: "lru-queue@npm:0.1.0" @@ -12791,10 +12496,10 @@ __metadata: languageName: node linkType: hard -"luxon@npm:^3.2.1": - version: 3.4.3 - resolution: "luxon@npm:3.4.3" - checksum: 65ad727684d367af9c8fcbde05ad7989ef2436a4496b62d993059baaa641e90a5fa74e98f34ee2ff29f7af7f2b27238ca78b87834f9068624e4133d786f87bc7 +"luxon@npm:^3.4.4": + version: 3.4.4 + resolution: "luxon@npm:3.4.4" + checksum: 02e26a0b039c11fd5b75e1d734c8f0332c95510f6a514a9a0991023e43fb233884da02d7f966823ffb230632a733fc86d4a4b1e63c3fbe00058b8ee0f8c728af languageName: node linkType: hard @@ -12832,30 +12537,6 @@ __metadata: languageName: node linkType: hard -"make-fetch-happen@npm:^10.0.3, make-fetch-happen@npm:^10.0.6, make-fetch-happen@npm:^10.2.0": - version: 10.2.1 - resolution: "make-fetch-happen@npm:10.2.1" - dependencies: - agentkeepalive: "npm:^4.2.1" - cacache: "npm:^16.1.0" - http-cache-semantics: "npm:^4.1.0" - http-proxy-agent: "npm:^5.0.0" - https-proxy-agent: "npm:^5.0.0" - is-lambda: "npm:^1.0.1" - lru-cache: "npm:^7.7.1" - minipass: "npm:^3.1.6" - minipass-collect: "npm:^1.0.2" - minipass-fetch: "npm:^2.0.3" - minipass-flush: "npm:^1.0.5" - minipass-pipeline: "npm:^1.2.4" - negotiator: "npm:^0.6.3" - promise-retry: "npm:^2.0.1" - socks-proxy-agent: "npm:^7.0.0" - ssri: "npm:^9.0.0" - checksum: 28ec392f63ab93511f400839dcee83107eeecfaad737d1e8487ea08b4332cd89a8f3319584222edd9f6f1d0833cf516691469496d46491863f9e88c658013949 - languageName: node - linkType: hard - "make-fetch-happen@npm:^13.0.0": version: 13.0.0 resolution: "make-fetch-happen@npm:13.0.0" @@ -12891,42 +12572,28 @@ __metadata: languageName: node linkType: hard -"map-obj@npm:^1.0.0": - version: 1.0.1 - resolution: "map-obj@npm:1.0.1" - checksum: ccca88395e7d38671ed9f5652ecf471ecd546924be2fb900836b9da35e068a96687d96a5f93dcdfa94d9a27d649d2f10a84595590f89a347fb4dda47629dcc52 - languageName: node - linkType: hard - -"map-obj@npm:^4.0.0": - version: 4.3.0 - resolution: "map-obj@npm:4.3.0" - checksum: 1c19e1c88513c8abdab25c316367154c6a0a6a0f77e3e8c391bb7c0e093aefed293f539d026dc013d86219e5e4c25f23b0003ea588be2101ccd757bacc12d43b - languageName: node - linkType: hard - -"marked-terminal@npm:^5.1.1": - version: 5.2.0 - resolution: "marked-terminal@npm:5.2.0" +"marked-terminal@npm:^6.0.0": + version: 6.2.0 + resolution: "marked-terminal@npm:6.2.0" dependencies: ansi-escapes: "npm:^6.2.0" cardinal: "npm:^2.1.1" - chalk: "npm:^5.2.0" + chalk: "npm:^5.3.0" cli-table3: "npm:^0.6.3" - node-emoji: "npm:^1.11.0" - supports-hyperlinks: "npm:^2.3.0" + node-emoji: "npm:^2.1.3" + supports-hyperlinks: "npm:^3.0.0" peerDependencies: - marked: ^1.0.0 || ^2.0.0 || ^3.0.0 || ^4.0.0 || ^5.0.0 - checksum: 3f10966cf5c7973453442cf2cf8a5479c68c266723af0de9aa6f0687d40dd30b2820de002bb2c737274223c338ef5fcf1215c7f71092ffa35f448f105713b267 + marked: ">=1 <12" + checksum: 72d4093cbb1ee864ced1f88fdb6fb8dbfea56d6aa3d8a1ec401ac51866ff3c32382c3f4642b19f2d808c798efde23b10300b99e3b6475b3f79e41e7741581d54 languageName: node linkType: hard -"marked@npm:^4.1.0": - version: 4.3.0 - resolution: "marked@npm:4.3.0" +"marked@npm:^9.0.0": + version: 9.1.6 + resolution: "marked@npm:9.1.6" bin: marked: bin/marked.js - checksum: 0013463855e31b9c88d8bb2891a611d10ef1dc79f2e3cbff1bf71ba389e04c5971298c886af0be799d7fa9aa4593b086a136062d59f1210b0480b026a8c5dc47 + checksum: 010bbd33c0f38300259c5d3bf0063deb36bab098d37ac0a3be5a35a65674a4c693427fc6704f486a89f638e9b36c36b8e220a93d47163f4e70e45a1fa8ca7b60 languageName: node linkType: hard @@ -12970,25 +12637,6 @@ __metadata: languageName: node linkType: hard -"meow@npm:^8.0.0": - version: 8.1.2 - resolution: "meow@npm:8.1.2" - dependencies: - "@types/minimist": "npm:^1.2.0" - camelcase-keys: "npm:^6.2.2" - decamelize-keys: "npm:^1.1.0" - hard-rejection: "npm:^2.1.0" - minimist-options: "npm:4.1.0" - normalize-package-data: "npm:^3.0.0" - read-pkg-up: "npm:^7.0.1" - redent: "npm:^3.0.0" - trim-newlines: "npm:^3.0.0" - type-fest: "npm:^0.18.0" - yargs-parser: "npm:^20.2.3" - checksum: 9a8d90e616f783650728a90f4ea1e5f763c1c5260369e6596b52430f877f4af8ecbaa8c9d952c93bbefd6d5bda4caed6a96a20ba7d27b511d2971909b01922a2 - languageName: node - linkType: hard - "merge-stream@npm:^2.0.0": version: 2.0.0 resolution: "merge-stream@npm:2.0.0" @@ -13080,6 +12728,15 @@ __metadata: languageName: node linkType: hard +"minimatch@npm:9.0.3, minimatch@npm:^9.0.0, minimatch@npm:^9.0.1, minimatch@npm:^9.0.3": + version: 9.0.3 + resolution: "minimatch@npm:9.0.3" + dependencies: + brace-expansion: "npm:^2.0.1" + checksum: 85f407dcd38ac3e180f425e86553911d101455ca3ad5544d6a7cec16286657e4f8a9aa6695803025c55e31e35a91a2252b5dc8e7d527211278b8b65b4dbd5eac + languageName: node + linkType: hard + "minimatch@npm:^3.0.4, minimatch@npm:^3.0.5, minimatch@npm:^3.1.1, minimatch@npm:^3.1.2": version: 3.1.2 resolution: "minimatch@npm:3.1.2" @@ -13098,39 +12755,10 @@ __metadata: languageName: node linkType: hard -"minimatch@npm:^5.0.1, minimatch@npm:^5.1.0": - version: 5.1.6 - resolution: "minimatch@npm:5.1.6" - dependencies: - brace-expansion: "npm:^2.0.1" - checksum: 3defdfd230914f22a8da203747c42ee3c405c39d4d37ffda284dac5e45b7e1f6c49aa8be606509002898e73091ff2a3bbfc59c2c6c71d4660609f63aa92f98e3 - languageName: node - linkType: hard - -"minimatch@npm:^9.0.0, minimatch@npm:^9.0.1, minimatch@npm:^9.0.3": - version: 9.0.3 - resolution: "minimatch@npm:9.0.3" - dependencies: - brace-expansion: "npm:^2.0.1" - checksum: 85f407dcd38ac3e180f425e86553911d101455ca3ad5544d6a7cec16286657e4f8a9aa6695803025c55e31e35a91a2252b5dc8e7d527211278b8b65b4dbd5eac - languageName: node - linkType: hard - -"minimist-options@npm:4.1.0": - version: 4.1.0 - resolution: "minimist-options@npm:4.1.0" - dependencies: - arrify: "npm:^1.0.1" - is-plain-obj: "npm:^1.1.0" - kind-of: "npm:^6.0.3" - checksum: 7871f9cdd15d1e7374e5b013e2ceda3d327a06a8c7b38ae16d9ef941e07d985e952c589e57213f7aa90a8744c60aed9524c0d85e501f5478382d9181f2763f54 - languageName: node - linkType: hard - -"minimist@npm:^1.2.0, minimist@npm:^1.2.5": - version: 1.2.8 - resolution: "minimist@npm:1.2.8" - checksum: 19d3fcdca050087b84c2029841a093691a91259a47def2f18222f41e7645a0b7c44ef4b40e88a1e58a40c84d2ef0ee6047c55594d298146d0eb3f6b737c20ce6 +"minimist@npm:^1.2.0, minimist@npm:^1.2.5": + version: 1.2.8 + resolution: "minimist@npm:1.2.8" + checksum: 19d3fcdca050087b84c2029841a093691a91259a47def2f18222f41e7645a0b7c44ef4b40e88a1e58a40c84d2ef0ee6047c55594d298146d0eb3f6b737c20ce6 languageName: node linkType: hard @@ -13143,21 +12771,6 @@ __metadata: languageName: node linkType: hard -"minipass-fetch@npm:^2.0.3": - version: 2.1.2 - resolution: "minipass-fetch@npm:2.1.2" - dependencies: - encoding: "npm:^0.1.13" - minipass: "npm:^3.1.6" - minipass-sized: "npm:^1.0.3" - minizlib: "npm:^2.1.2" - dependenciesMeta: - encoding: - optional: true - checksum: 33ab2c5bdb3d91b9cb8bc6ae42d7418f4f00f7f7beae14b3bb21ea18f9224e792f560a6e17b6f1be12bbeb70dbe99a269f4204c60e5d99130a0777b153505c43 - languageName: node - linkType: hard - "minipass-fetch@npm:^3.0.0": version: 3.0.4 resolution: "minipass-fetch@npm:3.0.4" @@ -13210,7 +12823,7 @@ __metadata: languageName: node linkType: hard -"minipass@npm:^3.0.0, minipass@npm:^3.1.1, minipass@npm:^3.1.6": +"minipass@npm:^3.0.0": version: 3.3.6 resolution: "minipass@npm:3.3.6" dependencies: @@ -13243,18 +12856,7 @@ __metadata: languageName: node linkType: hard -"mkdirp-infer-owner@npm:^2.0.0": - version: 2.0.0 - resolution: "mkdirp-infer-owner@npm:2.0.0" - dependencies: - chownr: "npm:^2.0.0" - infer-owner: "npm:^1.0.4" - mkdirp: "npm:^1.0.3" - checksum: 548356a586b92a16fc90eb62b953e5a23d594b56084ecdf72446f4164bbaa6a3bacd8c140672ad24f10c5f561e16c35ac3d97a5ab422832c5ed5449c72501a03 - languageName: node - linkType: hard - -"mkdirp@npm:^1.0.3, mkdirp@npm:^1.0.4": +"mkdirp@npm:^1.0.3": version: 1.0.4 resolution: "mkdirp@npm:1.0.4" bin: @@ -13263,6 +12865,18 @@ __metadata: languageName: node linkType: hard +"mlly@npm:^1.2.0, mlly@npm:^1.4.2": + version: 1.4.2 + resolution: "mlly@npm:1.4.2" + dependencies: + acorn: "npm:^8.10.0" + pathe: "npm:^1.1.1" + pkg-types: "npm:^1.0.3" + ufo: "npm:^1.3.0" + checksum: 905e3a704c7d3bcaad55f31d6efe9f680eab5be053ab7f8b299b8dbc027041f741fa6a93db9a3c461be2552632f3831b6c43c50af530f5fb2e9cd6273bc9d642 + languageName: node + linkType: hard + "mobx-utils@npm:^5.6.2": version: 5.6.2 resolution: "mobx-utils@npm:5.6.2" @@ -13286,13 +12900,6 @@ __metadata: languageName: node linkType: hard -"modify-values@npm:^1.0.0": - version: 1.0.1 - resolution: "modify-values@npm:1.0.1" - checksum: 6acb1b82aaf7a02f9f7b554b20cbfc159f223a79c66b0a257511c5933d50b85e12ea1220b0a90a2af6f80bc29ff784f929a52a51881867a93ae6a12ce87a729a - languageName: node - linkType: hard - "motion@npm:10.16.2": version: 10.16.2 resolution: "motion@npm:10.16.2" @@ -13307,6 +12914,13 @@ __metadata: languageName: node linkType: hard +"mri@npm:^1.2.0": + version: 1.2.0 + resolution: "mri@npm:1.2.0" + checksum: a3d32379c2554cf7351db6237ddc18dc9e54e4214953f3da105b97dc3babe0deb3ffe99cf409b38ea47cc29f9430561ba6b53b24ab8f9ce97a4b50409e4a50e7 + languageName: node + linkType: hard + "ms@npm:2.0.0": version: 2.0.0 resolution: "ms@npm:2.0.0" @@ -13321,7 +12935,7 @@ __metadata: languageName: node linkType: hard -"ms@npm:^2.0.0, ms@npm:^2.1.2": +"ms@npm:^2.1.2": version: 2.1.3 resolution: "ms@npm:2.1.3" checksum: d924b57e7312b3b63ad21fc5b3dc0af5e78d61a1fc7cfb5457edaf26326bf62be5307cc87ffb6862ef1c2b33b0233cdb5d4f01c4c958cc0d660948b65a287a48 @@ -13335,7 +12949,7 @@ __metadata: languageName: node linkType: hard -"mute-stream@npm:0.0.8, mute-stream@npm:~0.0.4": +"mute-stream@npm:0.0.8": version: 0.0.8 resolution: "mute-stream@npm:0.0.8" checksum: 18d06d92e5d6d45e2b63c0e1b8f25376af71748ac36f53c059baa8b76ffac31c5ab225480494e7d35d30215ecdb18fed26ec23cafcd2f7733f2f14406bcd19e2 @@ -13360,7 +12974,7 @@ __metadata: languageName: node linkType: hard -"nanoid@npm:^3.3.6": +"nanoid@npm:^3.3.6, nanoid@npm:^3.3.7": version: 3.3.7 resolution: "nanoid@npm:3.3.7" bin: @@ -13369,10 +12983,10 @@ __metadata: languageName: node linkType: hard -"natural-compare-lite@npm:^1.4.0": - version: 1.4.0 - resolution: "natural-compare-lite@npm:1.4.0" - checksum: f6cef26f5044515754802c0fc475d81426f3b90fe88c20fabe08771ce1f736ce46e0397c10acb569a4dd0acb84c7f1ee70676122f95d5bfdd747af3a6c6bbaa8 +"napi-wasm@npm:^1.1.0": + version: 1.1.0 + resolution: "napi-wasm@npm:1.1.0" + checksum: 074df6b5b72698f07b39ca3c448a3fcbaf8e6e78521f0cb3aefd8c2f059d69eae0e3bfe367b4aa3df1976c25e351e4e52a359f22fb2c379eb6781bfa042f582b languageName: node linkType: hard @@ -13432,6 +13046,15 @@ __metadata: languageName: node linkType: hard +"node-addon-api@npm:^7.0.0": + version: 7.0.0 + resolution: "node-addon-api@npm:7.0.0" + dependencies: + node-gyp: "npm:latest" + checksum: 3d5a15ee434e122b345e614db122a63f30194c298104c3d8a0fa9f68707abb278af27b45222602456a131890a59b4a92291ff5b4b7938ff282168e9ad1bf7103 + languageName: node + linkType: hard + "node-domexception@npm:^1.0.0": version: 1.0.0 resolution: "node-domexception@npm:1.0.0" @@ -13439,16 +13062,26 @@ __metadata: languageName: node linkType: hard -"node-emoji@npm:^1.11.0": - version: 1.11.0 - resolution: "node-emoji@npm:1.11.0" +"node-emoji@npm:^2.1.3": + version: 2.1.3 + resolution: "node-emoji@npm:2.1.3" dependencies: - lodash: "npm:^4.17.21" - checksum: 5dac6502dbef087092d041fcc2686d8be61168593b3a9baf964d62652f55a3a9c2277f171b81cccb851ccef33f2d070f45e633fab1fda3264f8e1ae9041c673f + "@sindresorhus/is": "npm:^4.6.0" + char-regex: "npm:^1.0.2" + emojilib: "npm:^2.4.0" + skin-tone: "npm:^2.0.0" + checksum: e688333373563aa8308df16111eee2b5837b53a51fb63bf8b7fbea2896327c5d24c9984eb0c8ca6ac155d4d9c194dcf1840d271033c1b588c7c45a3b65339ef7 languageName: node linkType: hard -"node-fetch@npm:^2.6.1, node-fetch@npm:^2.6.12, node-fetch@npm:^2.6.7": +"node-fetch-native@npm:^1.4.0, node-fetch-native@npm:^1.4.1": + version: 1.6.1 + resolution: "node-fetch-native@npm:1.6.1" + checksum: 5df52cd7fb18a51b7e3ec65420b04cd5c01ce6a15ca853b6112a3ae17eb071970a15e7099f3bd258006ab8a0cecac3c7c212800a680466c5bb1a679eab14338f + languageName: node + linkType: hard + +"node-fetch@npm:^2.6.1, node-fetch@npm:^2.6.12": version: 2.7.0 resolution: "node-fetch@npm:2.7.0" dependencies: @@ -13473,6 +13106,13 @@ __metadata: languageName: node linkType: hard +"node-forge@npm:^1.3.1": + version: 1.3.1 + resolution: "node-forge@npm:1.3.1" + checksum: e882819b251a4321f9fc1d67c85d1501d3004b4ee889af822fd07f64de3d1a8e272ff00b689570af0465d65d6bf5074df9c76e900e0aff23e60b847f2a46fbe8 + languageName: node + linkType: hard + "node-gyp-build@npm:^4.3.0": version: 4.6.1 resolution: "node-gyp-build@npm:4.6.1" @@ -13504,27 +13144,6 @@ __metadata: languageName: node linkType: hard -"node-gyp@npm:^9.0.0, node-gyp@npm:^9.1.0": - version: 9.4.1 - resolution: "node-gyp@npm:9.4.1" - dependencies: - env-paths: "npm:^2.2.0" - exponential-backoff: "npm:^3.1.1" - glob: "npm:^7.1.4" - graceful-fs: "npm:^4.2.6" - make-fetch-happen: "npm:^10.0.3" - nopt: "npm:^6.0.0" - npmlog: "npm:^6.0.0" - rimraf: "npm:^3.0.2" - semver: "npm:^7.3.5" - tar: "npm:^6.1.2" - which: "npm:^2.0.2" - bin: - node-gyp: bin/node-gyp.js - checksum: f7d676cfa79f27d35edf17fe9c80064123670362352d19729e5dc9393d7e99f1397491c3107eddc0c0e8941442a6244a7ba6c860cfbe4b433b4cae248a55fe10 - languageName: node - linkType: hard - "node-int64@npm:^0.4.0": version: 0.4.0 resolution: "node-int64@npm:0.4.0" @@ -13539,14 +13158,10 @@ __metadata: languageName: node linkType: hard -"nopt@npm:^6.0.0": - version: 6.0.0 - resolution: "nopt@npm:6.0.0" - dependencies: - abbrev: "npm:^1.0.0" - bin: - nopt: bin/nopt.js - checksum: 837b52c330df16fcaad816b1f54fec6b2854ab1aa771d935c1603fbcf9b023bb073f1466b1b67f48ea4dce127ae675b85b9d9355700e9b109de39db490919786 +"node-releases@npm:^2.0.14": + version: 2.0.14 + resolution: "node-releases@npm:2.0.14" + checksum: 199fc93773ae70ec9969bc6d5ac5b2bbd6eb986ed1907d751f411fef3ede0e4bfdb45ceb43711f8078bea237b6036db8b1bf208f6ff2b70c7d615afd157f3ab9 languageName: node linkType: hard @@ -13561,42 +13176,6 @@ __metadata: languageName: node linkType: hard -"normalize-package-data@npm:^2.5.0": - version: 2.5.0 - resolution: "normalize-package-data@npm:2.5.0" - dependencies: - hosted-git-info: "npm:^2.1.4" - resolve: "npm:^1.10.0" - semver: "npm:2 || 3 || 4 || 5" - validate-npm-package-license: "npm:^3.0.1" - checksum: 357cb1646deb42f8eb4c7d42c4edf0eec312f3628c2ef98501963cc4bbe7277021b2b1d977f982b2edce78f5a1014613ce9cf38085c3df2d76730481357ca504 - languageName: node - linkType: hard - -"normalize-package-data@npm:^3.0.0, normalize-package-data@npm:^3.0.2": - version: 3.0.3 - resolution: "normalize-package-data@npm:3.0.3" - dependencies: - hosted-git-info: "npm:^4.0.1" - is-core-module: "npm:^2.5.0" - semver: "npm:^7.3.4" - validate-npm-package-license: "npm:^3.0.1" - checksum: e5d0f739ba2c465d41f77c9d950e291ea4af78f8816ddb91c5da62257c40b76d8c83278b0d08ffbcd0f187636ebddad20e181e924873916d03e6e5ea2ef026be - languageName: node - linkType: hard - -"normalize-package-data@npm:^4.0.0": - version: 4.0.1 - resolution: "normalize-package-data@npm:4.0.1" - dependencies: - hosted-git-info: "npm:^5.0.0" - is-core-module: "npm:^2.8.1" - semver: "npm:^7.3.5" - validate-npm-package-license: "npm:^3.0.4" - checksum: 3a6ace810d1bd2fd23b98fa53790a28bbfade5380eea0f2e0cc5cbc24987db43a4780846942edee7069fa9574bf050a9ed8d35faf9079e5e4d9a737d07a136dd - languageName: node - linkType: hard - "normalize-package-data@npm:^6.0.0": version: 6.0.0 resolution: "normalize-package-data@npm:6.0.0" @@ -13632,7 +13211,7 @@ __metadata: languageName: node linkType: hard -"normalize-url@npm:^6.0.0, normalize-url@npm:^6.0.1": +"normalize-url@npm:^6.0.1": version: 6.1.0 resolution: "normalize-url@npm:6.1.0" checksum: 95d948f9bdd2cfde91aa786d1816ae40f8262946e13700bf6628105994fe0ff361662c20af3961161c38a119dc977adeb41fc0b41b1745eb77edaaf9cb22db23 @@ -13646,15 +13225,6 @@ __metadata: languageName: node linkType: hard -"npm-audit-report@npm:^3.0.0": - version: 3.0.0 - resolution: "npm-audit-report@npm:3.0.0" - dependencies: - chalk: "npm:^4.0.0" - checksum: a8ce2ce80cc11334d58fef28f0b8eef1626f134942d27212dbac8c2dfbfe10373d2978101ceb2b472b8199170bb1c6986f32d33d9879f05d28a32ec56d743915 - languageName: node - linkType: hard - "npm-audit-report@npm:^5.0.0": version: 5.0.0 resolution: "npm-audit-report@npm:5.0.0" @@ -13662,24 +13232,6 @@ __metadata: languageName: node linkType: hard -"npm-bundled@npm:^1.1.1": - version: 1.1.2 - resolution: "npm-bundled@npm:1.1.2" - dependencies: - npm-normalize-package-bin: "npm:^1.0.1" - checksum: 3f2337789afc8cb608a0dd71cefe459531053d48a5497db14b07b985c4cab15afcae88600db9f92eae072c89b982eeeec8e4463e1d77bc03a7e90f5dacf29769 - languageName: node - linkType: hard - -"npm-bundled@npm:^2.0.0": - version: 2.0.1 - resolution: "npm-bundled@npm:2.0.1" - dependencies: - npm-normalize-package-bin: "npm:^2.0.0" - checksum: 5b2dc1de455d38200e49c6205dee185ce919ea6b608672c693bec8907116bc5686dabcc150347630d351c1c533315fd60a1910ce00bdad6bb204cef016b90b7d - languageName: node - linkType: hard - "npm-bundled@npm:^3.0.0": version: 3.0.0 resolution: "npm-bundled@npm:3.0.0" @@ -13689,15 +13241,6 @@ __metadata: languageName: node linkType: hard -"npm-install-checks@npm:^5.0.0": - version: 5.0.0 - resolution: "npm-install-checks@npm:5.0.0" - dependencies: - semver: "npm:^7.1.1" - checksum: eb108e1c1ac38c76f9a658ab2b4871836246e262836c05d42a23049e0399e6c8cdcf65a1e50193b64807a3b2b86f8e158d0161db98e846d7e9617bc5f49337af - languageName: node - linkType: hard - "npm-install-checks@npm:^6.0.0, npm-install-checks@npm:^6.2.0, npm-install-checks@npm:^6.3.0": version: 6.3.0 resolution: "npm-install-checks@npm:6.3.0" @@ -13707,20 +13250,6 @@ __metadata: languageName: node linkType: hard -"npm-normalize-package-bin@npm:^1.0.1": - version: 1.0.1 - resolution: "npm-normalize-package-bin@npm:1.0.1" - checksum: b0c8c05fe419a122e0ff970ccbe7874ae24b4b4b08941a24d18097fe6e1f4b93e3f6abfb5512f9c5488827a5592f2fb3ce2431c41d338802aed24b9a0c160551 - languageName: node - linkType: hard - -"npm-normalize-package-bin@npm:^2.0.0": - version: 2.0.0 - resolution: "npm-normalize-package-bin@npm:2.0.0" - checksum: 9b5283a2e423124c60fbc14244d36686b59e517d29156eacf9df8d3dc5d5bf4d9444b7669c607567ed2e089bbdbef5a2b3678cbf567284eeff3612da6939514b - languageName: node - linkType: hard - "npm-normalize-package-bin@npm:^3.0.0": version: 3.0.1 resolution: "npm-normalize-package-bin@npm:3.0.1" @@ -13740,32 +13269,6 @@ __metadata: languageName: node linkType: hard -"npm-package-arg@npm:^9.0.0, npm-package-arg@npm:^9.0.1, npm-package-arg@npm:^9.1.0": - version: 9.1.2 - resolution: "npm-package-arg@npm:9.1.2" - dependencies: - hosted-git-info: "npm:^5.0.0" - proc-log: "npm:^2.0.1" - semver: "npm:^7.3.5" - validate-npm-package-name: "npm:^4.0.0" - checksum: e81aa931adfc5f19fb9f10fe9eb120a0203d63b879594b1a473c64257761cdde42e32fb5d9b2e90d6944a3229e8c3ffa62ce8c31a7c9c4971d34f9219fdc0bb5 - languageName: node - linkType: hard - -"npm-packlist@npm:^5.1.0": - version: 5.1.3 - resolution: "npm-packlist@npm:5.1.3" - dependencies: - glob: "npm:^8.0.1" - ignore-walk: "npm:^5.0.1" - npm-bundled: "npm:^2.0.0" - npm-normalize-package-bin: "npm:^2.0.0" - bin: - npm-packlist: bin/index.js - checksum: a8bea97661b2a7132bc8832d5560da24f823ee5324429bd16eb82b7873557de14641bc3fed8a7611b0d88b9771e59e99e01a9e551a53adb164327ded6128aada - languageName: node - linkType: hard - "npm-packlist@npm:^8.0.0": version: 8.0.0 resolution: "npm-packlist@npm:8.0.0" @@ -13775,18 +13278,6 @@ __metadata: languageName: node linkType: hard -"npm-pick-manifest@npm:^7.0.0, npm-pick-manifest@npm:^7.0.2": - version: 7.0.2 - resolution: "npm-pick-manifest@npm:7.0.2" - dependencies: - npm-install-checks: "npm:^5.0.0" - npm-normalize-package-bin: "npm:^2.0.0" - npm-package-arg: "npm:^9.0.0" - semver: "npm:^7.3.5" - checksum: 522ba83a9ec92405b720a135b4333bc237063994f1244ff8125fd906979feedff3775472caa87779a260294ff4d2cd949c6f679ab353b2d81bca76c466539b67 - languageName: node - linkType: hard - "npm-pick-manifest@npm:^9.0.0": version: 9.0.0 resolution: "npm-pick-manifest@npm:9.0.0" @@ -13799,16 +13290,6 @@ __metadata: languageName: node linkType: hard -"npm-profile@npm:^6.2.0": - version: 6.2.1 - resolution: "npm-profile@npm:6.2.1" - dependencies: - npm-registry-fetch: "npm:^13.0.1" - proc-log: "npm:^2.0.0" - checksum: 1397ce26905a4ca1a2ea4080acbceeddc93fcac753295b8cc7738e38b8e0018d59219c6cb7c5a059d870b3e94bd6bac6aea628dd971dbe47e0ec2d82f7e0a031 - languageName: node - linkType: hard - "npm-profile@npm:^9.0.0": version: 9.0.0 resolution: "npm-profile@npm:9.0.0" @@ -13819,21 +13300,6 @@ __metadata: languageName: node linkType: hard -"npm-registry-fetch@npm:^13.0.0, npm-registry-fetch@npm:^13.0.1, npm-registry-fetch@npm:^13.3.1": - version: 13.3.1 - resolution: "npm-registry-fetch@npm:13.3.1" - dependencies: - make-fetch-happen: "npm:^10.0.6" - minipass: "npm:^3.1.6" - minipass-fetch: "npm:^2.0.3" - minipass-json-stream: "npm:^1.0.1" - minizlib: "npm:^2.1.2" - npm-package-arg: "npm:^9.0.1" - proc-log: "npm:^2.0.0" - checksum: 86c8cdc2b0d2aa97d06031962f39442b0eacecd9989eebc88451e6b53b3c8572b89fb09cf0042ce6080e7d120353af359a75c5f60b085b5b455337d1e39e57ab - languageName: node - linkType: hard - "npm-registry-fetch@npm:^16.0.0, npm-registry-fetch@npm:^16.1.0": version: 16.1.0 resolution: "npm-registry-fetch@npm:16.1.0" @@ -13867,13 +13333,6 @@ __metadata: languageName: node linkType: hard -"npm-user-validate@npm:^1.0.1": - version: 1.0.1 - resolution: "npm-user-validate@npm:1.0.1" - checksum: b6533da7df07c4495e8e209eba7191846683443503897e10e0acfb52fedefde34028f221b7ee5ae45b79ada13748a8e881a20392cd0fb93d190b1bf54ef1ee42 - languageName: node - linkType: hard - "npm-user-validate@npm:^2.0.0": version: 2.0.0 resolution: "npm-user-validate@npm:2.0.0" @@ -13963,102 +13422,6 @@ __metadata: languageName: node linkType: hard -"npm@npm:^8.3.0": - version: 8.19.4 - resolution: "npm@npm:8.19.4" - dependencies: - "@isaacs/string-locale-compare": "npm:^1.1.0" - "@npmcli/arborist": "npm:^5.6.3" - "@npmcli/ci-detect": "npm:^2.0.0" - "@npmcli/config": "npm:^4.2.1" - "@npmcli/fs": "npm:^2.1.0" - "@npmcli/map-workspaces": "npm:^2.0.3" - "@npmcli/package-json": "npm:^2.0.0" - "@npmcli/run-script": "npm:^4.2.1" - abbrev: "npm:~1.1.1" - archy: "npm:~1.0.0" - cacache: "npm:^16.1.3" - chalk: "npm:^4.1.2" - chownr: "npm:^2.0.0" - cli-columns: "npm:^4.0.0" - cli-table3: "npm:^0.6.2" - columnify: "npm:^1.6.0" - fastest-levenshtein: "npm:^1.0.12" - fs-minipass: "npm:^2.1.0" - glob: "npm:^8.0.1" - graceful-fs: "npm:^4.2.10" - hosted-git-info: "npm:^5.2.1" - ini: "npm:^3.0.1" - init-package-json: "npm:^3.0.2" - is-cidr: "npm:^4.0.2" - json-parse-even-better-errors: "npm:^2.3.1" - libnpmaccess: "npm:^6.0.4" - libnpmdiff: "npm:^4.0.5" - libnpmexec: "npm:^4.0.14" - libnpmfund: "npm:^3.0.5" - libnpmhook: "npm:^8.0.4" - libnpmorg: "npm:^4.0.4" - libnpmpack: "npm:^4.1.3" - libnpmpublish: "npm:^6.0.5" - libnpmsearch: "npm:^5.0.4" - libnpmteam: "npm:^4.0.4" - libnpmversion: "npm:^3.0.7" - make-fetch-happen: "npm:^10.2.0" - minimatch: "npm:^5.1.0" - minipass: "npm:^3.1.6" - minipass-pipeline: "npm:^1.2.4" - mkdirp: "npm:^1.0.4" - mkdirp-infer-owner: "npm:^2.0.0" - ms: "npm:^2.1.2" - node-gyp: "npm:^9.1.0" - nopt: "npm:^6.0.0" - npm-audit-report: "npm:^3.0.0" - npm-install-checks: "npm:^5.0.0" - npm-package-arg: "npm:^9.1.0" - npm-pick-manifest: "npm:^7.0.2" - npm-profile: "npm:^6.2.0" - npm-registry-fetch: "npm:^13.3.1" - npm-user-validate: "npm:^1.0.1" - npmlog: "npm:^6.0.2" - opener: "npm:^1.5.2" - p-map: "npm:^4.0.0" - pacote: "npm:^13.6.2" - parse-conflict-json: "npm:^2.0.2" - proc-log: "npm:^2.0.1" - qrcode-terminal: "npm:^0.12.0" - read: "npm:~1.0.7" - read-package-json: "npm:^5.0.2" - read-package-json-fast: "npm:^2.0.3" - readdir-scoped-modules: "npm:^1.1.0" - rimraf: "npm:^3.0.2" - semver: "npm:^7.3.7" - ssri: "npm:^9.0.1" - tar: "npm:^6.1.11" - text-table: "npm:~0.2.0" - tiny-relative-date: "npm:^1.3.0" - treeverse: "npm:^2.0.0" - validate-npm-package-name: "npm:^4.0.0" - which: "npm:^2.0.2" - write-file-atomic: "npm:^4.0.1" - bin: - npm: bin/npm-cli.js - npx: bin/npx-cli.js - checksum: a27e0d108f6281b66fcad8daf6501dac62791285b974eba283275e65be1ababa8222b4e33fd95fddbd7236481e694141018f6715dac4831bcae3a54add092080 - languageName: node - linkType: hard - -"npmlog@npm:^6.0.0, npmlog@npm:^6.0.2": - version: 6.0.2 - resolution: "npmlog@npm:6.0.2" - dependencies: - are-we-there-yet: "npm:^3.0.0" - console-control-strings: "npm:^1.1.0" - gauge: "npm:^4.0.3" - set-blocking: "npm:^2.0.0" - checksum: 0cacedfbc2f6139c746d9cd4a85f62718435ad0ca4a2d6459cd331dd33ae58206e91a0742c1558634efcde3f33f8e8e7fd3adf1bfe7978310cf00bd55cccf890 - languageName: node - linkType: hard - "npmlog@npm:^7.0.1": version: 7.0.1 resolution: "npmlog@npm:7.0.1" @@ -14187,6 +13550,17 @@ __metadata: languageName: node linkType: hard +"ofetch@npm:^1.3.3": + version: 1.3.3 + resolution: "ofetch@npm:1.3.3" + dependencies: + destr: "npm:^2.0.1" + node-fetch-native: "npm:^1.4.0" + ufo: "npm:^1.3.0" + checksum: ac4d2519841c6ffcbb3f5dee6db7f29dc273e15d8fd6ee89d9dbfae7c0542cd72a2424e8527ae7147b36eec35667066754aeb69dc7c02e6c8dcb943579e9764e + languageName: node + linkType: hard + "on-exit-leak-free@npm:^0.2.0": version: 0.2.0 resolution: "on-exit-leak-free@npm:0.2.0" @@ -14221,15 +13595,6 @@ __metadata: languageName: node linkType: hard -"opener@npm:^1.5.2": - version: 1.5.2 - resolution: "opener@npm:1.5.2" - bin: - opener: bin/opener-bin.js - checksum: dd56256ab0cf796585617bc28e06e058adf09211781e70b264c76a1dbe16e90f868c974e5bf5309c93469157c7d14b89c35dc53fe7293b0e40b4d2f92073bc79 - languageName: node - linkType: hard - "optionator@npm:^0.9.3": version: 0.9.3 resolution: "optionator@npm:0.9.3" @@ -14275,21 +13640,12 @@ __metadata: languageName: node linkType: hard -"p-filter@npm:^2.0.0": - version: 2.1.0 - resolution: "p-filter@npm:2.1.0" - dependencies: - p-map: "npm:^2.0.0" - checksum: 5ac34b74b3b691c04212d5dd2319ed484f591c557a850a3ffc93a08cb38c4f5540be059c6b10a185773c479ca583a91ea00c7d6c9958c815e6b74d052f356645 - languageName: node - linkType: hard - -"p-filter@npm:^3.0.0": - version: 3.0.0 - resolution: "p-filter@npm:3.0.0" +"p-filter@npm:^4.0.0": + version: 4.1.0 + resolution: "p-filter@npm:4.1.0" dependencies: - p-map: "npm:^5.1.0" - checksum: 32e375fa6b3afd8b5eb65915746b75a471a3bedf38264dc9d738d6b1b8a0b2797b06b363f637b3387e766e0c7c6fab316cb1119e353baf7936da3ba6d8a4ac8d + p-map: "npm:^7.0.1" + checksum: aaa663a74e7d97846377f1b7f7713692f95ca3320f0e6f7f2f06db073926bd8ef7b452d0eefc102c6c23f7482339fc52ea487aec2071dc01cae054665f3f004e languageName: node linkType: hard @@ -14334,15 +13690,6 @@ __metadata: languageName: node linkType: hard -"p-limit@npm:^4.0.0": - version: 4.0.0 - resolution: "p-limit@npm:4.0.0" - dependencies: - yocto-queue: "npm:^1.0.0" - checksum: a56af34a77f8df2ff61ddfb29431044557fcbcb7642d5a3233143ebba805fc7306ac1d448de724352861cb99de934bc9ab74f0d16fe6a5460bdbdf938de875ad - languageName: node - linkType: hard - "p-locate@npm:^2.0.0": version: 2.0.0 resolution: "p-locate@npm:2.0.0" @@ -14370,22 +13717,6 @@ __metadata: languageName: node linkType: hard -"p-locate@npm:^6.0.0": - version: 6.0.0 - resolution: "p-locate@npm:6.0.0" - dependencies: - p-limit: "npm:^4.0.0" - checksum: d72fa2f41adce59c198270aa4d3c832536c87a1806e0f69dffb7c1a7ca998fb053915ca833d90f166a8c082d3859eabfed95f01698a3214c20df6bb8de046312 - languageName: node - linkType: hard - -"p-map@npm:^2.0.0": - version: 2.1.0 - resolution: "p-map@npm:2.1.0" - checksum: 735dae87badd4737a2dd582b6d8f93e49a1b79eabbc9815a4d63a528d5e3523e978e127a21d784cccb637010e32103a40d2aaa3ab23ae60250b1a820ca752043 - languageName: node - linkType: hard - "p-map@npm:^4.0.0": version: 4.0.0 resolution: "p-map@npm:4.0.0" @@ -14395,12 +13726,10 @@ __metadata: languageName: node linkType: hard -"p-map@npm:^5.1.0": - version: 5.5.0 - resolution: "p-map@npm:5.5.0" - dependencies: - aggregate-error: "npm:^4.0.0" - checksum: 410bce846b1e3db6bb2ccab6248372ecf4e635fc2b31331c8f56478e73fec9e146e8b4547585e635703160a3d252a6a65b8f855834aebc2c3408eb5789630cc4 +"p-map@npm:^7.0.1": + version: 7.0.1 + resolution: "p-map@npm:7.0.1" + checksum: c8ffa481d52e38a8d3e48c0628a63afd1fe8510d8d3feb0f0693351a52338c750e105bf74ff171dd7e6aed1ad26c2dd03aa1f8cfd86552cb5cbbc5054d311d74 languageName: node linkType: hard @@ -14451,37 +13780,6 @@ __metadata: languageName: node linkType: hard -"pacote@npm:^13.0.3, pacote@npm:^13.6.1, pacote@npm:^13.6.2": - version: 13.6.2 - resolution: "pacote@npm:13.6.2" - dependencies: - "@npmcli/git": "npm:^3.0.0" - "@npmcli/installed-package-contents": "npm:^1.0.7" - "@npmcli/promise-spawn": "npm:^3.0.0" - "@npmcli/run-script": "npm:^4.1.0" - cacache: "npm:^16.0.0" - chownr: "npm:^2.0.0" - fs-minipass: "npm:^2.1.0" - infer-owner: "npm:^1.0.4" - minipass: "npm:^3.1.6" - mkdirp: "npm:^1.0.4" - npm-package-arg: "npm:^9.0.0" - npm-packlist: "npm:^5.1.0" - npm-pick-manifest: "npm:^7.0.0" - npm-registry-fetch: "npm:^13.0.1" - proc-log: "npm:^2.0.0" - promise-retry: "npm:^2.0.1" - read-package-json: "npm:^5.0.0" - read-package-json-fast: "npm:^2.0.3" - rimraf: "npm:^3.0.2" - ssri: "npm:^9.0.0" - tar: "npm:^6.1.11" - bin: - pacote: lib/bin.js - checksum: 134d4ae5c3ab4a1745ee24de228796d7222320813d67d26016f6607319d6135d1b4fa2f4200d6d964be89749525b0daff893338237ac6284bb9b4a7a36770696 - languageName: node - linkType: hard - "pacote@npm:^17.0.0, pacote@npm:^17.0.4": version: 17.0.4 resolution: "pacote@npm:17.0.4" @@ -14536,17 +13834,6 @@ __metadata: languageName: node linkType: hard -"parse-conflict-json@npm:^2.0.1, parse-conflict-json@npm:^2.0.2": - version: 2.0.2 - resolution: "parse-conflict-json@npm:2.0.2" - dependencies: - json-parse-even-better-errors: "npm:^2.3.1" - just-diff: "npm:^5.0.1" - just-diff-apply: "npm:^5.2.0" - checksum: 7a6a116017cd2629d95eda0325d5928d950c69df412f2c14ca02c9581a606f258404a16a3b9a67a3294ca9e6e12571e65be4f80d3879b53c5b842fbae0495fd4 - languageName: node - linkType: hard - "parse-conflict-json@npm:^3.0.0, parse-conflict-json@npm:^3.0.1": version: 3.0.1 resolution: "parse-conflict-json@npm:3.0.1" @@ -14646,13 +13933,6 @@ __metadata: languageName: node linkType: hard -"path-exists@npm:^5.0.0": - version: 5.0.0 - resolution: "path-exists@npm:5.0.0" - checksum: b170f3060b31604cde93eefdb7392b89d832dfbc1bed717c9718cbe0f230c1669b7e75f87e19901da2250b84d092989a0f9e44d2ef41deb09aa3ad28e691a40a - languageName: node - linkType: hard - "path-is-absolute@npm:^1.0.0": version: 1.0.1 resolution: "path-is-absolute@npm:1.0.1" @@ -14721,23 +14001,30 @@ __metadata: languageName: node linkType: hard +"pathe@npm:^1.1.0, pathe@npm:^1.1.1": + version: 1.1.1 + resolution: "pathe@npm:1.1.1" + checksum: 3ae5a0529c3415d91c3ac9133f52cffea54a0dd46892fe059f4b80faf36fd207957d4594bdc87043b65d0761b1e5728f81f46bafff3b5302da4e2e48889b8c0e + languageName: node + linkType: hard + "pendulum-chain-portal@workspace:.": version: 0.0.0-use.local resolution: "pendulum-chain-portal@workspace:." dependencies: - "@babel/core": "npm:^7.20.12" + "@babel/core": "npm:^7.23.7" "@babel/plugin-proposal-class-properties": "npm:^7.18.6" - "@babel/preset-env": "npm:^7.20.2" - "@babel/preset-typescript": "npm:^7.18.6" + "@babel/preset-env": "npm:^7.23.7" + "@babel/preset-typescript": "npm:^7.23.3" "@esbuild-plugins/node-globals-polyfill": "npm:^0.1.1" "@esbuild-plugins/node-modules-polyfill": "npm:^0.1.4" "@graphql-codegen/cli": "npm:~5.0.0" "@graphql-codegen/client-preset": "npm:~4.1.0" - "@heroicons/react": "npm:^2.0.18" + "@heroicons/react": "npm:^2.1.1" "@hookform/resolvers": "npm:^2.9.11" "@pendulum-chain/api": "npm:^0.3.1" - "@pendulum-chain/api-solang": "npm:^0.0.6" - "@pendulum-chain/types": "npm:^0.2.3" + "@pendulum-chain/api-solang": "npm:~0.1.1" + "@pendulum-chain/types": "npm:^0.2.4" "@polkadot/api": "npm:^9.9.1" "@polkadot/api-base": "npm:^9.9.1" "@polkadot/api-contract": "npm:^9.9.1" @@ -14757,7 +14044,7 @@ __metadata: "@semantic-release/changelog": "npm:^6.0.3" "@semantic-release/commit-analyzer": "npm:^11.1.0" "@semantic-release/git": "npm:^10.0.1" - "@semantic-release/github": "npm:^9.2.4" + "@semantic-release/github": "npm:^9.2.6" "@semantic-release/npm": "npm:^11.0.1" "@semantic-release/release-notes-generator": "npm:^12.1.0" "@talismn/connect-components": "npm:^1.1.7" @@ -14766,41 +14053,42 @@ __metadata: "@tanstack/query-sync-storage-persister": "npm:~4.32.6" "@tanstack/react-query": "npm:~4.32.6" "@tanstack/react-query-persist-client": "npm:~4.32.6" - "@tanstack/react-table": "npm:^8.10.7" - "@testing-library/jest-dom": "npm:^5.16.5" + "@tanstack/react-table": "npm:^8.11.2" + "@testing-library/jest-dom": "npm:^6.1.6" "@testing-library/preact": "npm:^3.2.3" "@testing-library/preact-hooks": "npm:^1.1.0" - "@types/big.js": "npm:^6.1.6" - "@types/jest": "npm:^29.4.0" - "@types/lodash": "npm:^4" - "@types/luxon": "npm:^3.2.0" - "@types/node": "npm:^18.14.1" - "@types/react": "npm:^18.0.28" - "@types/react-table": "npm:^7.7.12" - "@types/testing-library__jest-dom": "npm:^5.14.5" - "@typescript-eslint/eslint-plugin": "npm:^5.53.0" - "@typescript-eslint/parser": "npm:^5.53.0" - "@walletconnect/modal": "npm:^2.4.7" - "@walletconnect/universal-provider": "npm:^2.8.1" - autoprefixer: "npm:^10.4.13" + "@types/big.js": "npm:^6.2.2" + "@types/jest": "npm:^29.5.11" + "@types/lodash": "npm:^4.14.202" + "@types/luxon": "npm:^3.3.7" + "@types/node": "npm:^18.19.4" + "@types/react": "npm:^18.2.46" + "@types/react-table": "npm:^7.7.18" + "@types/testing-library__jest-dom": "npm:^6.0.0" + "@typescript-eslint/eslint-plugin": "npm:^6.17.0" + "@typescript-eslint/parser": "npm:^6.17.0" + "@walletconnect/modal": "npm:^2.6.2" + "@walletconnect/universal-provider": "npm:^2.11.0" + autoprefixer: "npm:^10.4.16" big.js: "npm:^6.2.1" bn.js: "npm:^5.2.1" bs58: "npm:^5.0.0" daisyui: "npm:^2.52.0" - eslint: "npm:^8.34.0" - eslint-plugin-jest: "npm:^27.2.1" - eslint-plugin-react: "npm:^7.32.2" + eslint: "npm:^8.56.0" + eslint-plugin-jest: "npm:^27.6.1" + eslint-plugin-react: "npm:^7.33.2" eslint-plugin-react-hooks: "npm:^4.6.0" graphql: "npm:~16.6.0" graphql-request: "npm:~6.1.0" - jest: "npm:^29.4.3" - jest-environment-jsdom: "npm:^29.4.3" + jest: "npm:^29.7.0" + jest-environment-jsdom: "npm:^29.7.0" lodash: "npm:^4.17.21" - luxon: "npm:^3.2.1" + luxon: "npm:^3.4.4" match-sorter: "npm:^6.3.1" postcss: "npm:^8.4.21" - preact: "npm:^10.12.1" - prettier: "npm:^2.8.4" + postcss-import: "npm:^15.1.0" + preact: "npm:^10.19.3" + prettier: "npm:^3.1.1" react-daisyui: "npm:^3.1.2" react-device-detect: "npm:^2.2.3" react-hook-form: "npm:^7.43.2" @@ -14808,13 +14096,13 @@ __metadata: react-table: "npm:^7.8.0" react-toastify: "npm:^9.1.3" sass: "npm:^1.58.3" - semantic-release: "npm:^20.1.3" + semantic-release: "npm:^22.0.12" stellar-sdk: "npm:^10.4.1" - tailwindcss: "npm:^3.2.7" - ts-node: "npm:^10.9.1" + tailwindcss: "npm:^3.4.0" + ts-node: "npm:^10.9.2" typescript: "npm:^4.9.5" - vite: "npm:^3.2.5" - yup: "npm:^1.3.2" + vite: "npm:^3.2.7" + yup: "npm:^1.3.3" languageName: unknown linkType: soft @@ -14917,6 +14205,17 @@ __metadata: languageName: node linkType: hard +"pkg-types@npm:^1.0.3": + version: 1.0.3 + resolution: "pkg-types@npm:1.0.3" + dependencies: + jsonc-parser: "npm:^3.2.0" + mlly: "npm:^1.2.0" + pathe: "npm:^1.1.0" + checksum: 7f692ff2005f51b8721381caf9bdbc7f5461506ba19c34f8631660a215c8de5e6dca268f23a319dd180b8f7c47a0dc6efea14b376c485ff99e98d810b8f786c4 + languageName: node + linkType: hard + "pngjs@npm:^5.0.0": version: 5.0.0 resolution: "pngjs@npm:5.0.0" @@ -15397,7 +14696,7 @@ __metadata: languageName: node linkType: hard -"postcss@npm:^8, postcss@npm:^8.4.18, postcss@npm:^8.4.21, postcss@npm:^8.4.23, postcss@npm:^8.4.5": +"postcss@npm:^8, postcss@npm:^8.4.18, postcss@npm:^8.4.23, postcss@npm:^8.4.5": version: 8.4.31 resolution: "postcss@npm:8.4.31" dependencies: @@ -15408,10 +14707,21 @@ __metadata: languageName: node linkType: hard -"preact@npm:^10.12.1": - version: 10.18.2 - resolution: "preact@npm:10.18.2" - checksum: a92890a13c5d19fccc163e3d84c88a9da3c3996d0d9df6ca311c8018320a07e3ec4ecce0836cde46d940a031141d35fbe456123a794b8160bd8fa2d96c7d32a3 +"postcss@npm:^8.4.21": + version: 8.4.32 + resolution: "postcss@npm:8.4.32" + dependencies: + nanoid: "npm:^3.3.7" + picocolors: "npm:^1.0.0" + source-map-js: "npm:^1.0.2" + checksum: 39308a9195fa34d4dbdd7b58a896cff0c7809f84f7a4ac1b95b68ca86c9138a395addff33075668ed3983d41b90aac05754c445237a9365eb1c3a5602ebd03ad + languageName: node + linkType: hard + +"preact@npm:^10.19.3": + version: 10.19.3 + resolution: "preact@npm:10.19.3" + checksum: 251b237cc6fc8c39e4dc6cd65df1964b9622ec6005ccdaa57ea43171ba3e1e0f1e3386bbade370b2ce26ea480ceb73ea36b40e635e35e017e2d8614a233e1bed languageName: node linkType: hard @@ -15422,12 +14732,12 @@ __metadata: languageName: node linkType: hard -"prettier@npm:^2.8.4": - version: 2.8.8 - resolution: "prettier@npm:2.8.8" +"prettier@npm:^3.1.1": + version: 3.1.1 + resolution: "prettier@npm:3.1.1" bin: - prettier: bin-prettier.js - checksum: 463ea8f9a0946cd5b828d8cf27bd8b567345cf02f56562d5ecde198b91f47a76b7ac9eae0facd247ace70e927143af6135e8cf411986b8cb8478784a4d6d724a + prettier: bin/prettier.cjs + checksum: facc944ba20e194ff4db765e830ffbcb642803381f0d2033ed397e79904fa4ccc877dc25ad68f42d36985c01d051c990ca1b905fb83d2d7d65fe69e4386fa1a3 languageName: node linkType: hard @@ -15453,13 +14763,6 @@ __metadata: languageName: node linkType: hard -"proc-log@npm:^2.0.0, proc-log@npm:^2.0.1": - version: 2.0.1 - resolution: "proc-log@npm:2.0.1" - checksum: 701c501429775ce34cec28ef6a1c976537274b42917212fb8a5975ebcecb0a85612907fd7f99ff28ff4c2112bb84a0f4322fc9b9e1e52a8562fcbb1d5b3ce608 - languageName: node - linkType: hard - "proc-log@npm:^3.0.0": version: 3.0.0 resolution: "proc-log@npm:3.0.0" @@ -15495,7 +14798,7 @@ __metadata: languageName: node linkType: hard -"promise-call-limit@npm:^1.0.1, promise-call-limit@npm:^1.0.2": +"promise-call-limit@npm:^1.0.2": version: 1.0.2 resolution: "promise-call-limit@npm:1.0.2" checksum: 500aed321d7b9212da403db369551d7190c96c8937c3b2d15c6097d1037b17fb802c7decfbc8ba6bb937f1cc1ea291e5eba10ed9ea76adc0f398ab9f7d174a58 @@ -15545,15 +14848,6 @@ __metadata: languageName: node linkType: hard -"promzard@npm:^0.3.0": - version: 0.3.0 - resolution: "promzard@npm:0.3.0" - dependencies: - read: "npm:1" - checksum: 7fd8dbcd9764b35092da65867cc60fdcf2ea85d77e8ed1ae348ec0af1a22616f74053ccf8dad7d8de01e1e3aafe349d77ef56653c2db3791589ac2a8ef485149 - languageName: node - linkType: hard - "promzard@npm:^1.0.0": version: 1.0.0 resolution: "promzard@npm:1.0.0" @@ -15646,13 +14940,6 @@ __metadata: languageName: node linkType: hard -"q@npm:^1.5.1": - version: 1.5.1 - resolution: "q@npm:1.5.1" - checksum: 7855fbdba126cb7e92ef3a16b47ba998c0786ec7fface236e3eb0135b65df36429d91a86b1fff3ab0927b4ac4ee88a2c44527c7c3b8e2a37efbec9fe34803df4 - languageName: node - linkType: hard - "qrcode-terminal@npm:^0.12.0": version: 0.12.0 resolution: "qrcode-terminal@npm:0.12.0" @@ -15709,10 +14996,10 @@ __metadata: languageName: node linkType: hard -"quick-lru@npm:^4.0.1": - version: 4.0.1 - resolution: "quick-lru@npm:4.0.1" - checksum: f9b1596fa7595a35c2f9d913ac312fede13d37dc8a747a51557ab36e11ce113bbe88ef4c0154968845559a7709cb6a7e7cbe75f7972182451cd45e7f057a334d +"radix3@npm:^1.1.0": + version: 1.1.0 + resolution: "radix3@npm:1.1.0" + checksum: a0c3b2c698e365cf6ff8dd01d4651d5e79042c55dc008871247aa5e0d60951d86a00457ce0c75e3a71adc52992aa4c33ab060a63771d2dfb6a0c1502b97a644c languageName: node linkType: hard @@ -15879,13 +15166,6 @@ __metadata: languageName: node linkType: hard -"read-cmd-shim@npm:^3.0.0": - version: 3.0.1 - resolution: "read-cmd-shim@npm:3.0.1" - checksum: a157c401161d28178aee45b70fae5f721b4f65ddedd728c51e21c3d2ea09715f73bcd33e87462bc27601f3445dce313d44e99450fafa48ded0b295445c49c2bf - languageName: node - linkType: hard - "read-cmd-shim@npm:^4.0.0": version: 4.0.0 resolution: "read-cmd-shim@npm:4.0.0" @@ -15893,16 +15173,6 @@ __metadata: languageName: node linkType: hard -"read-package-json-fast@npm:^2.0.2, read-package-json-fast@npm:^2.0.3": - version: 2.0.3 - resolution: "read-package-json-fast@npm:2.0.3" - dependencies: - json-parse-even-better-errors: "npm:^2.3.0" - npm-normalize-package-bin: "npm:^1.0.1" - checksum: c265a5d6c85f4c8ee0bf35b0b0d92800a7439e5cf4d1f5a2b3f9615a02ee2fd46bca6c2f07e244bfac1c40816eb0d28aec259ae99d7552d144dd9f971a5d2028 - languageName: node - linkType: hard - "read-package-json-fast@npm:^3.0.0, read-package-json-fast@npm:^3.0.2": version: 3.0.2 resolution: "read-package-json-fast@npm:3.0.2" @@ -15913,18 +15183,6 @@ __metadata: languageName: node linkType: hard -"read-package-json@npm:^5.0.0, read-package-json@npm:^5.0.2": - version: 5.0.2 - resolution: "read-package-json@npm:5.0.2" - dependencies: - glob: "npm:^8.0.1" - json-parse-even-better-errors: "npm:^2.3.1" - normalize-package-data: "npm:^4.0.0" - npm-normalize-package-bin: "npm:^2.0.0" - checksum: 78972bda869efb6191f7b70ab0ca1e7a86549a4aaf73cb379dfeb57098e4ecaa1128ba3f81485ed0b52174605ef16fce1599a551228e5f656a17a1a53a1793e7 - languageName: node - linkType: hard - "read-package-json@npm:^7.0.0": version: 7.0.0 resolution: "read-package-json@npm:7.0.0" @@ -15937,60 +15195,14 @@ __metadata: languageName: node linkType: hard -"read-pkg-up@npm:^11.0.0": - version: 11.0.0 - resolution: "read-pkg-up@npm:11.0.0" - dependencies: - find-up-simple: "npm:^1.0.0" - read-pkg: "npm:^9.0.0" - type-fest: "npm:^4.6.0" - checksum: 9dfe7b1088d22804e275c235e21d64acdfb81edb73373c9ef2707aae2db8309fd35f6de90f569f0159411c25972c5a321ae6cb6a54ec01e449ce9df0a0b2397a - languageName: node - linkType: hard - -"read-pkg-up@npm:^7.0.0, read-pkg-up@npm:^7.0.1": - version: 7.0.1 - resolution: "read-pkg-up@npm:7.0.1" - dependencies: - find-up: "npm:^4.1.0" - read-pkg: "npm:^5.2.0" - type-fest: "npm:^0.8.1" - checksum: 82b3ac9fd7c6ca1bdc1d7253eb1091a98ff3d195ee0a45386582ce3e69f90266163c34121e6a0a02f1630073a6c0585f7880b3865efcae9c452fa667f02ca385 - languageName: node - linkType: hard - -"read-pkg-up@npm:^9.1.0": - version: 9.1.0 - resolution: "read-pkg-up@npm:9.1.0" - dependencies: - find-up: "npm:^6.3.0" - read-pkg: "npm:^7.1.0" - type-fest: "npm:^2.5.0" - checksum: 3fb44889ff930b5c7b5cef9929fc5b2a8a80bc877682be0aef8daff7fc65b1f150bb4e61e7d4e7a11772b7b9b8e05843528031fe8111a7696b6deb652ee4287f - languageName: node - linkType: hard - -"read-pkg@npm:^5.0.0, read-pkg@npm:^5.2.0": - version: 5.2.0 - resolution: "read-pkg@npm:5.2.0" - dependencies: - "@types/normalize-package-data": "npm:^2.4.0" - normalize-package-data: "npm:^2.5.0" - parse-json: "npm:^5.0.0" - type-fest: "npm:^0.6.0" - checksum: b51a17d4b51418e777029e3a7694c9bd6c578a5ab99db544764a0b0f2c7c0f58f8a6bc101f86a6fceb8ba6d237d67c89acf6170f6b98695d0420ddc86cf109fb - languageName: node - linkType: hard - -"read-pkg@npm:^7.1.0": - version: 7.1.0 - resolution: "read-pkg@npm:7.1.0" +"read-pkg-up@npm:^11.0.0": + version: 11.0.0 + resolution: "read-pkg-up@npm:11.0.0" dependencies: - "@types/normalize-package-data": "npm:^2.4.1" - normalize-package-data: "npm:^3.0.2" - parse-json: "npm:^5.2.0" - type-fest: "npm:^2.0.0" - checksum: 5d67a9a1c96f6ee7765743c741f446e0556388dd60236ebfe3a8675019753b49da0863a871763bbdde81a8b3a07d03039088a21bf2dbf6ec485728958d9e93a3 + find-up-simple: "npm:^1.0.0" + read-pkg: "npm:^9.0.0" + type-fest: "npm:^4.6.0" + checksum: 9dfe7b1088d22804e275c235e21d64acdfb81edb73373c9ef2707aae2db8309fd35f6de90f569f0159411c25972c5a321ae6cb6a54ec01e449ce9df0a0b2397a languageName: node linkType: hard @@ -16006,15 +15218,6 @@ __metadata: languageName: node linkType: hard -"read@npm:1, read@npm:^1.0.7, read@npm:~1.0.7": - version: 1.0.7 - resolution: "read@npm:1.0.7" - dependencies: - mute-stream: "npm:~0.0.4" - checksum: 443533f05d5bb11b36ef1c6d625aae4e2ced8967e93cf546f35aa77b4eb6bd157f4256619e446bae43467f8f6619c7bc5c76983348dffaf36afedf4224f46216 - languageName: node - linkType: hard - "read@npm:^2.0.0, read@npm:^2.1.0": version: 2.1.0 resolution: "read@npm:2.1.0" @@ -16024,17 +15227,6 @@ __metadata: languageName: node linkType: hard -"readable-stream@npm:3, readable-stream@npm:^3.0.0, readable-stream@npm:^3.1.1, readable-stream@npm:^3.4.0, readable-stream@npm:^3.6.0": - version: 3.6.2 - resolution: "readable-stream@npm:3.6.2" - dependencies: - inherits: "npm:^2.0.3" - string_decoder: "npm:^1.1.1" - util-deprecate: "npm:^1.0.1" - checksum: e37be5c79c376fdd088a45fa31ea2e423e5d48854be7a22a58869b4e84d25047b193f6acb54f1012331e1bcd667ffb569c01b99d36b0bd59658fb33f513511b7 - languageName: node - linkType: hard - "readable-stream@npm:^2.0.0, readable-stream@npm:^2.0.2, readable-stream@npm:~2.3.6": version: 2.3.8 resolution: "readable-stream@npm:2.3.8" @@ -16050,6 +15242,17 @@ __metadata: languageName: node linkType: hard +"readable-stream@npm:^3.1.1, readable-stream@npm:^3.4.0": + version: 3.6.2 + resolution: "readable-stream@npm:3.6.2" + dependencies: + inherits: "npm:^2.0.3" + string_decoder: "npm:^1.1.1" + util-deprecate: "npm:^1.0.1" + checksum: e37be5c79c376fdd088a45fa31ea2e423e5d48854be7a22a58869b4e84d25047b193f6acb54f1012331e1bcd667ffb569c01b99d36b0bd59658fb33f513511b7 + languageName: node + linkType: hard + "readable-stream@npm:^4.1.0": version: 4.4.2 resolution: "readable-stream@npm:4.4.2" @@ -16063,18 +15266,6 @@ __metadata: languageName: node linkType: hard -"readdir-scoped-modules@npm:^1.1.0": - version: 1.1.0 - resolution: "readdir-scoped-modules@npm:1.1.0" - dependencies: - debuglog: "npm:^1.0.1" - dezalgo: "npm:^1.0.0" - graceful-fs: "npm:^4.1.2" - once: "npm:^1.3.0" - checksum: 21a53741c488775cbf78b0b51f1b897e9c523b1bcf54567fc2c8ed09b12d9027741f45fcb720f388c0c3088021b54dc3f616c07af1531417678cc7962fc15e5c - languageName: node - linkType: hard - "readdirp@npm:~3.6.0": version: 3.6.0 resolution: "readdirp@npm:3.6.0" @@ -16110,6 +15301,22 @@ __metadata: languageName: node linkType: hard +"redis-errors@npm:^1.0.0, redis-errors@npm:^1.2.0": + version: 1.2.0 + resolution: "redis-errors@npm:1.2.0" + checksum: 5b316736e9f532d91a35bff631335137a4f974927bb2fb42bf8c2f18879173a211787db8ac4c3fde8f75ed6233eb0888e55d52510b5620e30d69d7d719c8b8a7 + languageName: node + linkType: hard + +"redis-parser@npm:^3.0.0": + version: 3.0.0 + resolution: "redis-parser@npm:3.0.0" + dependencies: + redis-errors: "npm:^1.0.0" + checksum: ee16ac4c7b2a60b1f42a2cdaee22b005bd4453eb2d0588b8a4939718997ae269da717434da5d570fe0b05030466eeb3f902a58cf2e8e1ca058bf6c9c596f632f + languageName: node + linkType: hard + "reflect.getprototypeof@npm:^1.0.4": version: 1.0.4 resolution: "reflect.getprototypeof@npm:1.0.4" @@ -16298,7 +15505,7 @@ __metadata: languageName: node linkType: hard -"resolve@npm:^1.1.7, resolve@npm:^1.10.0, resolve@npm:^1.14.2, resolve@npm:^1.19.0, resolve@npm:^1.20.0, resolve@npm:^1.21.0, resolve@npm:^1.22.1, resolve@npm:^1.22.2, resolve@npm:^1.22.8": +"resolve@npm:^1.1.7, resolve@npm:^1.14.2, resolve@npm:^1.19.0, resolve@npm:^1.20.0, resolve@npm:^1.21.0, resolve@npm:^1.22.1, resolve@npm:^1.22.2, resolve@npm:^1.22.8": version: 1.22.8 resolution: "resolve@npm:1.22.8" dependencies: @@ -16324,7 +15531,7 @@ __metadata: languageName: node linkType: hard -"resolve@patch:resolve@npm%3A^1.1.7#optional!builtin, resolve@patch:resolve@npm%3A^1.10.0#optional!builtin, resolve@patch:resolve@npm%3A^1.14.2#optional!builtin, resolve@patch:resolve@npm%3A^1.19.0#optional!builtin, resolve@patch:resolve@npm%3A^1.20.0#optional!builtin, resolve@patch:resolve@npm%3A^1.21.0#optional!builtin, resolve@patch:resolve@npm%3A^1.22.1#optional!builtin, resolve@patch:resolve@npm%3A^1.22.2#optional!builtin, resolve@patch:resolve@npm%3A^1.22.8#optional!builtin": +"resolve@patch:resolve@npm%3A^1.1.7#optional!builtin, resolve@patch:resolve@npm%3A^1.14.2#optional!builtin, resolve@patch:resolve@npm%3A^1.19.0#optional!builtin, resolve@patch:resolve@npm%3A^1.20.0#optional!builtin, resolve@patch:resolve@npm%3A^1.21.0#optional!builtin, resolve@patch:resolve@npm%3A^1.22.1#optional!builtin, resolve@patch:resolve@npm%3A^1.22.2#optional!builtin, resolve@patch:resolve@npm%3A^1.22.8#optional!builtin": version: 1.22.8 resolution: "resolve@patch:resolve@npm%3A1.22.8#optional!builtin::version=1.22.8&hash=c3c19d" dependencies: @@ -16381,7 +15588,7 @@ __metadata: languageName: node linkType: hard -"rimraf@npm:^3.0.0, rimraf@npm:^3.0.2": +"rimraf@npm:^3.0.2": version: 3.0.2 resolution: "rimraf@npm:3.0.2" dependencies: @@ -16558,13 +15765,6 @@ __metadata: languageName: node linkType: hard -"safe-json-utils@npm:^1.1.1": - version: 1.1.1 - resolution: "safe-json-utils@npm:1.1.1" - checksum: d2758b456dd2b388ef59ef254a7e677cb3ad382030d2949ee88c1af1ca5ead121f1b3dacc8035bafd4dfa6cdead6b80739fec793fe17e8e96105d9d220dbc88b - languageName: node - linkType: hard - "safe-regex-test@npm:^1.0.0": version: 1.0.0 resolution: "safe-regex-test@npm:1.0.0" @@ -16591,15 +15791,15 @@ __metadata: linkType: hard "sass@npm:^1.58.3": - version: 1.69.5 - resolution: "sass@npm:1.69.5" + version: 1.69.6 + resolution: "sass@npm:1.69.6" dependencies: chokidar: "npm:>=3.0.0 <4.0.0" immutable: "npm:^4.0.0" source-map-js: "npm:>=0.6.2 <2.0.0" bin: sass: sass.js - checksum: a9003a9482f2e467fc412cfe58ba4fa14fb78bef7e1283ce5d64a065f8a31114ec3bbf5d4e724f94eb8512c32c768a6f91f228c7f16a26a300bbf4db293b5608 + checksum: 8153db8e51e74a9007bb54332e14d122c34288c7d21a5f2eaefef753a1b7bb13f35e042dc6247253dab5b1550b05cea27970371e7548286b4f50f23dd1147d89 languageName: node linkType: hard @@ -16628,33 +15828,34 @@ __metadata: languageName: node linkType: hard -"semantic-release@npm:^20.1.3": - version: 20.1.3 - resolution: "semantic-release@npm:20.1.3" +"semantic-release@npm:^22.0.12": + version: 22.0.12 + resolution: "semantic-release@npm:22.0.12" dependencies: - "@semantic-release/commit-analyzer": "npm:^9.0.2" - "@semantic-release/error": "npm:^3.0.0" - "@semantic-release/github": "npm:^8.0.0" - "@semantic-release/npm": "npm:^9.0.0" - "@semantic-release/release-notes-generator": "npm:^10.0.0" - aggregate-error: "npm:^4.0.1" + "@semantic-release/commit-analyzer": "npm:^11.0.0" + "@semantic-release/error": "npm:^4.0.0" + "@semantic-release/github": "npm:^9.0.0" + "@semantic-release/npm": "npm:^11.0.0" + "@semantic-release/release-notes-generator": "npm:^12.0.0" + aggregate-error: "npm:^5.0.0" cosmiconfig: "npm:^8.0.0" debug: "npm:^4.0.0" - env-ci: "npm:^8.0.0" - execa: "npm:^7.0.0" - figures: "npm:^5.0.0" + env-ci: "npm:^10.0.0" + execa: "npm:^8.0.0" + figures: "npm:^6.0.0" find-versions: "npm:^5.1.0" get-stream: "npm:^6.0.0" git-log-parser: "npm:^1.2.0" hook-std: "npm:^3.0.0" - hosted-git-info: "npm:^6.0.0" + hosted-git-info: "npm:^7.0.0" + import-from-esm: "npm:^1.3.1" lodash-es: "npm:^4.17.21" - marked: "npm:^4.1.0" - marked-terminal: "npm:^5.1.1" + marked: "npm:^9.0.0" + marked-terminal: "npm:^6.0.0" micromatch: "npm:^4.0.2" p-each-series: "npm:^3.0.0" p-reduce: "npm:^3.0.0" - read-pkg-up: "npm:^9.1.0" + read-pkg-up: "npm:^11.0.0" resolve-from: "npm:^5.0.0" semver: "npm:^7.3.2" semver-diff: "npm:^4.0.0" @@ -16662,7 +15863,7 @@ __metadata: yargs: "npm:^17.5.1" bin: semantic-release: bin/semantic-release.js - checksum: 432f0c7ea506c24b909db51d710add2f7b889cdf919834b58618b2f00869cdd256a466890d083da174e8ac609c5d0d8dd81f3ca0317ee50f76108bf1a61284c0 + checksum: 13e86ab9e16e32fd51b09f486ec5ea950bb541c5ea3cd4e66b0527d2a7108cfd3488510d5f29cefc83c86d279e6d5075f886bad8478c88a74cc7d5942e936722 languageName: node linkType: hard @@ -16682,16 +15883,7 @@ __metadata: languageName: node linkType: hard -"semver@npm:2 || 3 || 4 || 5": - version: 5.7.2 - resolution: "semver@npm:5.7.2" - bin: - semver: bin/semver - checksum: e4cf10f86f168db772ae95d86ba65b3fd6c5967c94d97c708ccb463b778c2ee53b914cd7167620950fc07faf5a564e6efe903836639e512a1aa15fbc9667fa25 - languageName: node - linkType: hard - -"semver@npm:^6.0.0, semver@npm:^6.3.0, semver@npm:^6.3.1": +"semver@npm:^6.3.0, semver@npm:^6.3.1": version: 6.3.1 resolution: "semver@npm:6.3.1" bin: @@ -16700,7 +15892,7 @@ __metadata: languageName: node linkType: hard -"semver@npm:^7.0.0, semver@npm:^7.1.1, semver@npm:^7.1.2, semver@npm:^7.3.2, semver@npm:^7.3.4, semver@npm:^7.3.5, semver@npm:^7.3.7, semver@npm:^7.5.2, semver@npm:^7.5.3, semver@npm:^7.5.4": +"semver@npm:^7.0.0, semver@npm:^7.1.1, semver@npm:^7.1.2, semver@npm:^7.3.2, semver@npm:^7.3.5, semver@npm:^7.3.7, semver@npm:^7.5.2, semver@npm:^7.5.3, semver@npm:^7.5.4": version: 7.5.4 resolution: "semver@npm:7.5.4" dependencies: @@ -16865,6 +16057,15 @@ __metadata: languageName: node linkType: hard +"skin-tone@npm:^2.0.0": + version: 2.0.0 + resolution: "skin-tone@npm:2.0.0" + dependencies: + unicode-emoji-modifier-base: "npm:^1.0.0" + checksum: 82d4c2527864f9cbd6cb7f3c4abb31e2224752234d5013b881d3e34e9ab543545b05206df5a17d14b515459fcb265ce409f9cfe443903176b0360cd20e4e4ba5 + languageName: node + linkType: hard + "slash@npm:^3.0.0": version: 3.0.0 resolution: "slash@npm:3.0.0" @@ -16927,17 +16128,6 @@ __metadata: languageName: node linkType: hard -"socks-proxy-agent@npm:^7.0.0": - version: 7.0.0 - resolution: "socks-proxy-agent@npm:7.0.0" - dependencies: - agent-base: "npm:^6.0.2" - debug: "npm:^4.3.3" - socks: "npm:^2.6.2" - checksum: b859f7eb8e96ec2c4186beea233ae59c02404094f3eb009946836af27d6e5c1627d1975a69b4d2e20611729ed543b6db3ae8481eb38603433c50d0345c987600 - languageName: node - linkType: hard - "socks-proxy-agent@npm:^8.0.1": version: 8.0.2 resolution: "socks-proxy-agent@npm:8.0.2" @@ -16949,7 +16139,7 @@ __metadata: languageName: node linkType: hard -"socks@npm:^2.6.2, socks@npm:^2.7.1": +"socks@npm:^2.7.1": version: 2.7.1 resolution: "socks@npm:2.7.1" dependencies: @@ -17057,15 +16247,6 @@ __metadata: languageName: node linkType: hard -"split2@npm:^3.0.0": - version: 3.2.2 - resolution: "split2@npm:3.2.2" - dependencies: - readable-stream: "npm:^3.0.0" - checksum: 2dad5603c52b353939befa3e2f108f6e3aff42b204ad0f5f16dd12fd7c2beab48d117184ce6f7c8854f9ee5ffec6faae70d243711dd7d143a9f635b4a285de4e - languageName: node - linkType: hard - "split2@npm:^4.0.0": version: 4.2.0 resolution: "split2@npm:4.2.0" @@ -17082,15 +16263,6 @@ __metadata: languageName: node linkType: hard -"split@npm:^1.0.0": - version: 1.0.1 - resolution: "split@npm:1.0.1" - dependencies: - through: "npm:2" - checksum: 7f489e7ed5ff8a2e43295f30a5197ffcb2d6202c9cf99357f9690d645b19c812bccf0be3ff336fea5054cda17ac96b91d67147d95dbfc31fbb5804c61962af85 - languageName: node - linkType: hard - "sponge-case@npm:^1.0.1": version: 1.0.1 resolution: "sponge-case@npm:1.0.1" @@ -17116,15 +16288,6 @@ __metadata: languageName: node linkType: hard -"ssri@npm:^9.0.0, ssri@npm:^9.0.1": - version: 9.0.1 - resolution: "ssri@npm:9.0.1" - dependencies: - minipass: "npm:^3.1.1" - checksum: c5d153ce03b5980d683ecaa4d805f6a03d8dc545736213803e168a1907650c46c08a4e5ce6d670a0205482b35c35713d9d286d9133bdd79853a406e22ad81f04 - languageName: node - linkType: hard - "stable@npm:^0.1.8": version: 0.1.8 resolution: "stable@npm:0.1.8" @@ -17141,6 +16304,20 @@ __metadata: languageName: node linkType: hard +"standard-as-callback@npm:^2.1.0": + version: 2.1.0 + resolution: "standard-as-callback@npm:2.1.0" + checksum: 012677236e3d3fdc5689d29e64ea8a599331c4babe86956bf92fc5e127d53f85411c5536ee0079c52c43beb0026b5ce7aa1d834dd35dd026e82a15d1bcaead1f + languageName: node + linkType: hard + +"std-env@npm:^3.4.3": + version: 3.7.0 + resolution: "std-env@npm:3.7.0" + checksum: 60edf2d130a4feb7002974af3d5a5f3343558d1ccf8d9b9934d225c638606884db4a20d2fe6440a09605bca282af6b042ae8070a10490c0800d69e82e478f41e + languageName: node + linkType: hard + "stellar-base@npm:^8.2.2": version: 8.2.2 resolution: "stellar-base@npm:8.2.2" @@ -17478,13 +16655,13 @@ __metadata: languageName: node linkType: hard -"supports-hyperlinks@npm:^2.3.0": - version: 2.3.0 - resolution: "supports-hyperlinks@npm:2.3.0" +"supports-hyperlinks@npm:^3.0.0": + version: 3.0.0 + resolution: "supports-hyperlinks@npm:3.0.0" dependencies: has-flag: "npm:^4.0.0" supports-color: "npm:^7.0.0" - checksum: 4057f0d86afb056cd799602f72d575b8fdd79001c5894bcb691176f14e870a687e7981e50bc1484980e8b688c6d5bcd4931e1609816abb5a7dc1486b7babf6a1 + checksum: 36aaa55e67645dded8e0f846fd81d7dd05ce82ea81e62347f58d86213577eb627b2b45298656ce7a70e7155e39f071d0d3f83be91e112aed801ebaa8db1ef1d0 languageName: node linkType: hard @@ -17528,7 +16705,7 @@ __metadata: languageName: node linkType: hard -"tailwindcss@npm:^3, tailwindcss@npm:^3.2.7": +"tailwindcss@npm:^3": version: 3.3.5 resolution: "tailwindcss@npm:3.3.5" dependencies: @@ -17561,7 +16738,40 @@ __metadata: languageName: node linkType: hard -"tar@npm:^6.1.0, tar@npm:^6.1.11, tar@npm:^6.1.2, tar@npm:^6.2.0": +"tailwindcss@npm:^3.4.0": + version: 3.4.0 + resolution: "tailwindcss@npm:3.4.0" + dependencies: + "@alloc/quick-lru": "npm:^5.2.0" + arg: "npm:^5.0.2" + chokidar: "npm:^3.5.3" + didyoumean: "npm:^1.2.2" + dlv: "npm:^1.1.3" + fast-glob: "npm:^3.3.0" + glob-parent: "npm:^6.0.2" + is-glob: "npm:^4.0.3" + jiti: "npm:^1.19.1" + lilconfig: "npm:^2.1.0" + micromatch: "npm:^4.0.5" + normalize-path: "npm:^3.0.0" + object-hash: "npm:^3.0.0" + picocolors: "npm:^1.0.0" + postcss: "npm:^8.4.23" + postcss-import: "npm:^15.1.0" + postcss-js: "npm:^4.0.1" + postcss-load-config: "npm:^4.0.1" + postcss-nested: "npm:^6.0.1" + postcss-selector-parser: "npm:^6.0.11" + resolve: "npm:^1.22.2" + sucrase: "npm:^3.32.0" + bin: + tailwind: lib/cli.js + tailwindcss: lib/cli.js + checksum: 0a1cef7468e6d17c2857d0b3c4017af2cb37ed8ba27dfb14780c517b8a74f6786970227c400ac1325fc8bcfc09099d8e990fa7c60924bf945f3d0a912d63f546 + languageName: node + linkType: hard + +"tar@npm:^6.1.11, tar@npm:^6.1.2, tar@npm:^6.2.0": version: 6.2.0 resolution: "tar@npm:6.2.0" dependencies: @@ -17575,13 +16785,6 @@ __metadata: languageName: node linkType: hard -"temp-dir@npm:^2.0.0": - version: 2.0.0 - resolution: "temp-dir@npm:2.0.0" - checksum: b1df969e3f3f7903f3426861887ed76ba3b495f63f6d0c8e1ce22588679d9384d336df6064210fda14e640ed422e2a17d5c40d901f60e161c99482d723f4d309 - languageName: node - linkType: hard - "temp-dir@npm:^3.0.0": version: 3.0.0 resolution: "temp-dir@npm:3.0.0" @@ -17589,19 +16792,6 @@ __metadata: languageName: node linkType: hard -"tempy@npm:^1.0.0": - version: 1.0.1 - resolution: "tempy@npm:1.0.1" - dependencies: - del: "npm:^6.0.0" - is-stream: "npm:^2.0.0" - temp-dir: "npm:^2.0.0" - type-fest: "npm:^0.16.0" - unique-string: "npm:^2.0.0" - checksum: 864a1cf1b5536dc21e84ae45dbbc3ba4dd2c7ec1674d895f99c349cf209df959a53d797ca38d0b2cf69c7684d565fde5cfc67faaa63b7208ffb21d454b957472 - languageName: node - linkType: hard - "tempy@npm:^3.0.0": version: 3.1.0 resolution: "tempy@npm:3.1.0" @@ -17625,13 +16815,6 @@ __metadata: languageName: node linkType: hard -"text-extensions@npm:^1.0.0": - version: 1.9.0 - resolution: "text-extensions@npm:1.9.0" - checksum: 9ad5a9f723a871e2d884e132d7e93f281c60b5759c95f3f6b04704856548715d93a36c10dbaf5f12b91bf405f0cf3893bf169d4d143c0f5509563b992d385443 - languageName: node - linkType: hard - "text-extensions@npm:^2.0.0": version: 2.4.0 resolution: "text-extensions@npm:2.4.0" @@ -17673,15 +16856,6 @@ __metadata: languageName: node linkType: hard -"through2@npm:^4.0.0": - version: 4.0.2 - resolution: "through2@npm:4.0.2" - dependencies: - readable-stream: "npm:3" - checksum: 3741564ae99990a4a79097fe7a4152c22348adc4faf2df9199a07a66c81ed2011da39f631e479fdc56483996a9d34a037ad64e76d79f18c782ab178ea9b6778c - languageName: node - linkType: hard - "through2@npm:~2.0.0": version: 2.0.5 resolution: "through2@npm:2.0.5" @@ -17692,7 +16866,7 @@ __metadata: languageName: node linkType: hard -"through@npm:2, through@npm:>=2.2.7 <3, through@npm:^2.3.6, through@npm:^2.3.8": +"through@npm:>=2.2.7 <3, through@npm:^2.3.6, through@npm:^2.3.8": version: 2.3.8 resolution: "through@npm:2.3.8" checksum: 4b09f3774099de0d4df26d95c5821a62faee32c7e96fb1f4ebd54a2d7c11c57fe88b0a0d49cf375de5fee5ae6bf4eb56dbbf29d07366864e2ee805349970d3cc @@ -17813,13 +16987,6 @@ __metadata: languageName: node linkType: hard -"treeverse@npm:^2.0.0": - version: 2.0.0 - resolution: "treeverse@npm:2.0.0" - checksum: be37fd0d4d62c62fe7f4bfcac164d82f11456184dc397473896ed2efcdf9b307c3e433e1d275a1dd924fc7e66aa280ab36be8b8966b87f23e0f545417eb52900 - languageName: node - linkType: hard - "treeverse@npm:^3.0.0": version: 3.0.0 resolution: "treeverse@npm:3.0.0" @@ -17827,10 +16994,12 @@ __metadata: languageName: node linkType: hard -"trim-newlines@npm:^3.0.0": - version: 3.0.1 - resolution: "trim-newlines@npm:3.0.1" - checksum: 03cfefde6c59ff57138412b8c6be922ecc5aec30694d784f2a65ef8dcbd47faef580b7de0c949345abdc56ec4b4abf64dd1e5aea619b200316e471a3dd5bf1f6 +"ts-api-utils@npm:^1.0.1": + version: 1.0.3 + resolution: "ts-api-utils@npm:1.0.3" + peerDependencies: + typescript: ">=4.2.0" + checksum: 9408338819c3aca2a709f0bc54e3f874227901506cacb1163612a6c8a43df224174feb965a5eafdae16f66fc68fd7bfee8d3275d0fa73fbb8699e03ed26520c9 languageName: node linkType: hard @@ -17848,9 +17017,9 @@ __metadata: languageName: node linkType: hard -"ts-node@npm:^10.9.1": - version: 10.9.1 - resolution: "ts-node@npm:10.9.1" +"ts-node@npm:^10.9.2": + version: 10.9.2 + resolution: "ts-node@npm:10.9.2" dependencies: "@cspotcode/source-map-support": "npm:^0.8.0" "@tsconfig/node10": "npm:^1.0.7" @@ -17882,7 +17051,7 @@ __metadata: ts-node-script: dist/bin-script.js ts-node-transpile-only: dist/bin-transpile.js ts-script: dist/bin-script-deprecated.js - checksum: 95187932fb83f3901e22546bd2feeac7d2feb4f412f42ac3a595f049a23e8dcf70516dffb51866391228ea2dbcfaea039e250fb2bb334d48a86ab2b6aea0ae2d + checksum: 5f29938489f96982a25ba650b64218e83a3357d76f7bede80195c65ab44ad279c8357264639b7abdd5d7e75fc269a83daa0e9c62fd8637a3def67254ecc9ddc2 languageName: node linkType: hard @@ -17952,20 +17121,6 @@ __metadata: languageName: node linkType: hard -"type-fest@npm:^0.16.0": - version: 0.16.0 - resolution: "type-fest@npm:0.16.0" - checksum: 6b4d846534e7bcb49a6160b068ffaed2b62570d989d909ac3f29df5ef1e993859f890a4242eebe023c9e923f96adbcb3b3e88a198c35a1ee9a731e147a6839c3 - languageName: node - linkType: hard - -"type-fest@npm:^0.18.0": - version: 0.18.1 - resolution: "type-fest@npm:0.18.1" - checksum: 303f5ecf40d03e1d5b635ce7660de3b33c18ed8ebc65d64920c02974d9e684c72483c23f9084587e9dd6466a2ece1da42ddc95b412a461794dd30baca95e2bac - languageName: node - linkType: hard - "type-fest@npm:^0.20.2": version: 0.20.2 resolution: "type-fest@npm:0.20.2" @@ -17980,20 +17135,6 @@ __metadata: languageName: node linkType: hard -"type-fest@npm:^0.6.0": - version: 0.6.0 - resolution: "type-fest@npm:0.6.0" - checksum: 0c585c26416fce9ecb5691873a1301b5aff54673c7999b6f925691ed01f5b9232db408cdbb0bd003d19f5ae284322523f44092d1f81ca0a48f11f7cf0be8cd38 - languageName: node - linkType: hard - -"type-fest@npm:^0.8.1": - version: 0.8.1 - resolution: "type-fest@npm:0.8.1" - checksum: dffbb99329da2aa840f506d376c863bd55f5636f4741ad6e65e82f5ce47e6914108f44f340a0b74009b0cb5d09d6752ae83203e53e98b1192cf80ecee5651636 - languageName: node - linkType: hard - "type-fest@npm:^1.0.1": version: 1.4.0 resolution: "type-fest@npm:1.4.0" @@ -18001,7 +17142,7 @@ __metadata: languageName: node linkType: hard -"type-fest@npm:^2.0.0, type-fest@npm:^2.12.2, type-fest@npm:^2.19.0, type-fest@npm:^2.5.0": +"type-fest@npm:^2.12.2, type-fest@npm:^2.19.0": version: 2.19.0 resolution: "type-fest@npm:2.19.0" checksum: a5a7ecf2e654251613218c215c7493574594951c08e52ab9881c9df6a6da0aeca7528c213c622bc374b4e0cb5c443aa3ab758da4e3c959783ce884c3194e12cb @@ -18119,6 +17260,13 @@ __metadata: languageName: node linkType: hard +"ufo@npm:^1.3.0, ufo@npm:^1.3.1, ufo@npm:^1.3.2": + version: 1.3.2 + resolution: "ufo@npm:1.3.2" + checksum: 180f3dfcdf319b54fe0272780841c93cb08a024fc2ee5f95e63285c2a3c42d8b671cd3641e9a53aafccf100cf8466aa8c040ddfa0efea1fc1968c9bfb250a661 + languageName: node + linkType: hard + "uglify-js@npm:^3.1.4": version: 3.17.4 resolution: "uglify-js@npm:3.17.4" @@ -18156,6 +17304,13 @@ __metadata: languageName: node linkType: hard +"uncrypto@npm:^0.1.3": + version: 0.1.3 + resolution: "uncrypto@npm:0.1.3" + checksum: 74a29afefd76d5b77bedc983559ceb33f5bbc8dada84ff33755d1e3355da55a4e03a10e7ce717918c436b4dfafde1782e799ebaf2aadd775612b49f7b5b2998e + languageName: node + linkType: hard + "undici-types@npm:~5.26.4": version: 5.26.5 resolution: "undici-types@npm:5.26.5" @@ -18163,6 +17318,26 @@ __metadata: languageName: node linkType: hard +"unenv@npm:^1.7.4": + version: 1.8.0 + resolution: "unenv@npm:1.8.0" + dependencies: + consola: "npm:^3.2.3" + defu: "npm:^6.1.3" + mime: "npm:^3.0.0" + node-fetch-native: "npm:^1.4.1" + pathe: "npm:^1.1.1" + checksum: f5ad66425ef5b1848d2daab4bdb18e3f2576a4a8df48f3e994ef373290489a6251969b78b965963a905b90dc01db6e838e2deb826e384ec637df2345a146b0bb + languageName: node + linkType: hard + +"unfetch@npm:^4.2.0": + version: 4.2.0 + resolution: "unfetch@npm:4.2.0" + checksum: a5c0a896a6f09f278b868075aea65652ad185db30e827cb7df45826fe5ab850124bf9c44c4dafca4bf0c55a0844b17031e8243467fcc38dd7a7d435007151f1b + languageName: node + linkType: hard + "unicode-canonical-property-names-ecmascript@npm:^2.0.0": version: 2.0.0 resolution: "unicode-canonical-property-names-ecmascript@npm:2.0.0" @@ -18170,6 +17345,13 @@ __metadata: languageName: node linkType: hard +"unicode-emoji-modifier-base@npm:^1.0.0": + version: 1.0.0 + resolution: "unicode-emoji-modifier-base@npm:1.0.0" + checksum: b37623fcf0162186debd20f116483e035a2d5b905b932a2c472459d9143d446ebcbefb2a494e2fe4fa7434355396e2a95ec3fc1f0c29a3bc8f2c827220e79c66 + languageName: node + linkType: hard + "unicode-match-property-ecmascript@npm:^2.0.0": version: 2.0.0 resolution: "unicode-match-property-ecmascript@npm:2.0.0" @@ -18201,15 +17383,6 @@ __metadata: languageName: node linkType: hard -"unique-filename@npm:^2.0.0": - version: 2.0.1 - resolution: "unique-filename@npm:2.0.1" - dependencies: - unique-slug: "npm:^3.0.0" - checksum: 55d95cd670c4a86117ebc34d394936d712d43b56db6bc511f9ca00f666373818bf9f075fb0ab76bcbfaf134592ef26bb75aad20786c1ff1ceba4457eaba90fb8 - languageName: node - linkType: hard - "unique-filename@npm:^3.0.0": version: 3.0.0 resolution: "unique-filename@npm:3.0.0" @@ -18219,15 +17392,6 @@ __metadata: languageName: node linkType: hard -"unique-slug@npm:^3.0.0": - version: 3.0.0 - resolution: "unique-slug@npm:3.0.0" - dependencies: - imurmurhash: "npm:^0.1.4" - checksum: 617240eb921af803b47d322d75a71a363dacf2e56c29ae5d1404fad85f64f4ec81ef10ee4fd79215d0202cbe1e5a653edb0558d59c9c81d3bd538c2d58e4c026 - languageName: node - linkType: hard - "unique-slug@npm:^4.0.0": version: 4.0.0 resolution: "unique-slug@npm:4.0.0" @@ -18237,15 +17401,6 @@ __metadata: languageName: node linkType: hard -"unique-string@npm:^2.0.0": - version: 2.0.0 - resolution: "unique-string@npm:2.0.0" - dependencies: - crypto-random-string: "npm:^2.0.0" - checksum: 11820db0a4ba069d174bedfa96c588fc2c96b083066fafa186851e563951d0de78181ac79c744c1ed28b51f9d82ac5b8196ff3e4560d0178046ef455d8c2244b - languageName: node - linkType: hard - "unique-string@npm:^3.0.0": version: 3.0.0 resolution: "unique-string@npm:3.0.0" @@ -18285,6 +17440,76 @@ __metadata: languageName: node linkType: hard +"unstorage@npm:^1.9.0": + version: 1.10.1 + resolution: "unstorage@npm:1.10.1" + dependencies: + anymatch: "npm:^3.1.3" + chokidar: "npm:^3.5.3" + destr: "npm:^2.0.2" + h3: "npm:^1.8.2" + ioredis: "npm:^5.3.2" + listhen: "npm:^1.5.5" + lru-cache: "npm:^10.0.2" + mri: "npm:^1.2.0" + node-fetch-native: "npm:^1.4.1" + ofetch: "npm:^1.3.3" + ufo: "npm:^1.3.1" + peerDependencies: + "@azure/app-configuration": ^1.4.1 + "@azure/cosmos": ^4.0.0 + "@azure/data-tables": ^13.2.2 + "@azure/identity": ^3.3.2 + "@azure/keyvault-secrets": ^4.7.0 + "@azure/storage-blob": ^12.16.0 + "@capacitor/preferences": ^5.0.6 + "@netlify/blobs": ^6.2.0 + "@planetscale/database": ^1.11.0 + "@upstash/redis": ^1.23.4 + "@vercel/kv": ^0.2.3 + idb-keyval: ^6.2.1 + peerDependenciesMeta: + "@azure/app-configuration": + optional: true + "@azure/cosmos": + optional: true + "@azure/data-tables": + optional: true + "@azure/identity": + optional: true + "@azure/keyvault-secrets": + optional: true + "@azure/storage-blob": + optional: true + "@capacitor/preferences": + optional: true + "@netlify/blobs": + optional: true + "@planetscale/database": + optional: true + "@upstash/redis": + optional: true + "@vercel/kv": + optional: true + idb-keyval: + optional: true + checksum: c73c8c45c8f061aff46c1b0634fa2d8cf10bc77aa71512ec77c561cd43cd870efdbbc07379dda8abafafda740762ee1aedb977413341bb05f5b9e221a26df130 + languageName: node + linkType: hard + +"untun@npm:^0.1.2": + version: 0.1.3 + resolution: "untun@npm:0.1.3" + dependencies: + citty: "npm:^0.1.5" + consola: "npm:^3.2.3" + pathe: "npm:^1.1.1" + bin: + untun: bin/untun.mjs + checksum: 2b44a4cc84a5c21994f43b9f55348e5a8d9dd5fd0ad8fb5cd091b6f6b53d506b1cdb90e89cc238d61b46d488f7a89ab0d1a5c735bfc835581c7b22a236381295 + languageName: node + linkType: hard + "update-browserslist-db@npm:^1.0.13": version: 1.0.13 resolution: "update-browserslist-db@npm:1.0.13" @@ -18317,6 +17542,13 @@ __metadata: languageName: node linkType: hard +"uqr@npm:^0.1.2": + version: 0.1.2 + resolution: "uqr@npm:0.1.2" + checksum: 40cd81b4c13f1764d52ec28da2d58e60816e6fae54d4eb75b32fbf3137937f438eff16c766139fb0faec5d248a5314591f5a0dbd694e569d419eed6f3bd80242 + languageName: node + linkType: hard + "uri-js@npm:^4.2.2": version: 4.4.1 resolution: "uri-js@npm:4.4.1" @@ -18333,13 +17565,6 @@ __metadata: languageName: node linkType: hard -"url-join@npm:^4.0.0": - version: 4.0.1 - resolution: "url-join@npm:4.0.1" - checksum: ac65e2c7c562d7b49b68edddcf55385d3e922bc1dd5d90419ea40b53b6de1607d1e45ceb71efb9d60da02c681d13c6cb3a1aa8b13fc0c989dfc219df97ee992d - languageName: node - linkType: hard - "url-join@npm:^5.0.0": version: 5.0.0 resolution: "url-join@npm:5.0.0" @@ -18422,7 +17647,7 @@ __metadata: languageName: node linkType: hard -"validate-npm-package-license@npm:^3.0.1, validate-npm-package-license@npm:^3.0.4": +"validate-npm-package-license@npm:^3.0.4": version: 3.0.4 resolution: "validate-npm-package-license@npm:3.0.4" dependencies: @@ -18432,15 +17657,6 @@ __metadata: languageName: node linkType: hard -"validate-npm-package-name@npm:^4.0.0": - version: 4.0.0 - resolution: "validate-npm-package-name@npm:4.0.0" - dependencies: - builtins: "npm:^5.0.0" - checksum: d7f753c0aac0a2b8dd06752e7278d18165a21e28b5064d897a1b6f10350d857b339d6bd9e08dd140710433479940bec9ba151b619196780dc6e49dd8fbff6df8 - languageName: node - linkType: hard - "validate-npm-package-name@npm:^5.0.0": version: 5.0.0 resolution: "validate-npm-package-name@npm:5.0.0" @@ -18475,7 +17691,7 @@ __metadata: languageName: node linkType: hard -"vite@npm:^3.2.5": +"vite@npm:^3.2.7": version: 3.2.7 resolution: "vite@npm:3.2.7" dependencies: @@ -18522,13 +17738,6 @@ __metadata: languageName: node linkType: hard -"walk-up-path@npm:^1.0.0": - version: 1.0.0 - resolution: "walk-up-path@npm:1.0.0" - checksum: e2dc2346acfeec355c8af17095aa8689b57906f0f3ad5f3ff1b0a29a36ee41904608e9a3545a933a2cfa22f20905e2bbe5dd6469cb31b110c8e129c23103e985 - languageName: node - linkType: hard - "walk-up-path@npm:^3.0.1": version: 3.0.1 resolution: "walk-up-path@npm:3.0.1" @@ -18703,7 +17912,7 @@ __metadata: languageName: node linkType: hard -"which@npm:^2.0.1, which@npm:^2.0.2": +"which@npm:^2.0.1": version: 2.0.2 resolution: "which@npm:2.0.2" dependencies: @@ -18781,7 +17990,7 @@ __metadata: languageName: node linkType: hard -"write-file-atomic@npm:^4.0.0, write-file-atomic@npm:^4.0.1, write-file-atomic@npm:^4.0.2": +"write-file-atomic@npm:^4.0.2": version: 4.0.2 resolution: "write-file-atomic@npm:4.0.2" dependencies: @@ -18918,13 +18127,6 @@ __metadata: languageName: node linkType: hard -"yargs-parser@npm:^20.2.3": - version: 20.2.9 - resolution: "yargs-parser@npm:20.2.9" - checksum: 0685a8e58bbfb57fab6aefe03c6da904a59769bd803a722bb098bd5b0f29d274a1357762c7258fb487512811b8063fb5d2824a3415a0a4540598335b3b086c72 - languageName: node - linkType: hard - "yargs-parser@npm:^21.1.1": version: 21.1.1 resolution: "yargs-parser@npm:21.1.1" @@ -18980,21 +18182,14 @@ __metadata: languageName: node linkType: hard -"yocto-queue@npm:^1.0.0": - version: 1.0.0 - resolution: "yocto-queue@npm:1.0.0" - checksum: 856117aa15cf5103d2a2fb173f0ab4acb12b4b4d0ed3ab249fdbbf612e55d1cadfd27a6110940e24746fb0a78cf640b522cc8bca76f30a3b00b66e90cf82abe0 - languageName: node - linkType: hard - -"yup@npm:^1.3.2": - version: 1.3.2 - resolution: "yup@npm:1.3.2" +"yup@npm:^1.3.3": + version: 1.3.3 + resolution: "yup@npm:1.3.3" dependencies: property-expr: "npm:^2.0.5" tiny-case: "npm:^1.0.3" toposort: "npm:^2.0.2" type-fest: "npm:^2.19.0" - checksum: 0820db84fc617b5a75b739bbdef73599bc36ad5a23f2746ae2e2600bb8bc7274a4f178336ab030f5d1a36774aeb08b891aa3fb6d88f64ef61f82ffc8e328b67d + checksum: cc00e98af8617b779dd151d6a77779228cfe973a185c743628b2afdecda88c333187d058c1199518d696c15827ba9b757a6c57c1ace6766d970d3cd2368c3264 languageName: node linkType: hard From a87ca28fc809046f32224159d87db6cfb555363a Mon Sep 17 00:00:00 2001 From: Nejc Date: Tue, 2 Jan 2024 12:47:17 +0100 Subject: [PATCH 07/58] refactor: transaction helpers --- src/components/Transaction/Progress/index.tsx | 18 ++---------------- src/helpers/transaction.ts | 15 +++++++++++++++ 2 files changed, 17 insertions(+), 16 deletions(-) diff --git a/src/components/Transaction/Progress/index.tsx b/src/components/Transaction/Progress/index.tsx index 1793715f..fb64d5db 100644 --- a/src/components/Transaction/Progress/index.tsx +++ b/src/components/Transaction/Progress/index.tsx @@ -1,8 +1,8 @@ import { CheckCircleIcon, ExclamationCircleIcon } from '@heroicons/react/24/outline'; -import { MessageCallResult } from '@pendulum-chain/api-solang'; import { ComponentChildren } from 'preact'; import { Button } from 'react-daisyui'; import Spinner from '../../../assets/spinner'; +import { getErrorMessage } from '../../../helpers/transaction'; import { useGetTenantConfig } from '../../../hooks/useGetTenantConfig'; import { UseContractWriteResponse } from '../../../shared/useContractWrite'; @@ -15,26 +15,12 @@ export interface TransactionProgressProps { onClose: () => void; } -const getErrorMsg = (data?: MessageCallResult['result']) => { - if (!data) return undefined; - switch (data.type) { - case 'error': - return data.error; - case 'panic': - return data.explanation; - case 'reverted': - return data.description; - default: - return undefined; - } -}; - const TransactionProgress = ({ mutation, children, onClose }: TransactionProgressProps): JSX.Element | null => { const { explorer } = useGetTenantConfig(); if (mutation.isIdle) return null; const status = mutation.data?.result?.type; const isSuccess = status === 'success'; - const errorMsg = getErrorMsg(mutation.data?.result); + const errorMsg = getErrorMessage(mutation.data?.result); if (mutation.isLoading) { const isPending = false; // TODO: currently there is not status for this (waiting confirmation in wallet) return ( diff --git a/src/helpers/transaction.ts b/src/helpers/transaction.ts index 8a22ef93..8220cdeb 100644 --- a/src/helpers/transaction.ts +++ b/src/helpers/transaction.ts @@ -1,3 +1,4 @@ +import { MessageCallResult } from '@pendulum-chain/api-solang'; import { toast } from 'react-toastify'; import { config } from '../config'; @@ -6,6 +7,20 @@ export const transactionErrorToast = (err: unknown) => { toast(cancelled ? 'Transaction cancelled' : 'Transaction failed', { type: 'error' }); }; +export const getErrorMessage = (data?: MessageCallResult['result']) => { + if (!data) return undefined; + switch (data.type) { + case 'error': + return data.error; + case 'panic': + return data.explanation; + case 'reverted': + return data.description; + default: + return undefined; + } +}; + const { slippage, deadline } = config.transaction.settings; export const getValidSlippage = (val?: number): number | undefined => From 9551e3c1c923581f8b0be5955e95e8ed4ca5d81d Mon Sep 17 00:00:00 2001 From: Nejc Date: Thu, 4 Jan 2024 20:54:10 +0100 Subject: [PATCH 08/58] feat: updated erc20 contract abi --- src/contracts/nabla/ERC20Wrapper.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/contracts/nabla/ERC20Wrapper.ts b/src/contracts/nabla/ERC20Wrapper.ts index 4fc387cb..8dbcb8d5 100644 --- a/src/contracts/nabla/ERC20Wrapper.ts +++ b/src/contracts/nabla/ERC20Wrapper.ts @@ -216,7 +216,7 @@ export const erc20WrapperAbi = { default: false, docs: [''], label: 'totalSupply', - mutates: true, + mutates: false, payable: false, returnType: { displayName: ['uint256'], @@ -237,7 +237,7 @@ export const erc20WrapperAbi = { default: false, docs: [''], label: 'balanceOf', - mutates: true, + mutates: false, payable: false, returnType: { displayName: ['uint256'], @@ -293,7 +293,7 @@ export const erc20WrapperAbi = { default: false, docs: [''], label: 'allowance', - mutates: true, + mutates: false, payable: false, returnType: { displayName: ['uint256'], From 855bb3642e1eb1084527ab42cc68b2a5fad1cd4d Mon Sep 17 00:00:00 2001 From: Nejc Date: Thu, 4 Jan 2024 21:07:01 +0100 Subject: [PATCH 09/58] fix: lint issue --- src/components/Asset/Approval/index.tsx | 4 ++-- .../nabla/Pools/Backstop/AddLiquidity/index.tsx | 8 +++----- .../Backstop/AddLiquidity/useAddLiquidity.ts | 9 +++++---- .../Pools/Backstop/WithdrawLiquidity/index.tsx | 7 ++++--- .../WithdrawLiquidity/useBackstopWithdraw.ts | 7 ++++--- .../WithdrawLiquidity/useSwapPoolWithdraw.ts | 9 +++++---- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 6 +++--- src/components/nabla/Pools/Backstop/index.tsx | 4 ++-- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 8 +++----- .../Pools/Swap/AddLiquidity/useAddLiquidity.ts | 9 +++++---- src/components/nabla/Pools/Swap/Redeem/index.tsx | 5 +++-- .../nabla/Pools/Swap/Redeem/useRedeem.ts | 11 ++++++----- .../nabla/Pools/Swap/WithdrawLiquidity/index.tsx | 5 +++-- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 11 ++++++----- src/components/nabla/Pools/Swap/columns.tsx | 9 +++++---- src/components/nabla/Pools/TokenAmount/index.tsx | 5 +++-- src/components/nabla/Swap/From/index.tsx | 4 ++-- src/components/nabla/Swap/To/index.tsx | 9 +++++---- src/components/nabla/Swap/useSwapComponent.ts | 10 ++++------ src/config/apps/nabla.ts | 2 ++ src/helpers/__tests__/calc.test.ts | 15 ++++++++------- src/pages/collators/CollatorsTable.tsx | 4 ++-- src/pages/nabla/dev/index.tsx | 13 ++++++------- 23 files changed, 91 insertions(+), 83 deletions(-) diff --git a/src/components/Asset/Approval/index.tsx b/src/components/Asset/Approval/index.tsx index f5065b8f..d3f197dc 100644 --- a/src/components/Asset/Approval/index.tsx +++ b/src/components/Asset/Approval/index.tsx @@ -1,5 +1,5 @@ import { Button, ButtonProps } from 'react-daisyui'; -import { FixedU128Decimals } from '../../../shared/parseNumbers'; +import { defaultDecimals } from '../../../config/apps/nabla'; import { ApprovalState, useTokenApproval } from '../../../shared/useTokenApproval'; export type TokenApprovalProps = ButtonProps & { @@ -25,7 +25,7 @@ const TokenApproval = ({ token, spender, enabled, - decimals: FixedU128Decimals, + decimals: defaultDecimals, }); if (approval[0] === ApprovalState.APPROVED || !enabled) return <>{children}; diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index 586aede2..4611cb50 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -3,8 +3,9 @@ import { ChangeEvent } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { BackstopPool } from '../../../../../../gql/graphql'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { FixedU128Decimals, nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import TokenApproval from '../../../../Asset/Approval'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; @@ -114,10 +115,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { {depositQuery.isLoading ? numberLoader : minMax( - calcSharePercentage( - nativeToDecimal(data.totalSupply || 0, FixedU128Decimals).toNumber(), - deposit, - ), + calcSharePercentage(nativeToDecimal(data.totalSupply || 0, defaultDecimals).toNumber(), deposit), )} %
diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts index daab05f2..34b8dfba 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts @@ -1,11 +1,12 @@ import { yupResolver } from '@hookform/resolvers/yup'; import { useQueryClient } from '@tanstack/react-query'; import { useForm, useWatch } from 'react-hook-form'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenant'; import { useModalToggle } from '../../../../../services/modal'; -import { decimalToNative, FixedU128Decimals } from '../../../../../shared/parseNumbers'; +import { decimalToNative } from '../../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../../shared/useContractBalance'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import schema from './schema'; @@ -16,8 +17,8 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: FixedU128Decimals }); - const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: FixedU128Decimals }); + const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); + const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: defaultDecimals }); const form = useForm({ resolver: yupResolver(schema), @@ -40,7 +41,7 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { }); const onSubmit = form.handleSubmit((variables: AddLiquidityValues) => - mutation.mutate([decimalToNative(variables.amount, FixedU128Decimals).toString()]), + mutation.mutate([decimalToNative(variables.amount, defaultDecimals).toString()]), ); const amount = diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index 6a0fe9db..10a3fd51 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -4,10 +4,11 @@ import { ChangeEvent, useMemo } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { BackstopPool } from '../../../../../../gql/graphql'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { calcSharePercentage, getPoolSurplus, minMax } from '../../../../../helpers/calc'; import { useBackstopPool } from '../../../../../hooks/nabla/useBackstopPool'; -import { FixedU128Decimals, nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import { AssetSelectorModal } from '../../../../Asset/Selector/Modal'; import { numberLoader } from '../../../../Loader'; import FormLoader from '../../../../Loader/Form'; @@ -50,7 +51,7 @@ const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element | const isIdle = bpw.mutation.isIdle && spw.mutation.isIdle; const isLoading = bpw.mutation.isLoading || spw.mutation.isLoading; const deposit = depositQuery.balance || 0; - const withdrawLimit = nativeToDecimal(spw.withdrawLimit?.toString() || 0, FixedU128Decimals).toNumber(); + const withdrawLimit = nativeToDecimal(spw.withdrawLimit?.toString() || 0, defaultDecimals).toNumber(); const hideCss = !isIdle ? 'hidden' : ''; return ( @@ -170,7 +171,7 @@ const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element |
Pool share
{minMax( - calcSharePercentage(nativeToDecimal(data.totalSupply || 0, FixedU128Decimals).toNumber(), deposit), + calcSharePercentage(nativeToDecimal(data.totalSupply || 0, defaultDecimals).toNumber(), deposit), )} %
diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts index 7eaa5c22..ab8dfb6d 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts @@ -1,9 +1,10 @@ import { useCallback } from 'react'; import { config } from '../../../../../config'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { subtractPercentage } from '../../../../../helpers/calc'; import { getValidSlippage } from '../../../../../helpers/transaction'; -import { decimalToNative, FixedU128Decimals } from '../../../../../shared/parseNumbers'; +import { decimalToNative } from '../../../../../shared/parseNumbers'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import { WithdrawLiquidityValues } from './types'; @@ -26,8 +27,8 @@ export const useBackstopWithdraw = ({ address, onSuccess }: UseBackstopWithdrawP if (!variables.amount) return; const vSlippage = getValidSlippage(variables.slippage || config.backstop.defaults.slippage); mutate([ - decimalToNative(variables.amount, FixedU128Decimals).toString(), - decimalToNative(subtractPercentage(variables.amount, vSlippage), FixedU128Decimals).toString(), + decimalToNative(variables.amount, defaultDecimals).toString(), + decimalToNative(subtractPercentage(variables.amount, vSlippage), defaultDecimals).toString(), ]); }, [mutate], diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts index 89014100..8e10b488 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts @@ -1,13 +1,14 @@ import { useCallback, useMemo } from 'react'; import { BackstopPool, SwapPool } from '../../../../../../gql/graphql'; import { config } from '../../../../../config'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { useGlobalState } from '../../../../../GlobalStateProvider'; import { calcAvailablePoolWithdraw, subtractPercentage } from '../../../../../helpers/calc'; import { getValidSlippage } from '../../../../../helpers/transaction'; import { useSharesTargetWorth } from '../../../../../hooks/nabla/useSharesTargetWorth'; import { useTokenPrice } from '../../../../../hooks/nabla/useTokenPrice'; -import { decimalToNative, FixedU128Decimals } from '../../../../../shared/parseNumbers'; +import { decimalToNative } from '../../../../../shared/parseNumbers'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import { WithdrawLiquidityValues } from './types'; @@ -37,8 +38,8 @@ export const useSwapPoolWithdraw = ({ pool, selectedPool, deposit, onSuccess, en const vSlippage = getValidSlippage(variables.slippage || config.backstop.defaults.slippage); mutate([ swapPoolAddress, - decimalToNative(variables.amount, FixedU128Decimals).toString(), - decimalToNative(subtractPercentage(variables.amount, vSlippage), FixedU128Decimals).toString(), + decimalToNative(variables.amount, defaultDecimals).toString(), + decimalToNative(subtractPercentage(variables.amount, vSlippage), defaultDecimals).toString(), ]); }, [mutate, swapPoolAddress], @@ -66,7 +67,7 @@ export const useSwapPoolWithdraw = ({ pool, selectedPool, deposit, onSuccess, en shares, bpPrice: bpPrice ? BigInt(bpPrice) : undefined, spPrice: spPrice ? BigInt(spPrice) : undefined, - decimals: FixedU128Decimals, + decimals: defaultDecimals, }), [selectedPool, deposit, shares, bpPrice, spPrice], ); diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts index b931f21e..17e3506f 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -3,6 +3,7 @@ import { useQueryClient } from '@tanstack/react-query'; import { useCallback, useMemo } from 'preact/compat'; import { useForm, useWatch } from 'react-hook-form'; import { BackstopPool, SwapPool } from '../../../../../../gql/graphql'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { storageKeys } from '../../../../../constants/localStorage'; import { debounce } from '../../../../../helpers/function'; @@ -11,7 +12,6 @@ import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenan import { TransactionSettings } from '../../../../../models/Transaction'; import { useModalToggle } from '../../../../../services/modal'; import { storageService } from '../../../../../services/storage/local'; -import { FixedU128Decimals } from '../../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../../shared/useContractBalance'; import { defaultValues } from '../../../Swap/useSwapComponent'; import schema from './schema'; @@ -29,8 +29,8 @@ export const useWithdrawLiquidity = (pool: BackstopPool) => { const toggle = useModalToggle(); const tokenModal = useBoolean(); - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: FixedU128Decimals }); - const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: FixedU128Decimals }); + const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); + const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: defaultDecimals }); const { refetch: balanceRefetch } = balanceQuery; const { refetch: depositRefetch } = depositQuery; diff --git a/src/components/nabla/Pools/Backstop/index.tsx b/src/components/nabla/Pools/Backstop/index.tsx index fbf6d1b4..56d1a36a 100644 --- a/src/components/nabla/Pools/Backstop/index.tsx +++ b/src/components/nabla/Pools/Backstop/index.tsx @@ -1,7 +1,7 @@ import { Button, Card } from 'react-daisyui'; +import { defaultDecimals } from '../../../../config/apps/nabla'; import { useBackstopPools } from '../../../../hooks/nabla/useBackstopPools'; import ModalProvider, { useModalToggle } from '../../../../services/modal'; -import { FixedU128Decimals } from '../../../../shared/parseNumbers'; import Balance from '../../../Balance'; import { Skeleton } from '../../../Skeleton'; import Modals from './Modals'; @@ -22,7 +22,7 @@ const BackstopPoolsBody = (): JSX.Element | null => {

My pool balance

- +
diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index 970bb1b8..85489097 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -1,8 +1,9 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; import { Button } from 'react-daisyui'; import { PoolProgress } from '../..'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { FixedU128Decimals, nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import TokenApproval from '../../../../Asset/Approval'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; @@ -98,10 +99,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { {depositQuery.isLoading ? numberLoader : minMax( - calcSharePercentage( - nativeToDecimal(data.totalSupply || 0, FixedU128Decimals).toNumber(), - deposit, - ), + calcSharePercentage(nativeToDecimal(data.totalSupply || 0, defaultDecimals).toNumber(), deposit), )} %
diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index 87dfdc75..f1d72eac 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -1,11 +1,12 @@ import { yupResolver } from '@hookform/resolvers/yup'; import { useQueryClient } from '@tanstack/react-query'; import { useForm, useWatch } from 'react-hook-form'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenant'; import { useModalToggle } from '../../../../../services/modal'; -import { decimalToNative, FixedU128Decimals } from '../../../../../shared/parseNumbers'; +import { decimalToNative } from '../../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../../shared/useContractBalance'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import schema from './schema'; @@ -16,11 +17,11 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: FixedU128Decimals }); + const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); const depositQuery = useContractBalance({ contractAddress: poolAddress, abi: swapPoolAbi, - decimals: FixedU128Decimals, + decimals: defaultDecimals, }); const form = useForm({ @@ -44,7 +45,7 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { }); const onSubmit = form.handleSubmit((variables: AddLiquidityValues) => - mutation.mutate([decimalToNative(variables.amount, FixedU128Decimals).toString()]), + mutation.mutate([decimalToNative(variables.amount, defaultDecimals).toString()]), ); const amount = diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index ad126cf4..4f389c82 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -3,8 +3,9 @@ import { ChangeEvent } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { config } from '../../../../../config'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { FixedU128Decimals, nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; import { TransactionSettingsDropdown } from '../../../../Transaction/Settings'; @@ -119,7 +120,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => {
Pool share
{minMax( - calcSharePercentage(nativeToDecimal(data.totalSupply || 0, FixedU128Decimals).toNumber(), deposit), + calcSharePercentage(nativeToDecimal(data.totalSupply || 0, defaultDecimals).toNumber(), deposit), )} %
diff --git a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts index f04cb928..855ee280 100644 --- a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts +++ b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts @@ -3,6 +3,7 @@ import { useQueryClient } from '@tanstack/react-query'; import { useCallback } from 'preact/compat'; import { useForm, useWatch } from 'react-hook-form'; import { config } from '../../../../../config'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { storageKeys } from '../../../../../constants/localStorage'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; @@ -13,7 +14,7 @@ import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenan import { TransactionSettings } from '../../../../../models/Transaction'; import { useModalToggle } from '../../../../../services/modal'; import { storageService } from '../../../../../services/storage/local'; -import { decimalToNative, FixedU128Decimals } from '../../../../../shared/parseNumbers'; +import { decimalToNative } from '../../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../../shared/useContractBalance'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import { SwapPoolColumn } from '../columns'; @@ -44,8 +45,8 @@ export const useRedeem = (swapPoolData: SwapPoolColumn) => { const poolAddress = swapPoolData.id; const tokenAddress = swapPoolData.token.id; const backstopPoolAddress = swapPoolData.backstop?.id; - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: FixedU128Decimals }); - const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: FixedU128Decimals }); + const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); + const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: defaultDecimals }); const form = useForm({ resolver: yupResolver(schema), @@ -75,8 +76,8 @@ export const useRedeem = (swapPoolData: SwapPoolColumn) => { const vSlippage = getValidSlippage(variables.slippage || config.backstop.defaults.slippage); return mutate([ poolAddress, - decimalToNative(variables.amount, FixedU128Decimals).toString(), - decimalToNative(subtractPercentage(variables.amount, vSlippage), FixedU128Decimals).toString(), + decimalToNative(variables.amount, defaultDecimals).toString(), + decimalToNative(subtractPercentage(variables.amount, vSlippage), defaultDecimals).toString(), ]); }), [handleSubmit, poolAddress, mutate], diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index 07906d42..89bccc6e 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -2,9 +2,10 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; import { ChangeEvent } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { FixedU128Decimals, nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; import TokenAmount from '../../TokenAmount'; @@ -120,7 +121,7 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null
Pool share
{minMax( - calcSharePercentage(nativeToDecimal(data.totalSupply || 0, FixedU128Decimals).toNumber(), deposit), + calcSharePercentage(nativeToDecimal(data.totalSupply || 0, defaultDecimals).toNumber(), deposit), )} %
diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts index 93d8108c..ad373589 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -2,12 +2,13 @@ import { yupResolver } from '@hookform/resolvers/yup'; import { useQueryClient } from '@tanstack/react-query'; import { useCallback } from 'preact/compat'; import { useForm, useWatch } from 'react-hook-form'; +import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; import { subtractPercentage } from '../../../../../helpers/calc'; import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenant'; import { useModalToggle } from '../../../../../services/modal'; -import { decimalToNative, FixedU128Decimals } from '../../../../../shared/parseNumbers'; +import { decimalToNative } from '../../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../../shared/useContractBalance'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import schema from './schema'; @@ -18,8 +19,8 @@ export const useWithdrawLiquidity = (poolAddress: string, tokenAddress: string) const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: FixedU128Decimals }); - const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: FixedU128Decimals }); + const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); + const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: defaultDecimals }); const form = useForm({ resolver: yupResolver(schema), @@ -50,8 +51,8 @@ export const useWithdrawLiquidity = (poolAddress: string, tokenAddress: string) handleSubmit((variables) => { if (!variables.amount) return; return mutate([ - decimalToNative(variables.amount, FixedU128Decimals).toString(), - decimalToNative(subtractPercentage(variables.amount, 0.5), FixedU128Decimals).toString(), + decimalToNative(variables.amount, defaultDecimals).toString(), + decimalToNative(subtractPercentage(variables.amount, 0.5), defaultDecimals).toString(), ]); }), [handleSubmit, mutate], diff --git a/src/components/nabla/Pools/Swap/columns.tsx b/src/components/nabla/Pools/Swap/columns.tsx index 4525fada..9a4847c4 100644 --- a/src/components/nabla/Pools/Swap/columns.tsx +++ b/src/components/nabla/Pools/Swap/columns.tsx @@ -1,8 +1,9 @@ import { CellContext, ColumnDef } from '@tanstack/react-table'; import { Badge, Button } from 'react-daisyui'; import { SwapPool } from '../../../../../gql/graphql'; +import { defaultDecimals } from '../../../../config/apps/nabla'; import { useModalToggle } from '../../../../services/modal'; -import { FixedU128Decimals, nativeToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; +import { nativeToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; import { LiquidityModalProps, ModalTypes } from './Modals/types'; export type SwapPoolColumn = SwapPool & { @@ -19,7 +20,7 @@ export const nameColumn: ColumnDef = { export const liabilitiesColumn: ColumnDef = { header: 'Pool liabilities', accessorKey: 'liabilities', - accessorFn: (row) => prettyNumbers(nativeToDecimal(row.liabilities || 0, FixedU128Decimals).toNumber()), + accessorFn: (row) => prettyNumbers(nativeToDecimal(row.liabilities || 0, defaultDecimals).toNumber()), enableSorting: true, meta: { className: 'text-right justify-end', @@ -29,7 +30,7 @@ export const liabilitiesColumn: ColumnDef = { export const reservesColumn: ColumnDef = { header: 'Reserves', accessorKey: 'reserves', - accessorFn: (row) => prettyNumbers(nativeToDecimal(row.reserves || 0, FixedU128Decimals).toNumber()), + accessorFn: (row) => prettyNumbers(nativeToDecimal(row.reserves || 0, defaultDecimals).toNumber()), enableSorting: true, meta: { className: 'text-right justify-end', @@ -54,7 +55,7 @@ export const aprColumn: ColumnDef = { export const myAmountColumn: ColumnDef = { header: 'My Pool Amount', accessorKey: 'myAmount', - accessorFn: (row) => prettyNumbers(nativeToDecimal(row.myAmount || 0, FixedU128Decimals).toNumber()), + accessorFn: (row) => prettyNumbers(nativeToDecimal(row.myAmount || 0, defaultDecimals).toNumber()), enableSorting: true, meta: { className: 'text-right justify-end', diff --git a/src/components/nabla/Pools/TokenAmount/index.tsx b/src/components/nabla/Pools/TokenAmount/index.tsx index c2d51da2..760a60c2 100644 --- a/src/components/nabla/Pools/TokenAmount/index.tsx +++ b/src/components/nabla/Pools/TokenAmount/index.tsx @@ -1,7 +1,8 @@ import { Abi } from '@polkadot/api-contract'; +import { defaultDecimals } from '../../../../config/apps/nabla'; import { useSharesTargetWorth } from '../../../../hooks/nabla/useSharesTargetWorth'; import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; -import { FixedU128Decimals, nativeToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; +import { nativeToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; import { numberLoader } from '../../../Loader'; export interface TokenAmountProps { @@ -36,7 +37,7 @@ const TokenAmount = ({ } return ( - {data ? prettyNumbers(nativeToDecimal(data || '0', FixedU128Decimals).toNumber()) : fallback ?? null} + {data ? prettyNumbers(nativeToDecimal(data || '0', defaultDecimals).toNumber()) : fallback ?? null} {symbol ? symbol : null} ); diff --git a/src/components/nabla/Swap/From/index.tsx b/src/components/nabla/Swap/From/index.tsx index f7600bf3..c208190c 100644 --- a/src/components/nabla/Swap/From/index.tsx +++ b/src/components/nabla/Swap/From/index.tsx @@ -3,8 +3,8 @@ import { Fragment } from 'preact'; import { Button } from 'react-daisyui'; import { useFormContext, useWatch } from 'react-hook-form'; import pendulumIcon from '../../../../assets/pendulum-icon.svg'; +import { defaultDecimals } from '../../../../config/apps/nabla'; import { TokensData } from '../../../../hooks/nabla/useTokens'; -import { FixedU128Decimals } from '../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../shared/useContractBalance'; import TokenPrice from '../../Price'; import { SwapFormValues } from '../types'; @@ -22,7 +22,7 @@ const From = ({ tokensMap, onOpenSelector, className }: FromProps): JSX.Element name: 'from', }); const token = tokensMap?.[from]; - const { formatted, balance } = useContractBalance({ contractAddress: token?.id, decimals: FixedU128Decimals }); + const { formatted, balance } = useContractBalance({ contractAddress: token?.id, decimals: defaultDecimals }); return ( <>
diff --git a/src/components/nabla/Swap/To/index.tsx b/src/components/nabla/Swap/To/index.tsx index c7bbd44f..befb3539 100644 --- a/src/components/nabla/Swap/To/index.tsx +++ b/src/components/nabla/Swap/To/index.tsx @@ -5,12 +5,13 @@ import { Button } from 'react-daisyui'; import { useFormContext, useWatch } from 'react-hook-form'; import pendulumIcon from '../../../../assets/pendulum-icon.svg'; import { config } from '../../../../config'; +import { defaultDecimals } from '../../../../config/apps/nabla'; import { subtractPercentage } from '../../../../helpers/calc'; import { TokensData } from '../../../../hooks/nabla/useTokens'; import useBoolean from '../../../../hooks/useBoolean'; import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; import { useTokenOutAmount } from '../../../../hooks/useTokenOutAmount'; -import { FixedU128Decimals, nativeToDecimal, prettyNumbers, roundNumber } from '../../../../shared/parseNumbers'; +import { nativeToDecimal, prettyNumbers, roundNumber } from '../../../../shared/parseNumbers'; import Balance from '../../../Balance'; import { numberLoader } from '../../../Loader'; import { Skeleton } from '../../../Skeleton'; @@ -56,7 +57,7 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu from, to, onSuccess: (val) => { - const toAmount = val ? nativeToDecimal(val, FixedU128Decimals).toNumber() : 0; + const toAmount = val ? nativeToDecimal(val, defaultDecimals).toNumber() : 0; setValue('toAmount', toAmount, { shouldDirty: true, shouldTouch: true, @@ -71,7 +72,7 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu }, [isError, error, setError, clearErrors]); const loading = (isLoading && isLoading && fetchStatus !== 'idle') || fromAmount !== debouncedFromAmount; - const value = data?.data?.free ? prettyNumbers(nativeToDecimal(data.data.free, FixedU128Decimals).toNumber()) : 0; + const value = data?.data?.free ? prettyNumbers(nativeToDecimal(data.data.free, defaultDecimals).toNumber()) : 0; return ( <>
@@ -105,7 +106,7 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu
{toToken ? : '$ -'}
- Balance: + Balance:
diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index f13816ba..479e3688 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -4,6 +4,7 @@ import { useCallback, useEffect, useRef, useState } from 'preact/compat'; import { Resolver, useForm, useWatch } from 'react-hook-form'; import { Token } from '../../../../gql/graphql'; import { config } from '../../../config'; +import { defaultDecimals } from '../../../config/apps/nabla'; import { cacheKeys } from '../../../constants/cache'; import { storageKeys } from '../../../constants/localStorage'; import { routerAbi } from '../../../contracts/nabla/Router'; @@ -15,7 +16,7 @@ import { useTokens } from '../../../hooks/nabla/useTokens'; import { useGetAppDataByTenant } from '../../../hooks/useGetAppDataByTenant'; import { SwapSettings } from '../../../models/Swap'; import { storageService } from '../../../services/storage/local'; -import { calcDeadline, decimalToNative, FixedU128Decimals } from '../../../shared/parseNumbers'; +import { calcDeadline, decimalToNative } from '../../../shared/parseNumbers'; import { useContractWrite } from '../../../shared/useContractWrite'; import schema from './schema'; import { SwapFormValues } from './types'; @@ -94,11 +95,8 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { const vDeadline = getValidDeadline(variables.deadline || defaultValues.deadline); const vSlippage = getValidSlippage(variables.slippage || defaultValues.slippage); const deadline = calcDeadline(vDeadline).toString(); - const fromAmount = decimalToNative(variables.fromAmount, FixedU128Decimals).toString(); - const toMinAmount = decimalToNative( - subtractPercentage(variables.toAmount, vSlippage), - FixedU128Decimals, - ).toString(); + const fromAmount = decimalToNative(variables.fromAmount, defaultDecimals).toString(); + const toMinAmount = decimalToNative(subtractPercentage(variables.toAmount, vSlippage), defaultDecimals).toString(); const spender = address; return swapMutation.mutate([spender, fromAmount, toMinAmount, [variables.from, variables.to], address, deadline]); }); diff --git a/src/config/apps/nabla.ts b/src/config/apps/nabla.ts index 6dcaab81..bc9495cf 100644 --- a/src/config/apps/nabla.ts +++ b/src/config/apps/nabla.ts @@ -16,6 +16,8 @@ export type NablaConfig = AppConfigBase & > >; +export const defaultDecimals = 12; + export const nablaConfig: NablaConfig = { tenants: [TenantName.Foucoco], environment: ['staging', 'development'], diff --git a/src/helpers/__tests__/calc.test.ts b/src/helpers/__tests__/calc.test.ts index 63fed810..89d75646 100644 --- a/src/helpers/__tests__/calc.test.ts +++ b/src/helpers/__tests__/calc.test.ts @@ -1,5 +1,6 @@ import Big from 'big.js'; -import { decimalToNative, FixedU128Decimals } from '../../shared/parseNumbers'; +import { defaultDecimals } from '../../config/apps/nabla'; +import { decimalToNative } from '../../shared/parseNumbers'; import * as helpers from '../calc'; describe('calc', () => { @@ -14,7 +15,7 @@ describe('calc', () => { deposit: BigInt('1000000000000000000000'), // 1000 bpPrice: BigInt('100000000'), // 1 spPrice: BigInt('200000000'), // 2 - decimals: FixedU128Decimals, + decimals: defaultDecimals, }), ).toBe(undefined); @@ -28,7 +29,7 @@ describe('calc', () => { deposit: BigInt('1000000000000000000000'), // 1000 bpPrice: BigInt('100000000'), // 1 spPrice: BigInt('200000000'), // 2 - decimals: FixedU128Decimals, + decimals: defaultDecimals, }), ).toEqual(Big(0)); @@ -42,9 +43,9 @@ describe('calc', () => { deposit: BigInt('1000000000000000000000'), // 1000 bpPrice: BigInt('110000000'), // 1.1 spPrice: BigInt('220000000'), // 2.2 - decimals: FixedU128Decimals, + decimals: defaultDecimals, }), - ).toEqual(decimalToNative('400', FixedU128Decimals)); + ).toEqual(decimalToNative('400', defaultDecimals)); expect( helpers.calcAvailablePoolWithdraw({ @@ -56,8 +57,8 @@ describe('calc', () => { deposit: BigInt('1000000000000000000000'), // 1000 bpPrice: BigInt('110000000'), // 1.1 spPrice: BigInt('220000000'), // 2.2 - decimals: FixedU128Decimals, + decimals: defaultDecimals, }), - ).toEqual(decimalToNative('1000', FixedU128Decimals)); + ).toEqual(decimalToNative('1000', defaultDecimals)); }); }); diff --git a/src/pages/collators/CollatorsTable.tsx b/src/pages/collators/CollatorsTable.tsx index bc17f5cb..8165269c 100644 --- a/src/pages/collators/CollatorsTable.tsx +++ b/src/pages/collators/CollatorsTable.tsx @@ -9,7 +9,7 @@ import { useNodeInfoState } from '../../NodeInfoProvider'; import { nativeToFormat } from '../../shared/parseNumbers'; import { actionsColumn, - aprColumn, + apyColumn, delegatorsColumn, myStakedColumn, nameColumn, @@ -103,7 +103,7 @@ function CollatorsTable() { nameColumn, stakedColumn, delegatorsColumn, - aprColumn, + apyColumn, stakedCol, actionsColumn({ userAccountAddress, diff --git a/src/pages/nabla/dev/index.tsx b/src/pages/nabla/dev/index.tsx index 870d052e..d6fcea29 100644 --- a/src/pages/nabla/dev/index.tsx +++ b/src/pages/nabla/dev/index.tsx @@ -3,10 +3,11 @@ import { Button, Dropdown } from 'react-daisyui'; import { useNavigate } from 'react-router-dom'; import { Token } from '../../../../gql/graphql'; import { config } from '../../../config'; +import { defaultDecimals } from '../../../config/apps/nabla'; import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; import { useGlobalState } from '../../../GlobalStateProvider'; import { useTokens } from '../../../hooks/nabla/useTokens'; -import { decimalToNative, FixedU128Decimals } from '../../../shared/parseNumbers'; +import { decimalToNative } from '../../../shared/parseNumbers'; import { useContractWrite } from '../../../shared/useContractWrite'; const TokenItem = ({ token }: { token: Token }) => { @@ -31,7 +32,7 @@ const TokenItem = ({ token }: { token: Token }) => { color="secondary" type="button" disabled={isLoading} - onClick={() => mutate([address, decimalToNative(1000, FixedU128Decimals).toString()])} + onClick={() => mutate([address, decimalToNative(1000, defaultDecimals).toString()])} > {isLoading ? 'Loading' : 'Mint 1000'} @@ -44,7 +45,7 @@ const TokenItem = ({ token }: { token: Token }) => {
mutate([address, decimalToNative(10000, FixedU128Decimals).toString()])} + onClick={() => mutate([address, decimalToNative(10000, defaultDecimals).toString()])} > 10000
@@ -53,7 +54,7 @@ const TokenItem = ({ token }: { token: Token }) => {
mutate([address, decimalToNative(100000, FixedU128Decimals).toString()])} + onClick={() => mutate([address, decimalToNative(100000, defaultDecimals).toString()])} > 100000
@@ -81,9 +82,7 @@ const DevPage = () => {

Tokens

- {tokens?.map((token) => ( - - ))} + {tokens?.map((token) => )}
From 97d76714e3bfcdc6a83ce517f9cec4edccc6c05e Mon Sep 17 00:00:00 2001 From: Nejc Date: Mon, 8 Jan 2024 20:28:59 +0100 Subject: [PATCH 10/58] feat: show validation errors --- src/components/Transaction/Progress/index.tsx | 1 + .../Pools/Backstop/AddLiquidity/index.tsx | 8 ++++++- .../Backstop/WithdrawLiquidity/index.tsx | 8 ++++++- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 8 ++++++- .../nabla/Pools/Swap/Redeem/index.tsx | 8 ++++++- .../nabla/Pools/Swap/Redeem/useRedeem.ts | 2 +- .../Pools/Swap/WithdrawLiquidity/index.tsx | 8 ++++++- .../Pools/Swap/WithdrawLiquidity/schema.ts | 2 +- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 22 +++++++++---------- src/components/nabla/Pools/index.tsx | 14 +++++------- 10 files changed, 55 insertions(+), 26 deletions(-) diff --git a/src/components/Transaction/Progress/index.tsx b/src/components/Transaction/Progress/index.tsx index fb64d5db..6ec7b918 100644 --- a/src/components/Transaction/Progress/index.tsx +++ b/src/components/Transaction/Progress/index.tsx @@ -17,6 +17,7 @@ export interface TransactionProgressProps { const TransactionProgress = ({ mutation, children, onClose }: TransactionProgressProps): JSX.Element | null => { const { explorer } = useGetTenantConfig(); + console.log(mutation); if (mutation.isIdle) return null; const status = mutation.data?.result?.type; const isSuccess = status === 'success'; diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index 4611cb50..1367e8ee 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -7,6 +7,7 @@ import { defaultDecimals } from '../../../../../config/apps/nabla'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import TokenApproval from '../../../../Asset/Approval'; +import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; import { useAddLiquidity } from './useAddLiquidity'; @@ -23,7 +24,11 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { balanceQuery, depositQuery, amount, - form: { register, setValue }, + form: { + register, + setValue, + formState: { errors }, + }, } = useAddLiquidity(data.id, data.token.id); const balance = balanceQuery.balance || 0; const deposit = depositQuery.balance || 0; @@ -122,6 +127,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
+
+ diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index 85489097..b35baa30 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -5,6 +5,7 @@ import { defaultDecimals } from '../../../../../config/apps/nabla'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import TokenApproval from '../../../../Asset/Approval'; +import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; import { SwapPoolColumn } from '../columns'; @@ -22,7 +23,11 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { balanceQuery, depositQuery, amount, - form: { register, setValue }, + form: { + register, + setValue, + formState: { errors }, + }, } = useAddLiquidity(data.id, data.token.id); const balance = balanceQuery.balance || 0; const deposit = depositQuery.balance || 0; @@ -106,6 +111,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
+ { depositQuery, amount, updateStorage, - form: { register, setValue }, + form: { + register, + setValue, + formState: { errors }, + }, } = useRedeem(data); const deposit = depositQuery.balance || 0; @@ -127,6 +132,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => {
+ diff --git a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts index 855ee280..815cc259 100644 --- a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts +++ b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts @@ -31,7 +31,7 @@ const getInitialValues = (): Partial => { const storageValues = storageService.getParsed(storageKeys.POOL_SETTINGS); return { ...defaultValues, - amount: 0, + amount: undefined, slippage: getValidSlippage(storageValues?.slippage), }; }; diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index 89bccc6e..f396d57d 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -6,6 +6,7 @@ import { defaultDecimals } from '../../../../../config/apps/nabla'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; import TokenAmount from '../../TokenAmount'; @@ -25,7 +26,11 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null balanceQuery, depositQuery, amount, - form: { register, setValue }, + form: { + register, + setValue, + formState: { errors }, + }, } = useWithdrawLiquidity(data.id, data.token.id); const deposit = depositQuery.balance || 0; @@ -142,6 +147,7 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null Redeem from backstop pool
+ diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/schema.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/schema.ts index 4cbb6a06..94f6ff62 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/schema.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/schema.ts @@ -2,7 +2,7 @@ import * as Yup from 'yup'; import { WithdrawLiquidityValues } from './types'; const schema = Yup.object().shape({ - amount: Yup.number().min(0).max(100).required(), + amount: Yup.number().positive().required(), }); export default schema; diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts index ad373589..bbb554a6 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -25,7 +25,7 @@ export const useWithdrawLiquidity = (poolAddress: string, tokenAddress: string) const form = useForm({ resolver: yupResolver(schema), defaultValues: { - amount: 0, + amount: undefined, }, }); const { handleSubmit, reset } = form; @@ -47,15 +47,15 @@ export const useWithdrawLiquidity = (poolAddress: string, tokenAddress: string) const { mutate } = mutation; const onSubmit = useCallback( - () => - handleSubmit((variables) => { - if (!variables.amount) return; - return mutate([ - decimalToNative(variables.amount, defaultDecimals).toString(), - decimalToNative(subtractPercentage(variables.amount, 0.5), defaultDecimals).toString(), - ]); - }), - [handleSubmit, mutate], + (variables: WithdrawLiquidityValues) => { + console.log(variables); + if (!variables.amount) return; + return mutate([ + decimalToNative(variables.amount, defaultDecimals).toString(), + decimalToNative(subtractPercentage(variables.amount, 0.5), defaultDecimals).toString(), + ]); + }, + [mutate], ); const amount = @@ -67,5 +67,5 @@ export const useWithdrawLiquidity = (poolAddress: string, tokenAddress: string) }), ) || 0; - return { form, amount, mutation, onSubmit, toggle, balanceQuery, depositQuery }; + return { form, amount, mutation, onSubmit: handleSubmit(onSubmit), toggle, balanceQuery, depositQuery }; }; diff --git a/src/components/nabla/Pools/index.tsx b/src/components/nabla/Pools/index.tsx index eada14ba..7abc4a22 100644 --- a/src/components/nabla/Pools/index.tsx +++ b/src/components/nabla/Pools/index.tsx @@ -6,14 +6,12 @@ export type PoolProgressProps = { export const PoolProgress = ({ symbol, amount, className = '' }: PoolProgressProps) => { return ( -
-
- {symbol} -
-
- {amount} +
+
+ + {amount} + {symbol} +
); From d821fd74ec1f39544a2459f60214ec7570d96e36 Mon Sep 17 00:00:00 2001 From: Nejc Date: Mon, 8 Jan 2024 20:35:57 +0100 Subject: [PATCH 11/58] test: fix --- config/setupTests.ts | 2 +- package.json | 1 + src/helpers/__tests__/calc.test.ts | 52 ++++++++++++++++-------------- yarn.lock | 3 +- 4 files changed, 31 insertions(+), 27 deletions(-) diff --git a/config/setupTests.ts b/config/setupTests.ts index 1129ad8b..a53b8b36 100644 --- a/config/setupTests.ts +++ b/config/setupTests.ts @@ -1,2 +1,2 @@ /* eslint-env jest */ -import '@testing-library/jest-dom/extend-expect'; +import '@testing-library/jest-dom'; diff --git a/package.json b/package.json index 3bc0a712..dbb66b6f 100644 --- a/package.json +++ b/package.json @@ -97,6 +97,7 @@ "@typescript-eslint/eslint-plugin": "^6.17.0", "@typescript-eslint/parser": "^6.17.0", "autoprefixer": "^10.4.16", + "babel-jest": "^29.4.3", "daisyui": "^2.52.0", "eslint": "^8.56.0", "eslint-plugin-jest": "^27.6.1", diff --git a/src/helpers/__tests__/calc.test.ts b/src/helpers/__tests__/calc.test.ts index 89d75646..5a1e6890 100644 --- a/src/helpers/__tests__/calc.test.ts +++ b/src/helpers/__tests__/calc.test.ts @@ -3,18 +3,20 @@ import { defaultDecimals } from '../../config/apps/nabla'; import { decimalToNative } from '../../shared/parseNumbers'; import * as helpers from '../calc'; +const native1000 = decimalToNative(1000, defaultDecimals).toString(); + describe('calc', () => { it('should return correct withdraw amount from calcAvailablePoolWithdraw', () => { expect( helpers.calcAvailablePoolWithdraw({ selectedPool: { liabilities: undefined, - reserves: '1000000000000000000000', // 1000 + reserves: native1000, }, - shares: BigInt('1000000000000000000000'), // 1000 - deposit: BigInt('1000000000000000000000'), // 1000 - bpPrice: BigInt('100000000'), // 1 - spPrice: BigInt('200000000'), // 2 + shares: BigInt(native1000), + deposit: BigInt(native1000), + bpPrice: BigInt(decimalToNative(1, defaultDecimals).toString()), + spPrice: BigInt(decimalToNative(2, defaultDecimals).toString()), decimals: defaultDecimals, }), ).toBe(undefined); @@ -22,13 +24,13 @@ describe('calc', () => { expect( helpers.calcAvailablePoolWithdraw({ selectedPool: { - liabilities: '1000000000000000000000', // 1000 - reserves: '1000000000000000000000', // 1000 + liabilities: native1000, + reserves: native1000, }, - shares: BigInt('1000000000000000000000'), // 1000 - deposit: BigInt('1000000000000000000000'), // 1000 - bpPrice: BigInt('100000000'), // 1 - spPrice: BigInt('200000000'), // 2 + shares: BigInt(native1000), + deposit: BigInt(native1000), + bpPrice: BigInt(decimalToNative(1, defaultDecimals).toString()), + spPrice: BigInt(decimalToNative(2, defaultDecimals).toString()), decimals: defaultDecimals, }), ).toEqual(Big(0)); @@ -36,29 +38,29 @@ describe('calc', () => { expect( helpers.calcAvailablePoolWithdraw({ selectedPool: { - liabilities: '1000000000000000000000', - reserves: '1200000000000000000000', // 1200 + liabilities: native1000, + reserves: decimalToNative(1200, defaultDecimals).toString(), }, - shares: BigInt('1000000000000000000000'), // 1000 - deposit: BigInt('1000000000000000000000'), // 1000 - bpPrice: BigInt('110000000'), // 1.1 - spPrice: BigInt('220000000'), // 2.2 + shares: BigInt(native1000), + deposit: BigInt(native1000), + bpPrice: BigInt(decimalToNative(1.1, defaultDecimals).toString()), + spPrice: BigInt(decimalToNative(2.2, defaultDecimals).toString()), decimals: defaultDecimals, }), - ).toEqual(decimalToNative('400', defaultDecimals)); + ).toEqual(decimalToNative(400, defaultDecimals)); expect( helpers.calcAvailablePoolWithdraw({ selectedPool: { - liabilities: '1000000000000000000000', - reserves: '5200000000000000000000', // 5200 + liabilities: native1000, + reserves: decimalToNative(5200, defaultDecimals).toString(), }, - shares: BigInt('1000000000000000000000'), // 1000 - deposit: BigInt('1000000000000000000000'), // 1000 - bpPrice: BigInt('110000000'), // 1.1 - spPrice: BigInt('220000000'), // 2.2 + shares: BigInt(native1000), + deposit: BigInt(native1000), + bpPrice: BigInt(decimalToNative(1.1, defaultDecimals).toString()), + spPrice: BigInt(decimalToNative(2.2, defaultDecimals).toString()), decimals: defaultDecimals, }), - ).toEqual(decimalToNative('1000', defaultDecimals)); + ).toEqual(decimalToNative(1000, defaultDecimals)); }); }); diff --git a/yarn.lock b/yarn.lock index 3392b302..d088db74 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6701,7 +6701,7 @@ __metadata: languageName: node linkType: hard -"babel-jest@npm:^29.7.0": +"babel-jest@npm:^29.4.3, babel-jest@npm:^29.7.0": version: 29.7.0 resolution: "babel-jest@npm:29.7.0" dependencies: @@ -14070,6 +14070,7 @@ __metadata: "@walletconnect/modal": "npm:^2.6.2" "@walletconnect/universal-provider": "npm:^2.11.0" autoprefixer: "npm:^10.4.16" + babel-jest: "npm:^29.4.3" big.js: "npm:^6.2.1" bn.js: "npm:^5.2.1" bs58: "npm:^5.0.0" From abc8cff21ae31452dcb61d03a3e73ac6edef3429 Mon Sep 17 00:00:00 2001 From: Nejc Date: Mon, 8 Jan 2024 20:43:13 +0100 Subject: [PATCH 12/58] refactor: removed logs --- src/components/Transaction/Progress/index.tsx | 1 - .../nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts | 1 - src/components/nabla/Swap/From/index.tsx | 2 +- src/components/nabla/Swap/To/index.tsx | 2 +- 4 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/components/Transaction/Progress/index.tsx b/src/components/Transaction/Progress/index.tsx index 6ec7b918..fb64d5db 100644 --- a/src/components/Transaction/Progress/index.tsx +++ b/src/components/Transaction/Progress/index.tsx @@ -17,7 +17,6 @@ export interface TransactionProgressProps { const TransactionProgress = ({ mutation, children, onClose }: TransactionProgressProps): JSX.Element | null => { const { explorer } = useGetTenantConfig(); - console.log(mutation); if (mutation.isIdle) return null; const status = mutation.data?.result?.type; const isSuccess = status === 'success'; diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts index bbb554a6..6d67bb84 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -48,7 +48,6 @@ export const useWithdrawLiquidity = (poolAddress: string, tokenAddress: string) const onSubmit = useCallback( (variables: WithdrawLiquidityValues) => { - console.log(variables); if (!variables.amount) return; return mutate([ decimalToNative(variables.amount, defaultDecimals).toString(), diff --git a/src/components/nabla/Swap/From/index.tsx b/src/components/nabla/Swap/From/index.tsx index c208190c..c2dc83bc 100644 --- a/src/components/nabla/Swap/From/index.tsx +++ b/src/components/nabla/Swap/From/index.tsx @@ -44,7 +44,7 @@ const From = ({ tokensMap, onOpenSelector, className }: FromProps): JSX.Element Pendulum - {token?.symbol} + {token?.symbol || 'Select'}
diff --git a/src/components/nabla/Swap/To/index.tsx b/src/components/nabla/Swap/To/index.tsx index befb3539..af098c24 100644 --- a/src/components/nabla/Swap/To/index.tsx +++ b/src/components/nabla/Swap/To/index.tsx @@ -99,7 +99,7 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu Pendulum - {toToken?.symbol} + {toToken?.symbol || 'Select'}
From 0d4a494d6adce77038c7585cc95b2be0f581414f Mon Sep 17 00:00:00 2001 From: Nejc Date: Mon, 8 Jan 2024 21:45:33 +0100 Subject: [PATCH 13/58] refactor: folders --- .../Pools/Backstop/AddLiquidity/useAddLiquidity.ts | 6 ++++-- .../Pools/Swap/AddLiquidity/useAddLiquidity.ts | 2 +- src/components/nabla/Swap/To/index.tsx | 2 +- src/hooks/{ => nabla}/useTokenOutAmount.ts | 13 +++++++------ 4 files changed, 13 insertions(+), 10 deletions(-) rename src/hooks/{ => nabla}/useTokenOutAmount.ts (70%) diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts index 34b8dfba..47a9cb33 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts @@ -22,7 +22,9 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { const form = useForm({ resolver: yupResolver(schema), - defaultValues: {}, + defaultValues: { + amount: undefined, + }, }); const mutation = useContractWrite({ @@ -40,7 +42,7 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { }, }); - const onSubmit = form.handleSubmit((variables: AddLiquidityValues) => + const onSubmit = form.handleSubmit((variables) => mutation.mutate([decimalToNative(variables.amount, defaultDecimals).toString()]), ); diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index f1d72eac..f702330f 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -44,7 +44,7 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { }, }); - const onSubmit = form.handleSubmit((variables: AddLiquidityValues) => + const onSubmit = form.handleSubmit((variables) => mutation.mutate([decimalToNative(variables.amount, defaultDecimals).toString()]), ); diff --git a/src/components/nabla/Swap/To/index.tsx b/src/components/nabla/Swap/To/index.tsx index af098c24..4bd98bb3 100644 --- a/src/components/nabla/Swap/To/index.tsx +++ b/src/components/nabla/Swap/To/index.tsx @@ -7,10 +7,10 @@ import pendulumIcon from '../../../../assets/pendulum-icon.svg'; import { config } from '../../../../config'; import { defaultDecimals } from '../../../../config/apps/nabla'; import { subtractPercentage } from '../../../../helpers/calc'; +import { useTokenOutAmount } from '../../../../hooks/nabla/useTokenOutAmount'; import { TokensData } from '../../../../hooks/nabla/useTokens'; import useBoolean from '../../../../hooks/useBoolean'; import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; -import { useTokenOutAmount } from '../../../../hooks/useTokenOutAmount'; import { nativeToDecimal, prettyNumbers, roundNumber } from '../../../../shared/parseNumbers'; import Balance from '../../../Balance'; import { numberLoader } from '../../../Loader'; diff --git a/src/hooks/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts similarity index 70% rename from src/hooks/useTokenOutAmount.ts rename to src/hooks/nabla/useTokenOutAmount.ts index ac19329d..aab48f35 100644 --- a/src/hooks/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -1,9 +1,9 @@ -import { activeOptions, cacheKeys } from '../constants/cache'; -import { routerAbi } from '../contracts/nabla/Router'; -import { useGlobalState } from '../GlobalStateProvider'; -import { decimalToNative } from '../shared/parseNumbers'; -import { useContract } from '../shared/useContract'; -import { useGetAppDataByTenant } from './useGetAppDataByTenant'; +import { activeOptions, cacheKeys } from '../../constants/cache'; +import { routerAbi } from '../../contracts/nabla/Router'; +import { useGlobalState } from '../../GlobalStateProvider'; +import { decimalToNative } from '../../shared/parseNumbers'; +import { useContract } from '../../shared/useContract'; +import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; export type UseTokenOutAmountProps = { amount?: number; @@ -18,6 +18,7 @@ export const useTokenOutAmount = ({ amount, from, to, decimals, onSuccess, onErr const amountIn = decimalToNative(amount || 0, decimals).toString(); const { address } = useGlobalState().walletAccount || {}; const { router } = useGetAppDataByTenant('nabla').data || {}; + return useContract([cacheKeys.tokenOutAmount, from, to, amountIn], { ...activeOptions['30s'], abi: routerAbi, From 8938cd11f840f30ca3be8c19f5e710032a4cf57f Mon Sep 17 00:00:00 2001 From: Nejc Date: Sat, 13 Jan 2024 13:59:49 +0100 Subject: [PATCH 14/58] feat: updated message call --- .../WithdrawLiquidity/useSwapPoolWithdraw.ts | 7 ++- .../nabla/Pools/TokenAmount/index.tsx | 8 ++- src/components/nabla/Price/index.tsx | 6 +- src/components/nabla/Swap/To/index.tsx | 4 +- src/hooks/nabla/useSharesTargetWorth.ts | 3 +- src/shared/helpers.ts | 22 ++++++- src/shared/useContract.ts | 59 +++++++++---------- src/shared/useContractBalance.ts | 16 ++--- src/shared/useContractWrite.ts | 12 +--- src/shared/useTokenAllowance.ts | 5 +- src/shared/useTokenApproval.ts | 10 ++-- 11 files changed, 81 insertions(+), 71 deletions(-) diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts index 8e10b488..91c36d09 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts @@ -8,6 +8,7 @@ import { calcAvailablePoolWithdraw, subtractPercentage } from '../../../../../he import { getValidSlippage } from '../../../../../helpers/transaction'; import { useSharesTargetWorth } from '../../../../../hooks/nabla/useSharesTargetWorth'; import { useTokenPrice } from '../../../../../hooks/nabla/useTokenPrice'; +import { getMessageCallValue } from '../../../../../shared/helpers'; import { decimalToNative } from '../../../../../shared/parseNumbers'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import { WithdrawLiquidityValues } from './types'; @@ -53,11 +54,11 @@ export const useSwapPoolWithdraw = ({ pool, selectedPool, deposit, onSuccess, en }, { enabled }, ); - const shares = sharesQuery.data; + const shares = getMessageCallValue(sharesQuery.data); const bpPriceQuery = useTokenPrice(pool.token.id, owner, { enabled }); const spPriceQuery = useTokenPrice(selectedPool.token.id, owner, { enabled }); - const bpPrice = bpPriceQuery.data; - const spPrice = spPriceQuery.data; + const bpPrice = getMessageCallValue(bpPriceQuery.data); + const spPrice = getMessageCallValue(spPriceQuery.data); const withdrawLimit = useMemo( () => diff --git a/src/components/nabla/Pools/TokenAmount/index.tsx b/src/components/nabla/Pools/TokenAmount/index.tsx index 760a60c2..32891eb6 100644 --- a/src/components/nabla/Pools/TokenAmount/index.tsx +++ b/src/components/nabla/Pools/TokenAmount/index.tsx @@ -1,13 +1,13 @@ -import { Abi } from '@polkadot/api-contract'; import { defaultDecimals } from '../../../../config/apps/nabla'; import { useSharesTargetWorth } from '../../../../hooks/nabla/useSharesTargetWorth'; import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; +import { getMessageCallValue } from '../../../../shared/helpers'; import { nativeToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; import { numberLoader } from '../../../Loader'; export interface TokenAmountProps { address: string; - abi?: Abi | Record; + abi?: Dict; amount?: number; debounce?: number; loader?: boolean; @@ -37,7 +37,9 @@ const TokenAmount = ({ } return ( - {data ? prettyNumbers(nativeToDecimal(data || '0', defaultDecimals).toNumber()) : fallback ?? null} + {data + ? prettyNumbers(nativeToDecimal(getMessageCallValue(data) || '0', defaultDecimals).toNumber()) + : fallback ?? null} {symbol ? symbol : null} ); diff --git a/src/components/nabla/Price/index.tsx b/src/components/nabla/Price/index.tsx index 278ecb88..3a269ccd 100644 --- a/src/components/nabla/Price/index.tsx +++ b/src/components/nabla/Price/index.tsx @@ -1,6 +1,7 @@ import { UseQueryOptions } from '@tanstack/react-query'; import { useGlobalState } from '../../../GlobalStateProvider'; import { useTokenPrice } from '../../../hooks/nabla/useTokenPrice'; +import { getMessageCallValue } from '../../../shared/helpers'; import { nativeToDecimal, prettyNumbers } from '../../../shared/parseNumbers'; import { numberLoader } from '../../Loader'; @@ -24,10 +25,11 @@ const TokenPrice = ({ const { address: owner } = useGlobalState().walletAccount || {}; const { data, isLoading } = useTokenPrice(address, owner, options); if (isLoading) return loader ? <>{loader} : numberLoader; - if (!data) return <>{fallback}; + const price = getMessageCallValue(data); + if (!price) return <>{fallback}; return ( - {prefix}${prettyNumbers(amount * nativeToDecimal(data).toNumber())} + {prefix}${prettyNumbers(amount * nativeToDecimal(price).toNumber())} ); }; diff --git a/src/components/nabla/Swap/To/index.tsx b/src/components/nabla/Swap/To/index.tsx index 4bd98bb3..9b34cea3 100644 --- a/src/components/nabla/Swap/To/index.tsx +++ b/src/components/nabla/Swap/To/index.tsx @@ -11,6 +11,7 @@ import { useTokenOutAmount } from '../../../../hooks/nabla/useTokenOutAmount'; import { TokensData } from '../../../../hooks/nabla/useTokens'; import useBoolean from '../../../../hooks/useBoolean'; import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; +import { getMessageCallValue } from '../../../../shared/helpers'; import { nativeToDecimal, prettyNumbers, roundNumber } from '../../../../shared/parseNumbers'; import Balance from '../../../Balance'; import { numberLoader } from '../../../Loader'; @@ -72,7 +73,8 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu }, [isError, error, setError, clearErrors]); const loading = (isLoading && isLoading && fetchStatus !== 'idle') || fromAmount !== debouncedFromAmount; - const value = data?.data?.free ? prettyNumbers(nativeToDecimal(data.data.free, defaultDecimals).toNumber()) : 0; + const outValue = getMessageCallValue(data); + const value = outValue ? prettyNumbers(nativeToDecimal(outValue, defaultDecimals).toNumber()) : 0; return ( <>
diff --git a/src/hooks/nabla/useSharesTargetWorth.ts b/src/hooks/nabla/useSharesTargetWorth.ts index 8124bbbb..4f808b37 100644 --- a/src/hooks/nabla/useSharesTargetWorth.ts +++ b/src/hooks/nabla/useSharesTargetWorth.ts @@ -1,4 +1,3 @@ -import { Abi } from '@polkadot/api-contract'; import { cacheKeys, inactiveOptions } from '../../constants/cache'; import { swapPoolAbi } from '../../contracts/nabla/SwapPool'; import { QueryOptions } from '../../shared/helpers'; @@ -8,7 +7,7 @@ import { useContract } from '../../shared/useContract'; export type UseSharesTargetWorthProps = { address: string | undefined; amount: number | undefined; - abi?: Abi | Dict; + abi?: Dict; }; export const useSharesTargetWorth = ( diff --git a/src/shared/helpers.ts b/src/shared/helpers.ts index 3a5d3e9f..6c460bf0 100644 --- a/src/shared/helpers.ts +++ b/src/shared/helpers.ts @@ -1,3 +1,4 @@ +import { Limits, MessageCallResult } from '@pendulum-chain/api-solang'; import { ApiPromise } from '@polkadot/api'; import { SubmittableResultValue } from '@polkadot/api-base/types'; import type { QueryKey, UseQueryOptions } from '@tanstack/react-query'; @@ -24,7 +25,22 @@ export const parseTransactionError = (result: SubmittableResultValue | undefined } }; -export const gasDefaults = { - refTime: '120000000000', - proofSize: '1200000', +export const defaultReadLimits: Limits = { + gas: { + refTime: '120000000000', + proofSize: '1200000', + }, + storageDeposit: undefined, +}; + +export const defaultWriteLimits: Limits = { + gas: { + refTime: '30000000000', + proofSize: '2400000', + }, + storageDeposit: undefined, +}; + +export const getMessageCallValue = (response: MessageCallResult | undefined) => { + return response?.result.type === 'success' ? response.result.value : undefined; }; diff --git a/src/shared/useContract.ts b/src/shared/useContract.ts index e3cf0825..8e1a43ae 100644 --- a/src/shared/useContract.ts +++ b/src/shared/useContract.ts @@ -1,16 +1,14 @@ -// https://www.npmjs.com/package/@pendulum-chain/api-solang?activeTab=readme /* eslint-disable @typescript-eslint/no-explicit-any */ -/* eslint-disable @typescript-eslint/ban-types */ +import { Limits, messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; import { ApiPromise } from '@polkadot/api'; -import { Abi, ContractPromise } from '@polkadot/api-contract'; -import { ContractOptions } from '@polkadot/api-contract/types'; +import { Abi } from '@polkadot/api-contract'; import { QueryKey, useQuery } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; -import { emptyCacheKey, emptyFn, gasDefaults, QueryOptions } from './helpers'; +import { defaultReadLimits, emptyCacheKey, emptyFn, QueryOptions } from './helpers'; import { useSharedState } from './Provider'; -type ContractOpts = ContractOptions | ((api: ApiPromise) => ContractOptions); -export type UseContractProps> = QueryOptions & { +type ContractOpts = Limits | ((api: ApiPromise) => Limits); +export type UseContractProps> = QueryOptions & { abi: TAbi; address?: string; owner?: string; @@ -19,36 +17,37 @@ export type UseContractProps> = Query options?: ContractOpts; }; -const getOptions = (options: ContractOpts | undefined, api: ApiPromise) => - typeof options === 'function' - ? options(api) - : options || { - gasLimit: api.createType('WeightV2', gasDefaults), - storageDepositLimit: null, - }; +const getLimits = (options: ContractOpts | undefined, api: ApiPromise) => + typeof options === 'function' ? options(api) : options || defaultReadLimits; -export const useContract = >( +export const useContract = >( key: QueryKey, - { abi, address, owner, method, args, options, ...rest }: UseContractProps, + { abi, address, owner, method, options, args, ...rest }: UseContractProps, ) => { - const { api } = useSharedState(); - const contract = useMemo( - () => (api && address ? new ContractPromise(api, abi, address) : undefined), - [abi, address, api], + const { api, address: walletAddress } = useSharedState(); + const contractAbi = useMemo( + () => (abi && api?.registry ? new Abi(abi, api.registry.getChainProperties()) : undefined), + [abi, api?.registry], ); - const enabled = !!contract && rest.enabled !== false && !!api && !!owner; - const query = useQuery( + + const enabled = !!contractAbi && rest.enabled !== false && !!address && !!api && !!owner && !!walletAddress; + const query = useQuery( enabled ? key : emptyCacheKey, enabled ? async () => { - const opts = getOptions(options, api); - const response = await contract.query[method](owner, opts, ...(args || [])); - if (!response?.result?.isOk || response?.output === undefined) { - throw response; - } - // ? TODO: maybe not ideal to cache only output - // caching the whole object causes the output to be converted to hex string - return response.output?.toString(); + const limits = getLimits(options, api); + const response = await messageCall({ + abi: contractAbi, + api, + callerAddress: walletAddress, + contractDeploymentAddress: address, + getSigner: () => Promise.resolve({} as any), // TODO: cleanup in api-solang lib + messageName: method, + messageArguments: args || [], + limits, + }); + if (response?.result?.type !== 'success') throw response; + return response; } : emptyFn, { diff --git a/src/shared/useContractBalance.ts b/src/shared/useContractBalance.ts index 7a95906f..282f666d 100644 --- a/src/shared/useContractBalance.ts +++ b/src/shared/useContractBalance.ts @@ -1,15 +1,14 @@ -import { Abi } from '@polkadot/api-contract'; -import { FrameSystemAccountInfo } from '@polkadot/types/lookup'; +import { MessageCallResult } from '@pendulum-chain/api-solang'; import { UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; import { cacheKeys } from './constants'; -import { QueryOptions } from './helpers'; +import { getMessageCallValue, QueryOptions } from './helpers'; import { nativeToDecimal, prettyNumbers } from './parseNumbers'; import { useSharedState } from './Provider'; import { useContract } from './useContract'; -export type UseBalanceProps> = { +export type UseBalanceProps> = { /** token or contract address */ contractAddress?: string; /** account address */ @@ -19,13 +18,13 @@ export type UseBalanceProps> = { /** parse decimals */ decimals?: number; }; -export type UseBalanceResponse = UseQueryResult & { +export type UseBalanceResponse = UseQueryResult & { balance?: number; formatted?: string; enabled: boolean; }; -export const useContractBalance = >( +export const useContractBalance = >( { contractAddress, account, abi, decimals }: UseBalanceProps, options?: QueryOptions, ): UseBalanceResponse => { @@ -50,8 +49,9 @@ export const useContractBalance = >( }); const { data } = query; const val = useMemo(() => { - if (!data) return undefined; - const balance = nativeToDecimal(parseFloat(data || '0'), decimals).toNumber(); + if (!data || !data.result) return undefined; + const value = getMessageCallValue(data); + const balance = nativeToDecimal(parseFloat(value || '0'), decimals).toNumber(); return { balance, formatted: prettyNumbers(balance) }; }, [data, decimals]); diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index 396f16a0..3d34fc23 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -1,5 +1,4 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ -/* eslint-disable @typescript-eslint/ban-types */ import { Limits, messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; import { ApiPromise } from '@polkadot/api'; import { Abi } from '@polkadot/api-contract'; @@ -7,6 +6,7 @@ import { DispatchError, ExtrinsicStatus } from '@polkadot/types/interfaces'; import { MutationOptions, useMutation } from '@tanstack/react-query'; import { useMemo, useState } from 'preact/compat'; import { createWriteOptions } from '../services/api/helpers'; +import { defaultWriteLimits } from './helpers'; import { useSharedState } from './Provider'; // TODO: fix/improve types - parse abi file @@ -25,14 +25,6 @@ export type UseContractWriteProps> = Partia options?: Limits | ((api: ApiPromise) => Limits); }; -const defaultLimits: Limits = { - gas: { - refTime: '30000000000', - proofSize: '2400000', - }, - storageDeposit: undefined, -}; - export const useContractWrite = >({ abi, address, @@ -67,7 +59,7 @@ export const useContractWrite = >({ }), messageName: method, messageArguments: fnArgs, - limits: { ...defaultLimits, ...contractOptions }, + limits: { ...defaultWriteLimits, ...contractOptions }, }); }; const mutation = useMutation(submit, rest); diff --git a/src/shared/useTokenAllowance.ts b/src/shared/useTokenAllowance.ts index 3c871f6d..3c9999ae 100644 --- a/src/shared/useTokenAllowance.ts +++ b/src/shared/useTokenAllowance.ts @@ -1,10 +1,9 @@ -import { Abi } from '@polkadot/api-contract'; import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; import { cacheKeys } from './constants'; import { QueryOptions } from './helpers'; import { useContract } from './useContract'; -export type UseTokenAllowance = { +export type UseTokenAllowance> = { /** contract/token address */ token?: string; /** spender address */ @@ -15,7 +14,7 @@ export type UseTokenAllowance = { abi?: TAbi; }; -export const useTokenAllowance = ( +export const useTokenAllowance = >( { token, owner, spender, abi }: UseTokenAllowance, options?: QueryOptions, ) => { diff --git a/src/shared/useTokenApproval.ts b/src/shared/useTokenApproval.ts index 16f09079..c1ea4cd3 100644 --- a/src/shared/useTokenApproval.ts +++ b/src/shared/useTokenApproval.ts @@ -1,7 +1,7 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ import { useMemo, useState } from 'preact/compat'; import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; -import { gasDefaults } from './helpers'; +import { getMessageCallValue } from './helpers'; import { decimalToNative, nativeToDecimal } from './parseNumbers'; import { useSharedState } from './Provider'; import { useContractWrite, UseContractWriteProps } from './useContractWrite'; @@ -59,9 +59,6 @@ export const useTokenApproval = ({ address: token, method: 'approve', args: [spender, approveMax ? maxInt : amountBI.toString()], - options: { - gas: gasDefaults, - }, onError: (err) => { setPending(false); if (onError) onError(err); @@ -76,9 +73,10 @@ export const useTokenApproval = ({ }, }); + const allowanceValue = getMessageCallValue(allowanceData); const allowance = useMemo( - () => nativeToDecimal(parseFloat(allowanceData || '0'), decimals).toNumber(), - [allowanceData, decimals], + () => nativeToDecimal(parseFloat(allowanceValue || '0'), decimals).toNumber(), + [allowanceValue, decimals], ); return useMemo<[ApprovalState, typeof mutation]>(() => { From a6ca270d6e44d9c4f6c02c13f2bde3b1aa317873 Mon Sep 17 00:00:00 2001 From: Nejc Date: Sat, 13 Jan 2024 16:30:13 +0100 Subject: [PATCH 15/58] feat: added dev tools --- package.json | 1 + src/main.tsx | 2 ++ yarn.lock | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 53 insertions(+) diff --git a/package.json b/package.json index dbb66b6f..cd55fc7d 100644 --- a/package.json +++ b/package.json @@ -39,6 +39,7 @@ "@talismn/connect-wallets": "^1.2.3", "@tanstack/query-sync-storage-persister": "~4.32.6", "@tanstack/react-query": "~4.32.6", + "@tanstack/react-query-devtools": "~4.32.6", "@tanstack/react-query-persist-client": "~4.32.6", "@tanstack/react-table": "^8.11.2", "@walletconnect/modal": "^2.6.2", diff --git a/src/main.tsx b/src/main.tsx index 265e6fbd..b8a1fd81 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -1,5 +1,6 @@ import { createSyncStoragePersister } from '@tanstack/query-sync-storage-persister'; import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; +import { ReactQueryDevtools } from '@tanstack/react-query-devtools'; import { persistQueryClient } from '@tanstack/react-query-persist-client'; import { render } from 'preact'; import { Theme } from 'react-daisyui'; @@ -40,6 +41,7 @@ render( + , document.getElementById('app') as HTMLElement, ); diff --git a/yarn.lock b/yarn.lock index d088db74..d6b2b641 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5069,6 +5069,15 @@ __metadata: languageName: node linkType: hard +"@tanstack/match-sorter-utils@npm:^8.7.0": + version: 8.11.3 + resolution: "@tanstack/match-sorter-utils@npm:8.11.3" + dependencies: + remove-accents: "npm:0.4.2" + checksum: 2be996a6c0f7bfdfbd7b21ebf2dcfbb280818a27188991f2fab29316b06d99b10fd83799766f56e8fee63c7085604788bc7b992bd4e6d0134f14c3a9021dd797 + languageName: node + linkType: hard + "@tanstack/query-core@npm:4.32.6": version: 4.32.6 resolution: "@tanstack/query-core@npm:4.32.6" @@ -5094,6 +5103,21 @@ __metadata: languageName: node linkType: hard +"@tanstack/react-query-devtools@npm:~4.32.6": + version: 4.32.6 + resolution: "@tanstack/react-query-devtools@npm:4.32.6" + dependencies: + "@tanstack/match-sorter-utils": "npm:^8.7.0" + superjson: "npm:^1.10.0" + use-sync-external-store: "npm:^1.2.0" + peerDependencies: + "@tanstack/react-query": ^4.32.6 + react: ^16.8.0 || ^17.0.0 || ^18.0.0 + react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 + checksum: 3b1354b34348fdf9c604e0dc5e8af4c0afee140c0ed13f061514741bb5127772a9a29892ccd9da5d57d2b1ca5a98265c4c5fd1bec2573deddf682d930dba6c5b + languageName: node + linkType: hard + "@tanstack/react-query-persist-client@npm:~4.32.6": version: 4.32.6 resolution: "@tanstack/react-query-persist-client@npm:4.32.6" @@ -7758,6 +7782,15 @@ __metadata: languageName: node linkType: hard +"copy-anything@npm:^3.0.2": + version: 3.0.5 + resolution: "copy-anything@npm:3.0.5" + dependencies: + is-what: "npm:^4.1.8" + checksum: 01eadd500c7e1db71d32d95a3bfaaedcb839ef891c741f6305ab0461398056133de08f2d1bf4c392b364e7bdb7ce498513896e137a7a183ac2516b065c28a4fe + languageName: node + linkType: hard + "core-js-compat@npm:^3.31.0, core-js-compat@npm:^3.33.1": version: 3.33.2 resolution: "core-js-compat@npm:3.33.2" @@ -11071,6 +11104,13 @@ __metadata: languageName: node linkType: hard +"is-what@npm:^4.1.8": + version: 4.1.16 + resolution: "is-what@npm:4.1.16" + checksum: 611f1947776826dcf85b57cfb7bd3b3ea6f4b94a9c2f551d4a53f653cf0cb9d1e6518846648256d46ee6c91d114b6d09d2ac8a07306f7430c5900f87466aae5b + languageName: node + linkType: hard + "is-windows@npm:^1.0.1": version: 1.0.2 resolution: "is-windows@npm:1.0.2" @@ -14052,6 +14092,7 @@ __metadata: "@talismn/connect-wallets": "npm:^1.2.3" "@tanstack/query-sync-storage-persister": "npm:~4.32.6" "@tanstack/react-query": "npm:~4.32.6" + "@tanstack/react-query-devtools": "npm:~4.32.6" "@tanstack/react-query-persist-client": "npm:~4.32.6" "@tanstack/react-table": "npm:^8.11.2" "@testing-library/jest-dom": "npm:^6.1.6" @@ -16622,6 +16663,15 @@ __metadata: languageName: node linkType: hard +"superjson@npm:^1.10.0": + version: 1.13.3 + resolution: "superjson@npm:1.13.3" + dependencies: + copy-anything: "npm:^3.0.2" + checksum: 389a0a0c86884dd0558361af5d6d7f37102b71dda9595a665fe8b39d1ba0e57c859e39a9bd79b6f1fde6f4dcceac49a1c205f248d292744b2a340ee52846efdb + languageName: node + linkType: hard + "supports-color@npm:^5.3.0": version: 5.5.0 resolution: "supports-color@npm:5.5.0" From f17c19c27157e951f02bbf58f03ed05061f0201d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Sun, 14 Jan 2024 07:53:07 -0300 Subject: [PATCH 16/58] Change PriceOracle metadata --- src/contracts/nabla/PriceOracle.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/contracts/nabla/PriceOracle.ts b/src/contracts/nabla/PriceOracle.ts index e7d45f8a..5e038f8d 100644 --- a/src/contracts/nabla/PriceOracle.ts +++ b/src/contracts/nabla/PriceOracle.ts @@ -166,7 +166,7 @@ export const priceOracleAbi = { 'Returns the asset price in USD. This is called by Nabla and expected by their IPriceOracleGetter interface', ], label: 'getAssetPrice', - mutates: true, + mutates: false, payable: false, returnType: { displayName: ['uint256'], From ad4ff0cec093abf0d33ff8c796ea33ab70131c19 Mon Sep 17 00:00:00 2001 From: Nejc Date: Sun, 14 Jan 2024 12:29:31 +0100 Subject: [PATCH 17/58] refactor: disable react query storage --- src/helpers/addressFormatter.ts | 8 ++++++-- src/hooks/nabla/useTokenOutAmount.ts | 3 ++- src/hooks/nabla/useTokenPrice.ts | 2 +- src/main.tsx | 6 ++---- 4 files changed, 11 insertions(+), 8 deletions(-) diff --git a/src/helpers/addressFormatter.ts b/src/helpers/addressFormatter.ts index 1be2b7f0..c2b75896 100644 --- a/src/helpers/addressFormatter.ts +++ b/src/helpers/addressFormatter.ts @@ -6,8 +6,12 @@ export function getAddressForFormat(address: string, ss58Format: number | string } const keyring = new Keyring(); - const encodedAddress = keyring.encodeAddress(address, ss58Format); - return encodedAddress; + return keyring.encodeAddress(address, ss58Format); +} + +export function getAddressKeyring(address: string, ss58Format: number | string = 57) { + const keyring = new Keyring({ type: 'sr25519', ss58Format: Number(ss58Format) }); + return keyring.addFromAddress(address); } export function trimAddress(address: string, trimLength = 6): string { diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index aab48f35..ec56736f 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -19,6 +19,7 @@ export const useTokenOutAmount = ({ amount, from, to, decimals, onSuccess, onErr const { address } = useGlobalState().walletAccount || {}; const { router } = useGetAppDataByTenant('nabla').data || {}; + const enabled = !!amount && !!from && !!to; return useContract([cacheKeys.tokenOutAmount, from, to, amountIn], { ...activeOptions['30s'], abi: routerAbi, @@ -26,7 +27,7 @@ export const useTokenOutAmount = ({ amount, from, to, decimals, onSuccess, onErr owner: address, method: 'getAmountOut', args: [amountIn, [from, to]], - enabled: !!amount && !!from && !!to, + enabled, onSuccess, onError: (err) => { if (onError) onError(err); diff --git a/src/hooks/nabla/useTokenPrice.ts b/src/hooks/nabla/useTokenPrice.ts index a962bc2b..1d9196d4 100644 --- a/src/hooks/nabla/useTokenPrice.ts +++ b/src/hooks/nabla/useTokenPrice.ts @@ -5,8 +5,8 @@ import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; export const useTokenPrice = (address: string, owner?: string, options?: QueryOptions) => { const { oracle } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!address && !!oracle && options?.enabled !== false; + const enabled = !!address && !!oracle && options?.enabled !== false; return useContract([cacheKeys.tokenPrice, address], { ...inactiveOptions['1m'], ...options, diff --git a/src/main.tsx b/src/main.tsx index b8a1fd81..673104e4 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -1,7 +1,5 @@ -import { createSyncStoragePersister } from '@tanstack/query-sync-storage-persister'; import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; import { ReactQueryDevtools } from '@tanstack/react-query-devtools'; -import { persistQueryClient } from '@tanstack/react-query-persist-client'; import { render } from 'preact'; import { Theme } from 'react-daisyui'; import { BrowserRouter } from 'react-router-dom'; @@ -15,11 +13,11 @@ import SharedProvider from './SharedProvider'; const queryClient = new QueryClient(); -const localStoragePersister = createSyncStoragePersister({ storage: window.localStorage }); +/* const localStoragePersister = createSyncStoragePersister({ storage: window.localStorage }); persistQueryClient({ queryClient, persister: localStoragePersister, -}); +}); */ render( From 00a32f9e8ba8608858cb41fbd156f96af22a8097 Mon Sep 17 00:00:00 2001 From: Nejc Date: Sun, 14 Jan 2024 13:27:00 +0100 Subject: [PATCH 18/58] fix: swap response --- src/components/nabla/Swap/To/index.tsx | 3 ++- src/hooks/nabla/useTokenOutAmount.ts | 5 +++-- src/shared/helpers.ts | 4 ++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/components/nabla/Swap/To/index.tsx b/src/components/nabla/Swap/To/index.tsx index 9b34cea3..a2581790 100644 --- a/src/components/nabla/Swap/To/index.tsx +++ b/src/components/nabla/Swap/To/index.tsx @@ -57,7 +57,8 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu amount: debouncedFromAmount, from, to, - onSuccess: (val) => { + onSuccess: (response) => { + const val = getMessageCallValue(response); const toAmount = val ? nativeToDecimal(val, defaultDecimals).toNumber() : 0; setValue('toAmount', toAmount, { shouldDirty: true, diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index ec56736f..48ad277d 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -1,3 +1,4 @@ +import { MessageCallResult } from '@pendulum-chain/api-solang'; import { activeOptions, cacheKeys } from '../../constants/cache'; import { routerAbi } from '../../contracts/nabla/Router'; import { useGlobalState } from '../../GlobalStateProvider'; @@ -10,8 +11,8 @@ export type UseTokenOutAmountProps = { from?: string; to?: string; decimals?: number; - onSuccess?: (val: string) => void; - onError?: (err: Error) => void; + onSuccess?: (val: MessageCallResult) => void; + onError?: (err: Error | MessageCallResult) => void; }; export const useTokenOutAmount = ({ amount, from, to, decimals, onSuccess, onError }: UseTokenOutAmountProps) => { diff --git a/src/shared/helpers.ts b/src/shared/helpers.ts index 6c460bf0..447fa8be 100644 --- a/src/shared/helpers.ts +++ b/src/shared/helpers.ts @@ -27,8 +27,8 @@ export const parseTransactionError = (result: SubmittableResultValue | undefined export const defaultReadLimits: Limits = { gas: { - refTime: '120000000000', - proofSize: '1200000', + refTime: '500000000000', + proofSize: '4000000', }, storageDeposit: undefined, }; From 89c34bae4a3d2787a3f56d8a2bf05b207aa56a0f Mon Sep 17 00:00:00 2001 From: Nejc Date: Tue, 16 Jan 2024 23:07:57 +0100 Subject: [PATCH 19/58] fix: contract failure --- src/components/nabla/Swap/useSwapComponent.ts | 3 +-- src/shared/useContractWrite.ts | 4 +++- src/shared/useTokenAllowance.ts | 6 ++---- src/shared/useTokenApproval.ts | 2 +- 4 files changed, 7 insertions(+), 8 deletions(-) diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index 479e3688..f6479cbd 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -97,8 +97,7 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { const deadline = calcDeadline(vDeadline).toString(); const fromAmount = decimalToNative(variables.fromAmount, defaultDecimals).toString(); const toMinAmount = decimalToNative(subtractPercentage(variables.toAmount, vSlippage), defaultDecimals).toString(); - const spender = address; - return swapMutation.mutate([spender, fromAmount, toMinAmount, [variables.from, variables.to], address, deadline]); + return swapMutation.mutate([fromAmount, toMinAmount, [variables.from, variables.to], address, deadline]); }); const onFromChange = useCallback( diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index 3d34fc23..06c68797 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -46,7 +46,7 @@ export const useContractWrite = >({ //setTransaction({ status: 'Pending' }); const fnArgs = submitArgs || args || []; const contractOptions = (typeof options === 'function' ? options(api) : options) || createWriteOptions(api); - return messageCall({ + const response = await messageCall({ abi: contractAbi, api, callerAddress: walletAddress, @@ -61,6 +61,8 @@ export const useContractWrite = >({ messageArguments: fnArgs, limits: { ...defaultWriteLimits, ...contractOptions }, }); + if (response?.result?.type !== 'success') throw response; + return response; }; const mutation = useMutation(submit, rest); return { ...mutation, transaction, isReady }; diff --git a/src/shared/useTokenAllowance.ts b/src/shared/useTokenAllowance.ts index 3c9999ae..54d760e5 100644 --- a/src/shared/useTokenAllowance.ts +++ b/src/shared/useTokenAllowance.ts @@ -1,3 +1,4 @@ +import { activeOptions } from '../constants/cache'; import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; import { cacheKeys } from './constants'; import { QueryOptions } from './helpers'; @@ -20,11 +21,8 @@ export const useTokenAllowance = >( ) => { const isEnabled = Boolean(token && owner && spender && options?.enabled); return useContract([cacheKeys.tokenAllowance, spender, token, owner], { - cacheTime: 180000, - staleTime: 180000, + ...activeOptions['3m'], retry: 2, - refetchOnReconnect: false, - refetchOnWindowFocus: false, ...options, abi: abi || erc20WrapperAbi, address: token, diff --git a/src/shared/useTokenApproval.ts b/src/shared/useTokenApproval.ts index c1ea4cd3..76cbd5b9 100644 --- a/src/shared/useTokenApproval.ts +++ b/src/shared/useTokenApproval.ts @@ -69,7 +69,7 @@ export const useTokenApproval = ({ setTimeout(() => { refetch(); setPending(false); - }, 2000); + }, 2000); // delay refetch as sometimes the allowance takes some time to reflect }, }); From 33ad4bcefaff9d6e7e70432f35d6f16e4d608025 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Wed, 21 Feb 2024 19:06:42 -0300 Subject: [PATCH 20/58] Massive update and overhaul for Nabla UI --- gql/gql.ts | 19 +- gql/graphql.ts | 565 ++- src/SharedProvider.tsx | 2 + src/components/Asset/Approval/index.tsx | 23 +- src/components/Asset/Selector/Modal/index.tsx | 46 +- src/components/Asset/Selector/index.tsx | 70 - src/components/Balance/index.tsx | 36 +- src/components/Transaction/Settings/index.tsx | 38 +- .../Pools/Backstop/AddLiquidity/index.tsx | 24 +- .../Backstop/AddLiquidity/useAddLiquidity.ts | 30 +- .../nabla/Pools/Backstop/Modals/types.ts | 4 +- .../Backstop/WithdrawLiquidity/index.tsx | 102 +- .../WithdrawLiquidity/useBackstopWithdraw.ts | 18 +- .../WithdrawLiquidity/useSwapPoolWithdraw.ts | 70 +- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 59 +- src/components/nabla/Pools/Backstop/index.tsx | 15 +- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 21 +- .../Swap/AddLiquidity/useAddLiquidity.ts | 26 +- .../nabla/Pools/Swap/Redeem/index.tsx | 11 +- .../nabla/Pools/Swap/Redeem/useRedeem.ts | 36 +- .../Pools/Swap/WithdrawLiquidity/index.tsx | 30 +- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 30 +- src/components/nabla/Pools/Swap/columns.tsx | 14 +- src/components/nabla/Pools/Swap/index.tsx | 13 +- .../nabla/Pools/TokenAmount/index.tsx | 28 +- src/components/nabla/Price/index.tsx | 14 +- src/components/nabla/Swap/Approval/index.tsx | 12 +- src/components/nabla/Swap/From/index.tsx | 19 +- src/components/nabla/Swap/To/index.tsx | 69 +- src/components/nabla/Swap/index.tsx | 12 +- src/components/nabla/Swap/useSwapComponent.ts | 26 +- src/config/apps/nabla.ts | 24 +- src/constants/cache.ts | 1 + src/contracts/nabla/AmberCurve.ts | 340 -- src/contracts/nabla/BackstopPool.ts | 2577 +++++++------ src/contracts/nabla/ERC20Wrapper.ts | 1114 +++--- src/contracts/nabla/NablaCurve.ts | 734 ++-- src/contracts/nabla/PriceOracle.ts | 983 ++--- src/contracts/nabla/Router.ts | 1339 ++++--- src/contracts/nabla/SwapPool.ts | 3241 ++++++++++------- src/helpers/__tests__/calc.test.ts | 85 +- src/helpers/calc.ts | 71 +- src/helpers/function.ts | 5 +- src/hooks/nabla/mock.ts | 102 - src/hooks/nabla/useBackstopPool.ts | 63 - src/hooks/nabla/useBackstopPools.ts | 53 - src/hooks/nabla/useNablaInstance.ts | 96 + src/hooks/nabla/useSharesTargetWorth.ts | 14 +- src/hooks/nabla/useSwapPools.ts | 58 - src/hooks/nabla/useTokenOutAmount.ts | 25 +- src/hooks/nabla/useTokenPrice.ts | 5 +- src/hooks/nabla/useTokens.ts | 52 - src/pages/nabla/dev/index.tsx | 18 +- src/shared/parseNumbers.ts | 25 +- src/shared/useContract.ts | 49 +- src/shared/useContractBalance.ts | 32 +- src/shared/useTokenAllowance.ts | 17 +- src/shared/useTokenApproval.ts | 47 +- 58 files changed, 7054 insertions(+), 5598 deletions(-) delete mode 100644 src/components/Asset/Selector/index.tsx delete mode 100644 src/contracts/nabla/AmberCurve.ts delete mode 100644 src/hooks/nabla/mock.ts delete mode 100644 src/hooks/nabla/useBackstopPool.ts delete mode 100644 src/hooks/nabla/useBackstopPools.ts create mode 100644 src/hooks/nabla/useNablaInstance.ts delete mode 100644 src/hooks/nabla/useSwapPools.ts delete mode 100644 src/hooks/nabla/useTokens.ts diff --git a/gql/gql.ts b/gql/gql.ts index 50876297..3f680d29 100644 --- a/gql/gql.ts +++ b/gql/gql.ts @@ -13,10 +13,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/ * Therefore it is highly recommended to use the babel or swc plugin for production. */ const documents = { - "\n query getBackstopPool($id: String!) {\n backstopPoolById(id: $id) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n decimals\n id\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n decimals\n id\n name\n symbol\n }\n }\n id\n }\n }\n }\n": types.GetBackstopPoolDocument, - "\n query getBackstopPools($ids: [String!]) {\n backstopPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n decimals\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n }\n id\n }\n }\n }\n": types.GetBackstopPoolsDocument, - "\n query getSwapPools($ids: [String!]) {\n swapPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n name\n symbol\n decimals\n }\n router {\n id\n paused\n }\n backstop {\n id\n liabilities\n paused\n reserves\n totalSupply\n }\n }\n }\n": types.GetSwapPoolsDocument, - "\n query getTokens($ids: [String!]) {\n nablaTokens(where: { id_in: $ids }) {\n id\n name\n symbol\n decimals\n }\n }\n": types.GetTokensDocument, + "\n query getRouter($id: String!) {\n routerById(id: $id) {\n id\n swapPools {\n id\n paused\n name\n reserve\n reserveWithSlippage\n totalLiabilities\n totalSupply\n lpTokenDecimals\n apr\n symbol\n token {\n id\n decimals\n name\n symbol\n }\n }\n backstopPool {\n id\n name\n paused\n symbol\n totalSupply\n apr\n reserves\n lpTokenDecimals\n token {\n id\n decimals\n name\n symbol\n }\n }\n paused\n }\n }\n": types.GetRouterDocument, }; /** @@ -36,19 +33,7 @@ export function graphql(source: string): unknown; /** * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. */ -export function graphql(source: "\n query getBackstopPool($id: String!) {\n backstopPoolById(id: $id) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n decimals\n id\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n decimals\n id\n name\n symbol\n }\n }\n id\n }\n }\n }\n"): (typeof documents)["\n query getBackstopPool($id: String!) {\n backstopPoolById(id: $id) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n decimals\n id\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n decimals\n id\n name\n symbol\n }\n }\n id\n }\n }\n }\n"]; -/** - * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. - */ -export function graphql(source: "\n query getBackstopPools($ids: [String!]) {\n backstopPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n decimals\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n }\n id\n }\n }\n }\n"): (typeof documents)["\n query getBackstopPools($ids: [String!]) {\n backstopPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n decimals\n name\n symbol\n }\n router {\n swapPools(where: { router_isNull: false, paused_not_eq: true }) {\n id\n }\n id\n }\n }\n }\n"]; -/** - * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. - */ -export function graphql(source: "\n query getSwapPools($ids: [String!]) {\n swapPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n name\n symbol\n decimals\n }\n router {\n id\n paused\n }\n backstop {\n id\n liabilities\n paused\n reserves\n totalSupply\n }\n }\n }\n"): (typeof documents)["\n query getSwapPools($ids: [String!]) {\n swapPools(where: { paused_eq: false, id_in: $ids }) {\n id\n liabilities\n paused\n reserves\n totalSupply\n token {\n id\n name\n symbol\n decimals\n }\n router {\n id\n paused\n }\n backstop {\n id\n liabilities\n paused\n reserves\n totalSupply\n }\n }\n }\n"]; -/** - * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. - */ -export function graphql(source: "\n query getTokens($ids: [String!]) {\n nablaTokens(where: { id_in: $ids }) {\n id\n name\n symbol\n decimals\n }\n }\n"): (typeof documents)["\n query getTokens($ids: [String!]) {\n nablaTokens(where: { id_in: $ids }) {\n id\n name\n symbol\n decimals\n }\n }\n"]; +export function graphql(source: "\n query getRouter($id: String!) {\n routerById(id: $id) {\n id\n swapPools {\n id\n paused\n name\n reserve\n reserveWithSlippage\n totalLiabilities\n totalSupply\n lpTokenDecimals\n apr\n symbol\n token {\n id\n decimals\n name\n symbol\n }\n }\n backstopPool {\n id\n name\n paused\n symbol\n totalSupply\n apr\n reserves\n lpTokenDecimals\n token {\n id\n decimals\n name\n symbol\n }\n }\n paused\n }\n }\n"): (typeof documents)["\n query getRouter($id: String!) {\n routerById(id: $id) {\n id\n swapPools {\n id\n paused\n name\n reserve\n reserveWithSlippage\n totalLiabilities\n totalSupply\n lpTokenDecimals\n apr\n symbol\n token {\n id\n decimals\n name\n symbol\n }\n }\n backstopPool {\n id\n name\n paused\n symbol\n totalSupply\n apr\n reserves\n lpTokenDecimals\n token {\n id\n decimals\n name\n symbol\n }\n }\n paused\n }\n }\n"]; export function graphql(source: string) { return (documents as any)[source] ?? {}; diff --git a/gql/graphql.ts b/gql/graphql.ts index f604d748..fc06fa38 100644 --- a/gql/graphql.ts +++ b/gql/graphql.ts @@ -26,15 +26,36 @@ export type Scalars = { export type BackstopPool = { __typename?: 'BackstopPool'; + apr: Scalars['BigInt']['output']; + coveredSwapPools: Array; + feesHistory: Array; id: Scalars['String']['output']; - liabilities: Scalars['BigInt']['output']; + lpTokenDecimals: Scalars['Int']['output']; + name: Scalars['String']['output']; paused: Scalars['Boolean']['output']; reserves: Scalars['BigInt']['output']; router: Router; + symbol: Scalars['String']['output']; token: NablaToken; totalSupply: Scalars['BigInt']['output']; }; + +export type BackstopPoolCoveredSwapPoolsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type BackstopPoolFeesHistoryArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + export type BackstopPoolEdge = { __typename?: 'BackstopPoolEdge'; cursor: Scalars['String']['output']; @@ -42,14 +63,22 @@ export type BackstopPoolEdge = { }; export enum BackstopPoolOrderByInput { + AprAsc = 'apr_ASC', + AprAscNullsFirst = 'apr_ASC_NULLS_FIRST', + AprDesc = 'apr_DESC', + AprDescNullsLast = 'apr_DESC_NULLS_LAST', IdAsc = 'id_ASC', IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', IdDescNullsLast = 'id_DESC_NULLS_LAST', - LiabilitiesAsc = 'liabilities_ASC', - LiabilitiesAscNullsFirst = 'liabilities_ASC_NULLS_FIRST', - LiabilitiesDesc = 'liabilities_DESC', - LiabilitiesDescNullsLast = 'liabilities_DESC_NULLS_LAST', + LpTokenDecimalsAsc = 'lpTokenDecimals_ASC', + LpTokenDecimalsAscNullsFirst = 'lpTokenDecimals_ASC_NULLS_FIRST', + LpTokenDecimalsDesc = 'lpTokenDecimals_DESC', + LpTokenDecimalsDescNullsLast = 'lpTokenDecimals_DESC_NULLS_LAST', + NameAsc = 'name_ASC', + NameAscNullsFirst = 'name_ASC_NULLS_FIRST', + NameDesc = 'name_DESC', + NameDescNullsLast = 'name_DESC_NULLS_LAST', PausedAsc = 'paused_ASC', PausedAscNullsFirst = 'paused_ASC_NULLS_FIRST', PausedDesc = 'paused_DESC', @@ -66,6 +95,10 @@ export enum BackstopPoolOrderByInput { RouterPausedAscNullsFirst = 'router_paused_ASC_NULLS_FIRST', RouterPausedDesc = 'router_paused_DESC', RouterPausedDescNullsLast = 'router_paused_DESC_NULLS_LAST', + SymbolAsc = 'symbol_ASC', + SymbolAscNullsFirst = 'symbol_ASC_NULLS_FIRST', + SymbolDesc = 'symbol_DESC', + SymbolDescNullsLast = 'symbol_DESC_NULLS_LAST', TokenDecimalsAsc = 'token_decimals_ASC', TokenDecimalsAscNullsFirst = 'token_decimals_ASC_NULLS_FIRST', TokenDecimalsDesc = 'token_decimals_DESC', @@ -91,6 +124,21 @@ export enum BackstopPoolOrderByInput { export type BackstopPoolWhereInput = { AND?: InputMaybe>; OR?: InputMaybe>; + apr_eq?: InputMaybe; + apr_gt?: InputMaybe; + apr_gte?: InputMaybe; + apr_in?: InputMaybe>; + apr_isNull?: InputMaybe; + apr_lt?: InputMaybe; + apr_lte?: InputMaybe; + apr_not_eq?: InputMaybe; + apr_not_in?: InputMaybe>; + coveredSwapPools_every?: InputMaybe; + coveredSwapPools_none?: InputMaybe; + coveredSwapPools_some?: InputMaybe; + feesHistory_every?: InputMaybe; + feesHistory_none?: InputMaybe; + feesHistory_some?: InputMaybe; id_contains?: InputMaybe; id_containsInsensitive?: InputMaybe; id_endsWith?: InputMaybe; @@ -108,15 +156,32 @@ export type BackstopPoolWhereInput = { id_not_in?: InputMaybe>; id_not_startsWith?: InputMaybe; id_startsWith?: InputMaybe; - liabilities_eq?: InputMaybe; - liabilities_gt?: InputMaybe; - liabilities_gte?: InputMaybe; - liabilities_in?: InputMaybe>; - liabilities_isNull?: InputMaybe; - liabilities_lt?: InputMaybe; - liabilities_lte?: InputMaybe; - liabilities_not_eq?: InputMaybe; - liabilities_not_in?: InputMaybe>; + lpTokenDecimals_eq?: InputMaybe; + lpTokenDecimals_gt?: InputMaybe; + lpTokenDecimals_gte?: InputMaybe; + lpTokenDecimals_in?: InputMaybe>; + lpTokenDecimals_isNull?: InputMaybe; + lpTokenDecimals_lt?: InputMaybe; + lpTokenDecimals_lte?: InputMaybe; + lpTokenDecimals_not_eq?: InputMaybe; + lpTokenDecimals_not_in?: InputMaybe>; + name_contains?: InputMaybe; + name_containsInsensitive?: InputMaybe; + name_endsWith?: InputMaybe; + name_eq?: InputMaybe; + name_gt?: InputMaybe; + name_gte?: InputMaybe; + name_in?: InputMaybe>; + name_isNull?: InputMaybe; + name_lt?: InputMaybe; + name_lte?: InputMaybe; + name_not_contains?: InputMaybe; + name_not_containsInsensitive?: InputMaybe; + name_not_endsWith?: InputMaybe; + name_not_eq?: InputMaybe; + name_not_in?: InputMaybe>; + name_not_startsWith?: InputMaybe; + name_startsWith?: InputMaybe; paused_eq?: InputMaybe; paused_isNull?: InputMaybe; paused_not_eq?: InputMaybe; @@ -131,6 +196,23 @@ export type BackstopPoolWhereInput = { reserves_not_in?: InputMaybe>; router?: InputMaybe; router_isNull?: InputMaybe; + symbol_contains?: InputMaybe; + symbol_containsInsensitive?: InputMaybe; + symbol_endsWith?: InputMaybe; + symbol_eq?: InputMaybe; + symbol_gt?: InputMaybe; + symbol_gte?: InputMaybe; + symbol_in?: InputMaybe>; + symbol_isNull?: InputMaybe; + symbol_lt?: InputMaybe; + symbol_lte?: InputMaybe; + symbol_not_contains?: InputMaybe; + symbol_not_containsInsensitive?: InputMaybe; + symbol_not_endsWith?: InputMaybe; + symbol_not_eq?: InputMaybe; + symbol_not_in?: InputMaybe>; + symbol_not_startsWith?: InputMaybe; + symbol_startsWith?: InputMaybe; token?: InputMaybe; token_isNull?: InputMaybe; totalSupply_eq?: InputMaybe; @@ -3442,14 +3524,204 @@ export type MintsConnection = { totalCount: Scalars['Int']['output']; }; +export type NablaSwapFee = { + __typename?: 'NablaSwapFee'; + backstopFees: Scalars['BigInt']['output']; + backstopPool?: Maybe; + id: Scalars['String']['output']; + lpFees: Scalars['BigInt']['output']; + protocolFees: Scalars['BigInt']['output']; + swapPool: SwapPool; + timestamp: Scalars['BigInt']['output']; +}; + +export type NablaSwapFeeEdge = { + __typename?: 'NablaSwapFeeEdge'; + cursor: Scalars['String']['output']; + node: NablaSwapFee; +}; + +export enum NablaSwapFeeOrderByInput { + BackstopFeesAsc = 'backstopFees_ASC', + BackstopFeesAscNullsFirst = 'backstopFees_ASC_NULLS_FIRST', + BackstopFeesDesc = 'backstopFees_DESC', + BackstopFeesDescNullsLast = 'backstopFees_DESC_NULLS_LAST', + BackstopPoolAprAsc = 'backstopPool_apr_ASC', + BackstopPoolAprAscNullsFirst = 'backstopPool_apr_ASC_NULLS_FIRST', + BackstopPoolAprDesc = 'backstopPool_apr_DESC', + BackstopPoolAprDescNullsLast = 'backstopPool_apr_DESC_NULLS_LAST', + BackstopPoolIdAsc = 'backstopPool_id_ASC', + BackstopPoolIdAscNullsFirst = 'backstopPool_id_ASC_NULLS_FIRST', + BackstopPoolIdDesc = 'backstopPool_id_DESC', + BackstopPoolIdDescNullsLast = 'backstopPool_id_DESC_NULLS_LAST', + BackstopPoolLpTokenDecimalsAsc = 'backstopPool_lpTokenDecimals_ASC', + BackstopPoolLpTokenDecimalsAscNullsFirst = 'backstopPool_lpTokenDecimals_ASC_NULLS_FIRST', + BackstopPoolLpTokenDecimalsDesc = 'backstopPool_lpTokenDecimals_DESC', + BackstopPoolLpTokenDecimalsDescNullsLast = 'backstopPool_lpTokenDecimals_DESC_NULLS_LAST', + BackstopPoolNameAsc = 'backstopPool_name_ASC', + BackstopPoolNameAscNullsFirst = 'backstopPool_name_ASC_NULLS_FIRST', + BackstopPoolNameDesc = 'backstopPool_name_DESC', + BackstopPoolNameDescNullsLast = 'backstopPool_name_DESC_NULLS_LAST', + BackstopPoolPausedAsc = 'backstopPool_paused_ASC', + BackstopPoolPausedAscNullsFirst = 'backstopPool_paused_ASC_NULLS_FIRST', + BackstopPoolPausedDesc = 'backstopPool_paused_DESC', + BackstopPoolPausedDescNullsLast = 'backstopPool_paused_DESC_NULLS_LAST', + BackstopPoolReservesAsc = 'backstopPool_reserves_ASC', + BackstopPoolReservesAscNullsFirst = 'backstopPool_reserves_ASC_NULLS_FIRST', + BackstopPoolReservesDesc = 'backstopPool_reserves_DESC', + BackstopPoolReservesDescNullsLast = 'backstopPool_reserves_DESC_NULLS_LAST', + BackstopPoolSymbolAsc = 'backstopPool_symbol_ASC', + BackstopPoolSymbolAscNullsFirst = 'backstopPool_symbol_ASC_NULLS_FIRST', + BackstopPoolSymbolDesc = 'backstopPool_symbol_DESC', + BackstopPoolSymbolDescNullsLast = 'backstopPool_symbol_DESC_NULLS_LAST', + BackstopPoolTotalSupplyAsc = 'backstopPool_totalSupply_ASC', + BackstopPoolTotalSupplyAscNullsFirst = 'backstopPool_totalSupply_ASC_NULLS_FIRST', + BackstopPoolTotalSupplyDesc = 'backstopPool_totalSupply_DESC', + BackstopPoolTotalSupplyDescNullsLast = 'backstopPool_totalSupply_DESC_NULLS_LAST', + IdAsc = 'id_ASC', + IdAscNullsFirst = 'id_ASC_NULLS_FIRST', + IdDesc = 'id_DESC', + IdDescNullsLast = 'id_DESC_NULLS_LAST', + LpFeesAsc = 'lpFees_ASC', + LpFeesAscNullsFirst = 'lpFees_ASC_NULLS_FIRST', + LpFeesDesc = 'lpFees_DESC', + LpFeesDescNullsLast = 'lpFees_DESC_NULLS_LAST', + ProtocolFeesAsc = 'protocolFees_ASC', + ProtocolFeesAscNullsFirst = 'protocolFees_ASC_NULLS_FIRST', + ProtocolFeesDesc = 'protocolFees_DESC', + ProtocolFeesDescNullsLast = 'protocolFees_DESC_NULLS_LAST', + SwapPoolAprAsc = 'swapPool_apr_ASC', + SwapPoolAprAscNullsFirst = 'swapPool_apr_ASC_NULLS_FIRST', + SwapPoolAprDesc = 'swapPool_apr_DESC', + SwapPoolAprDescNullsLast = 'swapPool_apr_DESC_NULLS_LAST', + SwapPoolIdAsc = 'swapPool_id_ASC', + SwapPoolIdAscNullsFirst = 'swapPool_id_ASC_NULLS_FIRST', + SwapPoolIdDesc = 'swapPool_id_DESC', + SwapPoolIdDescNullsLast = 'swapPool_id_DESC_NULLS_LAST', + SwapPoolLpTokenDecimalsAsc = 'swapPool_lpTokenDecimals_ASC', + SwapPoolLpTokenDecimalsAscNullsFirst = 'swapPool_lpTokenDecimals_ASC_NULLS_FIRST', + SwapPoolLpTokenDecimalsDesc = 'swapPool_lpTokenDecimals_DESC', + SwapPoolLpTokenDecimalsDescNullsLast = 'swapPool_lpTokenDecimals_DESC_NULLS_LAST', + SwapPoolNameAsc = 'swapPool_name_ASC', + SwapPoolNameAscNullsFirst = 'swapPool_name_ASC_NULLS_FIRST', + SwapPoolNameDesc = 'swapPool_name_DESC', + SwapPoolNameDescNullsLast = 'swapPool_name_DESC_NULLS_LAST', + SwapPoolPausedAsc = 'swapPool_paused_ASC', + SwapPoolPausedAscNullsFirst = 'swapPool_paused_ASC_NULLS_FIRST', + SwapPoolPausedDesc = 'swapPool_paused_DESC', + SwapPoolPausedDescNullsLast = 'swapPool_paused_DESC_NULLS_LAST', + SwapPoolReserveWithSlippageAsc = 'swapPool_reserveWithSlippage_ASC', + SwapPoolReserveWithSlippageAscNullsFirst = 'swapPool_reserveWithSlippage_ASC_NULLS_FIRST', + SwapPoolReserveWithSlippageDesc = 'swapPool_reserveWithSlippage_DESC', + SwapPoolReserveWithSlippageDescNullsLast = 'swapPool_reserveWithSlippage_DESC_NULLS_LAST', + SwapPoolReserveAsc = 'swapPool_reserve_ASC', + SwapPoolReserveAscNullsFirst = 'swapPool_reserve_ASC_NULLS_FIRST', + SwapPoolReserveDesc = 'swapPool_reserve_DESC', + SwapPoolReserveDescNullsLast = 'swapPool_reserve_DESC_NULLS_LAST', + SwapPoolSymbolAsc = 'swapPool_symbol_ASC', + SwapPoolSymbolAscNullsFirst = 'swapPool_symbol_ASC_NULLS_FIRST', + SwapPoolSymbolDesc = 'swapPool_symbol_DESC', + SwapPoolSymbolDescNullsLast = 'swapPool_symbol_DESC_NULLS_LAST', + SwapPoolTotalLiabilitiesAsc = 'swapPool_totalLiabilities_ASC', + SwapPoolTotalLiabilitiesAscNullsFirst = 'swapPool_totalLiabilities_ASC_NULLS_FIRST', + SwapPoolTotalLiabilitiesDesc = 'swapPool_totalLiabilities_DESC', + SwapPoolTotalLiabilitiesDescNullsLast = 'swapPool_totalLiabilities_DESC_NULLS_LAST', + SwapPoolTotalSupplyAsc = 'swapPool_totalSupply_ASC', + SwapPoolTotalSupplyAscNullsFirst = 'swapPool_totalSupply_ASC_NULLS_FIRST', + SwapPoolTotalSupplyDesc = 'swapPool_totalSupply_DESC', + SwapPoolTotalSupplyDescNullsLast = 'swapPool_totalSupply_DESC_NULLS_LAST', + TimestampAsc = 'timestamp_ASC', + TimestampAscNullsFirst = 'timestamp_ASC_NULLS_FIRST', + TimestampDesc = 'timestamp_DESC', + TimestampDescNullsLast = 'timestamp_DESC_NULLS_LAST' +} + +export type NablaSwapFeeWhereInput = { + AND?: InputMaybe>; + OR?: InputMaybe>; + backstopFees_eq?: InputMaybe; + backstopFees_gt?: InputMaybe; + backstopFees_gte?: InputMaybe; + backstopFees_in?: InputMaybe>; + backstopFees_isNull?: InputMaybe; + backstopFees_lt?: InputMaybe; + backstopFees_lte?: InputMaybe; + backstopFees_not_eq?: InputMaybe; + backstopFees_not_in?: InputMaybe>; + backstopPool?: InputMaybe; + backstopPool_isNull?: InputMaybe; + id_contains?: InputMaybe; + id_containsInsensitive?: InputMaybe; + id_endsWith?: InputMaybe; + id_eq?: InputMaybe; + id_gt?: InputMaybe; + id_gte?: InputMaybe; + id_in?: InputMaybe>; + id_isNull?: InputMaybe; + id_lt?: InputMaybe; + id_lte?: InputMaybe; + id_not_contains?: InputMaybe; + id_not_containsInsensitive?: InputMaybe; + id_not_endsWith?: InputMaybe; + id_not_eq?: InputMaybe; + id_not_in?: InputMaybe>; + id_not_startsWith?: InputMaybe; + id_startsWith?: InputMaybe; + lpFees_eq?: InputMaybe; + lpFees_gt?: InputMaybe; + lpFees_gte?: InputMaybe; + lpFees_in?: InputMaybe>; + lpFees_isNull?: InputMaybe; + lpFees_lt?: InputMaybe; + lpFees_lte?: InputMaybe; + lpFees_not_eq?: InputMaybe; + lpFees_not_in?: InputMaybe>; + protocolFees_eq?: InputMaybe; + protocolFees_gt?: InputMaybe; + protocolFees_gte?: InputMaybe; + protocolFees_in?: InputMaybe>; + protocolFees_isNull?: InputMaybe; + protocolFees_lt?: InputMaybe; + protocolFees_lte?: InputMaybe; + protocolFees_not_eq?: InputMaybe; + protocolFees_not_in?: InputMaybe>; + swapPool?: InputMaybe; + swapPool_isNull?: InputMaybe; + timestamp_eq?: InputMaybe; + timestamp_gt?: InputMaybe; + timestamp_gte?: InputMaybe; + timestamp_in?: InputMaybe>; + timestamp_isNull?: InputMaybe; + timestamp_lt?: InputMaybe; + timestamp_lte?: InputMaybe; + timestamp_not_eq?: InputMaybe; + timestamp_not_in?: InputMaybe>; +}; + +export type NablaSwapFeesConnection = { + __typename?: 'NablaSwapFeesConnection'; + edges: Array; + pageInfo: PageInfo; + totalCount: Scalars['Int']['output']; +}; + export type NablaToken = { __typename?: 'NablaToken'; decimals: Scalars['Int']['output']; id: Scalars['String']['output']; name: Scalars['String']['output']; + swapPools: Array; symbol: Scalars['String']['output']; }; + +export type NablaTokenSwapPoolsArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + export type NablaTokenEdge = { __typename?: 'NablaTokenEdge'; cursor: Scalars['String']['output']; @@ -3521,6 +3793,9 @@ export type NablaTokenWhereInput = { name_not_in?: InputMaybe>; name_not_startsWith?: InputMaybe; name_startsWith?: InputMaybe; + swapPools_every?: InputMaybe; + swapPools_none?: InputMaybe; + swapPools_some?: InputMaybe; symbol_contains?: InputMaybe; symbol_containsInsensitive?: InputMaybe; symbol_endsWith?: InputMaybe; @@ -5105,6 +5380,11 @@ export type Query = { mintByUniqueInput?: Maybe; mints: Array; mintsConnection: MintsConnection; + nablaSwapFeeById?: Maybe; + /** @deprecated Use nablaSwapFeeById */ + nablaSwapFeeByUniqueInput?: Maybe; + nablaSwapFees: Array; + nablaSwapFeesConnection: NablaSwapFeesConnection; nablaTokenById?: Maybe; /** @deprecated Use nablaTokenById */ nablaTokenByUniqueInput?: Maybe; @@ -5654,6 +5934,32 @@ export type QueryMintsConnectionArgs = { }; +export type QueryNablaSwapFeeByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type QueryNablaSwapFeeByUniqueInputArgs = { + where: WhereIdInput; +}; + + +export type QueryNablaSwapFeesArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + +export type QueryNablaSwapFeesConnectionArgs = { + after?: InputMaybe; + first?: InputMaybe; + orderBy: Array; + where?: InputMaybe; +}; + + export type QueryNablaTokenByIdArgs = { id: Scalars['String']['input']; }; @@ -6461,14 +6767,14 @@ export type QueryZlkInfosConnectionArgs = { export type Router = { __typename?: 'Router'; - backstopPools: Array; + backstopPool: Array; id: Scalars['String']['output']; paused: Scalars['Boolean']['output']; swapPools: Array; }; -export type RouterBackstopPoolsArgs = { +export type RouterBackstopPoolArgs = { limit?: InputMaybe; offset?: InputMaybe; orderBy?: InputMaybe>; @@ -6503,9 +6809,9 @@ export enum RouterOrderByInput { export type RouterWhereInput = { AND?: InputMaybe>; OR?: InputMaybe>; - backstopPools_every?: InputMaybe; - backstopPools_none?: InputMaybe; - backstopPools_some?: InputMaybe; + backstopPool_every?: InputMaybe; + backstopPool_none?: InputMaybe; + backstopPool_some?: InputMaybe; id_contains?: InputMaybe; id_containsInsensitive?: InputMaybe; id_endsWith?: InputMaybe; @@ -8822,6 +9128,8 @@ export type Subscription = { liquidityPositions: Array; mintById?: Maybe; mints: Array; + nablaSwapFeeById?: Maybe; + nablaSwapFees: Array; nablaTokenById?: Maybe; nablaTokens: Array; oraclePriceById?: Maybe; @@ -9082,6 +9390,19 @@ export type SubscriptionMintsArgs = { }; +export type SubscriptionNablaSwapFeeByIdArgs = { + id: Scalars['String']['input']; +}; + + +export type SubscriptionNablaSwapFeesArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + + export type SubscriptionNablaTokenByIdArgs = { id: Scalars['String']['input']; }; @@ -9636,16 +9957,30 @@ export enum SwapOrderByInput { export type SwapPool = { __typename?: 'SwapPool'; + apr: Scalars['BigInt']['output']; backstop: BackstopPool; + feesHistory: Array; id: Scalars['String']['output']; - liabilities: Scalars['BigInt']['output']; + lpTokenDecimals: Scalars['Int']['output']; + name: Scalars['String']['output']; paused: Scalars['Boolean']['output']; - reserves: Scalars['BigInt']['output']; - router: Router; + reserve: Scalars['BigInt']['output']; + reserveWithSlippage: Scalars['BigInt']['output']; + router?: Maybe; + symbol: Scalars['String']['output']; token: NablaToken; + totalLiabilities: Scalars['BigInt']['output']; totalSupply: Scalars['BigInt']['output']; }; + +export type SwapPoolFeesHistoryArgs = { + limit?: InputMaybe; + offset?: InputMaybe; + orderBy?: InputMaybe>; + where?: InputMaybe; +}; + export type SwapPoolEdge = { __typename?: 'SwapPoolEdge'; cursor: Scalars['String']['output']; @@ -9653,14 +9988,26 @@ export type SwapPoolEdge = { }; export enum SwapPoolOrderByInput { + AprAsc = 'apr_ASC', + AprAscNullsFirst = 'apr_ASC_NULLS_FIRST', + AprDesc = 'apr_DESC', + AprDescNullsLast = 'apr_DESC_NULLS_LAST', + BackstopAprAsc = 'backstop_apr_ASC', + BackstopAprAscNullsFirst = 'backstop_apr_ASC_NULLS_FIRST', + BackstopAprDesc = 'backstop_apr_DESC', + BackstopAprDescNullsLast = 'backstop_apr_DESC_NULLS_LAST', BackstopIdAsc = 'backstop_id_ASC', BackstopIdAscNullsFirst = 'backstop_id_ASC_NULLS_FIRST', BackstopIdDesc = 'backstop_id_DESC', BackstopIdDescNullsLast = 'backstop_id_DESC_NULLS_LAST', - BackstopLiabilitiesAsc = 'backstop_liabilities_ASC', - BackstopLiabilitiesAscNullsFirst = 'backstop_liabilities_ASC_NULLS_FIRST', - BackstopLiabilitiesDesc = 'backstop_liabilities_DESC', - BackstopLiabilitiesDescNullsLast = 'backstop_liabilities_DESC_NULLS_LAST', + BackstopLpTokenDecimalsAsc = 'backstop_lpTokenDecimals_ASC', + BackstopLpTokenDecimalsAscNullsFirst = 'backstop_lpTokenDecimals_ASC_NULLS_FIRST', + BackstopLpTokenDecimalsDesc = 'backstop_lpTokenDecimals_DESC', + BackstopLpTokenDecimalsDescNullsLast = 'backstop_lpTokenDecimals_DESC_NULLS_LAST', + BackstopNameAsc = 'backstop_name_ASC', + BackstopNameAscNullsFirst = 'backstop_name_ASC_NULLS_FIRST', + BackstopNameDesc = 'backstop_name_DESC', + BackstopNameDescNullsLast = 'backstop_name_DESC_NULLS_LAST', BackstopPausedAsc = 'backstop_paused_ASC', BackstopPausedAscNullsFirst = 'backstop_paused_ASC_NULLS_FIRST', BackstopPausedDesc = 'backstop_paused_DESC', @@ -9669,6 +10016,10 @@ export enum SwapPoolOrderByInput { BackstopReservesAscNullsFirst = 'backstop_reserves_ASC_NULLS_FIRST', BackstopReservesDesc = 'backstop_reserves_DESC', BackstopReservesDescNullsLast = 'backstop_reserves_DESC_NULLS_LAST', + BackstopSymbolAsc = 'backstop_symbol_ASC', + BackstopSymbolAscNullsFirst = 'backstop_symbol_ASC_NULLS_FIRST', + BackstopSymbolDesc = 'backstop_symbol_DESC', + BackstopSymbolDescNullsLast = 'backstop_symbol_DESC_NULLS_LAST', BackstopTotalSupplyAsc = 'backstop_totalSupply_ASC', BackstopTotalSupplyAscNullsFirst = 'backstop_totalSupply_ASC_NULLS_FIRST', BackstopTotalSupplyDesc = 'backstop_totalSupply_DESC', @@ -9677,18 +10028,26 @@ export enum SwapPoolOrderByInput { IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', IdDescNullsLast = 'id_DESC_NULLS_LAST', - LiabilitiesAsc = 'liabilities_ASC', - LiabilitiesAscNullsFirst = 'liabilities_ASC_NULLS_FIRST', - LiabilitiesDesc = 'liabilities_DESC', - LiabilitiesDescNullsLast = 'liabilities_DESC_NULLS_LAST', + LpTokenDecimalsAsc = 'lpTokenDecimals_ASC', + LpTokenDecimalsAscNullsFirst = 'lpTokenDecimals_ASC_NULLS_FIRST', + LpTokenDecimalsDesc = 'lpTokenDecimals_DESC', + LpTokenDecimalsDescNullsLast = 'lpTokenDecimals_DESC_NULLS_LAST', + NameAsc = 'name_ASC', + NameAscNullsFirst = 'name_ASC_NULLS_FIRST', + NameDesc = 'name_DESC', + NameDescNullsLast = 'name_DESC_NULLS_LAST', PausedAsc = 'paused_ASC', PausedAscNullsFirst = 'paused_ASC_NULLS_FIRST', PausedDesc = 'paused_DESC', PausedDescNullsLast = 'paused_DESC_NULLS_LAST', - ReservesAsc = 'reserves_ASC', - ReservesAscNullsFirst = 'reserves_ASC_NULLS_FIRST', - ReservesDesc = 'reserves_DESC', - ReservesDescNullsLast = 'reserves_DESC_NULLS_LAST', + ReserveWithSlippageAsc = 'reserveWithSlippage_ASC', + ReserveWithSlippageAscNullsFirst = 'reserveWithSlippage_ASC_NULLS_FIRST', + ReserveWithSlippageDesc = 'reserveWithSlippage_DESC', + ReserveWithSlippageDescNullsLast = 'reserveWithSlippage_DESC_NULLS_LAST', + ReserveAsc = 'reserve_ASC', + ReserveAscNullsFirst = 'reserve_ASC_NULLS_FIRST', + ReserveDesc = 'reserve_DESC', + ReserveDescNullsLast = 'reserve_DESC_NULLS_LAST', RouterIdAsc = 'router_id_ASC', RouterIdAscNullsFirst = 'router_id_ASC_NULLS_FIRST', RouterIdDesc = 'router_id_DESC', @@ -9697,6 +10056,10 @@ export enum SwapPoolOrderByInput { RouterPausedAscNullsFirst = 'router_paused_ASC_NULLS_FIRST', RouterPausedDesc = 'router_paused_DESC', RouterPausedDescNullsLast = 'router_paused_DESC_NULLS_LAST', + SymbolAsc = 'symbol_ASC', + SymbolAscNullsFirst = 'symbol_ASC_NULLS_FIRST', + SymbolDesc = 'symbol_DESC', + SymbolDescNullsLast = 'symbol_DESC_NULLS_LAST', TokenDecimalsAsc = 'token_decimals_ASC', TokenDecimalsAscNullsFirst = 'token_decimals_ASC_NULLS_FIRST', TokenDecimalsDesc = 'token_decimals_DESC', @@ -9713,6 +10076,10 @@ export enum SwapPoolOrderByInput { TokenSymbolAscNullsFirst = 'token_symbol_ASC_NULLS_FIRST', TokenSymbolDesc = 'token_symbol_DESC', TokenSymbolDescNullsLast = 'token_symbol_DESC_NULLS_LAST', + TotalLiabilitiesAsc = 'totalLiabilities_ASC', + TotalLiabilitiesAscNullsFirst = 'totalLiabilities_ASC_NULLS_FIRST', + TotalLiabilitiesDesc = 'totalLiabilities_DESC', + TotalLiabilitiesDescNullsLast = 'totalLiabilities_DESC_NULLS_LAST', TotalSupplyAsc = 'totalSupply_ASC', TotalSupplyAscNullsFirst = 'totalSupply_ASC_NULLS_FIRST', TotalSupplyDesc = 'totalSupply_DESC', @@ -9722,8 +10089,20 @@ export enum SwapPoolOrderByInput { export type SwapPoolWhereInput = { AND?: InputMaybe>; OR?: InputMaybe>; + apr_eq?: InputMaybe; + apr_gt?: InputMaybe; + apr_gte?: InputMaybe; + apr_in?: InputMaybe>; + apr_isNull?: InputMaybe; + apr_lt?: InputMaybe; + apr_lte?: InputMaybe; + apr_not_eq?: InputMaybe; + apr_not_in?: InputMaybe>; backstop?: InputMaybe; backstop_isNull?: InputMaybe; + feesHistory_every?: InputMaybe; + feesHistory_none?: InputMaybe; + feesHistory_some?: InputMaybe; id_contains?: InputMaybe; id_containsInsensitive?: InputMaybe; id_endsWith?: InputMaybe; @@ -9741,31 +10120,83 @@ export type SwapPoolWhereInput = { id_not_in?: InputMaybe>; id_not_startsWith?: InputMaybe; id_startsWith?: InputMaybe; - liabilities_eq?: InputMaybe; - liabilities_gt?: InputMaybe; - liabilities_gte?: InputMaybe; - liabilities_in?: InputMaybe>; - liabilities_isNull?: InputMaybe; - liabilities_lt?: InputMaybe; - liabilities_lte?: InputMaybe; - liabilities_not_eq?: InputMaybe; - liabilities_not_in?: InputMaybe>; + lpTokenDecimals_eq?: InputMaybe; + lpTokenDecimals_gt?: InputMaybe; + lpTokenDecimals_gte?: InputMaybe; + lpTokenDecimals_in?: InputMaybe>; + lpTokenDecimals_isNull?: InputMaybe; + lpTokenDecimals_lt?: InputMaybe; + lpTokenDecimals_lte?: InputMaybe; + lpTokenDecimals_not_eq?: InputMaybe; + lpTokenDecimals_not_in?: InputMaybe>; + name_contains?: InputMaybe; + name_containsInsensitive?: InputMaybe; + name_endsWith?: InputMaybe; + name_eq?: InputMaybe; + name_gt?: InputMaybe; + name_gte?: InputMaybe; + name_in?: InputMaybe>; + name_isNull?: InputMaybe; + name_lt?: InputMaybe; + name_lte?: InputMaybe; + name_not_contains?: InputMaybe; + name_not_containsInsensitive?: InputMaybe; + name_not_endsWith?: InputMaybe; + name_not_eq?: InputMaybe; + name_not_in?: InputMaybe>; + name_not_startsWith?: InputMaybe; + name_startsWith?: InputMaybe; paused_eq?: InputMaybe; paused_isNull?: InputMaybe; paused_not_eq?: InputMaybe; - reserves_eq?: InputMaybe; - reserves_gt?: InputMaybe; - reserves_gte?: InputMaybe; - reserves_in?: InputMaybe>; - reserves_isNull?: InputMaybe; - reserves_lt?: InputMaybe; - reserves_lte?: InputMaybe; - reserves_not_eq?: InputMaybe; - reserves_not_in?: InputMaybe>; + reserveWithSlippage_eq?: InputMaybe; + reserveWithSlippage_gt?: InputMaybe; + reserveWithSlippage_gte?: InputMaybe; + reserveWithSlippage_in?: InputMaybe>; + reserveWithSlippage_isNull?: InputMaybe; + reserveWithSlippage_lt?: InputMaybe; + reserveWithSlippage_lte?: InputMaybe; + reserveWithSlippage_not_eq?: InputMaybe; + reserveWithSlippage_not_in?: InputMaybe>; + reserve_eq?: InputMaybe; + reserve_gt?: InputMaybe; + reserve_gte?: InputMaybe; + reserve_in?: InputMaybe>; + reserve_isNull?: InputMaybe; + reserve_lt?: InputMaybe; + reserve_lte?: InputMaybe; + reserve_not_eq?: InputMaybe; + reserve_not_in?: InputMaybe>; router?: InputMaybe; router_isNull?: InputMaybe; + symbol_contains?: InputMaybe; + symbol_containsInsensitive?: InputMaybe; + symbol_endsWith?: InputMaybe; + symbol_eq?: InputMaybe; + symbol_gt?: InputMaybe; + symbol_gte?: InputMaybe; + symbol_in?: InputMaybe>; + symbol_isNull?: InputMaybe; + symbol_lt?: InputMaybe; + symbol_lte?: InputMaybe; + symbol_not_contains?: InputMaybe; + symbol_not_containsInsensitive?: InputMaybe; + symbol_not_endsWith?: InputMaybe; + symbol_not_eq?: InputMaybe; + symbol_not_in?: InputMaybe>; + symbol_not_startsWith?: InputMaybe; + symbol_startsWith?: InputMaybe; token?: InputMaybe; token_isNull?: InputMaybe; + totalLiabilities_eq?: InputMaybe; + totalLiabilities_gt?: InputMaybe; + totalLiabilities_gte?: InputMaybe; + totalLiabilities_in?: InputMaybe>; + totalLiabilities_isNull?: InputMaybe; + totalLiabilities_lt?: InputMaybe; + totalLiabilities_lte?: InputMaybe; + totalLiabilities_not_eq?: InputMaybe; + totalLiabilities_not_in?: InputMaybe>; totalSupply_eq?: InputMaybe; totalSupply_gt?: InputMaybe; totalSupply_gte?: InputMaybe; @@ -11884,36 +12315,12 @@ export type ZenlinkInfosConnection = { totalCount: Scalars['Int']['output']; }; -export type GetBackstopPoolQueryVariables = Exact<{ +export type GetRouterQueryVariables = Exact<{ id: Scalars['String']['input']; }>; -export type GetBackstopPoolQuery = { __typename?: 'Query', backstopPoolById?: { __typename?: 'BackstopPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any, token: { __typename?: 'NablaToken', decimals: number, id: string, name: string, symbol: string }, router: { __typename?: 'Router', id: string, swapPools: Array<{ __typename?: 'SwapPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any, token: { __typename?: 'NablaToken', decimals: number, id: string, name: string, symbol: string } }> } } | null }; - -export type GetBackstopPoolsQueryVariables = Exact<{ - ids?: InputMaybe | Scalars['String']['input']>; -}>; - - -export type GetBackstopPoolsQuery = { __typename?: 'Query', backstopPools: Array<{ __typename?: 'BackstopPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any, token: { __typename?: 'NablaToken', id: string, decimals: number, name: string, symbol: string }, router: { __typename?: 'Router', id: string, swapPools: Array<{ __typename?: 'SwapPool', id: string }> } }> }; - -export type GetSwapPoolsQueryVariables = Exact<{ - ids?: InputMaybe | Scalars['String']['input']>; -}>; - - -export type GetSwapPoolsQuery = { __typename?: 'Query', swapPools: Array<{ __typename?: 'SwapPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any, token: { __typename?: 'NablaToken', id: string, name: string, symbol: string, decimals: number }, router: { __typename?: 'Router', id: string, paused: boolean }, backstop: { __typename?: 'BackstopPool', id: string, liabilities: any, paused: boolean, reserves: any, totalSupply: any } }> }; - -export type GetTokensQueryVariables = Exact<{ - ids?: InputMaybe | Scalars['String']['input']>; -}>; - - -export type GetTokensQuery = { __typename?: 'Query', nablaTokens: Array<{ __typename?: 'NablaToken', id: string, name: string, symbol: string, decimals: number }> }; +export type GetRouterQuery = { __typename?: 'Query', routerById?: { __typename?: 'Router', id: string, paused: boolean, swapPools: Array<{ __typename?: 'SwapPool', id: string, paused: boolean, name: string, reserve: any, reserveWithSlippage: any, totalLiabilities: any, totalSupply: any, lpTokenDecimals: number, apr: any, symbol: string, token: { __typename?: 'NablaToken', id: string, decimals: number, name: string, symbol: string } }>, backstopPool: Array<{ __typename?: 'BackstopPool', id: string, name: string, paused: boolean, symbol: string, totalSupply: any, apr: any, reserves: any, lpTokenDecimals: number, token: { __typename?: 'NablaToken', id: string, decimals: number, name: string, symbol: string } }> } | null }; -export const GetBackstopPoolDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getBackstopPool"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"id"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"backstopPoolById"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"id"},"value":{"kind":"Variable","name":{"kind":"Name","value":"id"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}},{"kind":"Field","name":{"kind":"Name","value":"router"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"router_isNull"},"value":{"kind":"BooleanValue","value":false}},{"kind":"ObjectField","name":{"kind":"Name","value":"paused_not_eq"},"value":{"kind":"BooleanValue","value":true}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]}}]} as unknown as DocumentNode; -export const GetBackstopPoolsDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getBackstopPools"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"ids"}},"type":{"kind":"ListType","type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"backstopPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"paused_eq"},"value":{"kind":"BooleanValue","value":false}},{"kind":"ObjectField","name":{"kind":"Name","value":"id_in"},"value":{"kind":"Variable","name":{"kind":"Name","value":"ids"}}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}},{"kind":"Field","name":{"kind":"Name","value":"router"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"router_isNull"},"value":{"kind":"BooleanValue","value":false}},{"kind":"ObjectField","name":{"kind":"Name","value":"paused_not_eq"},"value":{"kind":"BooleanValue","value":true}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]}}]} as unknown as DocumentNode; -export const GetSwapPoolsDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getSwapPools"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"ids"}},"type":{"kind":"ListType","type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"paused_eq"},"value":{"kind":"BooleanValue","value":false}},{"kind":"ObjectField","name":{"kind":"Name","value":"id_in"},"value":{"kind":"Variable","name":{"kind":"Name","value":"ids"}}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}}]}},{"kind":"Field","name":{"kind":"Name","value":"router"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}}]}},{"kind":"Field","name":{"kind":"Name","value":"backstop"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"liabilities"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}}]}}]}}]}}]} as unknown as DocumentNode; -export const GetTokensDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getTokens"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"ids"}},"type":{"kind":"ListType","type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"nablaTokens"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"where"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"id_in"},"value":{"kind":"Variable","name":{"kind":"Name","value":"ids"}}}]}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}}]}}]}}]} as unknown as DocumentNode; \ No newline at end of file +export const GetRouterDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getRouter"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"id"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"routerById"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"id"},"value":{"kind":"Variable","name":{"kind":"Name","value":"id"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"reserve"}},{"kind":"Field","name":{"kind":"Name","value":"reserveWithSlippage"}},{"kind":"Field","name":{"kind":"Name","value":"totalLiabilities"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"lpTokenDecimals"}},{"kind":"Field","name":{"kind":"Name","value":"apr"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"backstopPool"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"apr"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"lpTokenDecimals"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"paused"}}]}}]}}]} as unknown as DocumentNode; \ No newline at end of file diff --git a/src/SharedProvider.tsx b/src/SharedProvider.tsx index 4e4a7aa4..a7201af3 100644 --- a/src/SharedProvider.tsx +++ b/src/SharedProvider.tsx @@ -7,6 +7,8 @@ const SharedProvider = ({ children }: { children: ComponentChildren }) => { const { api } = useNodeInfoState().state; const { signer, address } = useGlobalState().walletAccount || {}; + console.log('Provider', api, signer, address); + return ( {children} diff --git a/src/components/Asset/Approval/index.tsx b/src/components/Asset/Approval/index.tsx index d3f197dc..a4951748 100644 --- a/src/components/Asset/Approval/index.tsx +++ b/src/components/Asset/Approval/index.tsx @@ -1,46 +1,51 @@ import { Button, ButtonProps } from 'react-daisyui'; -import { defaultDecimals } from '../../../config/apps/nabla'; import { ApprovalState, useTokenApproval } from '../../../shared/useTokenApproval'; export type TokenApprovalProps = ButtonProps & { - token: string | undefined; - amount: number; + token: string; + decimalAmount: number; /** contract address (eg. router address) */ - spender?: string; + spender: string; enabled?: boolean; children: ReactNode; + decimals: number; }; const TokenApproval = ({ - amount, + decimalAmount, token, spender, + decimals, enabled = true, children, className = '', ...rest }: TokenApprovalProps): JSX.Element | null => { const approval = useTokenApproval({ - amount, + decimalAmount, token, spender, enabled, - decimals: defaultDecimals, + decimals, }); + console.log('Approval button', approval[0], ApprovalState); if (approval[0] === ApprovalState.APPROVED || !enabled) return <>{children}; + + const noAccount = approval[0] === ApprovalState.NO_ACCOUNT; const isPending = approval[0] === ApprovalState.PENDING; const isLoading = approval[0] === ApprovalState.LOADING; + return ( ); }; diff --git a/src/components/Asset/Selector/Modal/index.tsx b/src/components/Asset/Selector/Modal/index.tsx index f34518c6..3b7fe462 100644 --- a/src/components/Asset/Selector/Modal/index.tsx +++ b/src/components/Asset/Selector/Modal/index.tsx @@ -5,35 +5,22 @@ import { Avatar, AvatarProps, Button, Input, Modal, ModalProps } from 'react-dai import { repeat } from '../../../../helpers/general'; import ModalCloseButton from '../../../Button/ModalClose'; import { Skeleton } from '../../../Skeleton'; +import { NablaInstanceToken } from '../../../../hooks/nabla/useNablaInstance'; -export type SelectorToken = { - decimals: number; - id: string; - name: string; - symbol: string; -}; -export type SelectorValue = SelectorToken | Dict; - -export interface AssetListProps { - assets?: T[]; - map?: (value: T) => SelectorToken | undefined; - onSelect: (asset: T) => void; +export interface AssetListProps { + assets?: NablaInstanceToken[]; + onSelect: (asset: NablaInstanceToken) => void; selected?: string; } -const AssetList = ({ - assets, - onSelect, - selected, - map, -}: AssetListProps): JSX.Element | null => { +function AssetList({ assets, onSelect, selected }: AssetListProps) { const [filter, setFilter] = useState(); const filteredTokens = useMemo( () => filter && assets ? matchSorter(assets, filter, { - keys: ['name', 'address', 'symbol', 'token.name', 'token.address', 'token.symbol'], + keys: ['name', 'address', 'symbol'], }) : assets, [assets, filter], @@ -48,16 +35,14 @@ const AssetList = ({ placeholder="Find by name or address" />
- {filteredTokens?.map((value) => { - const token = (map ? map(value) : value) as SelectorToken | undefined; - if (!token || !('symbol' in token)) return null; + {filteredTokens?.map((token) => { return (
); -}; +} -export type AssetSelectorModalProps = { +export type AssetSelectorModalProps = { isLoading?: boolean; onClose: () => void; -} & AssetListProps & +} & AssetListProps & Omit; -export const AssetSelectorModal = ({ +export function AssetSelectorModal({ assets, selected, isLoading, onSelect, onClose, - map, ...rest -}: AssetSelectorModalProps) => { +}: AssetSelectorModalProps) { return ( @@ -112,12 +96,12 @@ export const AssetSelectorModal = ({ {isLoading ? ( repeat() ) : ( - + )} ); -}; +} export default AssetList; diff --git a/src/components/Asset/Selector/index.tsx b/src/components/Asset/Selector/index.tsx deleted file mode 100644 index 6a10aff6..00000000 --- a/src/components/Asset/Selector/index.tsx +++ /dev/null @@ -1,70 +0,0 @@ -import { ChevronDownIcon } from '@heroicons/react/24/outline'; -import { useCallback, useState } from 'preact/compat'; -import { Button, ButtonProps } from 'react-daisyui'; -import { Token } from '../../../../gql/graphql'; -import pendulumIcon from '../../../assets/pendulum-icon.svg'; -import { useTokens } from '../../../hooks/nabla/useTokens'; -import useBoolean from '../../../hooks/useBoolean'; -import { AssetSelectorModal } from './Modal'; - -export type AssetSelectorProps = { - onSelect: (asset: Token) => void; - selected?: string; -} & ButtonProps; - -const iconSizes = { - xs: 4, - sm: 4, - md: 5, - lg: 5, -}; - -const AssetSelector = ({ onSelect, selected, size = 'xs', ...rest }: AssetSelectorProps): JSX.Element | null => { - const { isLoading, data } = useTokens(); - const { tokens, tokensMap } = data || {}; - const [open, { setFalse, setTrue }] = useBoolean(); - const [selectedAsset, setSelectedAsset] = useState(); - const initialSelected = selected ? tokensMap?.[selected] : undefined; - const selectedAssetVal = selectedAsset || initialSelected; - - const internalOnSelect = useCallback( - (asset: Token) => { - setSelectedAsset(asset); - onSelect(asset); - setFalse(); - }, - [onSelect, setFalse], - ); - - const iconSz = iconSizes[size] || iconSizes.sm; - return ( -
- - -
- ); -}; - -export default AssetSelector; diff --git a/src/components/Balance/index.tsx b/src/components/Balance/index.tsx index dbb64de0..b0a931d8 100644 --- a/src/components/Balance/index.tsx +++ b/src/components/Balance/index.tsx @@ -1,33 +1,19 @@ -import { ComponentChildren } from 'preact'; -import { QueryOptions } from '../../constants/cache'; import { useContractBalance } from '../../shared/useContractBalance'; import { numberLoader } from '../Loader'; export type BalanceProps = { - address?: string; - fallback?: string | number; - loader?: boolean; - decimals?: number; - options?: QueryOptions; - children?: ComponentChildren; + address: string | undefined; + decimals: number | undefined; + abi: Dict; }; -const Balance = ({ - address, - fallback = 0, - loader = true, - decimals, - options, - children, -}: BalanceProps): JSX.Element | null => { - const { isLoading, formatted, enabled } = useContractBalance({ contractAddress: address, decimals }, options); - if (!address || !enabled) return <>{fallback ?? null}; - if (isLoading) return loader ? numberLoader : null; - return ( - - {children} - {formatted ?? fallback ?? null} - - ); +const Balance = ({ address, decimals, abi }: BalanceProps): JSX.Element | null => { + const { isLoading, formatted, enabled } = useContractBalance({ contractAddress: address, decimals, abi }); + + if (address === undefined || decimals === undefined || !enabled) return <>{0}; + + if (isLoading) return numberLoader; + + return {formatted ?? 0}; }; export default Balance; diff --git a/src/components/Transaction/Settings/index.tsx b/src/components/Transaction/Settings/index.tsx index 7fd03519..42b2a187 100644 --- a/src/components/Transaction/Settings/index.tsx +++ b/src/components/Transaction/Settings/index.tsx @@ -5,13 +5,17 @@ import { config } from '../../../config'; export interface TransactionSettingsProps { setSlippage: (slippage: number | undefined) => void; - slippageProps: React.HTMLAttributes; + slippageProps: InputProps; deadlineProps?: InputProps; } const inputCls = 'bg-neutral-100 dark:bg-neutral-900 text-right text-neutral-600 dark:text-neutral-200'; -const TransactionSettings = ({ setSlippage, deadlineProps }: TransactionSettingsProps): JSX.Element | null => { +const TransactionSettings = ({ + setSlippage, + slippageProps, + deadlineProps, +}: TransactionSettingsProps): JSX.Element | null => { return (

Settings

@@ -36,7 +40,7 @@ const TransactionSettings = ({ setSlippage, deadlineProps }: TransactionSettings min={config.transaction.settings.slippage.min} max={config.transaction.settings.slippage.max} placeholder="Auto" - {...deadlineProps} + {...slippageProps} />
%
@@ -49,19 +53,21 @@ const TransactionSettings = ({ setSlippage, deadlineProps }: TransactionSettings -
- - minutes -
+ {deadlineProps && ( +
+ + minutes +
+ )} ); diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index 1367e8ee..ae5dde00 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -2,18 +2,17 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; import { ChangeEvent } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; -import { BackstopPool } from '../../../../../../gql/graphql'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import TokenApproval from '../../../../Asset/Approval'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; import { useAddLiquidity } from './useAddLiquidity'; +import { NablaInstanceBackstopPool } from '../../../../../hooks/nabla/useNablaInstance'; export type AddLiquidityProps = { - data: BackstopPool; + data: NablaInstanceBackstopPool; }; const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { @@ -23,13 +22,13 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { mutation, balanceQuery, depositQuery, - amount, + decimalAmount, form: { register, setValue, formState: { errors }, }, - } = useAddLiquidity(data.id, data.token.id); + } = useAddLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); const balance = balanceQuery.balance || 0; const deposit = depositQuery.balance || 0; @@ -37,7 +36,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { return (
- +
@@ -132,10 +131,11 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { className="w-full" spender={data.id} token={data.token.id} - amount={amount} - enabled={amount > 0} + decimals={data.token.decimals} + decimalAmount={decimalAmount} + enabled={decimalAmount > 0} > - diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts index 47a9cb33..c0f33005 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts @@ -1,24 +1,38 @@ import { yupResolver } from '@hookform/resolvers/yup'; import { useQueryClient } from '@tanstack/react-query'; import { useForm, useWatch } from 'react-hook-form'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenant'; import { useModalToggle } from '../../../../../services/modal'; -import { decimalToNative } from '../../../../../shared/parseNumbers'; +import { decimalToRaw } from '../../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../../shared/useContractBalance'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import schema from './schema'; import { AddLiquidityValues } from './types'; +import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; -export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { +export const useAddLiquidity = ( + poolAddress: string, + tokenAddress: string, + poolTokenDecimals: number, + lpTokenDecimals: number, +) => { const queryClient = useQueryClient(); const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); - const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: defaultDecimals }); + const balanceQuery = useContractBalance({ + contractAddress: tokenAddress, + decimals: poolTokenDecimals, + abi: erc20WrapperAbi, + }); + + const depositQuery = useContractBalance({ + contractAddress: poolAddress, + decimals: lpTokenDecimals, + abi: backstopPoolAbi, + }); const form = useForm({ resolver: yupResolver(schema), @@ -43,10 +57,10 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { }); const onSubmit = form.handleSubmit((variables) => - mutation.mutate([decimalToNative(variables.amount, defaultDecimals).toString()]), + mutation.mutate([decimalToRaw(variables.amount, poolTokenDecimals).toString()]), ); - const amount = + const decimalAmount = Number( useWatch({ control: form.control, @@ -55,5 +69,5 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { }), ) || 0; - return { form, amount, mutation, onSubmit, toggle, balanceQuery, depositQuery }; + return { form, decimalAmount, mutation, onSubmit, toggle, balanceQuery, depositQuery }; }; diff --git a/src/components/nabla/Pools/Backstop/Modals/types.ts b/src/components/nabla/Pools/Backstop/Modals/types.ts index 729d7879..98f931e2 100644 --- a/src/components/nabla/Pools/Backstop/Modals/types.ts +++ b/src/components/nabla/Pools/Backstop/Modals/types.ts @@ -1,4 +1,4 @@ -import { BackstopPool } from '../../../../../../gql/graphql'; +import { NablaInstanceBackstopPool } from '../../../../../hooks/nabla/useNablaInstance'; export const ModalTypes = { AddLiquidity: 2, @@ -6,5 +6,5 @@ export const ModalTypes = { }; export type LiquidityModalProps = { - data?: BackstopPool; + data?: NablaInstanceBackstopPool; }; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index 32d8574c..a3dd3a11 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -3,12 +3,9 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; import { ChangeEvent, useMemo } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; -import { BackstopPool } from '../../../../../../gql/graphql'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; -import { calcSharePercentage, getPoolSurplus, minMax } from '../../../../../helpers/calc'; -import { useBackstopPool } from '../../../../../hooks/nabla/useBackstopPool'; -import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { calcSharePercentage, getPoolSurplusNativeAmount, minMax } from '../../../../../helpers/calc'; +import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import { AssetSelectorModal } from '../../../../Asset/Selector/Modal'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; @@ -17,23 +14,13 @@ import TransactionProgress from '../../../../Transaction/Progress'; import { TransactionSettingsDropdown } from '../../../../Transaction/Settings'; import TokenAmount from '../../TokenAmount'; import { useWithdrawLiquidity } from './useWithdrawLiquidity'; +import { NablaInstance, NablaInstanceSwapPool, useNablaInstance } from '../../../../../hooks/nabla/useNablaInstance'; -export type WithdrawLiquidityProps = { - data: BackstopPool; +const filter = (swapPools: NablaInstanceSwapPool[]): NablaInstanceSwapPool[] => { + return swapPools?.filter((pool) => getPoolSurplusNativeAmount(pool) > 0n); }; -const filter = (pool: BackstopPool): BackstopPool => { - const filteredPools = pool.router.swapPools?.filter((pool) => !!getPoolSurplus(pool)); - return { - ...pool, - router: { - ...pool.router, - swapPools: filteredPools, - }, - }; -}; - -const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element | null => { +const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element | null => { const { toggle, balanceQuery, @@ -43,7 +30,7 @@ const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element | setValue, formState: { errors }, }, - amount, + backstopLpTokenDecimalAmountToRedeem, pools, selectedPool, tokenModal, @@ -52,13 +39,21 @@ const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element | isSwapPoolWithdraw, updateStorage, onSubmit, - } = useWithdrawLiquidity(data); + } = useWithdrawLiquidity(nabla); + const isIdle = bpw.mutation.isIdle && spw.mutation.isIdle; const isLoading = bpw.mutation.isLoading || spw.mutation.isLoading; - const deposit = depositQuery.balance || 0; - const withdrawLimit = nativeToDecimal(spw.withdrawLimit?.toString() || 0, defaultDecimals).toNumber(); + const depositedBackstopLpTokenDecimalAmount = depositQuery.balance || 0; + const withdrawLimit = rawToDecimal( + spw.withdrawLimitDecimalAmount?.toString() || 0, + nabla.backstopPool.lpTokenDecimals, + ).toNumber(); + + const poolTokens = useMemo(() => pools.map((pool) => pool.token), [pools]); const hideCss = !isIdle ? 'hidden' : ''; + + const backstopPool = nabla.backstopPool; return (
- +
-

Withdraw {data.token.symbol}

+

Withdraw {backstopPool.token.symbol}

@@ -87,7 +82,7 @@ const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element | - setValue('amount', deposit, { + setValue('amount', depositedBackstopLpTokenDecimalAmount, { shouldDirty: true, shouldTouch: true, }) @@ -96,7 +91,8 @@ const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element | )}

- Balance: {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} + Balance:{' '} + {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${backstopPool.token.symbol}`}

@@ -114,7 +110,7 @@ const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element | autoFocus className="input-ghost w-full text-4xl font-2 py-3 px-0" placeholder="Amount" - max={deposit} + max={depositedBackstopLpTokenDecimalAmount} {...register('amount')} />
Deposit
-
{roundNumber(deposit || 0)} LP
+
{roundNumber(depositedBackstopLpTokenDecimalAmount || 0)} LP
Pool share
{minMax( - calcSharePercentage(nativeToDecimal(data.totalSupply || 0, defaultDecimals).toNumber(), deposit), + calcSharePercentage( + rawToDecimal(backstopPool.totalSupply || 0, backstopPool.lpTokenDecimals).toNumber(), + depositedBackstopLpTokenDecimalAmount, + ), )} %
@@ -194,13 +199,12 @@ const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element |
{ - setValue('address', value.id && value.id.length > 5 ? value.id : null); + setValue('address', pools.find((pool) => pool.token.id === value.id)?.id); tokenModal[1].setFalse(); }} - map={(pool) => pool.token} selected={selectedPool.token.id} onClose={tokenModal[1].setFalse} /> @@ -208,13 +212,25 @@ const WithdrawLiquidityBody = ({ data }: WithdrawLiquidityProps): JSX.Element | ); }; -const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps) => { - const { data: pool, isLoading } = useBackstopPool(data.id); - const filtered = useMemo(() => (pool ? filter(pool) : pool), [pool]); +const WithdrawLiquidity = () => { + const { nabla, isLoading } = useNablaInstance(); + + const filteredNabla = useMemo( + () => + nabla + ? { + ...nabla, + swapPools: filter(nabla.swapPools), + } + : undefined, + [nabla], + ); if (isLoading) return ; - if (!filtered) return <>Nothing found; - return ; + + if (!filteredNabla) return <>Nothing found; + + return ; }; export default WithdrawLiquidity; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts index ab8dfb6d..f3a41702 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts @@ -1,19 +1,25 @@ import { useCallback } from 'react'; import { config } from '../../../../../config'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { subtractPercentage } from '../../../../../helpers/calc'; import { getValidSlippage } from '../../../../../helpers/transaction'; -import { decimalToNative } from '../../../../../shared/parseNumbers'; +import { decimalToRaw } from '../../../../../shared/parseNumbers'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import { WithdrawLiquidityValues } from './types'; export type UseBackstopWithdrawProps = { address: string; + poolTokenDecimals: number; + lpTokenDecimals: number; onSuccess: () => void; }; -export const useBackstopWithdraw = ({ address, onSuccess }: UseBackstopWithdrawProps) => { +export const useBackstopWithdraw = ({ + address, + poolTokenDecimals, + lpTokenDecimals, + onSuccess, +}: UseBackstopWithdrawProps) => { const mutation = useContractWrite({ abi: backstopPoolAbi, address, @@ -27,11 +33,11 @@ export const useBackstopWithdraw = ({ address, onSuccess }: UseBackstopWithdrawP if (!variables.amount) return; const vSlippage = getValidSlippage(variables.slippage || config.backstop.defaults.slippage); mutate([ - decimalToNative(variables.amount, defaultDecimals).toString(), - decimalToNative(subtractPercentage(variables.amount, vSlippage), defaultDecimals).toString(), + decimalToRaw(variables.amount, lpTokenDecimals).toString(), + decimalToRaw(subtractPercentage(variables.amount, vSlippage), poolTokenDecimals).toString(), ]); }, - [mutate], + [mutate, poolTokenDecimals, lpTokenDecimals], ); return { diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts index 91c36d09..05ec23fd 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts @@ -1,33 +1,36 @@ import { useCallback, useMemo } from 'react'; -import { BackstopPool, SwapPool } from '../../../../../../gql/graphql'; import { config } from '../../../../../config'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; -import { useGlobalState } from '../../../../../GlobalStateProvider'; import { calcAvailablePoolWithdraw, subtractPercentage } from '../../../../../helpers/calc'; import { getValidSlippage } from '../../../../../helpers/transaction'; import { useSharesTargetWorth } from '../../../../../hooks/nabla/useSharesTargetWorth'; import { useTokenPrice } from '../../../../../hooks/nabla/useTokenPrice'; import { getMessageCallValue } from '../../../../../shared/helpers'; -import { decimalToNative } from '../../../../../shared/parseNumbers'; +import { decimalToRaw } from '../../../../../shared/parseNumbers'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import { WithdrawLiquidityValues } from './types'; +import { NablaInstanceBackstopPool, NablaInstanceSwapPool } from '../../../../../hooks/nabla/useNablaInstance'; export type UseSwapPoolWithdrawProps = { - pool: BackstopPool; - selectedPool: SwapPool; - deposit: number | undefined; + backstopPool: NablaInstanceBackstopPool; + selectedSwapPool: NablaInstanceSwapPool; + depositedBackstopLpTokenDecimalAmount: number; onSuccess: () => void; enabled: boolean; }; -export const useSwapPoolWithdraw = ({ pool, selectedPool, deposit, onSuccess, enabled }: UseSwapPoolWithdrawProps) => { - const swapPoolAddress = selectedPool.id; - const { address: owner } = useGlobalState().walletAccount || {}; +export const useSwapPoolWithdraw = ({ + backstopPool, + selectedSwapPool, + depositedBackstopLpTokenDecimalAmount, + onSuccess, + enabled, +}: UseSwapPoolWithdrawProps) => { + const swapPoolAddress = selectedSwapPool?.id; const mutation = useContractWrite({ abi: backstopPoolAbi, - address: pool.id, + address: backstopPool.id, method: 'withdrawExcessSwapLiquidity', onSuccess, }); @@ -37,48 +40,53 @@ export const useSwapPoolWithdraw = ({ pool, selectedPool, deposit, onSuccess, en async (variables: WithdrawLiquidityValues) => { if (!variables.amount || !swapPoolAddress) return; const vSlippage = getValidSlippage(variables.slippage || config.backstop.defaults.slippage); + mutate([ swapPoolAddress, - decimalToNative(variables.amount, defaultDecimals).toString(), - decimalToNative(subtractPercentage(variables.amount, vSlippage), defaultDecimals).toString(), + decimalToRaw(variables.amount, backstopPool.token.decimals).toString(), + // TODO (Torsten): this next line does not make sense, there is no proper way to convert + // backstop pool shares to swap pool tokens + decimalToRaw(subtractPercentage(variables.amount, vSlippage), selectedSwapPool?.token.decimals).toString(), ]); }, - [mutate, swapPoolAddress], + [mutate, swapPoolAddress, backstopPool.token.decimals, selectedSwapPool?.token.decimals], ); const sharesQuery = useSharesTargetWorth( { address: swapPoolAddress, - amount: deposit, + lpTokenDecimalAmount: depositedBackstopLpTokenDecimalAmount, abi: backstopPoolAbi, + lpTokenDecimals: backstopPool.lpTokenDecimals, }, { enabled }, ); - const shares = getMessageCallValue(sharesQuery.data); - const bpPriceQuery = useTokenPrice(pool.token.id, owner, { enabled }); - const spPriceQuery = useTokenPrice(selectedPool.token.id, owner, { enabled }); + const sharesWorthNativeAmount = getMessageCallValue(sharesQuery.data); + const bpPriceQuery = useTokenPrice(backstopPool.token.id, { enabled }); + const spPriceQuery = useTokenPrice(selectedSwapPool?.token.id, { enabled }); const bpPrice = getMessageCallValue(bpPriceQuery.data); const spPrice = getMessageCallValue(spPriceQuery.data); - const withdrawLimit = useMemo( + const withdrawLimitDecimalAmount = useMemo( () => - calcAvailablePoolWithdraw({ - selectedPool, - deposit: BigInt(decimalToNative(deposit || 0).toString()), - shares, - bpPrice: bpPrice ? BigInt(bpPrice) : undefined, - spPrice: spPrice ? BigInt(spPrice) : undefined, - decimals: defaultDecimals, - }), - [selectedPool, deposit, shares, bpPrice, spPrice], + selectedSwapPool + ? calcAvailablePoolWithdraw({ + selectedSwapPool, + backstopLpDecimalAmount: depositedBackstopLpTokenDecimalAmount, + sharesWorthNativeAmount, + bpPrice: bpPrice ? BigInt(bpPrice) : undefined, + spPrice: spPrice ? BigInt(spPrice) : undefined, + backstopPoolTokenDecimals: backstopPool.token.decimals, + swapPoolTokenDecimals: selectedSwapPool.token.decimals, + }) + : 0, + [selectedSwapPool, backstopPool, depositedBackstopLpTokenDecimalAmount, sharesWorthNativeAmount, bpPrice, spPrice], ); return { onSubmit, mutation, isLoading: bpPriceQuery.isLoading || spPriceQuery.isLoading || sharesQuery.isLoading, - bpPriceQuery, - spPriceQuery, - withdrawLimit, + withdrawLimitDecimalAmount, }; }; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts index 17e3506f..c5d5cf6c 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -2,8 +2,6 @@ import { yupResolver } from '@hookform/resolvers/yup'; import { useQueryClient } from '@tanstack/react-query'; import { useCallback, useMemo } from 'preact/compat'; import { useForm, useWatch } from 'react-hook-form'; -import { BackstopPool, SwapPool } from '../../../../../../gql/graphql'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { storageKeys } from '../../../../../constants/localStorage'; import { debounce } from '../../../../../helpers/function'; @@ -18,19 +16,34 @@ import schema from './schema'; import { WithdrawLiquidityValues } from './types'; import { useBackstopWithdraw } from './useBackstopWithdraw'; import { useSwapPoolWithdraw } from './useSwapPoolWithdraw'; +import { NablaInstance } from '../../../../../hooks/nabla/useNablaInstance'; +import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; +import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; const storageSet = debounce(storageService.set, 1000); -export const useWithdrawLiquidity = (pool: BackstopPool) => { - const { id: poolAddress, token, router } = pool; +export const useWithdrawLiquidity = (nabla: NablaInstance) => { + const poolAddress = nabla.backstopPool.id; + const token = nabla.backstopPool.token; + const tokenAddress = token.id; - const swapPools = router?.swapPools; + const swapPools = nabla.swapPools; const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const queryClient = useQueryClient(); const toggle = useModalToggle(); const tokenModal = useBoolean(); - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); - const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: defaultDecimals }); + const balanceQuery = useContractBalance({ + contractAddress: tokenAddress, + decimals: nabla.backstopPool.token.decimals, + abi: erc20WrapperAbi, + }); + + const depositQuery = useContractBalance({ + contractAddress: poolAddress, + decimals: nabla.backstopPool.lpTokenDecimals, + abi: backstopPoolAbi, + }); + const { refetch: balanceRefetch } = balanceQuery; const { refetch: depositRefetch } = depositQuery; @@ -39,7 +52,7 @@ export const useWithdrawLiquidity = (pool: BackstopPool) => { defaultValues: {}, }); const { reset, getValues, handleSubmit } = form; - const amount = + const backstopLpTokenDecimalAmountToRedeem = Number( useWatch({ control: form.control, @@ -53,20 +66,7 @@ export const useWithdrawLiquidity = (pool: BackstopPool) => { name: 'address', }); - const pools = useMemo( - () => - [ - { - id: '', - token: { - ...token, - id: '', - }, - } as SwapPool, - ].concat(swapPools || []), - [swapPools, token], - ); - const selectedPool = useMemo(() => pools.find((t) => t.id === address) || pools[0], [address, pools]); + const selectedPool = useMemo(() => swapPools.find((t) => t.id === address)!, [address, swapPools]); const onWithdrawSuccess = useCallback(() => { reset(); @@ -77,14 +77,16 @@ export const useWithdrawLiquidity = (pool: BackstopPool) => { const backstopWithdraw = useBackstopWithdraw({ address: poolAddress, + poolTokenDecimals: nabla.backstopPool.token.decimals, + lpTokenDecimals: nabla.backstopPool.lpTokenDecimals, onSuccess: onWithdrawSuccess, }); const isSwapPoolWithdraw = !!address && address.length > 5; const swapPoolWithdraw = useSwapPoolWithdraw({ - pool, - deposit: depositQuery.balance || 0, - selectedPool, + backstopPool: nabla.backstopPool, + depositedBackstopLpTokenDecimalAmount: depositQuery.balance || 0, + selectedSwapPool: selectedPool, enabled: isSwapPoolWithdraw, onSuccess: onWithdrawSuccess, }); @@ -103,19 +105,18 @@ export const useWithdrawLiquidity = (pool: BackstopPool) => { ); return { - address, - amount, + backstopLpTokenDecimalAmountToRedeem, backstopWithdraw, balanceQuery, depositQuery, form, isSwapPoolWithdraw, - pools, + pools: swapPools, selectedPool, swapPoolWithdraw, tokenModal, toggle, updateStorage, - onSubmit: handleSubmit(address && address.length > 5 ? swapPoolWithdraw.onSubmit : backstopWithdraw.onSubmit), + onSubmit: handleSubmit(isSwapPoolWithdraw ? swapPoolWithdraw.onSubmit : backstopWithdraw.onSubmit), }; }; diff --git a/src/components/nabla/Pools/Backstop/index.tsx b/src/components/nabla/Pools/Backstop/index.tsx index 56d1a36a..4a86c0aa 100644 --- a/src/components/nabla/Pools/Backstop/index.tsx +++ b/src/components/nabla/Pools/Backstop/index.tsx @@ -1,19 +1,20 @@ import { Button, Card } from 'react-daisyui'; -import { defaultDecimals } from '../../../../config/apps/nabla'; -import { useBackstopPools } from '../../../../hooks/nabla/useBackstopPools'; import ModalProvider, { useModalToggle } from '../../../../services/modal'; import Balance from '../../../Balance'; import { Skeleton } from '../../../Skeleton'; import Modals from './Modals'; import { LiquidityModalProps, ModalTypes } from './Modals/types'; +import { useNablaInstance } from '../../../../hooks/nabla/useNablaInstance'; +import { backstopPoolAbi } from '../../../../contracts/nabla/BackstopPool'; const BackstopPoolsBody = (): JSX.Element | null => { const toggle = useModalToggle(); - const { data, isLoading } = useBackstopPools(); + const { nabla, isLoading } = useNablaInstance(); if (isLoading) return ; - const pool = data?.[0]; + const pool = nabla?.backstopPool; if (!pool) return

No backstop pools

; + return ( <>
@@ -22,7 +23,7 @@ const BackstopPoolsBody = (): JSX.Element | null => {

My pool balance

- +
@@ -59,7 +60,7 @@ const BackstopPoolsBody = (): JSX.Element | null => { ); }; -const BactopPools = (): JSX.Element | null => { +const BackstopPools = (): JSX.Element | null => { return ( @@ -67,4 +68,4 @@ const BactopPools = (): JSX.Element | null => { ); }; -export default BactopPools; +export default BackstopPools; diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index b35baa30..ef05785e 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -1,9 +1,8 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; import { Button } from 'react-daisyui'; import { PoolProgress } from '../..'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import TokenApproval from '../../../../Asset/Approval'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; @@ -22,13 +21,13 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { onSubmit, balanceQuery, depositQuery, - amount, + decimalAmount, form: { register, setValue, formState: { errors }, }, - } = useAddLiquidity(data.id, data.token.id); + } = useAddLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); const balance = balanceQuery.balance || 0; const deposit = depositQuery.balance || 0; @@ -36,7 +35,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { return (
- +
@@ -116,10 +118,11 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { className="mt-8 w-full" spender={data.id} token={data.token.id} - amount={amount} - enabled={amount > 0} + decimals={data.token.decimals} + decimalAmount={decimalAmount} + enabled={decimalAmount > 0} > - diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index f702330f..18ebaa32 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -1,27 +1,37 @@ import { yupResolver } from '@hookform/resolvers/yup'; import { useQueryClient } from '@tanstack/react-query'; import { useForm, useWatch } from 'react-hook-form'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenant'; import { useModalToggle } from '../../../../../services/modal'; -import { decimalToNative } from '../../../../../shared/parseNumbers'; +import { decimalToRaw } from '../../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../../shared/useContractBalance'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import schema from './schema'; import { AddLiquidityValues } from './types'; +import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; -export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { +export const useAddLiquidity = ( + poolAddress: string, + tokenAddress: string, + poolTokenDecimals: number, + lpTokenDecimals: number, +) => { const queryClient = useQueryClient(); const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); + const balanceQuery = useContractBalance({ + contractAddress: tokenAddress, + decimals: poolTokenDecimals, + abi: erc20WrapperAbi, + }); + const depositQuery = useContractBalance({ contractAddress: poolAddress, + decimals: lpTokenDecimals, abi: swapPoolAbi, - decimals: defaultDecimals, }); const form = useForm({ @@ -45,10 +55,10 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { }); const onSubmit = form.handleSubmit((variables) => - mutation.mutate([decimalToNative(variables.amount, defaultDecimals).toString()]), + mutation.mutate([decimalToRaw(variables.amount, poolTokenDecimals).toString()]), ); - const amount = + const decimalAmount = Number( useWatch({ control: form.control, @@ -57,5 +67,5 @@ export const useAddLiquidity = (poolAddress: string, tokenAddress: string) => { }), ) || 0; - return { form, amount, mutation, onSubmit, toggle, balanceQuery, depositQuery }; + return { form, decimalAmount, mutation, onSubmit, toggle, balanceQuery, depositQuery }; }; diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index c0c72a9d..d3450861 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -3,9 +3,8 @@ import { ChangeEvent } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { config } from '../../../../../config'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; @@ -25,7 +24,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => { onSubmit, balanceQuery, depositQuery, - amount, + lpTokensDecimalAmount, updateStorage, form: { register, @@ -39,7 +38,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => { return (
- +
@@ -97,7 +96,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => { min={0} max={100} size="sm" - value={amount ? (amount / deposit) * 100 : 0} + value={lpTokensDecimalAmount ? (lpTokensDecimalAmount / deposit) * 100 : 0} onChange={(ev: ChangeEvent) => setValue('amount', (Number(ev.currentTarget.value) / 100) * deposit, { shouldDirty: true, @@ -125,7 +124,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => {
Pool share
{minMax( - calcSharePercentage(nativeToDecimal(data.totalSupply || 0, defaultDecimals).toNumber(), deposit), + calcSharePercentage(rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), deposit), )} %
diff --git a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts index 815cc259..cbdc131d 100644 --- a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts +++ b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts @@ -3,7 +3,6 @@ import { useQueryClient } from '@tanstack/react-query'; import { useCallback } from 'preact/compat'; import { useForm, useWatch } from 'react-hook-form'; import { config } from '../../../../../config'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { storageKeys } from '../../../../../constants/localStorage'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; @@ -14,12 +13,14 @@ import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenan import { TransactionSettings } from '../../../../../models/Transaction'; import { useModalToggle } from '../../../../../services/modal'; import { storageService } from '../../../../../services/storage/local'; -import { decimalToNative } from '../../../../../shared/parseNumbers'; +import { decimalToRaw } from '../../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../../shared/useContractBalance'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import { SwapPoolColumn } from '../columns'; import schema from './schema'; import { RedeemLiquidityValues } from './types'; +import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; +import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; export const setValueProps = { shouldDirty: true, @@ -44,9 +45,19 @@ export const useRedeem = (swapPoolData: SwapPoolColumn) => { const poolAddress = swapPoolData.id; const tokenAddress = swapPoolData.token.id; - const backstopPoolAddress = swapPoolData.backstop?.id; - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); - const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: defaultDecimals }); + const backstopPoolAddress = swapPoolData.backstopPool.id; + + const balanceQuery = useContractBalance({ + contractAddress: tokenAddress, + decimals: swapPoolData.token.decimals, + abi: erc20WrapperAbi, + }); + + const depositQuery = useContractBalance({ + contractAddress: poolAddress, + decimals: swapPoolData.lpTokenDecimals, + abi: swapPoolAbi, + }); const form = useForm({ resolver: yupResolver(schema), @@ -76,11 +87,16 @@ export const useRedeem = (swapPoolData: SwapPoolColumn) => { const vSlippage = getValidSlippage(variables.slippage || config.backstop.defaults.slippage); return mutate([ poolAddress, - decimalToNative(variables.amount, defaultDecimals).toString(), - decimalToNative(subtractPercentage(variables.amount, vSlippage), defaultDecimals).toString(), + decimalToRaw(variables.amount, swapPoolData.lpTokenDecimals).toString(), + // TODO (Torsten): this next line does not make sense, there is no proper way to convert + // swap pool shares to backstop pool tokens + decimalToRaw( + subtractPercentage(variables.amount, vSlippage), + swapPoolData.backstopPool.token.decimals, + ).toString(), ]); }), - [handleSubmit, poolAddress, mutate], + [handleSubmit, poolAddress, mutate, swapPoolData.lpTokenDecimals, swapPoolData.backstopPool.token.decimals], ); const updateStorage = useCallback( @@ -96,7 +112,7 @@ export const useRedeem = (swapPoolData: SwapPoolColumn) => { [getValues], ); - const amount = + const lpTokensDecimalAmount = Number( useWatch({ control: control, @@ -113,6 +129,6 @@ export const useRedeem = (swapPoolData: SwapPoolColumn) => { mutation, balanceQuery, depositQuery, - amount, + lpTokensDecimalAmount, }; }; diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index f396d57d..be09b670 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -2,17 +2,16 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; import { ChangeEvent } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { nativeToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; import TransactionProgress from '../../../../Transaction/Progress'; import TokenAmount from '../../TokenAmount'; import { SwapPoolColumn } from '../columns'; import { ModalTypes } from '../Modals/types'; -import { useWithdrawLiquidity } from './useWithdrawLiquidity'; +import { useSwapPoolWithdrawLiquidity } from './useWithdrawLiquidity'; export interface WithdrawLiquidityProps { data: SwapPoolColumn; @@ -31,8 +30,8 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null setValue, formState: { errors }, }, - } = useWithdrawLiquidity(data.id, data.token.id); - const deposit = depositQuery.balance || 0; + } = useSwapPoolWithdrawLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); + const depositedLpTokensDecimalAmount = depositQuery.balance || 0; const hideCss = !mutation.isIdle ? 'hidden' : ''; return ( @@ -61,7 +60,7 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null autoFocus className="input-ghost flex-grow w-full text-4xl font-2" placeholder="0.0" - max={deposit} + max={depositedLpTokensDecimalAmount} {...register('amount')} />
Deposit
-
{roundNumber(deposit)}
+
{roundNumber(depositedLpTokensDecimalAmount)}
Pool share
{minMax( - calcSharePercentage(nativeToDecimal(data.totalSupply || 0, defaultDecimals).toNumber(), deposit), + calcSharePercentage( + rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), + depositedLpTokensDecimalAmount, + ), )} %
diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts index 6d67bb84..2dda9c3b 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -2,25 +2,39 @@ import { yupResolver } from '@hookform/resolvers/yup'; import { useQueryClient } from '@tanstack/react-query'; import { useCallback } from 'preact/compat'; import { useForm, useWatch } from 'react-hook-form'; -import { defaultDecimals } from '../../../../../config/apps/nabla'; import { cacheKeys } from '../../../../../constants/cache'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; import { subtractPercentage } from '../../../../../helpers/calc'; import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenant'; import { useModalToggle } from '../../../../../services/modal'; -import { decimalToNative } from '../../../../../shared/parseNumbers'; +import { decimalToRaw } from '../../../../../shared/parseNumbers'; import { useContractBalance } from '../../../../../shared/useContractBalance'; import { useContractWrite } from '../../../../../shared/useContractWrite'; import schema from './schema'; import { WithdrawLiquidityValues } from './types'; +import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; -export const useWithdrawLiquidity = (poolAddress: string, tokenAddress: string) => { +export const useSwapPoolWithdrawLiquidity = ( + poolAddress: string, + tokenAddress: string, + poolTokenDecimals: number, + lpTokenDecimals: number, +) => { const queryClient = useQueryClient(); const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); - const balanceQuery = useContractBalance({ contractAddress: tokenAddress, decimals: defaultDecimals }); - const depositQuery = useContractBalance({ contractAddress: poolAddress, decimals: defaultDecimals }); + const balanceQuery = useContractBalance({ + contractAddress: tokenAddress, + decimals: poolTokenDecimals, + abi: erc20WrapperAbi, + }); + + const depositQuery = useContractBalance({ + contractAddress: poolAddress, + decimals: lpTokenDecimals, + abi: swapPoolAbi, + }); const form = useForm({ resolver: yupResolver(schema), @@ -50,11 +64,11 @@ export const useWithdrawLiquidity = (poolAddress: string, tokenAddress: string) (variables: WithdrawLiquidityValues) => { if (!variables.amount) return; return mutate([ - decimalToNative(variables.amount, defaultDecimals).toString(), - decimalToNative(subtractPercentage(variables.amount, 0.5), defaultDecimals).toString(), + decimalToRaw(variables.amount, lpTokenDecimals).toString(), + decimalToRaw(subtractPercentage(variables.amount, 0.5), poolTokenDecimals).toString(), ]); }, - [mutate], + [mutate, lpTokenDecimals, poolTokenDecimals], ); const amount = diff --git a/src/components/nabla/Pools/Swap/columns.tsx b/src/components/nabla/Pools/Swap/columns.tsx index 9a4847c4..2b236f22 100644 --- a/src/components/nabla/Pools/Swap/columns.tsx +++ b/src/components/nabla/Pools/Swap/columns.tsx @@ -1,13 +1,13 @@ import { CellContext, ColumnDef } from '@tanstack/react-table'; import { Badge, Button } from 'react-daisyui'; -import { SwapPool } from '../../../../../gql/graphql'; -import { defaultDecimals } from '../../../../config/apps/nabla'; import { useModalToggle } from '../../../../services/modal'; -import { nativeToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; +import { rawToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; import { LiquidityModalProps, ModalTypes } from './Modals/types'; +import { NablaInstanceBackstopPool, NablaInstanceSwapPool } from '../../../../hooks/nabla/useNablaInstance'; -export type SwapPoolColumn = SwapPool & { +export type SwapPoolColumn = NablaInstanceSwapPool & { myAmount?: number; + backstopPool: NablaInstanceBackstopPool; }; export const nameColumn: ColumnDef = { @@ -20,7 +20,7 @@ export const nameColumn: ColumnDef = { export const liabilitiesColumn: ColumnDef = { header: 'Pool liabilities', accessorKey: 'liabilities', - accessorFn: (row) => prettyNumbers(nativeToDecimal(row.liabilities || 0, defaultDecimals).toNumber()), + accessorFn: (row) => prettyNumbers(rawToDecimal(row.totalLiabilities || 0, row.lpTokenDecimals).toNumber()), enableSorting: true, meta: { className: 'text-right justify-end', @@ -30,7 +30,7 @@ export const liabilitiesColumn: ColumnDef = { export const reservesColumn: ColumnDef = { header: 'Reserves', accessorKey: 'reserves', - accessorFn: (row) => prettyNumbers(nativeToDecimal(row.reserves || 0, defaultDecimals).toNumber()), + accessorFn: (row) => prettyNumbers(rawToDecimal(row.reserve || 0, row.token.decimals).toNumber()), enableSorting: true, meta: { className: 'text-right justify-end', @@ -55,7 +55,7 @@ export const aprColumn: ColumnDef = { export const myAmountColumn: ColumnDef = { header: 'My Pool Amount', accessorKey: 'myAmount', - accessorFn: (row) => prettyNumbers(nativeToDecimal(row.myAmount || 0, defaultDecimals).toNumber()), + accessorFn: (row) => prettyNumbers(rawToDecimal(row.myAmount || 0, row.lpTokenDecimals).toNumber()), enableSorting: true, meta: { className: 'text-right justify-end', diff --git a/src/components/nabla/Pools/Swap/index.tsx b/src/components/nabla/Pools/Swap/index.tsx index 5943bc7d..8c0e03ea 100644 --- a/src/components/nabla/Pools/Swap/index.tsx +++ b/src/components/nabla/Pools/Swap/index.tsx @@ -1,16 +1,21 @@ -import { useSwapPools } from '../../../../hooks/nabla/useSwapPools'; +import { useNablaInstance } from '../../../../hooks/nabla/useNablaInstance'; import ModalProvider from '../../../../services/modal'; import Table from '../../../Table'; -import { columns } from './columns'; +import { columns, SwapPoolColumn } from './columns'; import PoolsModals from './Modals'; const SwapPools = (): JSX.Element | null => { - const { data, isLoading } = useSwapPools(); + const { nabla, isLoading } = useNablaInstance(); + + const swapPools = nabla?.swapPools; + + if (swapPools == undefined) return null; + const columnData = swapPools.map((pool) => ({ ...pool, backstopPool: nabla!.backstopPool })); return ( - + data={columnData} isLoading={isLoading} columns={columns} fontSize="text-base" search /> ); }; diff --git a/src/components/nabla/Pools/TokenAmount/index.tsx b/src/components/nabla/Pools/TokenAmount/index.tsx index 32891eb6..460e9971 100644 --- a/src/components/nabla/Pools/TokenAmount/index.tsx +++ b/src/components/nabla/Pools/TokenAmount/index.tsx @@ -1,18 +1,19 @@ -import { defaultDecimals } from '../../../../config/apps/nabla'; import { useSharesTargetWorth } from '../../../../hooks/nabla/useSharesTargetWorth'; import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; import { getMessageCallValue } from '../../../../shared/helpers'; -import { nativeToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; +import { rawToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; import { numberLoader } from '../../../Loader'; export interface TokenAmountProps { address: string; - abi?: Dict; - amount?: number; + abi: Dict; + lpTokenDecimalAmount: number; + symbol: ReactNode; + fallback: number; + poolTokenDecimals: number; + lpTokenDecimals: number; debounce?: number; loader?: boolean; - symbol?: ReactNode; - fallback?: string | number; } const TokenAmount = ({ @@ -20,25 +21,28 @@ const TokenAmount = ({ abi, fallback, address, - amount = 0, + poolTokenDecimals, + lpTokenDecimals, + lpTokenDecimalAmount, loader = true, debounce = 800, }: TokenAmountProps): JSX.Element | null => { - const debouncedAmount = useDebouncedValue(amount, debounce); - const arg = debounce ? debouncedAmount : amount; + const debouncedAmount = useDebouncedValue(lpTokenDecimalAmount, debounce); const { isLoading, data } = useSharesTargetWorth({ address, abi, - amount: arg, + lpTokenDecimalAmount: debounce ? debouncedAmount : lpTokenDecimalAmount, + lpTokenDecimals, }); - if (amount && (isLoading || (!!debounce && amount !== debouncedAmount))) { + if (lpTokenDecimalAmount && (isLoading || (!!debounce && lpTokenDecimalAmount !== debouncedAmount))) { return loader ? numberLoader : null; } + return ( {data - ? prettyNumbers(nativeToDecimal(getMessageCallValue(data) || '0', defaultDecimals).toNumber()) + ? prettyNumbers(rawToDecimal(getMessageCallValue(data) ?? '0', poolTokenDecimals).toNumber()) : fallback ?? null} {symbol ? symbol : null} diff --git a/src/components/nabla/Price/index.tsx b/src/components/nabla/Price/index.tsx index 3a269ccd..35c68421 100644 --- a/src/components/nabla/Price/index.tsx +++ b/src/components/nabla/Price/index.tsx @@ -1,8 +1,7 @@ import { UseQueryOptions } from '@tanstack/react-query'; -import { useGlobalState } from '../../../GlobalStateProvider'; import { useTokenPrice } from '../../../hooks/nabla/useTokenPrice'; import { getMessageCallValue } from '../../../shared/helpers'; -import { nativeToDecimal, prettyNumbers } from '../../../shared/parseNumbers'; +import { rawToDecimal, prettyNumbers } from '../../../shared/parseNumbers'; import { numberLoader } from '../../Loader'; export type TokenPriceProps = { @@ -14,6 +13,8 @@ export type TokenPriceProps = { fallback?: ReactNode; }; +const TOKEN_PRICE_DECIMALS = 12; + const TokenPrice = ({ address, prefix = null, @@ -22,14 +23,15 @@ const TokenPrice = ({ amount = 1, options, }: TokenPriceProps): JSX.Element | null => { - const { address: owner } = useGlobalState().walletAccount || {}; - const { data, isLoading } = useTokenPrice(address, owner, options); + const { data, isLoading } = useTokenPrice(address, options); if (isLoading) return loader ? <>{loader} : numberLoader; + const price = getMessageCallValue(data); - if (!price) return <>{fallback}; + if (price === undefined) return <>{fallback}; + return ( - {prefix}${prettyNumbers(amount * nativeToDecimal(price).toNumber())} + {prefix}${prettyNumbers(amount * rawToDecimal(price, TOKEN_PRICE_DECIMALS).toNumber())} ); }; diff --git a/src/components/nabla/Swap/Approval/index.tsx b/src/components/nabla/Swap/Approval/index.tsx index 4c6649d9..537f8b73 100644 --- a/src/components/nabla/Swap/Approval/index.tsx +++ b/src/components/nabla/Swap/Approval/index.tsx @@ -3,24 +3,28 @@ import { useFormContext, useWatch } from 'react-hook-form'; import { useGetAppDataByTenant } from '../../../../hooks/useGetAppDataByTenant'; import TokenApproval from '../../../Asset/Approval'; import { SwapFormValues } from '../types'; +import { NablaInstanceToken } from '../../../../hooks/nabla/useNablaInstance'; export interface ApprovalProps { - token: string; + token: NablaInstanceToken | undefined; } const ApprovalSubmit = ({ token }: ApprovalProps): JSX.Element | null => { const { router } = useGetAppDataByTenant('nabla').data || {}; const { control } = useFormContext(); - const amount = Number( + const decimalAmount = Number( useWatch({ control, name: 'fromAmount', defaultValue: 0, }), ); + + if (!router || !token) return null; + return ( - - diff --git a/src/components/nabla/Swap/From/index.tsx b/src/components/nabla/Swap/From/index.tsx index c2dc83bc..281f8ad0 100644 --- a/src/components/nabla/Swap/From/index.tsx +++ b/src/components/nabla/Swap/From/index.tsx @@ -3,26 +3,32 @@ import { Fragment } from 'preact'; import { Button } from 'react-daisyui'; import { useFormContext, useWatch } from 'react-hook-form'; import pendulumIcon from '../../../../assets/pendulum-icon.svg'; -import { defaultDecimals } from '../../../../config/apps/nabla'; -import { TokensData } from '../../../../hooks/nabla/useTokens'; import { useContractBalance } from '../../../../shared/useContractBalance'; import TokenPrice from '../../Price'; import { SwapFormValues } from '../types'; +import { NablaInstanceToken } from '../../../../hooks/nabla/useNablaInstance'; +import { erc20WrapperAbi } from '../../../../contracts/nabla/ERC20Wrapper'; export interface FromProps { - tokensMap?: TokensData['tokensMap']; + tokensMap: Record; onOpenSelector: () => void; + errorMessage?: string; className?: string; } -const From = ({ tokensMap, onOpenSelector, className }: FromProps): JSX.Element | null => { +const From = ({ tokensMap, onOpenSelector, className, errorMessage }: FromProps): JSX.Element | null => { const { register, setValue, control } = useFormContext(); const from = useWatch({ control, name: 'from', }); - const token = tokensMap?.[from]; - const { formatted, balance } = useContractBalance({ contractAddress: token?.id, decimals: defaultDecimals }); + const token = tokensMap[from]; + const { formatted, balance } = useContractBalance({ + contractAddress: token?.id, + decimals: token?.decimals, + abi: erc20WrapperAbi, + }); + return ( <>
@@ -71,6 +77,7 @@ const From = ({ tokensMap, onOpenSelector, className }: FromProps): JSX.Element )}
+ {errorMessage !== undefined &&
{errorMessage}
} diff --git a/src/components/nabla/Swap/To/index.tsx b/src/components/nabla/Swap/To/index.tsx index a2581790..d11d188b 100644 --- a/src/components/nabla/Swap/To/index.tsx +++ b/src/components/nabla/Swap/To/index.tsx @@ -5,22 +5,22 @@ import { Button } from 'react-daisyui'; import { useFormContext, useWatch } from 'react-hook-form'; import pendulumIcon from '../../../../assets/pendulum-icon.svg'; import { config } from '../../../../config'; -import { defaultDecimals } from '../../../../config/apps/nabla'; import { subtractPercentage } from '../../../../helpers/calc'; import { useTokenOutAmount } from '../../../../hooks/nabla/useTokenOutAmount'; -import { TokensData } from '../../../../hooks/nabla/useTokens'; import useBoolean from '../../../../hooks/useBoolean'; import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; import { getMessageCallValue } from '../../../../shared/helpers'; -import { nativeToDecimal, prettyNumbers, roundNumber } from '../../../../shared/parseNumbers'; +import { rawToDecimal, prettyNumbers, roundNumber } from '../../../../shared/parseNumbers'; import Balance from '../../../Balance'; import { numberLoader } from '../../../Loader'; import { Skeleton } from '../../../Skeleton'; import TokenPrice from '../../Price'; import { SwapFormValues } from '../types'; +import { NablaInstanceToken } from '../../../../hooks/nabla/useNablaInstance'; +import { erc20WrapperAbi } from '../../../../contracts/nabla/ERC20Wrapper'; export interface ToProps { - tokensMap?: TokensData['tokensMap']; + tokensMap: Record; onOpenSelector: () => void; className?: string; } @@ -28,21 +28,25 @@ export interface ToProps { const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | null => { const [isOpen, { toggle }] = useBoolean(true); const { setValue, setError, clearErrors, control } = useFormContext(); + const from = useWatch({ control, name: 'from', }); + const to = useWatch({ control, name: 'to', }); - const fromAmount = Number( + + const fromDecimalAmount = Number( useWatch({ control, name: 'fromAmount', defaultValue: 0, }), ); + const slippage = Number( useWatch({ control, @@ -50,16 +54,20 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu defaultValue: config.swap.defaults.slippage, }), ); - const fromToken = tokensMap?.[from]; - const toToken = tokensMap?.[to]; - const debouncedFromAmount = useDebouncedValue(fromAmount, 800); - const { isLoading, fetchStatus, data, refetch, isError, error } = useTokenOutAmount({ - amount: debouncedFromAmount, + const fromToken: NablaInstanceToken | undefined = tokensMap?.[from]; + const toToken: NablaInstanceToken | undefined = tokensMap?.[to]; + + const debouncedFromDecimalAmount = useDebouncedValue(fromDecimalAmount, 800); + const { isLoading, fetchStatus, data, refetch } = useTokenOutAmount({ + fromDecimalAmount: debouncedFromDecimalAmount, from, to, + fromTokenDecimals: fromToken?.decimals, onSuccess: (response) => { + if (toToken === undefined) return; + const val = getMessageCallValue(response); - const toAmount = val ? nativeToDecimal(val, defaultDecimals).toNumber() : 0; + const toAmount = val ? rawToDecimal(val, toToken.decimals).toNumber() : 0; setValue('toAmount', toAmount, { shouldDirty: true, shouldTouch: true, @@ -69,13 +77,34 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu }); useEffect(() => { - if (isError) setError('toAmount', { message: error ? String(error) : 'Something went wrong' }); - else clearErrors('toAmount'); - }, [isError, error, setError, clearErrors]); + if (data && data.result.type !== 'success') { + let errorMessage; + switch (data.result.type) { + case 'error': + errorMessage = 'Something went wrong'; + break; + case 'panic': + errorMessage = data.result.errorCode === 0x11 ? 'The input amount is too large' : 'Something went wrong'; + break; + case 'reverted': + errorMessage = + data.result.description === 'SwapPool: EXCEEDS_MAX_COVERAGE_RATIO' + ? 'The input amount is too large' + : 'Something went wrong'; + } + + console.log('ToAmount Error', errorMessage); + setError('fromAmount', { type: 'manual', message: errorMessage }); + } else { + clearErrors('fromAmount'); + } + }, [data, setError, clearErrors]); - const loading = (isLoading && isLoading && fetchStatus !== 'idle') || fromAmount !== debouncedFromAmount; + const loading = + (isLoading && isLoading && fetchStatus !== 'idle') || fromDecimalAmount !== debouncedFromDecimalAmount; const outValue = getMessageCallValue(data); - const value = outValue ? prettyNumbers(nativeToDecimal(outValue, defaultDecimals).toNumber()) : 0; + const value = + outValue && toToken !== undefined ? prettyNumbers(rawToDecimal(outValue, toToken.decimals).toNumber()) : 0; return ( <>
@@ -85,7 +114,7 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu numberLoader ) : value ? ( `${value}` - ) : fromAmount > 0 ? ( + ) : fromDecimalAmount > 0 ? ( @@ -109,7 +138,7 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu
{toToken ? : '$ -'}
- Balance: + Balance:
@@ -120,12 +149,12 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu >
- {fromToken && toToken && value && fromAmount ? ( + {fromToken && toToken && value && fromDecimalAmount ? ( <>
- {`1 ${fromToken.symbol} = ${roundNumber(Number(value) / fromAmount, 6)} ${toToken.symbol}`} + {`1 ${fromToken.symbol} = ${roundNumber(Number(value) / fromDecimalAmount, 6)} ${toToken.symbol}`} ) : ( `- ${toToken?.symbol || ''}` diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index c18f4119..a1c9f630 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -23,20 +23,22 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { updateStorage, progressClose, tokensQuery, + isLoading, } = useSwapComponent(props); + const { setValue, register, getValues, formState: { errors }, } = form; - const { tokens, tokensMap } = tokensQuery.data || {}; + const { tokens, tokensMap } = tokensQuery; const progressUi = useMemo(() => { if (swapMutation?.isIdle) return null; const { from: fromV, to: toV, fromAmount = 0, toAmount = 0 } = getValues(); - const fromAsset = tokensMap?.[fromV]; - const toAsset = tokensMap?.[toV]; + const fromAsset = tokensMap[fromV]; + const toAsset = tokensMap[toV]; return (

{`Swapping ${fromAmount} ${fromAsset?.symbol} for ${toAmount} ${toAsset?.symbol}`}

); @@ -80,6 +82,7 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { tokensMap={tokensMap} onOpenSelector={() => setModalType('from')} className={`border ${errorClass(errors.fromAmount, 'border-red-600', 'border-transparent')}`} + errorMessage={errors.fromAmount?.message} /> { />
{/* */} - +
@@ -99,6 +102,7 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { onSelect={modalType === 'from' ? onFromChange : onToChange} selected={modalType ? (modalType === 'from' ? getValues('from') : getValues('to')) : undefined} onClose={() => setModalType(undefined)} + isLoading={isLoading} /> {progressUi} diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index f6479cbd..c89c274b 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -2,9 +2,7 @@ import { yupResolver } from '@hookform/resolvers/yup'; import { useQueryClient } from '@tanstack/react-query'; import { useCallback, useEffect, useRef, useState } from 'preact/compat'; import { Resolver, useForm, useWatch } from 'react-hook-form'; -import { Token } from '../../../../gql/graphql'; import { config } from '../../../config'; -import { defaultDecimals } from '../../../config/apps/nabla'; import { cacheKeys } from '../../../constants/cache'; import { storageKeys } from '../../../constants/localStorage'; import { routerAbi } from '../../../contracts/nabla/Router'; @@ -12,14 +10,14 @@ import { useGlobalState } from '../../../GlobalStateProvider'; import { subtractPercentage } from '../../../helpers/calc'; import { debounce } from '../../../helpers/function'; import { getValidDeadline, getValidSlippage } from '../../../helpers/transaction'; -import { useTokens } from '../../../hooks/nabla/useTokens'; import { useGetAppDataByTenant } from '../../../hooks/useGetAppDataByTenant'; import { SwapSettings } from '../../../models/Swap'; import { storageService } from '../../../services/storage/local'; -import { calcDeadline, decimalToNative } from '../../../shared/parseNumbers'; +import { calcDeadline, decimalToRaw } from '../../../shared/parseNumbers'; import { useContractWrite } from '../../../shared/useContractWrite'; import schema from './schema'; import { SwapFormValues } from './types'; +import { NablaInstanceToken, useNablaInstance } from '../../../hooks/nabla/useNablaInstance'; export interface UseSwapComponentProps { from?: string; @@ -39,7 +37,10 @@ const storageSet = debounce(storageService.set, 1000); export const useSwapComponent = (props: UseSwapComponentProps) => { const { onChange } = props; - const tokensQuery = useTokens(); + const { nabla, isLoading } = useNablaInstance(); + const tokens = nabla?.swapPools.map((p) => p.token) ?? []; + const tokensMap = nabla?.tokens ?? {}; + const { address } = useGlobalState().walletAccount || {}; const hadMountedRef = useRef(false); const queryClient = useQueryClient(); @@ -92,16 +93,20 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { }); const onSubmit = form.handleSubmit((variables: SwapFormValues) => { + const fromToken = tokens.find((token) => token.id === variables.from)!; + const toToken = tokens.find((token) => token.id === variables.to)!; + const vDeadline = getValidDeadline(variables.deadline || defaultValues.deadline); const vSlippage = getValidSlippage(variables.slippage || defaultValues.slippage); const deadline = calcDeadline(vDeadline).toString(); - const fromAmount = decimalToNative(variables.fromAmount, defaultDecimals).toString(); - const toMinAmount = decimalToNative(subtractPercentage(variables.toAmount, vSlippage), defaultDecimals).toString(); + const fromAmount = decimalToRaw(variables.fromAmount, fromToken?.decimals).toString(); + const toMinAmount = decimalToRaw(subtractPercentage(variables.toAmount, vSlippage), toToken?.decimals).toString(); + return swapMutation.mutate([fromAmount, toMinAmount, [variables.from, variables.to], address, deadline]); }); const onFromChange = useCallback( - (a: string | Token, event = true) => { + (a: string | NablaInstanceToken, event = true) => { const f = typeof a === 'string' ? a : a.id; const prev = getValues(); const updated = { @@ -118,7 +123,7 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { ); const onToChange = useCallback( - (a: string | Token, event = true) => { + (a: string | NablaInstanceToken, event = true) => { const t = typeof a === 'string' ? a : a.id; const prev = getValues(); const updated = { @@ -151,7 +156,7 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { return { form, - tokensQuery, + tokensQuery: { tokens, tokensMap }, swapMutation, onSubmit, tokensModal, @@ -160,6 +165,7 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { onReverse, updateStorage, from, + isLoading, progressClose: () => { swapMutation.reset(); }, diff --git a/src/config/apps/nabla.ts b/src/config/apps/nabla.ts index bc9495cf..3a0c0842 100644 --- a/src/config/apps/nabla.ts +++ b/src/config/apps/nabla.ts @@ -8,36 +8,16 @@ export type NablaConfig = AppConfigBase & indexerUrl: string; router: string; oracle: string; - curve: string; - assets: string[]; - swapPools: string[]; - backstopPools: string[]; } > >; -export const defaultDecimals = 12; - export const nablaConfig: NablaConfig = { tenants: [TenantName.Foucoco], environment: ['staging', 'development'], foucoco: { indexerUrl: 'https://squid.subsquid.io/foucoco-squid/graphql', - - // TODO: if these addresses change we will need to fetch them from the indexer - router: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', - curve: '6mwEn6oJpMLfkBB3PwDWvdvv8XystGsnHwE2Jm6JUmTtbfmW', - oracle: '6mRAW3J7FhfW9cK4pQN2gLUohBvejvXagTMaG57mm79MMukh', - assets: [ - '6iFkBQJ1C5rKeAc3Np6xAZBM9WfNuukLyjJffELK9HGkDjoa', - '6h4VmXd5MHBTyJbem7f68xsi7otXvqLUiKf8SdRH9n2nuYaP', - '6nbACDpR3WCCy7qcTBb5MQZjpZZJCLzQ3g9sBH3RqXgWx4T4', - ], - swapPools: [ - '6knNBRZ6L6KDdS9JxBUN92ffUdNGHnA4MiFFNbVfbYkKZSUv', - '6hCd2N5PVhHEoRwg5Db1Ja11sdwNKEmsRd24i76CV2NmdH46', - '6nSUPH1Zubuipt1Knit352hkNEMKdSobaYGsZyo271mFd6fp', - ], - backstopPools: ['6m6SUHd1XRpboq3GMsL73RigXCfz9iKZGWjoAzMnJJ9dJNgs'], + router: '6mS8roUTrZe7fFDYLa2NgWbMrG1YGK6roC6WtDo82dqd7TP6', + oracle: '6jrZjQgfbmW6yD3BkQhKfhT1xV4EoRpCve3RRvGiAdfff5T9', }, }; diff --git a/src/constants/cache.ts b/src/constants/cache.ts index 4a360e33..c94c26a2 100644 --- a/src/constants/cache.ts +++ b/src/constants/cache.ts @@ -13,6 +13,7 @@ export const cacheKeys = { tokenOutAmount: 'tokenOutAmount', sharesTargetWorth: 'sharesTargetWorth', tokenPrice: 'tokenPrice', + nablaInstance: 'nablaInstance', }; export type QueryOptions = Partial< diff --git a/src/contracts/nabla/AmberCurve.ts b/src/contracts/nabla/AmberCurve.ts deleted file mode 100644 index ae47800f..00000000 --- a/src/contracts/nabla/AmberCurve.ts +++ /dev/null @@ -1,340 +0,0 @@ -export const amberCurveAbi = { - contract: { - authors: ['unknown'], - description: 'implementation of the 0xAmber slippage curve', - name: 'AmberCurve', - version: '0.0.1', - }, - source: { - compiler: 'solang 0.3.0', - hash: '0x19a93fa817d5199daa422e1fb71b05f8be5e9e06c458845c1631b440ba050222', - language: 'Solidity 0.3.0', - }, - spec: { - constructors: [ - { - args: [ - { - label: '_alpha', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_beta', - type: { - displayName: ['u256'], - type: 0, - }, - }, - ], - docs: [''], - label: 'new', - payable: false, - returnType: null, - selector: '0x19b51a53', - }, - ], - docs: ['implementation of the 0xAmber slippage curve\n\n'], - events: [], - lang_error: { - displayName: [], - type: 0, - }, - messages: [ - { - args: [], - docs: [''], - label: 'params', - mutates: false, - payable: false, - returnType: { - displayName: ['Params'], - type: 1, - }, - selector: '0xcff0ab96', - }, - { - args: [ - { - label: '_reservesBefore', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_liabilitiesBefore', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_accumulatedPoolSlippage', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_depositAmount', - type: { - displayName: ['u256'], - type: 0, - }, - }, - ], - docs: ['adjusts deposit amount by slippage for a pool of a given coverage ratio\n\n'], - label: 'effectiveDeposit', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 0, - }, - selector: '0x7a84126b', - }, - { - args: [ - { - label: '_reservesBefore', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_liabilitiesBefore', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_accumulatedPoolSlippage', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_deltaAmount', - type: { - displayName: ['u256'], - type: 0, - }, - }, - ], - docs: [ - 'adjusts amount by slippage for a swap adding liquidity to this pool total swap fee is the sum of the swap fees of each pool involved\n\n', - ], - label: 'effectiveSwapIn', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 0, - }, - selector: '0x623cbcb8', - }, - { - args: [ - { - label: '_reservesBefore', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_liabilitiesBefore', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_accumulatedPoolSlippage', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_deltaAmount', - type: { - displayName: ['u256'], - type: 0, - }, - }, - ], - docs: [ - 'adjusts amount by slippage for a swap draining liquidity from this pool total swap fee is the sum of the swap fees of each pool involved\n\n', - ], - label: 'effectiveSwapOut', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 0, - }, - selector: '0x84ea820f', - }, - { - args: [ - { - label: '_reservesBefore', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_liabilitiesBefore', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_accumulatedPoolSlippage', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_withdrawalAmount', - type: { - displayName: ['u256'], - type: 0, - }, - }, - ], - docs: ['adjusts withdrawal amount by slippage for a pool of a given coverage ratio\n\n'], - label: 'effectiveWithdrawal', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 0, - }, - selector: '0x986c43e5', - }, - { - args: [ - { - label: '_reserves', - type: { - displayName: ['u256'], - type: 0, - }, - }, - { - label: '_liabilities', - type: { - displayName: ['u256'], - type: 0, - }, - }, - ], - docs: [''], - label: 'phi', - mutates: false, - payable: false, - returnType: { - displayName: ['u256'], - type: 0, - }, - selector: '0xc7d1cfa6', - }, - ], - }, - storage: { - struct: { - fields: [ - { - layout: { - root: { - layout: { - struct: { - fields: [ - { - layout: { - leaf: { - key: '0x00000000', - ty: 0, - }, - }, - name: 'alpha', - }, - { - layout: { - leaf: { - key: '0x00000000', - ty: 0, - }, - }, - name: 'beta', - }, - { - layout: { - leaf: { - key: '0x00000000', - ty: 0, - }, - }, - name: 'c', - }, - ], - name: 'Params', - }, - }, - root_key: '0x00000000', - }, - }, - name: 'params', - }, - ], - name: 'AmberCurve', - }, - }, - types: [ - { - id: 0, - type: { - def: { - primitive: 'u256', - }, - path: ['u256'], - }, - }, - { - id: 1, - type: { - def: { - composite: { - fields: [ - { - name: 'alpha', - type: 0, - }, - { - name: 'beta', - type: 0, - }, - { - name: 'c', - type: 0, - }, - ], - }, - }, - path: ['Params'], - }, - }, - ], - version: '4', -} as const; diff --git a/src/contracts/nabla/BackstopPool.ts b/src/contracts/nabla/BackstopPool.ts index 221adcfe..d3be6580 100644 --- a/src/contracts/nabla/BackstopPool.ts +++ b/src/contracts/nabla/BackstopPool.ts @@ -1,1459 +1,1866 @@ export const backstopPoolAbi = { - contract: { - authors: ['unknown'], - description: - 'The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees.', - name: 'BackstopPool', - version: '0.0.1', + "contract": { + "authors": [ + "unknown" + ], + "description": "The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees.", + "name": "BackstopPool", + "version": "0.0.1" }, - source: { - compiler: 'solang 0.3.2', - hash: '0x09e907520a2e0be46d0a350df95c431857cbf88f52094be242f15ae79e524f3c', - language: 'Solidity 0.3.2', + "source": { + "compiler": "solang 0.3.2", + "hash": "0x026ff1b46ca6ae1d60aed9cea110e48ee635da3087675e463bc717a9c23ffbe1", + "language": "Solidity 0.3.2" }, - spec: { - constructors: [ + "spec": { + "constructors": [ { - args: [ + "args": [ { - label: '_router', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_router", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_asset', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_name', - type: { - displayName: ['string'], - type: 5, - }, + "label": "_name", + "type": { + "displayName": [ + "string" + ], + "type": 5 + } }, { - label: '_symbol', - type: { - displayName: ['string'], - type: 5, - }, - }, + "label": "_symbol", + "type": { + "displayName": [ + "string" + ], + "type": 5 + } + } ], - default: false, - docs: [''], - label: 'new', - payable: false, - returnType: null, - selector: '0xf01fa595', - }, + "default": false, + "docs": [ + "" + ], + "label": "new", + "payable": false, + "returnType": null, + "selector": "0xf01fa595" + } ], - docs: [ - 'The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees.', + "docs": [ + "The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees." ], - environment: { - accountId: { - displayName: ['AccountId'], - type: 2, - }, - balance: { - displayName: ['Balance'], - type: 10, + "environment": { + "accountId": { + "displayName": [ + "AccountId" + ], + "type": 2 }, - blockNumber: { - displayName: ['BlockNumber'], - type: 11, + "balance": { + "displayName": [ + "Balance" + ], + "type": 11 }, - chainExtension: { - displayName: [], - type: 0, + "blockNumber": { + "displayName": [ + "BlockNumber" + ], + "type": 12 }, - hash: { - displayName: ['Hash'], - type: 12, + "chainExtension": { + "displayName": [], + "type": 0 }, - maxEventTopics: 4, - timestamp: { - displayName: ['Timestamp'], - type: 11, + "hash": { + "displayName": [ + "Hash" + ], + "type": 13 }, + "maxEventTopics": 4, + "timestamp": { + "displayName": [ + "Timestamp" + ], + "type": 12 + } }, - events: [ + "events": [ { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'from', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "from", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: true, - label: 'to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'value', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "value", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "docs": [ + "" ], - docs: [''], - label: 'Transfer', + "label": "Transfer" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: true, - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'value', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "value", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "docs": [ + "" ], - docs: [''], - label: 'Approval', + "label": "Approval" }, { - args: [ + "args": [ { - docs: [], - indexed: false, - label: 'account', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "docs": [], + "indexed": false, + "label": "account", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - docs: [''], - label: 'Paused', + "docs": [ + "" + ], + "label": "Paused" }, { - args: [ + "args": [ { - docs: [], - indexed: false, - label: 'account', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "docs": [], + "indexed": false, + "label": "account", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - docs: [''], - label: 'Unpaused', + "docs": [ + "" + ], + "label": "Unpaused" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'previousOwner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "previousOwner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: true, - label: 'newOwner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "docs": [], + "indexed": true, + "label": "newOwner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - docs: [''], - label: 'OwnershipTransferred', + "docs": [ + "" + ], + "label": "OwnershipTransferred" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'sender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "sender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'poolSharesMinted', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "poolSharesMinted", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'amountPrincipleDeposited', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "amountPrincipleDeposited", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - docs: ['emitted on every deposit'], - label: 'Mint', + "docs": [ + "emitted on every deposit" + ], + "label": "Mint" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'sender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "sender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'poolSharesBurned', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "poolSharesBurned", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'amountPrincipleWithdrawn', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "amountPrincipleWithdrawn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - docs: [ - 'emitted on every withdrawal special case withdrawal using swap liquidiity: amountPrincipleWithdrawn = 0', + "docs": [ + "emitted on every withdrawal special case withdrawal using swap liquidiity: amountPrincipleWithdrawn = 0" ], - label: 'Burn', + "label": "Burn" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'swapPool', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": false, + "label": "swapPool", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'amountSwapShares', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "amountSwapShares", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'amountSwapTokens', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "amountSwapTokens", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'amountBackstopTokens', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "amountBackstopTokens", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "docs": [ + "emitted when a swap pool LP withdraws from backstop pool" ], - docs: ['emitted when a swap pool LP withdraws from backstop pool'], - label: 'CoverSwapWithdrawal', + "label": "CoverSwapWithdrawal" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'swapPool', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": false, + "label": "swapPool", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'amountSwapTokens', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "amountSwapTokens", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'amountBackstopTokens', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "amountBackstopTokens", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - docs: ['emitted when a backstop pool LP withdraws liquidity from swap pool'], - label: 'WithdrawSwapLiquidity', - }, + "docs": [ + "emitted when a backstop pool LP withdraws liquidity from swap pool" + ], + "label": "WithdrawSwapLiquidity" + } ], - lang_error: { - displayName: ['SolidityError'], - type: 15, + "lang_error": { + "displayName": [ + "SolidityError" + ], + "type": 16 }, - messages: [ + "messages": [ { - args: [], - default: false, - docs: [''], - label: 'name', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 5, - }, - selector: '0x06fdde03', - }, - { - args: [], - default: false, - docs: [''], - label: 'symbol', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 5, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "name", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "string" + ], + "type": 5 }, - selector: '0x95d89b41', + "selector": "0x06fdde03" }, { - args: [], - default: false, - docs: [''], - label: 'decimals', - mutates: false, - payable: false, - returnType: { - displayName: ['uint8'], - type: 0, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "symbol", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "string" + ], + "type": 5 }, - selector: '0x313ce567', + "selector": "0x95d89b41" }, { - args: [], - default: false, - docs: [''], - label: 'totalSupply', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "totalSupply", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x18160ddd', + "selector": "0x18160ddd" }, { - args: [ + "args": [ { - label: 'account', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "account", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'balanceOf', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "default": false, + "docs": [ + "" + ], + "label": "balanceOf", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x70a08231', + "selector": "0x70a08231" }, { - args: [ + "args": [ { - label: 'to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [''], - label: 'transfer', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "default": false, + "docs": [ + "" + ], + "label": "transfer", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0xa9059cbb', + "selector": "0xa9059cbb" }, { - args: [ + "args": [ { - label: 'owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'allowance', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "default": false, + "docs": [ + "" + ], + "label": "allowance", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0xdd62ed3e', + "selector": "0xdd62ed3e" }, { - args: [ + "args": [ { - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [''], - label: 'approve', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "default": false, + "docs": [ + "" + ], + "label": "approve", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0x095ea7b3', + "selector": "0x095ea7b3" }, { - args: [ + "args": [ { - label: 'from', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "from", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'transferFrom', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "label": "transferFrom", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0x23b872dd', + "selector": "0x23b872dd" }, { - args: [ + "args": [ { - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'addedValue', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "addedValue", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'increaseAllowance', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "label": "increaseAllowance", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0x39509351', + "selector": "0x39509351" }, { - args: [ + "args": [ { - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'subtractedValue', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "subtractedValue", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'decreaseAllowance', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "label": "decreaseAllowance", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0xa457c2d7', + "selector": "0xa457c2d7" }, { - args: [], - default: false, - docs: [''], - label: 'paused', - mutates: false, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "paused", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0x5c975abb', + "selector": "0x5c975abb" }, { - args: [], - default: false, - docs: [''], - label: 'owner', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "owner", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 }, - selector: '0x8da5cb5b', + "selector": "0x8da5cb5b" }, { - args: [], - default: false, - docs: [''], - label: 'renounceOwnership', - mutates: true, - payable: false, - returnType: null, - selector: '0x715018a6', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "renounceOwnership", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0x715018a6" }, { - args: [ + "args": [ { - label: 'newOwner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "newOwner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'transferOwnership', - mutates: true, - payable: false, - returnType: null, - selector: '0xf2fde38b', + "label": "transferOwnership", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0xf2fde38b" }, { - args: [], - default: false, - docs: [''], - label: 'poolCap', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "poolCap", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0xb954dc57', + "selector": "0xb954dc57" }, { - args: [], - default: false, - docs: ["Returns the pooled token's address"], - label: 'asset', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, + "args": [], + "default": false, + "docs": [ + "Returns the pooled token's address" + ], + "label": "asset", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 }, - selector: '0x38d52e0f', + "selector": "0x38d52e0f" }, { - args: [], - default: false, - docs: ['Returns the decimals of the pool asset'], - label: 'assetDecimals', - mutates: false, - payable: false, - returnType: { - displayName: ['uint8'], - type: 0, + "args": [], + "default": false, + "docs": [ + "Returns the decimals of the pool asset" + ], + "label": "assetDecimals", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint8" + ], + "type": 0 }, - selector: '0xc2d41601', + "selector": "0xc2d41601" }, { - args: [], - default: false, - docs: [''], - label: 'router', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, + "args": [], + "default": false, + "docs": [ + "Returns the decimals of the LP token of this pool\nThis is defined to have the same decimals as the pool token itself\nin order to greatly simplify calculations that involve pool token amounts\nand LP token amounts" + ], + "label": "decimals", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint8" + ], + "type": 0 }, - selector: '0xf887ea40', + "selector": "0x313ce567" }, { - args: [ + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "router", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + }, + "selector": "0xf887ea40" + }, + { + "args": [ { - label: '_maxTokens', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_maxTokens", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [ - 'Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits.', + "default": false, + "docs": [ + "Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits." ], - label: 'setPoolCap', - mutates: true, - payable: false, - returnType: null, - selector: '0xd835f535', + "label": "setPoolCap", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0xd835f535" }, { - args: [ + "args": [ { - label: '_swapPool', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_swapPool", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_insuranceFeeBps', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_insuranceFeeBps", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [ - 'Make this backstop pool cover another swap pool Beware: Adding a swap pool holding the same token as the backstop pool\ncan easily cause undesirable conditions and must be secured (i.e. long time lock)!', + "default": false, + "docs": [ + "Make this backstop pool cover another swap pool Beware: Adding a swap pool holding the same token as the backstop pool\ncan easily cause undesirable conditions and must be secured (i.e. long time lock)!" ], - label: 'addSwapPool', - mutates: true, - payable: false, - returnType: null, - selector: '0xabb26587', + "label": "addSwapPool", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0xabb26587" }, { - args: [ + "args": [ { - label: '_swapPool', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_swapPool", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_insuranceFeeBps', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_insuranceFeeBps", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ["Change a swap pool's insurance withdrawal fee"], - label: 'setInsuranceFee', - mutates: true, - payable: false, - returnType: null, - selector: '0xc6a78196', + "default": false, + "docs": [ + "Change a swap pool's insurance withdrawal fee" + ], + "label": "setInsuranceFee", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0xc6a78196" }, { - args: [ + "args": [ { - label: '_index', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_index", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ['enumerate swap pools backed by this backstop pool'], - label: 'getBackedPool', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, + "default": false, + "docs": [ + "enumerate swap pools backed by this backstop pool" + ], + "label": "getBackedPool", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 }, - selector: '0xa04345f2', + "selector": "0xa04345f2" }, { - args: [], - default: false, - docs: ['get swap pool count backed by this backstop pool'], - label: 'getBackedPoolCount', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "args": [], + "default": false, + "docs": [ + "get swap pool count backed by this backstop pool" + ], + "label": "getBackedPoolCount", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x5fda8689', + "selector": "0x5fda8689" }, { - args: [ + "args": [ { - label: '_swapPool', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "_swapPool", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "default": false, + "docs": [ + "get insurance withdrawal fee for a given swap pool" ], - default: false, - docs: ['get insurance withdrawal fee for a given swap pool'], - label: 'getInsuranceFee', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "getInsuranceFee", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x504e0153', + "selector": "0x504e0153" }, { - args: [ + "args": [ { - label: '_depositAmount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_depositAmount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0" ], - default: false, - docs: ['Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0'], - label: 'deposit', - mutates: true, - payable: false, - returnType: { - displayName: ['BackstopPool', 'deposit', 'return_type'], - type: 8, + "label": "deposit", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "BackstopPool", + "deposit", + "return_type" + ], + "type": 8 }, - selector: '0xb6b55f25', + "selector": "0xb6b55f25" }, { - args: [ + "args": [ { - label: '_sharesToBurn', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_sharesToBurn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_minimumAmount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_minimumAmount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [ - 'Withdraws liquidity amount of asset ensuring minimum amount required Slippage is applied (withdrawal fee)', + "default": false, + "docs": [ + "Withdraws liquidity amount of asset ensuring minimum amount required Slippage is applied (withdrawal fee)" ], - label: 'withdraw', - mutates: true, - payable: false, - returnType: { - displayName: ['BackstopPool', 'withdraw', 'return_type'], - type: 9, + "label": "withdraw", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "BackstopPool", + "withdraw", + "return_type" + ], + "type": 9 }, - selector: '0x441a3e70', + "selector": "0x441a3e70" }, { - args: [ + "args": [ { - label: '_swapPool', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_swapPool", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_shares', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_shares", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_minAmount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_minAmount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [ - "withdraw from a swap pool using backstop liquidity without slippage only possible if swap pool's coverage ratio < 100%", + "default": false, + "docs": [ + "withdraw from a swap pool using backstop liquidity without slippage only possible if swap pool's coverage ratio < 100%" ], - label: 'redeemSwapPoolShares', - mutates: true, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "redeemSwapPoolShares", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x6e7e91fd', + "selector": "0x6e7e91fd" }, { - args: [ + "args": [ { - label: '_swapPool', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_swapPool", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_shares', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_shares", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_minAmount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_minAmount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [ - 'withdraw from backstop pool, but receive excess liquidity\nof a swap pool without slippage, instead of backstop liquidity', + "default": false, + "docs": [ + "withdraw from backstop pool, but receive excess liquidity\nof a swap pool without slippage, instead of backstop liquidity" ], - label: 'withdrawExcessSwapLiquidity', - mutates: true, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "withdrawExcessSwapLiquidity", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0xcaf8c105', + "selector": "0xcaf8c105" }, { - args: [], - default: false, - docs: [ - "return worth of the whole backstop pool in `asset()`, incl. all\nswap pools' excess liquidity and the backstop pool's liabilities", - ], - label: 'getTotalPoolWorth', - mutates: false, - payable: false, - returnType: { - displayName: ['int256'], - type: 7, + "args": [], + "default": false, + "docs": [ + "return worth of the whole backstop pool in `asset()`, incl. all\nswap pools' excess liquidity and the backstop pool's liabilities\nthis is a fixed point number, using the backstop pool decimals" + ], + "label": "getTotalPoolWorth", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "int256" + ], + "type": 7 }, - selector: '0x18ba24c4', + "selector": "0x18ba24c4" }, { - args: [ + "args": [ { - label: '_sharesToBurn', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_sharesToBurn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ['Returns the worth of an amount of pool shares (LP tokens) in underlying principle'], - label: 'sharesTargetWorth', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "default": false, + "docs": [ + "Returns the worth of an amount of pool shares (LP tokens) in underlying principle" + ], + "label": "sharesTargetWorth", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0xcc045745', + "selector": "0xcc045745" }, - ], + { + "args": [], + "default": false, + "docs": [ + "returns the backstop pool state" + ], + "label": "getPoolState", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "BackstopPool", + "getPoolState", + "return_type" + ], + "type": 10 + }, + "selector": "0x217ac237" + } + ] }, - storage: { - struct: { - fields: [ + "storage": { + "struct": { + "fields": [ { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000000', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000000', - }, + "root_key": "0x00000000" + } }, - name: '_owner', + "name": "_owner" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000001', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000001", + "ty": 3 + } }, - root_key: '0x00000001', - }, + "root_key": "0x00000001" + } }, - name: '_status', + "name": "_status" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000002', - ty: 4, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000002", + "ty": 4 + } }, - root_key: '0x00000002', - }, + "root_key": "0x00000002" + } }, - name: '_paused', + "name": "_paused" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000003', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000003", + "ty": 3 + } }, - root_key: '0x00000003', - }, + "root_key": "0x00000003" + } }, - name: '_balances', + "name": "_balances" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000004', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000004", + "ty": 3 + } }, - root_key: '0x00000004', - }, + "root_key": "0x00000004" + } }, - name: '_allowances', + "name": "_allowances" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000005', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000005", + "ty": 3 + } }, - root_key: '0x00000005', - }, + "root_key": "0x00000005" + } }, - name: '_totalSupply', + "name": "_totalSupply" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000006', - ty: 5, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000006", + "ty": 5 + } }, - root_key: '0x00000006', - }, + "root_key": "0x00000006" + } }, - name: '_name', + "name": "_name" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000007', - ty: 5, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000007", + "ty": 5 + } }, - root_key: '0x00000007', - }, + "root_key": "0x00000007" + } }, - name: '_symbol', + "name": "_symbol" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000008', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000008", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000008', - }, + "root_key": "0x00000008" + } }, - name: 'poolAsset', + "name": "poolAsset" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000009', - ty: 0, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000009", + "ty": 0 + } }, - root_key: '0x00000009', - }, + "root_key": "0x00000009" + } }, - name: 'poolAssetDecimals', + "name": "poolAssetDecimals" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000a', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x0000000a", + "ty": 3 + } }, - root_key: '0x0000000a', - }, + "root_key": "0x0000000a" + } }, - name: 'poolCap', + "name": "poolCap" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x0000000b', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x0000000b", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x0000000b', - }, + "root_key": "0x0000000b" + } }, - name: 'router', + "name": "router" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000c', - ty: 6, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x0000000c", + "ty": 6 + } }, - root_key: '0x0000000c', - }, + "root_key": "0x0000000c" + } }, - name: 'swapPools', + "name": "swapPools" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000d', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x0000000d", + "ty": 3 + } }, - root_key: '0x0000000d', - }, + "root_key": "0x0000000d" + } }, - name: 'swapPoolInsuranceFeeBps', + "name": "swapPoolInsuranceFeeBps" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000e', - ty: 4, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x0000000e", + "ty": 4 + } }, - root_key: '0x0000000e', - }, + "root_key": "0x0000000e" + } }, - name: 'swapPoolCovered', - }, + "name": "swapPoolCovered" + } ], - name: 'BackstopPool', - }, + "name": "BackstopPool" + } }, - types: [ + "types": [ { - id: 0, - type: { - def: { - primitive: 'u8', + "id": 0, + "type": { + "def": { + "primitive": "u8" }, - path: ['uint8'], - }, + "path": [ + "uint8" + ] + } }, { - id: 1, - type: { - def: { - array: { - len: 32, - type: 0, - }, - }, - }, + "id": 1, + "type": { + "def": { + "array": { + "len": 32, + "type": 0 + } + } + } }, { - id: 2, - type: { - def: { - composite: { - fields: [ + "id": 2, + "type": { + "def": { + "composite": { + "fields": [ { - type: 1, - }, - ], - }, + "type": 1 + } + ] + } }, - path: ['ink_primitives', 'types', 'AccountId'], - }, + "path": [ + "ink_primitives", + "types", + "AccountId" + ] + } }, { - id: 3, - type: { - def: { - primitive: 'u256', + "id": 3, + "type": { + "def": { + "primitive": "u256" }, - path: ['uint256'], - }, + "path": [ + "uint256" + ] + } }, { - id: 4, - type: { - def: { - primitive: 'bool', + "id": 4, + "type": { + "def": { + "primitive": "bool" }, - path: ['bool'], - }, + "path": [ + "bool" + ] + } }, { - id: 5, - type: { - def: { - primitive: 'str', + "id": 5, + "type": { + "def": { + "primitive": "str" }, - path: ['string'], - }, + "path": [ + "string" + ] + } }, { - id: 6, - type: { - def: { - sequence: { - type: 2, - }, + "id": 6, + "type": { + "def": { + "sequence": { + "type": 2 + } + } + } + }, + { + "id": 7, + "type": { + "def": { + "primitive": "i256" }, - }, + "path": [ + "int256" + ] + } }, { - id: 7, - type: { - def: { - primitive: 'i256', + "id": 8, + "type": { + "def": { + "tuple": [ + 3, + 7 + ] }, - path: ['int256'], - }, + "path": [ + "BackstopPool", + "deposit", + "return_type" + ] + } }, { - id: 8, - type: { - def: { - tuple: [3, 7], + "id": 9, + "type": { + "def": { + "tuple": [ + 3, + 7 + ] }, - path: ['BackstopPool', 'deposit', 'return_type'], - }, + "path": [ + "BackstopPool", + "withdraw", + "return_type" + ] + } }, { - id: 9, - type: { - def: { - tuple: [3, 7], + "id": 10, + "type": { + "def": { + "tuple": [ + 3, + 7, + 3 + ] }, - path: ['BackstopPool', 'withdraw', 'return_type'], - }, + "path": [ + "BackstopPool", + "getPoolState", + "return_type" + ] + } }, { - id: 10, - type: { - def: { - primitive: 'u128', + "id": 11, + "type": { + "def": { + "primitive": "u128" }, - path: ['uint128'], - }, + "path": [ + "uint128" + ] + } }, { - id: 11, - type: { - def: { - primitive: 'u64', + "id": 12, + "type": { + "def": { + "primitive": "u64" }, - path: ['uint64'], - }, + "path": [ + "uint64" + ] + } }, { - id: 12, - type: { - def: { - composite: { - fields: [ + "id": 13, + "type": { + "def": { + "composite": { + "fields": [ { - type: 1, - }, - ], - }, + "type": 1 + } + ] + } }, - path: ['ink_primitives', 'types', 'Hash'], - }, + "path": [ + "ink_primitives", + "types", + "Hash" + ] + } }, { - id: 13, - type: { - def: { - composite: { - fields: [ + "id": 14, + "type": { + "def": { + "composite": { + "fields": [ { - type: 5, - }, - ], - }, + "type": 5 + } + ] + } }, - path: ['0x08c379a0'], - }, + "path": [ + "0x08c379a0" + ] + } }, { - id: 14, - type: { - def: { - composite: { - fields: [ + "id": 15, + "type": { + "def": { + "composite": { + "fields": [ { - type: 3, - }, - ], - }, + "type": 3 + } + ] + } }, - path: ['0x4e487b71'], - }, + "path": [ + "0x4e487b71" + ] + } }, { - id: 15, - type: { - def: { - variant: { - variants: [ + "id": 16, + "type": { + "def": { + "variant": { + "variants": [ { - fields: [ + "fields": [ { - type: 13, - }, + "type": 14 + } ], - index: 0, - name: 'Error', + "index": 0, + "name": "Error" }, { - fields: [ + "fields": [ { - type: 14, - }, + "type": 15 + } ], - index: 1, - name: 'Panic', - }, - ], - }, + "index": 1, + "name": "Panic" + } + ] + } }, - path: ['SolidityError'], - }, - }, + "path": [ + "SolidityError" + ] + } + } ], - version: '4', + "version": "4" } as const; diff --git a/src/contracts/nabla/ERC20Wrapper.ts b/src/contracts/nabla/ERC20Wrapper.ts index 8dbcb8d5..021b6a98 100644 --- a/src/contracts/nabla/ERC20Wrapper.ts +++ b/src/contracts/nabla/ERC20Wrapper.ts @@ -1,654 +1,798 @@ export const erc20WrapperAbi = { - contract: { - authors: ['unknown'], - name: 'ERC20Wrapper', - version: '0.0.1', + "contract": { + "authors": [ + "unknown" + ], + "name": "ERC20Wrapper", + "version": "0.0.1" }, - source: { - compiler: 'solang 0.3.2', - hash: '0xd070e8f0df66f4f13a8ee42d5bf90220b1867883444c8f73f400f8c57ae2c9cd', - language: 'Solidity 0.3.2', + "source": { + "compiler": "solang 0.3.2", + "hash": "0xd070e8f0df66f4f13a8ee42d5bf90220b1867883444c8f73f400f8c57ae2c9cd", + "language": "Solidity 0.3.2" }, - spec: { - constructors: [ + "spec": { + "constructors": [ { - args: [ + "args": [ { - label: 'name_', - type: { - displayName: ['string'], - type: 0, - }, + "label": "name_", + "type": { + "displayName": [ + "string" + ], + "type": 0 + } }, { - label: 'symbol_', - type: { - displayName: ['string'], - type: 0, - }, + "label": "symbol_", + "type": { + "displayName": [ + "string" + ], + "type": 0 + } }, { - label: 'decimals_', - type: { - displayName: ['uint8'], - type: 1, - }, + "label": "decimals_", + "type": { + "displayName": [ + "uint8" + ], + "type": 1 + } }, { - label: 'variant_', - type: { - displayName: [], - type: 2, - }, + "label": "variant_", + "type": { + "displayName": [], + "type": 2 + } }, { - label: 'index_', - type: { - displayName: [], - type: 2, - }, + "label": "index_", + "type": { + "displayName": [], + "type": 2 + } }, { - label: 'code_', - type: { - displayName: [], - type: 3, - }, + "label": "code_", + "type": { + "displayName": [], + "type": 3 + } }, { - label: 'issuer_', - type: { - displayName: [], - type: 4, - }, - }, + "label": "issuer_", + "type": { + "displayName": [], + "type": 4 + } + } ], - default: false, - docs: [''], - label: 'new', - payable: false, - returnType: null, - selector: '0xd3b751bd', - }, + "default": false, + "docs": [ + "" + ], + "label": "new", + "payable": false, + "returnType": null, + "selector": "0xd3b751bd" + } ], - docs: [''], - environment: { - accountId: { - displayName: ['AccountId'], - type: 6, - }, - balance: { - displayName: ['Balance'], - type: 8, + "docs": [ + "" + ], + "environment": { + "accountId": { + "displayName": [ + "AccountId" + ], + "type": 6 }, - blockNumber: { - displayName: ['BlockNumber'], - type: 9, + "balance": { + "displayName": [ + "Balance" + ], + "type": 8 }, - chainExtension: { - displayName: [], - type: 0, + "blockNumber": { + "displayName": [ + "BlockNumber" + ], + "type": 9 }, - hash: { - displayName: ['Hash'], - type: 10, + "chainExtension": { + "displayName": [], + "type": 0 }, - maxEventTopics: 4, - timestamp: { - displayName: ['Timestamp'], - type: 9, + "hash": { + "displayName": [ + "Hash" + ], + "type": 10 }, + "maxEventTopics": 4, + "timestamp": { + "displayName": [ + "Timestamp" + ], + "type": 9 + } }, - events: [ + "events": [ { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'from', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, + "docs": [], + "indexed": true, + "label": "from", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } }, { - docs: [], - indexed: true, - label: 'to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, + "docs": [], + "indexed": true, + "label": "to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } }, { - docs: [], - indexed: false, - label: 'value', - type: { - displayName: ['uint256'], - type: 5, - }, - }, + "docs": [], + "indexed": false, + "label": "value", + "type": { + "displayName": [ + "uint256" + ], + "type": 5 + } + } + ], + "docs": [ + "" ], - docs: [''], - label: 'Transfer', + "label": "Transfer" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, + "docs": [], + "indexed": true, + "label": "owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } }, { - docs: [], - indexed: true, - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, + "docs": [], + "indexed": true, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } }, { - docs: [], - indexed: false, - label: 'value', - type: { - displayName: ['uint256'], - type: 5, - }, - }, + "docs": [], + "indexed": false, + "label": "value", + "type": { + "displayName": [ + "uint256" + ], + "type": 5 + } + } ], - docs: [''], - label: 'Approval', - }, + "docs": [ + "" + ], + "label": "Approval" + } ], - lang_error: { - displayName: ['SolidityError'], - type: 13, + "lang_error": { + "displayName": [ + "SolidityError" + ], + "type": 13 }, - messages: [ + "messages": [ { - args: [], - default: false, - docs: [''], - label: 'name', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 0, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "name", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "string" + ], + "type": 0 }, - selector: '0x06fdde03', + "selector": "0x06fdde03" }, { - args: [], - default: false, - docs: [''], - label: 'symbol', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 0, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "symbol", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "string" + ], + "type": 0 }, - selector: '0x95d89b41', + "selector": "0x95d89b41" }, { - args: [], - default: false, - docs: [''], - label: 'decimals', - mutates: false, - payable: false, - returnType: { - displayName: ['uint8'], - type: 1, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "decimals", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint8" + ], + "type": 1 }, - selector: '0x313ce567', + "selector": "0x313ce567" }, { - args: [], - default: false, - docs: [''], - label: 'totalSupply', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 5, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "totalSupply", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 5 }, - selector: '0x18160ddd', + "selector": "0x18160ddd" }, { - args: [ + "args": [ { - label: '_owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, - }, + "label": "_owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'balanceOf', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 5, + "label": "balanceOf", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 5 }, - selector: '0x70a08231', + "selector": "0x70a08231" }, { - args: [ + "args": [ { - label: '_to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, + "label": "_to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } }, { - label: '_amount', - type: { - displayName: ['uint256'], - type: 5, - }, - }, + "label": "_amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 5 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'transfer', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 7, + "label": "transfer", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 7 }, - selector: '0xa9059cbb', + "selector": "0xa9059cbb" }, { - args: [ + "args": [ { - label: '_owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, + "label": "_owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } }, { - label: '_spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, - }, + "label": "_spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'allowance', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 5, + "label": "allowance", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 5 }, - selector: '0xdd62ed3e', + "selector": "0xdd62ed3e" }, { - args: [ + "args": [ { - label: '_spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, + "label": "_spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } }, { - label: '_amount', - type: { - displayName: ['uint256'], - type: 5, - }, - }, + "label": "_amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 5 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'approve', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 7, + "label": "approve", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 7 }, - selector: '0x095ea7b3', + "selector": "0x095ea7b3" }, { - args: [ + "args": [ { - label: '_from', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, + "label": "_from", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } }, { - label: '_to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 6, - }, + "label": "_to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 6 + } }, { - label: '_amount', - type: { - displayName: ['uint256'], - type: 5, - }, - }, + "label": "_amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 5 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'transferFrom', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 7, + "label": "transferFrom", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 7 }, - selector: '0x23b872dd', - }, - ], + "selector": "0x23b872dd" + } + ] }, - storage: { - struct: { - fields: [ + "storage": { + "struct": { + "fields": [ { - layout: { - root: { - layout: { - leaf: { - key: '0x00000000', - ty: 0, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 0 + } }, - root_key: '0x00000000', - }, + "root_key": "0x00000000" + } }, - name: '_name', + "name": "_name" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000001', - ty: 0, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000001", + "ty": 0 + } }, - root_key: '0x00000001', - }, + "root_key": "0x00000001" + } }, - name: '_symbol', + "name": "_symbol" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000002', - ty: 1, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000002", + "ty": 1 + } }, - root_key: '0x00000002', - }, + "root_key": "0x00000002" + } }, - name: '_decimals', + "name": "_decimals" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000003', - ty: 2, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000003", + "ty": 2 + } }, - root_key: '0x00000003', - }, + "root_key": "0x00000003" + } }, - name: '_variant', + "name": "_variant" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000004', - ty: 2, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000004", + "ty": 2 + } }, - root_key: '0x00000004', - }, + "root_key": "0x00000004" + } }, - name: '_index', + "name": "_index" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000005', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000005", + "ty": 3 + } }, - root_key: '0x00000005', - }, + "root_key": "0x00000005" + } }, - name: '_code', + "name": "_code" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000006', - ty: 4, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000006", + "ty": 4 + } }, - root_key: '0x00000006', - }, + "root_key": "0x00000006" + } }, - name: '_issuer', - }, + "name": "_issuer" + } ], - name: 'ERC20Wrapper', - }, + "name": "ERC20Wrapper" + } }, - types: [ + "types": [ { - id: 0, - type: { - def: { - primitive: 'str', + "id": 0, + "type": { + "def": { + "primitive": "str" }, - path: ['string'], - }, + "path": [ + "string" + ] + } }, { - id: 1, - type: { - def: { - primitive: 'u8', + "id": 1, + "type": { + "def": { + "primitive": "u8" }, - path: ['uint8'], - }, + "path": [ + "uint8" + ] + } }, { - id: 2, - type: { - def: { - array: { - len: 1, - type: 1, - }, - }, - }, + "id": 2, + "type": { + "def": { + "array": { + "len": 1, + "type": 1 + } + } + } }, { - id: 3, - type: { - def: { - array: { - len: 12, - type: 1, - }, - }, - }, + "id": 3, + "type": { + "def": { + "array": { + "len": 12, + "type": 1 + } + } + } }, { - id: 4, - type: { - def: { - array: { - len: 32, - type: 1, - }, - }, - }, + "id": 4, + "type": { + "def": { + "array": { + "len": 32, + "type": 1 + } + } + } }, { - id: 5, - type: { - def: { - primitive: 'u256', + "id": 5, + "type": { + "def": { + "primitive": "u256" }, - path: ['uint256'], - }, + "path": [ + "uint256" + ] + } }, { - id: 6, - type: { - def: { - composite: { - fields: [ + "id": 6, + "type": { + "def": { + "composite": { + "fields": [ { - type: 4, - }, - ], - }, + "type": 4 + } + ] + } }, - path: ['ink_primitives', 'types', 'AccountId'], - }, + "path": [ + "ink_primitives", + "types", + "AccountId" + ] + } }, { - id: 7, - type: { - def: { - primitive: 'bool', + "id": 7, + "type": { + "def": { + "primitive": "bool" }, - path: ['bool'], - }, + "path": [ + "bool" + ] + } }, { - id: 8, - type: { - def: { - primitive: 'u128', + "id": 8, + "type": { + "def": { + "primitive": "u128" }, - path: ['uint128'], - }, + "path": [ + "uint128" + ] + } }, { - id: 9, - type: { - def: { - primitive: 'u64', + "id": 9, + "type": { + "def": { + "primitive": "u64" }, - path: ['uint64'], - }, + "path": [ + "uint64" + ] + } }, { - id: 10, - type: { - def: { - composite: { - fields: [ + "id": 10, + "type": { + "def": { + "composite": { + "fields": [ { - type: 4, - }, - ], - }, + "type": 4 + } + ] + } }, - path: ['ink_primitives', 'types', 'Hash'], - }, + "path": [ + "ink_primitives", + "types", + "Hash" + ] + } }, { - id: 11, - type: { - def: { - composite: { - fields: [ + "id": 11, + "type": { + "def": { + "composite": { + "fields": [ { - type: 0, - }, - ], - }, + "type": 0 + } + ] + } }, - path: ['0x08c379a0'], - }, + "path": [ + "0x08c379a0" + ] + } }, { - id: 12, - type: { - def: { - composite: { - fields: [ + "id": 12, + "type": { + "def": { + "composite": { + "fields": [ { - type: 5, - }, - ], - }, + "type": 5 + } + ] + } }, - path: ['0x4e487b71'], - }, + "path": [ + "0x4e487b71" + ] + } }, { - id: 13, - type: { - def: { - variant: { - variants: [ + "id": 13, + "type": { + "def": { + "variant": { + "variants": [ { - fields: [ + "fields": [ { - type: 11, - }, + "type": 11 + } ], - index: 0, - name: 'Error', + "index": 0, + "name": "Error" }, { - fields: [ + "fields": [ { - type: 12, - }, + "type": 12 + } ], - index: 1, - name: 'Panic', - }, - ], - }, + "index": 1, + "name": "Panic" + } + ] + } }, - path: ['SolidityError'], - }, - }, + "path": [ + "SolidityError" + ] + } + } ], - version: '4', + "version": "4" } as const; diff --git a/src/contracts/nabla/NablaCurve.ts b/src/contracts/nabla/NablaCurve.ts index 63edf9af..6565604d 100644 --- a/src/contracts/nabla/NablaCurve.ts +++ b/src/contracts/nabla/NablaCurve.ts @@ -1,438 +1,532 @@ export const nablaCurveAbi = { - contract: { - authors: ['unknown'], - description: - 'implementation of the Nabla slippage curve\nIt represents the function Psi(b,l) = beta * (b-l) ** 2 / (b + c * l) + b', - name: 'NablaCurve', - version: '0.0.1', + "contract": { + "authors": [ + "unknown" + ], + "description": "implementation of the Nabla slippage curve\nIt represents the function Psi(b,l) = beta * (b-l) ** 2 / (b + c * l) + b", + "name": "NablaCurve", + "version": "0.0.1" }, - source: { - compiler: 'solang 0.3.2', - hash: '0x228ecf05004b7a73783f6479db3e8125ddaaae3a25c72d70e89604d65728a0b6', - language: 'Solidity 0.3.2', + "source": { + "compiler": "solang 0.3.2", + "hash": "0x228ecf05004b7a73783f6479db3e8125ddaaae3a25c72d70e89604d65728a0b6", + "language": "Solidity 0.3.2" }, - spec: { - constructors: [ + "spec": { + "constructors": [ { - args: [ + "args": [ { - label: '_alpha', - type: { - displayName: ['uint256'], - type: 2, - }, + "label": "_alpha", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } }, { - label: '_beta', - type: { - displayName: ['uint256'], - type: 2, - }, - }, + "label": "_beta", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'new', - payable: false, - returnType: null, - selector: '0x19b51a53', - }, + "default": false, + "docs": [ + "" + ], + "label": "new", + "payable": false, + "returnType": null, + "selector": "0x19b51a53" + } ], - docs: [ - 'implementation of the Nabla slippage curve\nIt represents the function Psi(b,l) = beta * (b-l) ** 2 / (b + c * l) + b', + "docs": [ + "implementation of the Nabla slippage curve\nIt represents the function Psi(b,l) = beta * (b-l) ** 2 / (b + c * l) + b" ], - environment: { - accountId: { - displayName: ['AccountId'], - type: 6, - }, - balance: { - displayName: ['Balance'], - type: 7, + "environment": { + "accountId": { + "displayName": [ + "AccountId" + ], + "type": 6 }, - blockNumber: { - displayName: ['BlockNumber'], - type: 8, + "balance": { + "displayName": [ + "Balance" + ], + "type": 7 }, - chainExtension: { - displayName: [], - type: 0, + "blockNumber": { + "displayName": [ + "BlockNumber" + ], + "type": 8 }, - hash: { - displayName: ['Hash'], - type: 9, + "chainExtension": { + "displayName": [], + "type": 0 }, - maxEventTopics: 4, - timestamp: { - displayName: ['Timestamp'], - type: 8, + "hash": { + "displayName": [ + "Hash" + ], + "type": 9 }, + "maxEventTopics": 4, + "timestamp": { + "displayName": [ + "Timestamp" + ], + "type": 8 + } }, - events: [], - lang_error: { - displayName: ['SolidityError'], - type: 13, + "events": [], + "lang_error": { + "displayName": [ + "SolidityError" + ], + "type": 13 }, - messages: [ + "messages": [ { - args: [], - default: false, - docs: [''], - label: 'params', - mutates: false, - payable: false, - returnType: { - displayName: ['NablaCurve', 'params', 'return_type'], - type: 3, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "params", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "NablaCurve", + "params", + "return_type" + ], + "type": 3 }, - selector: '0xcff0ab96', + "selector": "0xcff0ab96" }, { - args: [ + "args": [ { - label: '_b', - type: { - displayName: ['uint256'], - type: 2, - }, + "label": "_b", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } }, { - label: '_l', - type: { - displayName: ['uint256'], - type: 2, - }, + "label": "_l", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } }, { - label: '_decimals', - type: { - displayName: ['uint8'], - type: 4, - }, - }, + "label": "_decimals", + "type": { + "displayName": [ + "uint8" + ], + "type": 4 + } + } ], - default: false, - docs: ['Calculates the output of the function Psi for input values b and l'], - label: 'psi', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 2, + "default": false, + "docs": [ + "Calculates the output of the function Psi for input values b and l" + ], + "label": "psi", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 2 }, - selector: '0x44ff824c', + "selector": "0x44ff824c" }, { - args: [ + "args": [ { - label: '_b', - type: { - displayName: ['uint256'], - type: 2, - }, + "label": "_b", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } }, { - label: '_l', - type: { - displayName: ['uint256'], - type: 2, - }, + "label": "_l", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } }, { - label: '_capitalB', - type: { - displayName: ['uint256'], - type: 2, - }, + "label": "_capitalB", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } }, { - label: '_decimals', - type: { - displayName: ['uint8'], - type: 4, - }, - }, + "label": "_decimals", + "type": { + "displayName": [ + "uint8" + ], + "type": 4 + } + } ], - default: false, - docs: ['Given b,l and B >= Psi(b, l), this function determines the unique t>=0\nsuch that Psi(b+t, l+t) = B'], - label: 'inverseDiagonal', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 2, + "default": false, + "docs": [ + "Given b,l and B >= Psi(b, l), this function determines the unique t>=0\nsuch that Psi(b+t, l+t) = B" + ], + "label": "inverseDiagonal", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 2 }, - selector: '0x79e3ddf2', + "selector": "0x79e3ddf2" }, { - args: [ + "args": [ { - label: '_b', - type: { - displayName: ['uint256'], - type: 2, - }, + "label": "_b", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } }, { - label: '_l', - type: { - displayName: ['uint256'], - type: 2, - }, + "label": "_l", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } }, { - label: '_capitalB', - type: { - displayName: ['uint256'], - type: 2, - }, + "label": "_capitalB", + "type": { + "displayName": [ + "uint256" + ], + "type": 2 + } }, { - label: '_decimals', - type: { - displayName: ['uint8'], - type: 4, - }, - }, + "label": "_decimals", + "type": { + "displayName": [ + "uint8" + ], + "type": 4 + } + } ], - default: false, - docs: ['Given b,l and B >= Psi(b, l), this function determines the unique t>=0\nsuch that Psi(b+t, l) = B'], - label: 'inverseHorizontal', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 2, + "default": false, + "docs": [ + "Given b,l and B >= Psi(b, l), this function determines the unique t>=0\nsuch that Psi(b+t, l) = B" + ], + "label": "inverseHorizontal", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 2 }, - selector: '0xe67b3643', - }, - ], + "selector": "0xe67b3643" + } + ] }, - storage: { - struct: { - fields: [ + "storage": { + "struct": { + "fields": [ { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000000', - ty: 0, - }, + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 0 + } }, - name: 'beta', + "name": "beta" }, { - layout: { - leaf: { - key: '0x00000000', - ty: 0, - }, + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 0 + } }, - name: 'c', - }, + "name": "c" + } ], - name: 'Params', - }, + "name": "Params" + } }, - root_key: '0x00000000', - }, + "root_key": "0x00000000" + } }, - name: 'params', - }, + "name": "params" + } ], - name: 'NablaCurve', - }, + "name": "NablaCurve" + } }, - types: [ + "types": [ { - id: 0, - type: { - def: { - primitive: 'i256', + "id": 0, + "type": { + "def": { + "primitive": "i256" }, - path: ['int256'], - }, + "path": [ + "int256" + ] + } }, { - id: 1, - type: { - def: { - composite: { - fields: [ + "id": 1, + "type": { + "def": { + "composite": { + "fields": [ { - name: 'beta', - type: 0, + "name": "beta", + "type": 0 }, { - name: 'c', - type: 0, - }, - ], - }, + "name": "c", + "type": 0 + } + ] + } }, - path: ['Params'], - }, + "path": [ + "Params" + ] + } }, { - id: 2, - type: { - def: { - primitive: 'u256', + "id": 2, + "type": { + "def": { + "primitive": "u256" }, - path: ['uint256'], - }, + "path": [ + "uint256" + ] + } }, { - id: 3, - type: { - def: { - tuple: [0, 0], + "id": 3, + "type": { + "def": { + "tuple": [ + 0, + 0 + ] }, - path: ['NablaCurve', 'params', 'return_type'], - }, + "path": [ + "NablaCurve", + "params", + "return_type" + ] + } }, { - id: 4, - type: { - def: { - primitive: 'u8', + "id": 4, + "type": { + "def": { + "primitive": "u8" }, - path: ['uint8'], - }, + "path": [ + "uint8" + ] + } }, { - id: 5, - type: { - def: { - array: { - len: 32, - type: 4, - }, - }, - }, + "id": 5, + "type": { + "def": { + "array": { + "len": 32, + "type": 4 + } + } + } }, { - id: 6, - type: { - def: { - composite: { - fields: [ + "id": 6, + "type": { + "def": { + "composite": { + "fields": [ { - type: 5, - }, - ], - }, + "type": 5 + } + ] + } }, - path: ['ink_primitives', 'types', 'AccountId'], - }, + "path": [ + "ink_primitives", + "types", + "AccountId" + ] + } }, { - id: 7, - type: { - def: { - primitive: 'u128', + "id": 7, + "type": { + "def": { + "primitive": "u128" }, - path: ['uint128'], - }, + "path": [ + "uint128" + ] + } }, { - id: 8, - type: { - def: { - primitive: 'u64', + "id": 8, + "type": { + "def": { + "primitive": "u64" }, - path: ['uint64'], - }, + "path": [ + "uint64" + ] + } }, { - id: 9, - type: { - def: { - composite: { - fields: [ + "id": 9, + "type": { + "def": { + "composite": { + "fields": [ { - type: 5, - }, - ], - }, + "type": 5 + } + ] + } }, - path: ['ink_primitives', 'types', 'Hash'], - }, + "path": [ + "ink_primitives", + "types", + "Hash" + ] + } }, { - id: 10, - type: { - def: { - primitive: 'str', + "id": 10, + "type": { + "def": { + "primitive": "str" }, - path: ['string'], - }, + "path": [ + "string" + ] + } }, { - id: 11, - type: { - def: { - composite: { - fields: [ + "id": 11, + "type": { + "def": { + "composite": { + "fields": [ { - type: 10, - }, - ], - }, + "type": 10 + } + ] + } }, - path: ['0x08c379a0'], - }, + "path": [ + "0x08c379a0" + ] + } }, { - id: 12, - type: { - def: { - composite: { - fields: [ + "id": 12, + "type": { + "def": { + "composite": { + "fields": [ { - type: 2, - }, - ], - }, + "type": 2 + } + ] + } }, - path: ['0x4e487b71'], - }, + "path": [ + "0x4e487b71" + ] + } }, { - id: 13, - type: { - def: { - variant: { - variants: [ + "id": 13, + "type": { + "def": { + "variant": { + "variants": [ { - fields: [ + "fields": [ { - type: 11, - }, + "type": 11 + } ], - index: 0, - name: 'Error', + "index": 0, + "name": "Error" }, { - fields: [ + "fields": [ { - type: 12, - }, + "type": 12 + } ], - index: 1, - name: 'Panic', - }, - ], - }, + "index": 1, + "name": "Panic" + } + ] + } }, - path: ['SolidityError'], - }, - }, + "path": [ + "SolidityError" + ] + } + } ], - version: '4', + "version": "4" } as const; diff --git a/src/contracts/nabla/PriceOracle.ts b/src/contracts/nabla/PriceOracle.ts index 5e038f8d..9565cd66 100644 --- a/src/contracts/nabla/PriceOracle.ts +++ b/src/contracts/nabla/PriceOracle.ts @@ -1,590 +1,713 @@ export const priceOracleAbi = { - contract: { - authors: ['unknown'], - description: - 'PriceOracleWrapper\nPrice oracle that uses the native chain via chain extension. It stores _asset, _blockchain and _symbol for use by function getAssetPrice() which is called by Nabla.', - name: 'PriceOracleWrapper', - version: '0.0.1', + "contract": { + "authors": [ + "unknown" + ], + "description": "PriceOracleWrapper\nPrice oracle that uses the native chain via chain extension. It stores _asset, _blockchain and _symbol for use by function getAssetPrice() which is called by Nabla.", + "name": "PriceOracleWrapper", + "version": "0.0.1" }, - source: { - compiler: 'solang 0.3.2', - hash: '0x03b6e72dd745ae29cddc8f15ad73b91bd1b32f2c7369b8f4dc8be1c363116740', - language: 'Solidity 0.3.2', + "source": { + "compiler": "solang 0.3.2", + "hash": "0x03b6e72dd745ae29cddc8f15ad73b91bd1b32f2c7369b8f4dc8be1c363116740", + "language": "Solidity 0.3.2" }, - spec: { - constructors: [ + "spec": { + "constructors": [ { - args: [ + "args": [ { - label: 'oracleKeys', - type: { - displayName: [], - type: 5, - }, - }, + "label": "oracleKeys", + "type": { + "displayName": [], + "type": 5 + } + } ], - default: false, - docs: [''], - label: 'new', - payable: false, - returnType: null, - selector: '0xd0656c89', - }, + "default": false, + "docs": [ + "" + ], + "label": "new", + "payable": false, + "returnType": null, + "selector": "0xd0656c89" + } ], - docs: [ - 'PriceOracleWrapper\n\nPrice oracle that uses the native chain via chain extension. It stores _asset, _blockchain and _symbol for use by function getAssetPrice() which is called by Nabla.', + "docs": [ + "PriceOracleWrapper\n\nPrice oracle that uses the native chain via chain extension. It stores _asset, _blockchain and _symbol for use by function getAssetPrice() which is called by Nabla." ], - environment: { - accountId: { - displayName: ['AccountId'], - type: 2, - }, - balance: { - displayName: ['Balance'], - type: 8, + "environment": { + "accountId": { + "displayName": [ + "AccountId" + ], + "type": 2 }, - blockNumber: { - displayName: ['BlockNumber'], - type: 9, + "balance": { + "displayName": [ + "Balance" + ], + "type": 8 }, - chainExtension: { - displayName: [], - type: 0, + "blockNumber": { + "displayName": [ + "BlockNumber" + ], + "type": 9 }, - hash: { - displayName: ['Hash'], - type: 12, + "chainExtension": { + "displayName": [], + "type": 0 }, - maxEventTopics: 4, - timestamp: { - displayName: ['Timestamp'], - type: 9, + "hash": { + "displayName": [ + "Hash" + ], + "type": 12 }, + "maxEventTopics": 4, + "timestamp": { + "displayName": [ + "Timestamp" + ], + "type": 9 + } }, - events: [], - lang_error: { - displayName: ['SolidityError'], - type: 15, + "events": [], + "lang_error": { + "displayName": [ + "SolidityError" + ], + "type": 15 }, - messages: [ + "messages": [ { - args: [ + "args": [ { - label: '', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'oracleByAsset', - mutates: false, - payable: false, - returnType: { - displayName: ['PriceOracleWrapper', 'oracleByAsset', 'return_type'], - type: 6, + "default": false, + "docs": [ + "" + ], + "label": "oracleByAsset", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "PriceOracleWrapper", + "oracleByAsset", + "return_type" + ], + "type": 6 }, - selector: '0x38163032', + "selector": "0x38163032" }, { - args: [ + "args": [ { - label: 'asset', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'getOracleKeyAsset', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, + "default": false, + "docs": [ + "" + ], + "label": "getOracleKeyAsset", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 }, - selector: '0x1d6752d1', + "selector": "0x1d6752d1" }, { - args: [ + "args": [ { - label: 'asset', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'getOracleKeyBlockchain', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 3, + "default": false, + "docs": [ + "" + ], + "label": "getOracleKeyBlockchain", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "string" + ], + "type": 3 }, - selector: '0xf457eab5', + "selector": "0xf457eab5" }, { - args: [ + "args": [ { - label: 'asset', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'getOracleKeySymbol', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 3, + "default": false, + "docs": [ + "" + ], + "label": "getOracleKeySymbol", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "string" + ], + "type": 3 }, - selector: '0x416c2844', + "selector": "0x416c2844" }, { - args: [ + "args": [ { - label: 'asset', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [ - 'Returns the asset price in USD. This is called by Nabla and expected by their IPriceOracleGetter interface', + "default": false, + "docs": [ + "Returns the asset price in USD. This is called by Nabla and expected by their IPriceOracleGetter interface" ], - label: 'getAssetPrice', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 7, + "label": "getAssetPrice", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 7 }, - selector: '0xb3596f07', + "selector": "0xb3596f07" }, { - args: [ + "args": [ { - label: 'blockchain', - type: { - displayName: ['string'], - type: 3, - }, + "label": "blockchain", + "type": { + "displayName": [ + "string" + ], + "type": 3 + } }, { - label: 'symbol', - type: { - displayName: ['string'], - type: 3, - }, - }, + "label": "symbol", + "type": { + "displayName": [ + "string" + ], + "type": 3 + } + } ], - default: false, - docs: [''], - label: 'getAnyAssetSupply', - mutates: true, - payable: false, - returnType: { - displayName: ['uint128'], - type: 8, + "default": false, + "docs": [ + "" + ], + "label": "getAnyAssetSupply", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint128" + ], + "type": 8 }, - selector: '0xb27f53dd', + "selector": "0xb27f53dd" }, { - args: [ + "args": [ { - label: 'blockchain', - type: { - displayName: ['string'], - type: 3, - }, + "label": "blockchain", + "type": { + "displayName": [ + "string" + ], + "type": 3 + } }, { - label: 'symbol', - type: { - displayName: ['string'], - type: 3, - }, - }, + "label": "symbol", + "type": { + "displayName": [ + "string" + ], + "type": 3 + } + } ], - default: false, - docs: [''], - label: 'getAnyAssetLastUpdateTimestamp', - mutates: true, - payable: false, - returnType: { - displayName: ['uint64'], - type: 9, + "default": false, + "docs": [ + "" + ], + "label": "getAnyAssetLastUpdateTimestamp", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint64" + ], + "type": 9 }, - selector: '0x30c8d868', + "selector": "0x30c8d868" }, { - args: [ + "args": [ { - label: 'blockchain', - type: { - displayName: ['string'], - type: 3, - }, + "label": "blockchain", + "type": { + "displayName": [ + "string" + ], + "type": 3 + } }, { - label: 'symbol', - type: { - displayName: ['string'], - type: 3, - }, - }, + "label": "symbol", + "type": { + "displayName": [ + "string" + ], + "type": 3 + } + } ], - default: false, - docs: [''], - label: 'getAnyAssetPrice', - mutates: true, - payable: false, - returnType: { - displayName: ['uint128'], - type: 8, + "default": false, + "docs": [ + "" + ], + "label": "getAnyAssetPrice", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint128" + ], + "type": 8 }, - selector: '0x96e182f6', + "selector": "0x96e182f6" }, { - args: [ + "args": [ { - label: 'blockchain', - type: { - displayName: ['string'], - type: 3, - }, + "label": "blockchain", + "type": { + "displayName": [ + "string" + ], + "type": 3 + } }, { - label: 'symbol', - type: { - displayName: ['string'], - type: 3, - }, - }, + "label": "symbol", + "type": { + "displayName": [ + "string" + ], + "type": 3 + } + } ], - default: false, - docs: [ - 'performs the actual chain extension call to get the price feed. blockchain and symbol are the keys used to access a particular price feed from the chain.', + "default": false, + "docs": [ + "performs the actual chain extension call to get the price feed. blockchain and symbol are the keys used to access a particular price feed from the chain." ], - label: 'getAnyAsset', - mutates: true, - payable: false, - returnType: { - displayName: ['CoinInfo'], - type: 11, + "label": "getAnyAsset", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "CoinInfo" + ], + "type": 11 }, - selector: '0xb57ba499', - }, - ], + "selector": "0xb57ba499" + } + ] }, - storage: { - struct: { - fields: [ + "storage": { + "struct": { + "fields": [ { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - struct: { - fields: [ + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000000', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - name: 'asset', + "name": "asset" }, { - layout: { - leaf: { - key: '0x00000000', - ty: 3, - }, + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 3 + } }, - name: 'blockchain', + "name": "blockchain" }, { - layout: { - leaf: { - key: '0x00000000', - ty: 3, - }, + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 3 + } }, - name: 'symbol', - }, + "name": "symbol" + } ], - name: 'OracleKey', - }, + "name": "OracleKey" + } }, - root_key: '0x00000000', - }, + "root_key": "0x00000000" + } }, - name: 'oracleByAsset', - }, + "name": "oracleByAsset" + } ], - name: 'PriceOracleWrapper', - }, + "name": "PriceOracleWrapper" + } }, - types: [ + "types": [ { - id: 0, - type: { - def: { - primitive: 'u8', + "id": 0, + "type": { + "def": { + "primitive": "u8" }, - path: ['uint8'], - }, + "path": [ + "uint8" + ] + } }, { - id: 1, - type: { - def: { - array: { - len: 32, - type: 0, - }, - }, - }, + "id": 1, + "type": { + "def": { + "array": { + "len": 32, + "type": 0 + } + } + } }, { - id: 2, - type: { - def: { - composite: { - fields: [ + "id": 2, + "type": { + "def": { + "composite": { + "fields": [ { - type: 1, - }, - ], - }, + "type": 1 + } + ] + } }, - path: ['ink_primitives', 'types', 'AccountId'], - }, + "path": [ + "ink_primitives", + "types", + "AccountId" + ] + } }, { - id: 3, - type: { - def: { - primitive: 'str', + "id": 3, + "type": { + "def": { + "primitive": "str" }, - path: ['string'], - }, + "path": [ + "string" + ] + } }, { - id: 4, - type: { - def: { - composite: { - fields: [ + "id": 4, + "type": { + "def": { + "composite": { + "fields": [ { - name: 'asset', - type: 2, + "name": "asset", + "type": 2 }, { - name: 'blockchain', - type: 3, + "name": "blockchain", + "type": 3 }, { - name: 'symbol', - type: 3, - }, - ], - }, + "name": "symbol", + "type": 3 + } + ] + } }, - path: ['OracleKey'], - }, + "path": [ + "OracleKey" + ] + } }, { - id: 5, - type: { - def: { - sequence: { - type: 4, - }, - }, - }, + "id": 5, + "type": { + "def": { + "sequence": { + "type": 4 + } + } + } }, { - id: 6, - type: { - def: { - tuple: [2, 3, 3], + "id": 6, + "type": { + "def": { + "tuple": [ + 2, + 3, + 3 + ] }, - path: ['PriceOracleWrapper', 'oracleByAsset', 'return_type'], - }, + "path": [ + "PriceOracleWrapper", + "oracleByAsset", + "return_type" + ] + } }, { - id: 7, - type: { - def: { - primitive: 'u256', + "id": 7, + "type": { + "def": { + "primitive": "u256" }, - path: ['uint256'], - }, + "path": [ + "uint256" + ] + } }, { - id: 8, - type: { - def: { - primitive: 'u128', + "id": 8, + "type": { + "def": { + "primitive": "u128" }, - path: ['uint128'], - }, + "path": [ + "uint128" + ] + } }, { - id: 9, - type: { - def: { - primitive: 'u64', + "id": 9, + "type": { + "def": { + "primitive": "u64" }, - path: ['uint64'], - }, + "path": [ + "uint64" + ] + } }, { - id: 10, - type: { - def: { - sequence: { - type: 0, - }, - }, - }, + "id": 10, + "type": { + "def": { + "sequence": { + "type": 0 + } + } + } }, { - id: 11, - type: { - def: { - composite: { - fields: [ + "id": 11, + "type": { + "def": { + "composite": { + "fields": [ { - name: 'symbol', - type: 10, + "name": "symbol", + "type": 10 }, { - name: 'name', - type: 10, + "name": "name", + "type": 10 }, { - name: 'blockchain', - type: 10, + "name": "blockchain", + "type": 10 }, { - name: 'supply', - type: 8, + "name": "supply", + "type": 8 }, { - name: 'last_update_timestamp', - type: 9, + "name": "last_update_timestamp", + "type": 9 }, { - name: 'price', - type: 8, - }, - ], - }, + "name": "price", + "type": 8 + } + ] + } }, - path: ['CoinInfo'], - }, + "path": [ + "CoinInfo" + ] + } }, { - id: 12, - type: { - def: { - composite: { - fields: [ + "id": 12, + "type": { + "def": { + "composite": { + "fields": [ { - type: 1, - }, - ], - }, + "type": 1 + } + ] + } }, - path: ['ink_primitives', 'types', 'Hash'], - }, + "path": [ + "ink_primitives", + "types", + "Hash" + ] + } }, { - id: 13, - type: { - def: { - composite: { - fields: [ + "id": 13, + "type": { + "def": { + "composite": { + "fields": [ { - type: 3, - }, - ], - }, + "type": 3 + } + ] + } }, - path: ['0x08c379a0'], - }, + "path": [ + "0x08c379a0" + ] + } }, { - id: 14, - type: { - def: { - composite: { - fields: [ + "id": 14, + "type": { + "def": { + "composite": { + "fields": [ { - type: 7, - }, - ], - }, + "type": 7 + } + ] + } }, - path: ['0x4e487b71'], - }, + "path": [ + "0x4e487b71" + ] + } }, { - id: 15, - type: { - def: { - variant: { - variants: [ + "id": 15, + "type": { + "def": { + "variant": { + "variants": [ { - fields: [ + "fields": [ { - type: 13, - }, + "type": 13 + } ], - index: 0, - name: 'Error', + "index": 0, + "name": "Error" }, { - fields: [ + "fields": [ { - type: 14, - }, + "type": 14 + } ], - index: 1, - name: 'Panic', - }, - ], - }, + "index": 1, + "name": "Panic" + } + ] + } }, - path: ['SolidityError'], - }, - }, + "path": [ + "SolidityError" + ] + } + } ], - version: '4', + "version": "4" } as const; diff --git a/src/contracts/nabla/Router.ts b/src/contracts/nabla/Router.ts index cd1fad9d..7e7a3742 100644 --- a/src/contracts/nabla/Router.ts +++ b/src/contracts/nabla/Router.ts @@ -1,731 +1,986 @@ export const routerAbi = { - contract: { - authors: ['unknown'], - name: 'Router', - version: '0.0.1', + "contract": { + "authors": [ + "unknown" + ], + "name": "Router", + "version": "0.0.1" }, - source: { - compiler: 'solang 0.3.2', - hash: '0xc3a4799cb3feb885864b7bda2b7340893d52fc4f096024e42c5c59319e9cf4ed', - language: 'Solidity 0.3.2', + "source": { + "compiler": "solang 0.3.2", + "hash": "0xe2399cb35f8b6165c02038216d66719e2f91be30096c0324fc759c0826684bcc", + "language": "Solidity 0.3.2" }, - spec: { - constructors: [ + "spec": { + "constructors": [ { - args: [], - default: false, - docs: [''], - label: 'new', - payable: false, - returnType: null, - selector: '0x861731d5', - }, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "new", + "payable": false, + "returnType": null, + "selector": "0x861731d5" + } ], - docs: [''], - environment: { - accountId: { - displayName: ['AccountId'], - type: 2, - }, - balance: { - displayName: ['Balance'], - type: 7, + "docs": [ + "" + ], + "environment": { + "accountId": { + "displayName": [ + "AccountId" + ], + "type": 2 }, - blockNumber: { - displayName: ['BlockNumber'], - type: 8, + "balance": { + "displayName": [ + "Balance" + ], + "type": 7 }, - chainExtension: { - displayName: [], - type: 0, + "blockNumber": { + "displayName": [ + "BlockNumber" + ], + "type": 8 }, - hash: { - displayName: ['Hash'], - type: 9, + "chainExtension": { + "displayName": [], + "type": 0 }, - maxEventTopics: 4, - timestamp: { - displayName: ['Timestamp'], - type: 8, + "hash": { + "displayName": [ + "Hash" + ], + "type": 9 }, + "maxEventTopics": 4, + "timestamp": { + "displayName": [ + "Timestamp" + ], + "type": 8 + } }, - events: [ + "events": [ { - args: [ + "args": [ { - docs: [], - indexed: false, - label: 'account', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "docs": [], + "indexed": false, + "label": "account", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - docs: [''], - label: 'Paused', + "docs": [ + "" + ], + "label": "Paused" }, { - args: [ + "args": [ { - docs: [], - indexed: false, - label: 'account', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "docs": [], + "indexed": false, + "label": "account", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "docs": [ + "" ], - docs: [''], - label: 'Unpaused', + "label": "Unpaused" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'previousOwner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "previousOwner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: true, - label: 'newOwner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "docs": [], + "indexed": true, + "label": "newOwner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "docs": [ + "" ], - docs: [''], - label: 'OwnershipTransferred', + "label": "OwnershipTransferred" }, { - args: [ + "args": [ { - docs: [], - indexed: false, - label: 'pool', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "sender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'asset', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": false, + "label": "pool", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, + { + "docs": [], + "indexed": false, + "label": "asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - docs: ['Emitted when a new pool is registered'], - label: 'SwapPoolRegistered', + "docs": [ + "Emitted when a new pool is registered" + ], + "label": "SwapPoolRegistered" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'sender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "sender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'amountIn', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "docs": [ + "Emitted when pool is unregistered" + ], + "label": "SwapPoolUnregistered" + }, + { + "args": [ + { + "docs": [], + "indexed": true, + "label": "sender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'amountOut', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "amountIn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'tokenIn', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": false, + "label": "amountOut", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'tokenOut', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": false, + "label": "tokenIn", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: true, - label: 'to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": false, + "label": "tokenOut", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, + { + "docs": [], + "indexed": true, + "label": "to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - docs: ['Emitted on each swap'], - label: 'Swap', - }, + "docs": [ + "Emitted on each swap" + ], + "label": "Swap" + } ], - lang_error: { - displayName: ['SolidityError'], - type: 13, + "lang_error": { + "displayName": [ + "SolidityError" + ], + "type": 13 }, - messages: [ + "messages": [ { - args: [], - default: false, - docs: [''], - label: 'paused', - mutates: false, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "paused", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0x5c975abb', + "selector": "0x5c975abb" }, { - args: [], - default: false, - docs: [''], - label: 'owner', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "owner", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 }, - selector: '0x8da5cb5b', + "selector": "0x8da5cb5b" }, { - args: [], - default: false, - docs: [''], - label: 'renounceOwnership', - mutates: true, - payable: false, - returnType: null, - selector: '0x715018a6', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "renounceOwnership", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0x715018a6" }, { - args: [ + "args": [ { - label: 'newOwner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "newOwner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'transferOwnership', - mutates: true, - payable: false, - returnType: null, - selector: '0xf2fde38b', + "default": false, + "docs": [ + "" + ], + "label": "transferOwnership", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0xf2fde38b" }, { - args: [ + "args": [ { - label: '', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'poolByAsset', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, + "default": false, + "docs": [ + "" + ], + "label": "poolByAsset", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 }, - selector: '0x06de94d8', + "selector": "0x06de94d8" }, { - args: [ + "args": [ { - label: '', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'oracleByAsset', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, + "label": "oracleByAsset", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 }, - selector: '0x38163032', + "selector": "0x38163032" }, { - args: [ + "args": [ { - label: '_asset', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_priceOracle', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "_priceOracle", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "default": false, + "docs": [ + "Changes the pools priceOracle. Can only be set by the contract owner." ], - default: false, - docs: ['Changes the pools priceOracle. Can only be set by the contract owner.'], - label: 'setPriceOracle', - mutates: true, - payable: false, - returnType: null, - selector: '0x67a74ddc', + "label": "setPriceOracle", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0x67a74ddc" }, { - args: [ + "args": [ { - label: '_asset', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_swapPool', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "_swapPool", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "default": false, + "docs": [ + "Registers a newly created swap pool" + ], + "label": "registerPool", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 + }, + "selector": "0x7286e5e5" + }, + { + "args": [ + { + "label": "_asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "default": false, + "docs": [ + "Unregisters a swap pool" ], - default: false, - docs: ['Registers a newly created swap pool.'], - label: 'registerPool', - mutates: true, - payable: false, - returnType: null, - selector: '0x7286e5e5', + "label": "unregisterPool", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 + }, + "selector": "0xada61cc3" }, { - args: [], - default: false, - docs: ['Disable all swaps'], - label: 'pause', - mutates: true, - payable: false, - returnType: null, - selector: '0x8456cb59', + "args": [], + "default": false, + "docs": [ + "Disable all swaps" + ], + "label": "pause", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0x8456cb59" }, { - args: [], - default: false, - docs: ['Resume all swaps'], - label: 'unpause', - mutates: true, - payable: false, - returnType: null, - selector: '0x3f4ba83a', + "args": [], + "default": false, + "docs": [ + "Resume all swaps" + ], + "label": "unpause", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0x3f4ba83a" }, { - args: [ + "args": [ { - label: '_amountIn', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_amountIn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_amountOutMin', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_amountOutMin", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_tokenInOut', - type: { - displayName: [], - type: 6, - }, + "label": "_tokenInOut", + "type": { + "displayName": [], + "type": 6 + } }, { - label: '_to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_deadline', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_deadline", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [ - 'Swap some `_fromToken` tokens for `_toToken` tokens,\nensures `_amountOutMin` and `_deadline`, sends funds to `_to` address `msg.sender` needs to grant the chef contract a sufficient allowance beforehand', + "default": false, + "docs": [ + "Swap some `_fromToken` tokens for `_toToken` tokens,\nensures `_amountOutMin` and `_deadline`, sends funds to `_to` address `msg.sender` needs to grant the chef contract a sufficient allowance beforehand" ], - label: 'swapExactTokensForTokens', - mutates: true, - payable: false, - returnType: { - displayName: [], - type: 5, + "label": "swapExactTokensForTokens", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [], + "type": 5 }, - selector: '0x38ed1739', + "selector": "0x38ed1739" }, { - args: [ + "args": [ { - label: '_amountIn', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_amountIn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_tokenInOut', - type: { - displayName: [], - type: 6, - }, - }, + "label": "_tokenInOut", + "type": { + "displayName": [], + "type": 6 + } + } ], - default: false, - docs: [ - 'Get a quote for how many `_toToken` tokens `_amountIn` many `tokenIn`\ntokens can currently be swapped for.', + "default": false, + "docs": [ + "Get a quote for how many `_toToken` tokens `_amountIn` many `tokenIn`\ntokens can currently be swapped for." ], - label: 'getAmountOut', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "getAmountOut", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0xb8239ebb', - }, - ], + "selector": "0xb8239ebb" + } + ] }, - storage: { - struct: { - fields: [ + "storage": { + "struct": { + "fields": [ { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000000', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000000', - }, + "root_key": "0x00000000" + } }, - name: '_owner', + "name": "_owner" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000001', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000001", + "ty": 3 + } }, - root_key: '0x00000001', - }, + "root_key": "0x00000001" + } }, - name: '_status', + "name": "_status" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000002', - ty: 4, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000002", + "ty": 4 + } }, - root_key: '0x00000002', - }, + "root_key": "0x00000002" + } }, - name: '_paused', + "name": "_paused" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000003', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000003", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000003', - }, + "root_key": "0x00000003" + } }, - name: 'poolByAsset', + "name": "poolByAsset" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000004', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000004", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000004', - }, + "root_key": "0x00000004" + } }, - name: 'oracleByAsset', - }, + "name": "oracleByAsset" + } ], - name: 'Router', - }, + "name": "Router" + } }, - types: [ + "types": [ { - id: 0, - type: { - def: { - primitive: 'u8', + "id": 0, + "type": { + "def": { + "primitive": "u8" }, - path: ['uint8'], - }, + "path": [ + "uint8" + ] + } }, { - id: 1, - type: { - def: { - array: { - len: 32, - type: 0, - }, - }, - }, + "id": 1, + "type": { + "def": { + "array": { + "len": 32, + "type": 0 + } + } + } }, { - id: 2, - type: { - def: { - composite: { - fields: [ + "id": 2, + "type": { + "def": { + "composite": { + "fields": [ { - type: 1, - }, - ], - }, + "type": 1 + } + ] + } }, - path: ['ink_primitives', 'types', 'AccountId'], - }, + "path": [ + "ink_primitives", + "types", + "AccountId" + ] + } }, { - id: 3, - type: { - def: { - primitive: 'u256', + "id": 3, + "type": { + "def": { + "primitive": "u256" }, - path: ['uint256'], - }, + "path": [ + "uint256" + ] + } }, { - id: 4, - type: { - def: { - primitive: 'bool', + "id": 4, + "type": { + "def": { + "primitive": "bool" }, - path: ['bool'], - }, + "path": [ + "bool" + ] + } }, { - id: 5, - type: { - def: { - sequence: { - type: 3, - }, - }, - }, + "id": 5, + "type": { + "def": { + "sequence": { + "type": 3 + } + } + } }, { - id: 6, - type: { - def: { - sequence: { - type: 2, - }, - }, - }, + "id": 6, + "type": { + "def": { + "sequence": { + "type": 2 + } + } + } }, { - id: 7, - type: { - def: { - primitive: 'u128', + "id": 7, + "type": { + "def": { + "primitive": "u128" }, - path: ['uint128'], - }, + "path": [ + "uint128" + ] + } }, { - id: 8, - type: { - def: { - primitive: 'u64', + "id": 8, + "type": { + "def": { + "primitive": "u64" }, - path: ['uint64'], - }, + "path": [ + "uint64" + ] + } }, { - id: 9, - type: { - def: { - composite: { - fields: [ + "id": 9, + "type": { + "def": { + "composite": { + "fields": [ { - type: 1, - }, - ], - }, + "type": 1 + } + ] + } }, - path: ['ink_primitives', 'types', 'Hash'], - }, + "path": [ + "ink_primitives", + "types", + "Hash" + ] + } }, { - id: 10, - type: { - def: { - primitive: 'str', + "id": 10, + "type": { + "def": { + "primitive": "str" }, - path: ['string'], - }, + "path": [ + "string" + ] + } }, { - id: 11, - type: { - def: { - composite: { - fields: [ + "id": 11, + "type": { + "def": { + "composite": { + "fields": [ { - type: 10, - }, - ], - }, + "type": 10 + } + ] + } }, - path: ['0x08c379a0'], - }, + "path": [ + "0x08c379a0" + ] + } }, { - id: 12, - type: { - def: { - composite: { - fields: [ + "id": 12, + "type": { + "def": { + "composite": { + "fields": [ { - type: 3, - }, - ], - }, + "type": 3 + } + ] + } }, - path: ['0x4e487b71'], - }, + "path": [ + "0x4e487b71" + ] + } }, { - id: 13, - type: { - def: { - variant: { - variants: [ + "id": 13, + "type": { + "def": { + "variant": { + "variants": [ { - fields: [ + "fields": [ { - type: 11, - }, + "type": 11 + } ], - index: 0, - name: 'Error', + "index": 0, + "name": "Error" }, { - fields: [ + "fields": [ { - type: 12, - }, + "type": 12 + } ], - index: 1, - name: 'Panic', - }, - ], - }, + "index": 1, + "name": "Panic" + } + ] + } }, - path: ['SolidityError'], - }, - }, + "path": [ + "SolidityError" + ] + } + } ], - version: '4', + "version": "4" } as const; diff --git a/src/contracts/nabla/SwapPool.ts b/src/contracts/nabla/SwapPool.ts index 1527b9d9..67dc8474 100644 --- a/src/contracts/nabla/SwapPool.ts +++ b/src/contracts/nabla/SwapPool.ts @@ -1,1798 +1,2295 @@ export const swapPoolAbi = { - contract: { - authors: ['unknown'], - description: - 'Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool.', - name: 'SwapPool', - version: '0.0.1', + "contract": { + "authors": [ + "unknown" + ], + "description": "Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool.", + "name": "SwapPool", + "version": "0.0.1" }, - source: { - compiler: 'solang 0.3.2', - hash: '0x480a1345d46a94f8d4a41c5f443c00de2f6d784e8ae1ebc3ea8a8a585990872a', - language: 'Solidity 0.3.2', + "source": { + "compiler": "solang 0.3.2", + "hash": "0xc473b9f6f31f711534a19a44c15935f3e1ffe0f031cf98b3f5701111dc793f49", + "language": "Solidity 0.3.2" }, - spec: { - constructors: [ + "spec": { + "constructors": [ { - args: [ + "args": [ { - label: '_asset', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_asset", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_slippageCurve', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_slippageCurve", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_router', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_router", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_backstop', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_backstop", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_protocolTreasury', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_protocolTreasury", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_name', - type: { - displayName: ['string'], - type: 5, - }, + "label": "_name", + "type": { + "displayName": [ + "string" + ], + "type": 5 + } }, { - label: '_symbol', - type: { - displayName: ['string'], - type: 5, - }, - }, + "label": "_symbol", + "type": { + "displayName": [ + "string" + ], + "type": 5 + } + } ], - default: false, - docs: [''], - label: 'new', - payable: false, - returnType: null, - selector: '0x15c2c342', - }, + "default": false, + "docs": [ + "" + ], + "label": "new", + "payable": false, + "returnType": null, + "selector": "0x15c2c342" + } ], - docs: [ - 'Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool.', + "docs": [ + "Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool." ], - environment: { - accountId: { - displayName: ['AccountId'], - type: 2, - }, - balance: { - displayName: ['Balance'], - type: 13, + "environment": { + "accountId": { + "displayName": [ + "AccountId" + ], + "type": 2 }, - blockNumber: { - displayName: ['BlockNumber'], - type: 14, + "balance": { + "displayName": [ + "Balance" + ], + "type": 13 }, - chainExtension: { - displayName: [], - type: 0, + "blockNumber": { + "displayName": [ + "BlockNumber" + ], + "type": 14 }, - hash: { - displayName: ['Hash'], - type: 15, + "chainExtension": { + "displayName": [], + "type": 0 }, - maxEventTopics: 4, - timestamp: { - displayName: ['Timestamp'], - type: 14, + "hash": { + "displayName": [ + "Hash" + ], + "type": 15 }, + "maxEventTopics": 4, + "timestamp": { + "displayName": [ + "Timestamp" + ], + "type": 14 + } }, - events: [ + "events": [ { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'from', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "from", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: true, - label: 'to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'value', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "value", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "docs": [ + "" ], - docs: [''], - label: 'Transfer', + "label": "Transfer" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: true, - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'value', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "value", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "docs": [ + "" ], - docs: [''], - label: 'Approval', + "label": "Approval" }, { - args: [ + "args": [ { - docs: [], - indexed: false, - label: 'account', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "docs": [], + "indexed": false, + "label": "account", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - docs: [''], - label: 'Paused', + "docs": [ + "" + ], + "label": "Paused" }, { - args: [ + "args": [ { - docs: [], - indexed: false, - label: 'account', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "docs": [], + "indexed": false, + "label": "account", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "docs": [ + "" ], - docs: [''], - label: 'Unpaused', + "label": "Unpaused" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'previousOwner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "previousOwner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: true, - label: 'newOwner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "docs": [], + "indexed": true, + "label": "newOwner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "docs": [ + "" ], - docs: [''], - label: 'OwnershipTransferred', + "label": "OwnershipTransferred" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'sender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "sender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'poolSharesMinted', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "poolSharesMinted", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'amountPrincipleDeposited', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "amountPrincipleDeposited", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - docs: ['emitted on every deposit'], - label: 'Mint', + "docs": [ + "emitted on every deposit" + ], + "label": "Mint" }, { - args: [ + "args": [ { - docs: [], - indexed: true, - label: 'sender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": true, + "label": "sender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'poolSharesBurned', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "poolSharesBurned", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'amountPrincipleWithdrawn', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "amountPrincipleWithdrawn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - docs: [ - 'emitted on every withdrawal special case withdrawal using backstop liquidiity: amountPrincipleWithdrawn = 0', + "docs": [ + "emitted on every withdrawal special case withdrawal using backstop liquidiity: amountPrincipleWithdrawn = 0" ], - label: 'Burn', + "label": "Burn" }, { - args: [ + "args": [ { - docs: [], - indexed: false, - label: 'recipient', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "docs": [], + "indexed": false, + "label": "recipient", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - docs: [], - indexed: false, - label: 'amountSwapTokens', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "amountSwapTokens", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - docs: [ - 'emitted when a backstop pool LP withdraws liquidity from swap pool only possible if swap pool coverage ratio remains >= 100%', + "docs": [ + "emitted when a backstop pool LP withdraws liquidity from swap pool only possible if swap pool coverage ratio remains >= 100%" ], - label: 'BackstopDrain', + "label": "BackstopDrain" }, { - args: [ + "args": [ { - docs: [], - indexed: false, - label: 'lpFees', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "lpFees", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'backstopFees', - type: { - displayName: ['uint256'], - type: 3, - }, + "docs": [], + "indexed": false, + "label": "backstopFees", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - docs: [], - indexed: false, - label: 'protocolFees', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "docs": [], + "indexed": false, + "label": "protocolFees", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - docs: ['Tracks the exact amounts of individual fees paid during a swap'], - label: 'ChargedSwapFees', - }, + "docs": [ + "Tracks the exact amounts of individual fees paid during a swap" + ], + "label": "ChargedSwapFees" + } ], - lang_error: { - displayName: ['SolidityError'], - type: 18, + "lang_error": { + "displayName": [ + "SolidityError" + ], + "type": 18 }, - messages: [ - { - args: [], - default: false, - docs: [''], - label: 'name', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 5, - }, - selector: '0x06fdde03', - }, + "messages": [ { - args: [], - default: false, - docs: [''], - label: 'symbol', - mutates: false, - payable: false, - returnType: { - displayName: ['string'], - type: 5, - }, - selector: '0x95d89b41', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "name", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "string" + ], + "type": 5 + }, + "selector": "0x06fdde03" }, { - args: [], - default: false, - docs: [''], - label: 'decimals', - mutates: false, - payable: false, - returnType: { - displayName: ['uint8'], - type: 0, - }, - selector: '0x313ce567', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "symbol", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "string" + ], + "type": 5 + }, + "selector": "0x95d89b41" }, { - args: [], - default: false, - docs: [''], - label: 'totalSupply', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, - }, - selector: '0x18160ddd', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "totalSupply", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 + }, + "selector": "0x18160ddd" }, { - args: [ + "args": [ { - label: 'account', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "account", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'balanceOf', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "balanceOf", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x70a08231', + "selector": "0x70a08231" }, { - args: [ + "args": [ { - label: 'to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'transfer', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "label": "transfer", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0xa9059cbb', + "selector": "0xa9059cbb" }, { - args: [ + "args": [ { - label: 'owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'allowance', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "default": false, + "docs": [ + "" + ], + "label": "allowance", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0xdd62ed3e', + "selector": "0xdd62ed3e" }, { - args: [ + "args": [ { - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'approve', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "label": "approve", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0x095ea7b3', + "selector": "0x095ea7b3" }, { - args: [ + "args": [ { - label: 'from', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "from", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'to', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "to", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'transferFrom', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "label": "transferFrom", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0x23b872dd', + "selector": "0x23b872dd" }, { - args: [ + "args": [ { - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'addedValue', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "addedValue", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "" ], - default: false, - docs: [''], - label: 'increaseAllowance', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "label": "increaseAllowance", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0x39509351', + "selector": "0x39509351" }, { - args: [ + "args": [ { - label: 'spender', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "spender", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: 'subtractedValue', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "subtractedValue", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [''], - label: 'decreaseAllowance', - mutates: true, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, + "default": false, + "docs": [ + "" + ], + "label": "decreaseAllowance", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 }, - selector: '0xa457c2d7', + "selector": "0xa457c2d7" }, { - args: [], - default: false, - docs: [''], - label: 'paused', - mutates: false, - payable: false, - returnType: { - displayName: ['bool'], - type: 4, - }, - selector: '0x5c975abb', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "paused", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "bool" + ], + "type": 4 + }, + "selector": "0x5c975abb" }, { - args: [], - default: false, - docs: [''], - label: 'owner', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - selector: '0x8da5cb5b', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "owner", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + }, + "selector": "0x8da5cb5b" }, { - args: [], - default: false, - docs: [''], - label: 'renounceOwnership', - mutates: true, - payable: false, - returnType: null, - selector: '0x715018a6', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "renounceOwnership", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0x715018a6" }, { - args: [ + "args": [ { - label: 'newOwner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "newOwner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [''], - label: 'transferOwnership', - mutates: true, - payable: false, - returnType: null, - selector: '0xf2fde38b', + "default": false, + "docs": [ + "" + ], + "label": "transferOwnership", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0xf2fde38b" }, { - args: [], - default: false, - docs: [''], - label: 'poolCap', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, - }, - selector: '0xb954dc57', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "poolCap", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 + }, + "selector": "0xb954dc57" + }, + { + "args": [], + "default": false, + "docs": [ + "Returns the pooled token's address" + ], + "label": "asset", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + }, + "selector": "0x38d52e0f" + }, + { + "args": [], + "default": false, + "docs": [ + "Returns the decimals of the pool asset" + ], + "label": "assetDecimals", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint8" + ], + "type": 0 + }, + "selector": "0xc2d41601" + }, + { + "args": [], + "default": false, + "docs": [ + "Returns the decimals of the LP token of this pool\nThis is defined to have the same decimals as the pool token itself\nin order to greatly simplify calculations that involve pool token amounts\nand LP token amounts" + ], + "label": "decimals", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint8" + ], + "type": 0 + }, + "selector": "0x313ce567" }, { - args: [], - default: false, - docs: ["Returns the pooled token's address"], - label: 'asset', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - selector: '0x38d52e0f', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "totalLiabilities", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 + }, + "selector": "0xf73579a9" }, { - args: [], - default: false, - docs: ['Returns the decimals of the pool asset'], - label: 'assetDecimals', - mutates: false, - payable: false, - returnType: { - displayName: ['uint8'], - type: 0, - }, - selector: '0xc2d41601', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "reserve", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 + }, + "selector": "0xcd3293de" }, { - args: [], - default: false, - docs: [''], - label: 'totalLiabilities', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, - }, - selector: '0xf73579a9', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "reserveWithSlippage", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 + }, + "selector": "0x0b09d91e" }, { - args: [], - default: false, - docs: [''], - label: 'reserve', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, - }, - selector: '0xcd3293de', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "insuranceWithdrawalTimelock", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 + }, + "selector": "0x0d3a7fd4" }, { - args: [], - default: false, - docs: [''], - label: 'reserveWithSlippage', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, - }, - selector: '0x0b09d91e', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "protocolTreasury", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + }, + "selector": "0x803db96d" }, { - args: [], - default: false, - docs: [''], - label: 'insuranceWithdrawalTimelock', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, - }, - selector: '0x0d3a7fd4', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "backstop", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + }, + "selector": "0x7dea1817" }, { - args: [], - default: false, - docs: [''], - label: 'protocolTreasury', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - selector: '0x803db96d', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "router", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + }, + "selector": "0xf887ea40" }, { - args: [], - default: false, - docs: [''], - label: 'backstop', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - selector: '0x7dea1817', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "slippageCurve", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + }, + "selector": "0xebe26b9e" }, { - args: [], - default: false, - docs: [''], - label: 'router', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - selector: '0xf887ea40', + "args": [], + "default": false, + "docs": [ + "" + ], + "label": "maxCoverageRatioForSwapIn", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 + }, + "selector": "0xb2f3447a" }, { - args: [], - default: false, - docs: [''], - label: 'slippageCurve', - mutates: false, - payable: false, - returnType: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - selector: '0xebe26b9e', + "args": [ + { + "label": "_durationInBlocks", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "Set new insurance withdrawal time lock. Can only be called by the owner" + ], + "label": "setInsuranceWithdrawalTimelock", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0xcfcc238d" }, { - args: [ + "args": [ { - label: '_durationInBlocks', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_maxTokens", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ['Set new insurance withdrawal time lock. Can only be called by the owner'], - label: 'setInsuranceWithdrawalTimelock', - mutates: true, - payable: false, - returnType: null, - selector: '0xcfcc238d', + "default": false, + "docs": [ + "Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits." + ], + "label": "setPoolCap", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0xd835f535" }, { - args: [ + "args": [ { - label: '_maxTokens', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_maxCoverageRatio", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [ - 'Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits.', + "default": false, + "docs": [ + "Set new upper limit of pool coverage ratio (reserves / liabilities) for swap-in" ], - label: 'setPoolCap', - mutates: true, - payable: false, - returnType: null, - selector: '0xd835f535', + "label": "setMaxCoverageRatioForSwapIn", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0x0668d07c" }, { - args: [ + "args": [ { - label: '_lpFeeBps', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_lpFee", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_backstopFeeBps', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_backstopFee", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_protocolFeeBps', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_protocolFee", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ['Set swap fees (applied when swapping funds out of the pool)'], - label: 'setSwapFees', - mutates: true, - payable: false, - returnType: null, - selector: '0xeb43434e', + "default": false, + "docs": [ + "Set swap fees (applied when swapping funds out of the pool)" + ], + "label": "setSwapFees", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0xeb43434e" }, { - args: [], - default: false, - docs: ['Return the configured swap fees for this pool'], - label: 'swapFees', - mutates: false, - payable: false, - returnType: { - displayName: ['SwapPool', 'swapFees', 'return_type'], - type: 8, - }, - selector: '0xb9ccf21d', + "args": [], + "default": false, + "docs": [ + "Return the configured swap fees for this pool" + ], + "label": "swapFees", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "SwapPool", + "swapFees", + "return_type" + ], + "type": 8 + }, + "selector": "0xb9ccf21d" }, { - args: [ + "args": [ { - label: '_depositAmount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_depositAmount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ['Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0'], - label: 'deposit', - mutates: true, - payable: false, - returnType: { - displayName: ['SwapPool', 'deposit', 'return_type'], - type: 10, - }, - selector: '0xb6b55f25', + "default": false, + "docs": [ + "Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0" + ], + "label": "deposit", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "SwapPool", + "deposit", + "return_type" + ], + "type": 10 + }, + "selector": "0xb6b55f25" }, { - args: [ + "args": [ { - label: '_sharesToBurn', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_sharesToBurn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_minimumAmount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_minimumAmount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ['Withdraws liquidity amount of asset ensuring minimum amount required'], - label: 'withdraw', - mutates: true, - payable: false, - returnType: { - displayName: ['SwapPool', 'withdraw', 'return_type'], - type: 11, - }, - selector: '0x441a3e70', + "default": false, + "docs": [ + "Withdraws liquidity amount of asset ensuring minimum amount required" + ], + "label": "withdraw", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "SwapPool", + "withdraw", + "return_type" + ], + "type": 11 + }, + "selector": "0x441a3e70" }, { - args: [ + "args": [ { - label: '_owner', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, + "label": "_owner", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } }, { - label: '_sharesToBurn', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_sharesToBurn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: [ - 'Burns LP tokens of owner, will get compensated using backstop liquidity Can only be invoked by backstop pool, disabled when pool is paused', + "default": false, + "docs": [ + "Burns LP tokens of owner, will get compensated using backstop liquidity Can only be invoked by backstop pool, disabled when pool is paused" ], - label: 'backstopBurn', - mutates: true, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "backstopBurn", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0xe45f37bd', + "selector": "0xe45f37bd" }, { - args: [ + "args": [ { - label: '_amount', - type: { - displayName: ['uint256'], - type: 3, - }, + "label": "_amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } }, { - label: '_recipient', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "_recipient", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } ], - default: false, - docs: [ - "For backstop pool to withdraw liquidity if swap pool's coverage ratio > 100% Can only be invoked by backstop pool", + "default": false, + "docs": [ + "For backstop pool to withdraw liquidity if swap pool's coverage ratio > 100% Can only be invoked by backstop pool" ], - label: 'backstopDrain', - mutates: true, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "backstopDrain", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0xc2cb15de', + "selector": "0xc2cb15de" }, { - args: [ + "args": [ { - label: '_amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ['Get called by Router to deposit an amount of pool asset Can only be called by Router'], - label: 'swapIntoFromRouter', - mutates: true, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "default": false, + "docs": [ + "Get called by Router to deposit an amount of pool asset Can only be called by Router" + ], + "label": "swapIntoFromRouter", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x4d8ea83f', + "selector": "0x4d8ea83f" }, { - args: [ + "args": [ { - label: '_amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "Get a quote for the effective amount of tokens for a swap into" ], - default: false, - docs: ['Get a quote for the effective amount of tokens for a swap into'], - label: 'quoteSwapInto', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "quoteSwapInto", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x3c945248', + "selector": "0x3c945248" }, { - args: [ + "args": [ { - label: '_amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } + ], + "default": false, + "docs": [ + "get called by Router to withdraw amount of pool asset Can only be called by Router" ], - default: false, - docs: ['get called by Router to withdraw amount of pool asset Can only be called by Router'], - label: 'swapOutFromRouter', - mutates: true, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "swapOutFromRouter", + "mutates": true, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x5f79d44f', + "selector": "0x5f79d44f" }, { - args: [ + "args": [ { - label: '_amount', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_amount", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ['Get a quote for the effective amount of tokens, incl. slippage and fees'], - label: 'quoteSwapOut', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "default": false, + "docs": [ + "Get a quote for the effective amount of tokens, incl. slippage and fees" + ], + "label": "quoteSwapOut", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x8735c246', + "selector": "0x8735c246" }, { - args: [], - default: false, - docs: ['Pause deposits and swaps'], - label: 'pause', - mutates: true, - payable: false, - returnType: null, - selector: '0x8456cb59', + "args": [], + "default": false, + "docs": [ + "Pause deposits and swaps" + ], + "label": "pause", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0x8456cb59" }, { - args: [], - default: false, - docs: ['Resume deposits and swaps'], - label: 'unpause', - mutates: true, - payable: false, - returnType: null, - selector: '0x3f4ba83a', + "args": [], + "default": false, + "docs": [ + "Resume deposits and swaps" + ], + "label": "unpause", + "mutates": true, + "payable": false, + "returnType": null, + "selector": "0x3f4ba83a" }, { - args: [], - default: false, - docs: ['returns pool coverage ratio'], - label: 'coverage', - mutates: false, - payable: false, - returnType: { - displayName: ['SwapPool', 'coverage', 'return_type'], - type: 12, - }, - selector: '0xee8f6a0e', + "args": [], + "default": false, + "docs": [ + "returns pool coverage ratio" + ], + "label": "coverage", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "SwapPool", + "coverage", + "return_type" + ], + "type": 12 + }, + "selector": "0xee8f6a0e" }, { - args: [], - default: false, - docs: [ - 'Computes the excess liquidity that forms that valuation of the backstop pool is defined as b + C - B - L where - b is reserve - C is the amount of pool tokens in the pool - B is reserveWithSlippage - L is totalLiabilities', - ], - label: 'getExcessLiquidity', - mutates: false, - payable: false, - returnType: { - displayName: ['int256'], - type: 9, - }, - selector: '0xace0f0d5', + "args": [], + "default": false, + "docs": [ + "Computes the excess liquidity that forms that valuation of the backstop pool is defined as b + C - B - L where - b is reserve - C is the amount of `asset()` tokens in the pool - B is reserveWithSlippage - L is totalLiabilities The excess liquidity is a fixed point number using the decimals of this pool" + ], + "label": "getExcessLiquidity", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "int256" + ], + "type": 9 + }, + "selector": "0xace0f0d5" }, { - args: [ + "args": [ { - label: '_liquidityProvider', - type: { - displayName: ['ink_primitives', 'types', 'AccountId'], - type: 2, - }, - }, + "label": "_liquidityProvider", + "type": { + "displayName": [ + "ink_primitives", + "types", + "AccountId" + ], + "type": 2 + } + } + ], + "default": false, + "docs": [ + "Return the earliest block no that insurance withdrawals are possible." ], - default: false, - docs: ['Return the earliest block no that insurance withdrawals are possible.'], - label: 'insuranceWithdrawalUnlock', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, + "label": "insuranceWithdrawalUnlock", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 }, - selector: '0x5c6f4279', + "selector": "0x5c6f4279" }, { - args: [ + "args": [ { - label: '_sharesToBurn', - type: { - displayName: ['uint256'], - type: 3, - }, - }, + "label": "_sharesToBurn", + "type": { + "displayName": [ + "uint256" + ], + "type": 3 + } + } ], - default: false, - docs: ['Returns the worth of an amount of pool shares (LP tokens) in underlying principle'], - label: 'sharesTargetWorth', - mutates: false, - payable: false, - returnType: { - displayName: ['uint256'], - type: 3, - }, - selector: '0xcc045745', - }, - ], + "default": false, + "docs": [ + "Returns the worth of an amount of pool shares (LP tokens) in underlying principle" + ], + "label": "sharesTargetWorth", + "mutates": false, + "payable": false, + "returnType": { + "displayName": [ + "uint256" + ], + "type": 3 + }, + "selector": "0xcc045745" + } + ] }, - storage: { - struct: { - fields: [ + "storage": { + "struct": { + "fields": [ { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000000', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000000", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000000', - }, + "root_key": "0x00000000" + } }, - name: '_owner', + "name": "_owner" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000001', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000001", + "ty": 3 + } }, - root_key: '0x00000001', - }, + "root_key": "0x00000001" + } }, - name: '_status', + "name": "_status" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000002', - ty: 4, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000002", + "ty": 4 + } }, - root_key: '0x00000002', - }, + "root_key": "0x00000002" + } }, - name: '_paused', + "name": "_paused" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000003', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000003", + "ty": 3 + } }, - root_key: '0x00000003', - }, + "root_key": "0x00000003" + } }, - name: '_balances', + "name": "_balances" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000004', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000004", + "ty": 3 + } }, - root_key: '0x00000004', - }, + "root_key": "0x00000004" + } }, - name: '_allowances', + "name": "_allowances" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000005', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000005", + "ty": 3 + } }, - root_key: '0x00000005', - }, + "root_key": "0x00000005" + } }, - name: '_totalSupply', + "name": "_totalSupply" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000006', - ty: 5, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000006", + "ty": 5 + } }, - root_key: '0x00000006', - }, + "root_key": "0x00000006" + } }, - name: '_name', + "name": "_name" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000007', - ty: 5, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000007", + "ty": 5 + } }, - root_key: '0x00000007', - }, + "root_key": "0x00000007" + } }, - name: '_symbol', + "name": "_symbol" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000008', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000008", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000008', - }, + "root_key": "0x00000008" + } }, - name: 'poolAsset', + "name": "poolAsset" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000009', - ty: 0, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000009", + "ty": 0 + } }, - root_key: '0x00000009', - }, + "root_key": "0x00000009" + } }, - name: 'poolAssetDecimals', + "name": "poolAssetDecimals" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000a', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x0000000a", + "ty": 3 + } }, - root_key: '0x0000000a', - }, + "root_key": "0x0000000a" + } }, - name: 'poolCap', + "name": "poolCap" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000b', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x0000000b", + "ty": 3 + } }, - root_key: '0x0000000b', - }, + "root_key": "0x0000000b" + } }, - name: 'totalLiabilities', + "name": "totalLiabilities" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000c', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x0000000c", + "ty": 3 + } }, - root_key: '0x0000000c', - }, + "root_key": "0x0000000c" + } }, - name: 'reserve', + "name": "reserve" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000d', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x0000000d", + "ty": 3 + } }, - root_key: '0x0000000d', - }, + "root_key": "0x0000000d" + } }, - name: 'reserveWithSlippage', + "name": "reserveWithSlippage" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x0000000e', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x0000000e", + "ty": 3 + } }, - root_key: '0x0000000e', - }, + "root_key": "0x0000000e" + } }, - name: 'insuranceWithdrawalTimelock', + "name": "insuranceWithdrawalTimelock" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x0000000f', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x0000000f", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x0000000f', - }, + "root_key": "0x0000000f" + } }, - name: 'protocolTreasury', + "name": "protocolTreasury" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000010', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000010", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000010', - }, + "root_key": "0x00000010" + } }, - name: 'backstop', + "name": "backstop" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000011', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000011", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000011', - }, + "root_key": "0x00000011" + } }, - name: 'router', + "name": "router" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000012', - ty: 1, - }, + "layout": { + "leaf": { + "key": "0x00000012", + "ty": 1 + } }, - name: '', - }, + "name": "" + } ], - name: 'AccountId', - }, + "name": "AccountId" + } }, - root_key: '0x00000012', - }, + "root_key": "0x00000012" + } }, - name: 'slippageCurve', + "name": "slippageCurve" }, { - layout: { - root: { - layout: { - leaf: { - key: '0x00000013', - ty: 3, - }, + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000013", + "ty": 3 + } }, - root_key: '0x00000013', - }, + "root_key": "0x00000013" + } }, - name: 'latestDepositAtBlockNo', + "name": "latestDepositAtBlockNo" }, { - layout: { - root: { - layout: { - struct: { - fields: [ + "layout": { + "root": { + "layout": { + "struct": { + "fields": [ { - layout: { - leaf: { - key: '0x00000014', - ty: 6, - }, + "layout": { + "leaf": { + "key": "0x00000014", + "ty": 6 + } }, - name: 'lpFeeBps', + "name": "lpFee" }, { - layout: { - leaf: { - key: '0x00000014', - ty: 6, - }, + "layout": { + "leaf": { + "key": "0x00000014", + "ty": 6 + } }, - name: 'backstopFeeBps', + "name": "backstopFee" }, { - layout: { - leaf: { - key: '0x00000014', - ty: 6, - }, + "layout": { + "leaf": { + "key": "0x00000014", + "ty": 6 + } }, - name: 'protocolFeeBps', - }, + "name": "protocolFee" + } ], - name: 'SwapFees', - }, + "name": "SwapFees" + } }, - root_key: '0x00000014', - }, + "root_key": "0x00000014" + } }, - name: 'swapFeeConfig', + "name": "swapFeeConfig" }, + { + "layout": { + "root": { + "layout": { + "leaf": { + "key": "0x00000017", + "ty": 3 + } + }, + "root_key": "0x00000017" + } + }, + "name": "maxCoverageRatioForSwapIn" + } ], - name: 'SwapPool', - }, + "name": "SwapPool" + } }, - types: [ + "types": [ { - id: 0, - type: { - def: { - primitive: 'u8', - }, - path: ['uint8'], - }, + "id": 0, + "type": { + "def": { + "primitive": "u8" + }, + "path": [ + "uint8" + ] + } }, { - id: 1, - type: { - def: { - array: { - len: 32, - type: 0, - }, - }, - }, + "id": 1, + "type": { + "def": { + "array": { + "len": 32, + "type": 0 + } + } + } }, { - id: 2, - type: { - def: { - composite: { - fields: [ + "id": 2, + "type": { + "def": { + "composite": { + "fields": [ { - type: 1, - }, - ], - }, - }, - path: ['ink_primitives', 'types', 'AccountId'], - }, + "type": 1 + } + ] + } + }, + "path": [ + "ink_primitives", + "types", + "AccountId" + ] + } }, { - id: 3, - type: { - def: { - primitive: 'u256', - }, - path: ['uint256'], - }, + "id": 3, + "type": { + "def": { + "primitive": "u256" + }, + "path": [ + "uint256" + ] + } }, { - id: 4, - type: { - def: { - primitive: 'bool', - }, - path: ['bool'], - }, + "id": 4, + "type": { + "def": { + "primitive": "bool" + }, + "path": [ + "bool" + ] + } }, { - id: 5, - type: { - def: { - primitive: 'str', - }, - path: ['string'], - }, + "id": 5, + "type": { + "def": { + "primitive": "str" + }, + "path": [ + "string" + ] + } }, { - id: 6, - type: { - def: { - primitive: 'u32', - }, - path: ['uint32'], - }, + "id": 6, + "type": { + "def": { + "primitive": "u32" + }, + "path": [ + "uint32" + ] + } }, { - id: 7, - type: { - def: { - composite: { - fields: [ + "id": 7, + "type": { + "def": { + "composite": { + "fields": [ { - name: 'lpFeeBps', - type: 6, + "name": "lpFee", + "type": 6 }, { - name: 'backstopFeeBps', - type: 6, + "name": "backstopFee", + "type": 6 }, { - name: 'protocolFeeBps', - type: 6, - }, - ], - }, - }, - path: ['SwapFees'], - }, + "name": "protocolFee", + "type": 6 + } + ] + } + }, + "path": [ + "SwapFees" + ] + } }, { - id: 8, - type: { - def: { - tuple: [3, 3, 3], - }, - path: ['SwapPool', 'swapFees', 'return_type'], - }, + "id": 8, + "type": { + "def": { + "tuple": [ + 3, + 3, + 3 + ] + }, + "path": [ + "SwapPool", + "swapFees", + "return_type" + ] + } }, { - id: 9, - type: { - def: { - primitive: 'i256', - }, - path: ['int256'], - }, + "id": 9, + "type": { + "def": { + "primitive": "i256" + }, + "path": [ + "int256" + ] + } }, { - id: 10, - type: { - def: { - tuple: [3, 9], - }, - path: ['SwapPool', 'deposit', 'return_type'], - }, + "id": 10, + "type": { + "def": { + "tuple": [ + 3, + 9 + ] + }, + "path": [ + "SwapPool", + "deposit", + "return_type" + ] + } }, { - id: 11, - type: { - def: { - tuple: [3, 9], - }, - path: ['SwapPool', 'withdraw', 'return_type'], - }, + "id": 11, + "type": { + "def": { + "tuple": [ + 3, + 9 + ] + }, + "path": [ + "SwapPool", + "withdraw", + "return_type" + ] + } }, { - id: 12, - type: { - def: { - tuple: [3, 3], - }, - path: ['SwapPool', 'coverage', 'return_type'], - }, + "id": 12, + "type": { + "def": { + "tuple": [ + 3, + 3 + ] + }, + "path": [ + "SwapPool", + "coverage", + "return_type" + ] + } }, { - id: 13, - type: { - def: { - primitive: 'u128', - }, - path: ['uint128'], - }, + "id": 13, + "type": { + "def": { + "primitive": "u128" + }, + "path": [ + "uint128" + ] + } }, { - id: 14, - type: { - def: { - primitive: 'u64', - }, - path: ['uint64'], - }, + "id": 14, + "type": { + "def": { + "primitive": "u64" + }, + "path": [ + "uint64" + ] + } }, { - id: 15, - type: { - def: { - composite: { - fields: [ + "id": 15, + "type": { + "def": { + "composite": { + "fields": [ { - type: 1, - }, - ], - }, - }, - path: ['ink_primitives', 'types', 'Hash'], - }, + "type": 1 + } + ] + } + }, + "path": [ + "ink_primitives", + "types", + "Hash" + ] + } }, { - id: 16, - type: { - def: { - composite: { - fields: [ + "id": 16, + "type": { + "def": { + "composite": { + "fields": [ { - type: 5, - }, - ], - }, - }, - path: ['0x08c379a0'], - }, + "type": 5 + } + ] + } + }, + "path": [ + "0x08c379a0" + ] + } }, { - id: 17, - type: { - def: { - composite: { - fields: [ + "id": 17, + "type": { + "def": { + "composite": { + "fields": [ { - type: 3, - }, - ], - }, - }, - path: ['0x4e487b71'], - }, + "type": 3 + } + ] + } + }, + "path": [ + "0x4e487b71" + ] + } }, { - id: 18, - type: { - def: { - variant: { - variants: [ + "id": 18, + "type": { + "def": { + "variant": { + "variants": [ { - fields: [ + "fields": [ { - type: 16, - }, + "type": 16 + } ], - index: 0, - name: 'Error', + "index": 0, + "name": "Error" }, { - fields: [ + "fields": [ { - type: 17, - }, + "type": 17 + } ], - index: 1, - name: 'Panic', - }, - ], - }, - }, - path: ['SolidityError'], - }, - }, + "index": 1, + "name": "Panic" + } + ] + } + }, + "path": [ + "SolidityError" + ] + } + } ], - version: '4', + "version": "4" } as const; diff --git a/src/helpers/__tests__/calc.test.ts b/src/helpers/__tests__/calc.test.ts index 5a1e6890..35c19a67 100644 --- a/src/helpers/__tests__/calc.test.ts +++ b/src/helpers/__tests__/calc.test.ts @@ -1,66 +1,71 @@ import Big from 'big.js'; -import { defaultDecimals } from '../../config/apps/nabla'; import { decimalToNative } from '../../shared/parseNumbers'; import * as helpers from '../calc'; +import { NablaInstanceSwapPool } from '../../hooks/nabla/useNablaInstance'; -const native1000 = decimalToNative(1000, defaultDecimals).toString(); +const DEFAULT_DECIMALS = 12; +const native1000 = decimalToNative(1000).toString(); describe('calc', () => { it('should return correct withdraw amount from calcAvailablePoolWithdraw', () => { expect( helpers.calcAvailablePoolWithdraw({ - selectedPool: { - liabilities: undefined, - reserves: native1000, - }, - shares: BigInt(native1000), - deposit: BigInt(native1000), - bpPrice: BigInt(decimalToNative(1, defaultDecimals).toString()), - spPrice: BigInt(decimalToNative(2, defaultDecimals).toString()), - decimals: defaultDecimals, + selectedSwapPool: { + totalLiabilities: undefined, + reserve: native1000, + } as unknown as NablaInstanceSwapPool, + sharesWorthNativeAmount: BigInt(native1000), + backstopLpDecimalAmount: 1000, + bpPrice: BigInt(decimalToNative(1).toString()), + spPrice: BigInt(decimalToNative(2).toString()), + backstopPoolTokenDecimals: DEFAULT_DECIMALS, + swapPoolTokenDecimals: DEFAULT_DECIMALS, }), ).toBe(undefined); expect( helpers.calcAvailablePoolWithdraw({ - selectedPool: { - liabilities: native1000, - reserves: native1000, - }, - shares: BigInt(native1000), - deposit: BigInt(native1000), - bpPrice: BigInt(decimalToNative(1, defaultDecimals).toString()), - spPrice: BigInt(decimalToNative(2, defaultDecimals).toString()), - decimals: defaultDecimals, + selectedSwapPool: { + totalLiabilities: native1000, + reserve: native1000, + } as unknown as NablaInstanceSwapPool, + sharesWorthNativeAmount: BigInt(native1000), + backstopLpDecimalAmount: 1000, + bpPrice: BigInt(decimalToNative(1).toString()), + spPrice: BigInt(decimalToNative(2).toString()), + backstopPoolTokenDecimals: DEFAULT_DECIMALS, + swapPoolTokenDecimals: DEFAULT_DECIMALS, }), ).toEqual(Big(0)); expect( helpers.calcAvailablePoolWithdraw({ - selectedPool: { - liabilities: native1000, - reserves: decimalToNative(1200, defaultDecimals).toString(), - }, - shares: BigInt(native1000), - deposit: BigInt(native1000), - bpPrice: BigInt(decimalToNative(1.1, defaultDecimals).toString()), - spPrice: BigInt(decimalToNative(2.2, defaultDecimals).toString()), - decimals: defaultDecimals, + selectedSwapPool: { + totalLiabilities: native1000, + reserve: decimalToNative(1200).toString(), + } as unknown as NablaInstanceSwapPool, + sharesWorthNativeAmount: BigInt(native1000), + backstopLpDecimalAmount: 1000, + bpPrice: BigInt(decimalToNative(1.1).toString()), + spPrice: BigInt(decimalToNative(2.2).toString()), + backstopPoolTokenDecimals: DEFAULT_DECIMALS, + swapPoolTokenDecimals: DEFAULT_DECIMALS, }), - ).toEqual(decimalToNative(400, defaultDecimals)); + ).toEqual(decimalToNative(400)); expect( helpers.calcAvailablePoolWithdraw({ - selectedPool: { - liabilities: native1000, - reserves: decimalToNative(5200, defaultDecimals).toString(), - }, - shares: BigInt(native1000), - deposit: BigInt(native1000), - bpPrice: BigInt(decimalToNative(1.1, defaultDecimals).toString()), - spPrice: BigInt(decimalToNative(2.2, defaultDecimals).toString()), - decimals: defaultDecimals, + selectedSwapPool: { + totalLiabilities: native1000, + reserve: decimalToNative(5200).toString(), + } as unknown as NablaInstanceSwapPool, + sharesWorthNativeAmount: BigInt(native1000), + backstopLpDecimalAmount: 1000, + bpPrice: BigInt(decimalToNative(1.1).toString()), + spPrice: BigInt(decimalToNative(2.2).toString()), + backstopPoolTokenDecimals: DEFAULT_DECIMALS, + swapPoolTokenDecimals: DEFAULT_DECIMALS, }), - ).toEqual(decimalToNative(1000, defaultDecimals)); + ).toEqual(decimalToNative(1000)); }); }); diff --git a/src/helpers/calc.ts b/src/helpers/calc.ts index 3d9abfef..26b95348 100644 --- a/src/helpers/calc.ts +++ b/src/helpers/calc.ts @@ -1,5 +1,6 @@ import Big from 'big.js'; -import { decimalToNative, nativeToDecimal, roundNumber } from '../shared/parseNumbers'; +import { rawToDecimal, roundNumber } from '../shared/parseNumbers'; +import { NablaInstanceSwapPool } from '../hooks/nabla/useNablaInstance'; export type Percent = number; @@ -30,39 +31,55 @@ export const calcAPR = (dailyFees: number, tvl: number, round = 2) => roundNumber(((dailyFees * 365) / tvl) * 100, round); /** Calculate pool surplus from reserves and liabilities */ -export const calcPoolSurplus = (reserves = '0', liabilities = '0', min0 = true) => { - const surplus = BigInt(reserves) - BigInt(liabilities); - return !min0 || surplus > 0 ? surplus : BigInt(0); -}; - -/** Calculate pool surplus from reserves and liabilities */ -export const getPoolSurplus = (pool: { reserves?: string; liabilities?: string }, min0 = true) => - pool.reserves && pool.liabilities ? calcPoolSurplus(pool.reserves, pool.liabilities, min0) : undefined; +export function getPoolSurplusNativeAmount(pool: NablaInstanceSwapPool) { + const surplus = BigInt(pool.reserve) - BigInt(pool.totalLiabilities); + return surplus > 0n ? surplus : 0n; +} /** Calculate max withdraw value based on deposit and pool surplus */ type CAPWProps = { - selectedPool: { reserves?: string; liabilities?: string }; - shares: bigint | undefined; - deposit: bigint | undefined; + selectedSwapPool: NablaInstanceSwapPool; + backstopLpDecimalAmount: number; + sharesWorthNativeAmount: bigint; bpPrice: bigint | undefined; spPrice: bigint | undefined; - decimals: number; + backstopPoolTokenDecimals: number; + swapPoolTokenDecimals: number; }; -export const calcAvailablePoolWithdraw = ({ selectedPool, shares, deposit, bpPrice, spPrice, decimals }: CAPWProps) => { - const surplus = getPoolSurplus(selectedPool); - if (surplus === undefined || !bpPrice || !spPrice || !shares || !deposit) { + +// TODO (Torsten) I don't understand whether this calculation really makes sense +export const calcAvailablePoolWithdraw = ({ + selectedSwapPool, + backstopLpDecimalAmount, + sharesWorthNativeAmount, + bpPrice, + spPrice, + backstopPoolTokenDecimals, + swapPoolTokenDecimals, +}: CAPWProps) => { + const surplusNativeAmount = getPoolSurplusNativeAmount(selectedSwapPool); + if (!bpPrice || !spPrice || !sharesWorthNativeAmount || !backstopLpDecimalAmount) { return undefined; } - const surplusVal = Big(nativeToDecimal(surplus.toString(), decimals).toString()); - if (surplusVal.lte(0)) return Big(0); - const depositVal = Big(nativeToDecimal(deposit.toString(), decimals)); - const sharesVal = Big(nativeToDecimal(shares.toString(), decimals)); - const spPriceVal = Big(nativeToDecimal(spPrice.toString(), decimals)); - const bpPriceVal = Big(nativeToDecimal(bpPrice.toString(), decimals)); - const spMax = surplusVal.mul(spPriceVal); - const bpMax = sharesVal.mul(bpPriceVal); + const surplusDecimalAmount = Big(rawToDecimal(surplusNativeAmount.toString(), swapPoolTokenDecimals).toString()); + if (surplusDecimalAmount.lte(0)) return Big(0); + + const sharesValueDecimalAmount = Big(rawToDecimal(sharesWorthNativeAmount.toString(), backstopPoolTokenDecimals)); + const spPriceVal = new Big(spPrice.toString()); + const bpPriceVal = new Big(bpPrice.toString()); + + const spMax = surplusDecimalAmount.mul(spPriceVal); + const bpMax = sharesValueDecimalAmount.mul(bpPriceVal); + const maxValue = bpMax.gt(spMax) ? spMax : bpMax; - const maxLP = maxValue.div(bpPriceVal); - const final = maxLP.gt(depositVal) ? depositVal : maxLP; - return decimalToNative(final.toString(), decimals); + const maxBackstopPoolTokensDecimalAmount = maxValue.div(bpPriceVal); + + const depositedBackstopLpTokenDecimalAmount = Big(backstopLpDecimalAmount); + const redeemableBackstopLpTokensDecimalAmount = maxBackstopPoolTokensDecimalAmount.gt( + depositedBackstopLpTokenDecimalAmount, + ) + ? depositedBackstopLpTokenDecimalAmount + : maxBackstopPoolTokensDecimalAmount; + + return redeemableBackstopLpTokensDecimalAmount; }; diff --git a/src/helpers/function.ts b/src/helpers/function.ts index d1092564..0faf41f2 100644 --- a/src/helpers/function.ts +++ b/src/helpers/function.ts @@ -2,7 +2,10 @@ export const debounce = (func: (...args: T) => any, timeout = 300) => { let timer: NodeJS.Timeout | undefined; return (...args: T) => { - clearTimeout(timer); + if (timer !== undefined) { + clearTimeout(timer); + } + timer = setTimeout(() => { func(...args); }, timeout); diff --git a/src/hooks/nabla/mock.ts b/src/hooks/nabla/mock.ts deleted file mode 100644 index 0856cd09..00000000 --- a/src/hooks/nabla/mock.ts +++ /dev/null @@ -1,102 +0,0 @@ -import { BackstopPool, NablaToken, SwapPool } from '../../../gql/graphql'; - -const common = { - decimals: 18, - derivedETH: '', - pairBase: [], - pairDayDataBase: [], - pairDayDataQuote: [], - pairQuote: [], - tokenDayData: [], - totalLiquidity: '1000000000', - totalSupply: '10000000000', - tradeVolume: '500000000', - tradeVolumeUSD: '500000000', - txCount: 1000, - untrackedVolumeUSD: '', -}; -export const mockTokens: NablaToken[] = [ - { - id: '6iFkBQJ1C5rKeAc3Np6xAZBM9WfNuukLyjJffELK9HGkDjoa', - name: 'Mock USD', - symbol: 'mUSD', - ...common, - }, - { - id: '6h4VmXd5MHBTyJbem7f68xsi7otXvqLUiKf8SdRH9n2nuYaP', - name: 'Mock EUR', - symbol: 'mEUR', - ...common, - }, - { - id: '6nbACDpR3WCCy7qcTBb5MQZjpZZJCLzQ3g9sBH3RqXgWx4T4', - name: 'Mock ETH', - symbol: 'mETH', - ...common, - }, -]; - -export const mockBackstopPools: BackstopPool[] = [ - { - id: '6m6SUHd1XRpboq3GMsL73RigXCfz9iKZGWjoAzMnJJ9dJNgs', - token: mockTokens[0], - liabilities: '1200000000', - paused: false, - reserves: '1400000000', - router: { - id: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', - backstopPools: [], - paused: false, - swapPools: [], - }, - ...common, - }, -]; - -export const mockSwapPools: SwapPool[] = [ - { - id: '6nSUPH1Zubuipt1Knit352hkNEMKdSobaYGsZyo271mFd6fp', - token: mockTokens[0], - liabilities: '1200000000', - paused: false, - reserves: '1400000000', - router: { - id: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', - backstopPools: [], - paused: false, - swapPools: [], - }, - backstop: mockBackstopPools[0], - ...common, - }, - { - id: '6knNBRZ6L6KDdS9JxBUN92ffUdNGHnA4MiFFNbVfbYkKZSUv', - token: mockTokens[1], - liabilities: '1200000000', - paused: false, - reserves: '1400000000', - router: { - id: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', - backstopPools: [], - paused: false, - swapPools: [], - }, - backstop: mockBackstopPools[0], - ...common, - }, - { - id: '6hCd2N5PVhHEoRwg5Db1Ja11sdwNKEmsRd24i76CV2NmdH46', - token: mockTokens[2], - liabilities: '1200000000', - paused: false, - reserves: '1400000000', - router: { - id: '6mZ1nPRz2YhBH9GpmowSMdcLA28ZCPjRY3RJdGTj6z4hXLez', - backstopPools: [], - paused: false, - swapPools: [], - }, - backstop: mockBackstopPools[0], - ...common, - }, -]; diff --git a/src/hooks/nabla/useBackstopPool.ts b/src/hooks/nabla/useBackstopPool.ts deleted file mode 100644 index 48aac045..00000000 --- a/src/hooks/nabla/useBackstopPool.ts +++ /dev/null @@ -1,63 +0,0 @@ -import { useQuery, UseQueryOptions } from '@tanstack/react-query'; -import request from 'graphql-request'; -import { graphql } from '../../../gql/gql'; -import { BackstopPool } from '../../../gql/graphql'; -import { cacheKeys, inactiveOptions } from '../../constants/cache'; -import { emptyCacheKey, emptyFn } from '../../helpers/general'; -import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; -import { mockBackstopPools } from './mock'; - -export type UseBackstopPoolProps = UseQueryOptions; - -export const useBackstopPool = (id: string, options?: UseBackstopPoolProps) => { - const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!indexerUrl && options?.enabled !== false; - return useQuery( - enabled ? [cacheKeys.backstopPools, id, indexerUrl] : emptyCacheKey, - enabled - ? async () => - (mockBackstopPools[0] || // TODO: temporary solution - (await request(indexerUrl, getBackstopPool, { id }))?.backstopPoolById) as BackstopPool - : emptyFn, - { - ...inactiveOptions['1m'], - refetchInterval: 30000, - ...options, - enabled, - }, - ); -}; - -export const getBackstopPool = graphql(` - query getBackstopPool($id: String!) { - backstopPoolById(id: $id) { - id - liabilities - paused - reserves - totalSupply - token { - decimals - id - name - symbol - } - router { - swapPools(where: { router_isNull: false, paused_not_eq: true }) { - id - liabilities - paused - reserves - totalSupply - token { - decimals - id - name - symbol - } - } - id - } - } - } -`); diff --git a/src/hooks/nabla/useBackstopPools.ts b/src/hooks/nabla/useBackstopPools.ts deleted file mode 100644 index ae0c3a2c..00000000 --- a/src/hooks/nabla/useBackstopPools.ts +++ /dev/null @@ -1,53 +0,0 @@ -import { useQuery, UseQueryOptions } from '@tanstack/react-query'; -import request from 'graphql-request'; -import { graphql } from '../../../gql/gql'; -import { BackstopPool } from '../../../gql/graphql'; -import { cacheKeys, inactiveOptions } from '../../constants/cache'; -import { emptyCacheKey, emptyFn } from '../../helpers/general'; -import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; -import { mockBackstopPools } from './mock'; - -export type UseBackstopPoolsProps = UseQueryOptions; - -export const useBackstopPools = (options?: UseBackstopPoolsProps) => { - const { indexerUrl, backstopPools } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!indexerUrl && !!backstopPools && options?.enabled !== false; - return useQuery( - enabled ? [cacheKeys.backstopPools, indexerUrl] : emptyCacheKey, - enabled - ? async () => - (mockBackstopPools || // TODO: temporary solution - (await request(indexerUrl, getBackstopPools, { ids: backstopPools }))?.backstopPools) as BackstopPool[] - : emptyFn, - { - ...inactiveOptions['1m'], - refetchInterval: 30000, - ...options, - enabled, - }, - ); -}; - -export const getBackstopPools = graphql(` - query getBackstopPools($ids: [String!]) { - backstopPools(where: { paused_eq: false, id_in: $ids }) { - id - liabilities - paused - reserves - totalSupply - token { - id - decimals - name - symbol - } - router { - swapPools(where: { router_isNull: false, paused_not_eq: true }) { - id - } - id - } - } - } -`); diff --git a/src/hooks/nabla/useNablaInstance.ts b/src/hooks/nabla/useNablaInstance.ts new file mode 100644 index 00000000..469e853e --- /dev/null +++ b/src/hooks/nabla/useNablaInstance.ts @@ -0,0 +1,96 @@ +import { useQuery } from '@tanstack/react-query'; +import request from 'graphql-request'; +import { graphql } from '../../../gql/gql'; +import { GetRouterQuery } from '../../../gql/graphql'; +import { cacheKeys, inactiveOptions } from '../../constants/cache'; +import { emptyCacheKey, emptyFn } from '../../helpers/general'; +import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; + +export type NablaInstanceRouter = NonNullable; +export type NablaInstanceBackstopPool = NablaInstanceRouter['backstopPool'][number]; +export type NablaInstanceSwapPool = NablaInstanceRouter['swapPools'][number]; +export type NablaInstanceToken = NablaInstanceBackstopPool['token']; + +export interface NablaInstance { + router: NablaInstanceRouter; + backstopPool: NablaInstanceBackstopPool; + swapPools: NablaInstanceSwapPool[]; + tokens: Record; +} + +export function useNablaInstance(): { nabla: NablaInstance | undefined; isLoading: boolean } { + const { indexerUrl, router } = useGetAppDataByTenant('nabla').data ?? {}; + const enabled = !!indexerUrl && !!router; + + const result = useQuery( + enabled ? [cacheKeys.nablaInstance] : emptyCacheKey, + enabled ? async () => await request(indexerUrl, getNablaInstance, { id: router }) : emptyFn, + { + ...inactiveOptions['1m'], + refetchInterval: 10000, + }, + ); + + if (result.data !== undefined && result.data.routerById && result.data.routerById.backstopPool.length === 1) { + const router = result.data.routerById; + const backstopPool = router.backstopPool[0]; + const tokensMap = router.swapPools.reduce((acc, pool) => ({ ...acc, [pool.token.id]: pool.token }), { + [backstopPool.token.id]: backstopPool.token, + }); + + return { + nabla: { + router, + backstopPool, + swapPools: router.swapPools, + tokens: tokensMap, + }, + isLoading: result.isLoading, + }; + } + + return { nabla: undefined, isLoading: result.isLoading }; +} + +export const getNablaInstance = graphql(` + query getRouter($id: String!) { + routerById(id: $id) { + id + swapPools { + id + paused + name + reserve + reserveWithSlippage + totalLiabilities + totalSupply + lpTokenDecimals + apr + symbol + token { + id + decimals + name + symbol + } + } + backstopPool { + id + name + paused + symbol + totalSupply + apr + reserves + lpTokenDecimals + token { + id + decimals + name + symbol + } + } + paused + } + } +`); diff --git a/src/hooks/nabla/useSharesTargetWorth.ts b/src/hooks/nabla/useSharesTargetWorth.ts index 4f808b37..7b0dcabb 100644 --- a/src/hooks/nabla/useSharesTargetWorth.ts +++ b/src/hooks/nabla/useSharesTargetWorth.ts @@ -1,17 +1,17 @@ import { cacheKeys, inactiveOptions } from '../../constants/cache'; -import { swapPoolAbi } from '../../contracts/nabla/SwapPool'; import { QueryOptions } from '../../shared/helpers'; -import { decimalToNative } from '../../shared/parseNumbers'; +import { decimalToRaw } from '../../shared/parseNumbers'; import { useContract } from '../../shared/useContract'; export type UseSharesTargetWorthProps = { address: string | undefined; - amount: number | undefined; - abi?: Dict; + lpTokenDecimalAmount: number; + lpTokenDecimals: number; + abi: Dict; }; export const useSharesTargetWorth = ( - { address, amount, abi = swapPoolAbi }: UseSharesTargetWorthProps, + { address, lpTokenDecimalAmount, abi, lpTokenDecimals }: UseSharesTargetWorthProps, options?: QueryOptions, ) => { return useContract([cacheKeys.sharesTargetWorth], { @@ -20,7 +20,7 @@ export const useSharesTargetWorth = ( address, abi, method: 'sharesTargetWorth', - args: [decimalToNative(amount || 0).toString()], - enabled: Boolean(address && amount && options?.enabled !== false), + args: [decimalToRaw(lpTokenDecimalAmount || 0, lpTokenDecimals).toString()], + enabled: Boolean(address && lpTokenDecimalAmount && options?.enabled !== false), }); }; diff --git a/src/hooks/nabla/useSwapPools.ts b/src/hooks/nabla/useSwapPools.ts deleted file mode 100644 index 570e6a05..00000000 --- a/src/hooks/nabla/useSwapPools.ts +++ /dev/null @@ -1,58 +0,0 @@ -import { useQuery, UseQueryOptions } from '@tanstack/react-query'; -import request from 'graphql-request'; -import { graphql } from '../../../gql/gql'; -import { SwapPool } from '../../../gql/graphql'; -import { cacheKeys, inactiveOptions } from '../../constants/cache'; -import { emptyCacheKey, emptyFn } from '../../helpers/general'; -import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; -import { mockSwapPools } from './mock'; - -export type UseSwapPoolsProps = UseQueryOptions; - -export const useSwapPools = (options?: UseSwapPoolsProps) => { - const { indexerUrl, swapPools } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!indexerUrl && !!swapPools && options?.enabled !== false; - return useQuery( - enabled ? [cacheKeys.swapPools, indexerUrl] : emptyCacheKey, - enabled - ? async () => - // TODO: temporary solution - (mockSwapPools || (await request(indexerUrl, getSwapPools, { ids: swapPools }))?.swapPools) as SwapPool[] - : emptyFn, - { - ...inactiveOptions['1m'], - refetchInterval: 30000, - ...options, - enabled, - }, - ); -}; - -export const getSwapPools = graphql(` - query getSwapPools($ids: [String!]) { - swapPools(where: { paused_eq: false, id_in: $ids }) { - id - liabilities - paused - reserves - totalSupply - token { - id - name - symbol - decimals - } - router { - id - paused - } - backstop { - id - liabilities - paused - reserves - totalSupply - } - } - } -`); diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index 48ad277d..da538503 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -1,34 +1,41 @@ import { MessageCallResult } from '@pendulum-chain/api-solang'; import { activeOptions, cacheKeys } from '../../constants/cache'; import { routerAbi } from '../../contracts/nabla/Router'; -import { useGlobalState } from '../../GlobalStateProvider'; -import { decimalToNative } from '../../shared/parseNumbers'; +import { decimalToRaw } from '../../shared/parseNumbers'; import { useContract } from '../../shared/useContract'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; export type UseTokenOutAmountProps = { - amount?: number; + fromDecimalAmount: number; from?: string; to?: string; - decimals?: number; + fromTokenDecimals: number; onSuccess?: (val: MessageCallResult) => void; onError?: (err: Error | MessageCallResult) => void; }; -export const useTokenOutAmount = ({ amount, from, to, decimals, onSuccess, onError }: UseTokenOutAmountProps) => { - const amountIn = decimalToNative(amount || 0, decimals).toString(); - const { address } = useGlobalState().walletAccount || {}; +export const useTokenOutAmount = ({ + fromDecimalAmount: decimalAmount, + from, + to, + fromTokenDecimals, + onSuccess, + onError, +}: UseTokenOutAmountProps) => { const { router } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!amount && !!from && !!to; + const enabled = fromTokenDecimals !== undefined && !!decimalAmount && !!from && !!to; + const amountIn = + fromTokenDecimals !== undefined ? decimalToRaw(decimalAmount, fromTokenDecimals).toString() : undefined; + return useContract([cacheKeys.tokenOutAmount, from, to, amountIn], { ...activeOptions['30s'], abi: routerAbi, address: router, - owner: address, method: 'getAmountOut', args: [amountIn, [from, to]], enabled, + noWalletAddressRequired: true, onSuccess, onError: (err) => { if (onError) onError(err); diff --git a/src/hooks/nabla/useTokenPrice.ts b/src/hooks/nabla/useTokenPrice.ts index 1d9196d4..5790922e 100644 --- a/src/hooks/nabla/useTokenPrice.ts +++ b/src/hooks/nabla/useTokenPrice.ts @@ -3,18 +3,19 @@ import { priceOracleAbi } from '../../contracts/nabla/PriceOracle'; import { useContract } from '../../shared/useContract'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; -export const useTokenPrice = (address: string, owner?: string, options?: QueryOptions) => { +export const useTokenPrice = (address: string | undefined, options?: QueryOptions) => { const { oracle } = useGetAppDataByTenant('nabla').data || {}; const enabled = !!address && !!oracle && options?.enabled !== false; + return useContract([cacheKeys.tokenPrice, address], { ...inactiveOptions['1m'], ...options, enabled, address: oracle, - owner, abi: priceOracleAbi, method: 'getAssetPrice', + noWalletAddressRequired: true, args: [address], }); }; diff --git a/src/hooks/nabla/useTokens.ts b/src/hooks/nabla/useTokens.ts deleted file mode 100644 index 48ce9079..00000000 --- a/src/hooks/nabla/useTokens.ts +++ /dev/null @@ -1,52 +0,0 @@ -import { useQuery } from '@tanstack/react-query'; -import request from 'graphql-request'; -import { graphql } from '../../../gql/gql'; -import { Token } from '../../../gql/graphql'; -import { cacheKeys, inactiveOptions, QueryOptions } from '../../constants/cache'; -import { emptyCacheKey, emptyFn } from '../../helpers/general'; -import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; -import { mockTokens } from './mock'; - -export type TokensData = { - tokensMap: Record; - tokens: Token[] | undefined; -}; - -export const useTokens = (options?: QueryOptions) => { - const { indexerUrl, assets } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!indexerUrl && options?.enabled !== false && !!assets; - return useQuery( - enabled ? [cacheKeys.tokens, indexerUrl] : emptyCacheKey, - enabled - ? async () => { - const response = (mockTokens || // TODO: temporary solution - (await request(indexerUrl, getTokens, { ids: assets }))?.nablaTokens) as Token[]; - return response?.reduce( - (acc, curr) => { - acc.tokensMap[curr.id] = curr; - return acc; - }, - { - tokens: response, - tokensMap: {}, - } as TokensData, - ); - } - : emptyFn, - { - ...inactiveOptions['15m'], - ...options, - }, - ); -}; - -const getTokens = graphql(` - query getTokens($ids: [String!]) { - nablaTokens(where: { id_in: $ids }) { - id - name - symbol - decimals - } - } -`); diff --git a/src/pages/nabla/dev/index.tsx b/src/pages/nabla/dev/index.tsx index d6fcea29..083423df 100644 --- a/src/pages/nabla/dev/index.tsx +++ b/src/pages/nabla/dev/index.tsx @@ -1,16 +1,14 @@ import { EllipsisVerticalIcon } from '@heroicons/react/20/solid'; import { Button, Dropdown } from 'react-daisyui'; import { useNavigate } from 'react-router-dom'; -import { Token } from '../../../../gql/graphql'; import { config } from '../../../config'; -import { defaultDecimals } from '../../../config/apps/nabla'; import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; import { useGlobalState } from '../../../GlobalStateProvider'; -import { useTokens } from '../../../hooks/nabla/useTokens'; -import { decimalToNative } from '../../../shared/parseNumbers'; +import { decimalToRaw } from '../../../shared/parseNumbers'; import { useContractWrite } from '../../../shared/useContractWrite'; +import { NablaInstanceToken, useNablaInstance } from '../../../hooks/nabla/useNablaInstance'; -const TokenItem = ({ token }: { token: Token }) => { +const TokenItem = ({ token }: { token: NablaInstanceToken }) => { const { address } = useGlobalState().walletAccount || {}; const { mutate, isLoading } = useContractWrite({ abi: erc20WrapperAbi, @@ -32,7 +30,7 @@ const TokenItem = ({ token }: { token: Token }) => { color="secondary" type="button" disabled={isLoading} - onClick={() => mutate([address, decimalToNative(1000, defaultDecimals).toString()])} + onClick={() => mutate([address, decimalToRaw(1000, token.decimals).toString()])} > {isLoading ? 'Loading' : 'Mint 1000'} @@ -45,7 +43,7 @@ const TokenItem = ({ token }: { token: Token }) => {
mutate([address, decimalToNative(10000, defaultDecimals).toString()])} + onClick={() => mutate([address, decimalToRaw(10000, 12).toString()])} > 10000
@@ -54,7 +52,7 @@ const TokenItem = ({ token }: { token: Token }) => {
mutate([address, decimalToNative(100000, defaultDecimals).toString()])} + onClick={() => mutate([address, decimalToRaw(100000, 12).toString()])} > 100000
@@ -70,8 +68,8 @@ const TokenItem = ({ token }: { token: Token }) => { const DevPage = () => { const navigate = useNavigate(); const wallet = useGlobalState().walletAccount; - const { data } = useTokens(); - const { tokens } = data || {}; + const { nabla } = useNablaInstance(); + const tokens = nabla?.swapPools.map((pool) => pool.token) ?? []; if (config.isProd) navigate('/'); if (!wallet?.address) { diff --git a/src/shared/parseNumbers.ts b/src/shared/parseNumbers.ts index dc5e71a7..0b61810b 100644 --- a/src/shared/parseNumbers.ts +++ b/src/shared/parseNumbers.ts @@ -1,12 +1,10 @@ import { u128, UInt } from '@polkadot/types-codec'; import BigNumber from 'big.js'; -// These are the decimals used for the native currency on the Amplitude network -export const ChainDecimals = 12; - // These are the decimals used by the Stellar network // We actually up-scale the amounts on Stellar now to match the expected decimals of the other tokens. -export const StellarDecimals = ChainDecimals; +export const StellarDecimals = 12; +export const NativeDecimals = 12; // These are the decimals used by the FixedU128 type export const FixedU128Decimals = 18; @@ -17,7 +15,7 @@ BigNumber.PE = 100; BigNumber.NE = -20; // Converts a decimal number to the native representation (a large integer) -export const decimalToNative = (value: BigNumber | number | string, decimals: number = ChainDecimals) => { +export const decimalToNative = (value: BigNumber | number | string, decimals: number = NativeDecimals) => { let bigIntValue; try { bigIntValue = new BigNumber(value); @@ -28,6 +26,10 @@ export const decimalToNative = (value: BigNumber | number | string, decimals: nu return bigIntValue.times(multiplier).round(0); }; +export const decimalToRaw = (value: BigNumber | number | string, decimals: number) => { + return decimalToNative(value, decimals); +}; + export const decimalToStellarNative = (value: BigNumber | number | string) => { let bigIntValue; try { @@ -46,7 +48,10 @@ export const fixedPointToDecimal = (value: BigNumber | number | string) => { return bigIntValue.div(divisor); }; -export const nativeToDecimal = (value: BigNumber | number | string | u128 | UInt, decimals: number = ChainDecimals) => { +export const nativeToDecimal = ( + value: BigNumber | number | string | u128 | UInt, + decimals: number = NativeDecimals, +) => { if (!value) return new BigNumber(0); if (typeof value === 'string' || value instanceof u128 || value instanceof UInt) { @@ -59,6 +64,10 @@ export const nativeToDecimal = (value: BigNumber | number | string | u128 | UInt return bigIntValue.div(divisor); }; +export const rawToDecimal = (value: BigNumber | number | string | u128 | UInt, decimals: number) => { + return nativeToDecimal(value, decimals); +}; + export const nativeStellarToDecimal = (value: BigNumber | number | string) => { const bigIntValue = new BigNumber(value); const divisor = new BigNumber(10).pow(StellarDecimals); @@ -91,7 +100,7 @@ export const nativeToFormat = ( value: BigNumber | number | string, tokenSymbol: string | undefined, oneCharOnly = false, -) => format(nativeToDecimal(value).toNumber(), tokenSymbol, oneCharOnly); +) => format(rawToDecimal(value, StellarDecimals).toNumber(), tokenSymbol, oneCharOnly); export const prettyNumbers = (number: number, lang?: string, opts?: Intl.NumberFormatOptions) => number.toLocaleString(lang || navigator.language, { @@ -105,4 +114,4 @@ export const roundNumber = (value: number | string = 0, round = 6) => { }; /** Calculate deadline from minutes */ -export const calcDeadline = (min: number) => decimalToNative(`${Math.floor(Date.now() / 1000) + min * 60}`); +export const calcDeadline = (min: number) => `${Math.floor(Date.now() / 1000) + min * 60}`; diff --git a/src/shared/useContract.ts b/src/shared/useContract.ts index 8e1a43ae..78e36a43 100644 --- a/src/shared/useContract.ts +++ b/src/shared/useContract.ts @@ -2,51 +2,63 @@ import { Limits, messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; import { ApiPromise } from '@polkadot/api'; import { Abi } from '@polkadot/api-contract'; -import { QueryKey, useQuery } from '@tanstack/react-query'; +import { QueryKey, useQuery, UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; import { defaultReadLimits, emptyCacheKey, emptyFn, QueryOptions } from './helpers'; import { useSharedState } from './Provider'; type ContractOpts = Limits | ((api: ApiPromise) => Limits); -export type UseContractProps> = QueryOptions & { - abi: TAbi; - address?: string; - owner?: string; +export type UseContractProps = QueryOptions & { + abi: Dict; + address: string | undefined; method: string; args?: any[]; options?: ContractOpts; + noWalletAddressRequired?: boolean; }; +export type UseContractResult = Pick< + UseQueryResult, + 'refetch' | 'isLoading' | 'data' | 'fetchStatus' +>; + +const ALICE = '6mfqoTMHrMeVMyKwjqomUjVomPMJ4AjdCm1VReFtk7Be8wqr'; + const getLimits = (options: ContractOpts | undefined, api: ApiPromise) => typeof options === 'function' ? options(api) : options || defaultReadLimits; -export const useContract = >( +export function useContract( key: QueryKey, - { abi, address, owner, method, options, args, ...rest }: UseContractProps, -) => { + { abi, address, method, options, args, noWalletAddressRequired, ...rest }: UseContractProps, +): UseContractResult { const { api, address: walletAddress } = useSharedState(); const contractAbi = useMemo( () => (abi && api?.registry ? new Abi(abi, api.registry.getChainProperties()) : undefined), [abi, api?.registry], ); - const enabled = !!contractAbi && rest.enabled !== false && !!address && !!api && !!owner && !!walletAddress; - const query = useQuery( + const actualWalletAddress = noWalletAddressRequired ? ALICE : walletAddress; + + const enabled = !!contractAbi && rest.enabled !== false && !!address && !!api && !!actualWalletAddress; + const query = useQuery( enabled ? key : emptyCacheKey, enabled ? async () => { const limits = getLimits(options, api); + console.log('Call message', address, method, args); + const response = await messageCall({ abi: contractAbi, api, - callerAddress: walletAddress, + callerAddress: actualWalletAddress, contractDeploymentAddress: address, getSigner: () => Promise.resolve({} as any), // TODO: cleanup in api-solang lib messageName: method, messageArguments: args || [], limits, }); - if (response?.result?.type !== 'success') throw response; + console.log('messageCall result', method, response); + return response; } : emptyFn, @@ -55,5 +67,14 @@ export const useContract = >( enabled, }, ); - return { ...query, enabled }; -}; + + console.log(!!contractAbi, rest.enabled !== false, !!address, !!api, !!actualWalletAddress); + console.log('useContract result', method, enabled, key, address, method, args, query.status, query.data, query); + + return { + refetch: query.refetch, + isLoading: query.isLoading, + data: query.data, + fetchStatus: query.fetchStatus, + }; +} diff --git a/src/shared/useContractBalance.ts b/src/shared/useContractBalance.ts index 282f666d..34ff9244 100644 --- a/src/shared/useContractBalance.ts +++ b/src/shared/useContractBalance.ts @@ -1,31 +1,33 @@ import { MessageCallResult } from '@pendulum-chain/api-solang'; import { UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; -import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; import { cacheKeys } from './constants'; import { getMessageCallValue, QueryOptions } from './helpers'; -import { nativeToDecimal, prettyNumbers } from './parseNumbers'; +import { rawToDecimal, prettyNumbers } from './parseNumbers'; import { useSharedState } from './Provider'; import { useContract } from './useContract'; -export type UseBalanceProps> = { +export type UseBalanceProps = { /** token or contract address */ - contractAddress?: string; + contractAddress: string | undefined; /** account address */ account?: string; /** contract abi */ - abi?: TAbi; + abi: Dict; /** parse decimals */ - decimals?: number; + decimals: number | undefined; }; -export type UseBalanceResponse = UseQueryResult & { +export type UseBalanceResponse = Pick< + UseQueryResult, + 'refetch' | 'isLoading' +> & { balance?: number; formatted?: string; enabled: boolean; }; -export const useContractBalance = >( - { contractAddress, account, abi, decimals }: UseBalanceProps, +export const useContractBalance = ( + { contractAddress, account, abi, decimals }: UseBalanceProps, options?: QueryOptions, ): UseBalanceResponse => { const { api, address: defAddress } = useSharedState(); @@ -40,23 +42,25 @@ export const useContractBalance = >( refetchOnWindowFocus: false, onError: console.error, ...options, - abi: abi || erc20WrapperAbi, + abi, address: contractAddress, - owner: address, method: 'balanceOf', args: [address], enabled, }); + const { data } = query; const val = useMemo(() => { - if (!data || !data.result) return undefined; + if (!data || data.result.type !== 'success') return undefined; const value = getMessageCallValue(data); - const balance = nativeToDecimal(parseFloat(value || '0'), decimals).toNumber(); + const balance = rawToDecimal(value.toString(), decimals!).toNumber(); return { balance, formatted: prettyNumbers(balance) }; }, [data, decimals]); return { - ...query, + isLoading: query.isLoading, + refetch: query.refetch, + enabled, ...val, }; }; diff --git a/src/shared/useTokenAllowance.ts b/src/shared/useTokenAllowance.ts index 54d760e5..b1cae5d1 100644 --- a/src/shared/useTokenAllowance.ts +++ b/src/shared/useTokenAllowance.ts @@ -4,29 +4,24 @@ import { cacheKeys } from './constants'; import { QueryOptions } from './helpers'; import { useContract } from './useContract'; -export type UseTokenAllowance> = { +export type UseTokenAllowance = { /** contract/token address */ - token?: string; + token: string; /** spender address */ spender: string | undefined; /** owner address */ owner: string | undefined; - /** contract abi */ - abi?: TAbi; }; -export const useTokenAllowance = >( - { token, owner, spender, abi }: UseTokenAllowance, - options?: QueryOptions, -) => { - const isEnabled = Boolean(token && owner && spender && options?.enabled); +export const useTokenAllowance = ({ token, owner, spender }: UseTokenAllowance, options?: QueryOptions) => { + const isEnabled = Boolean(owner && spender && options?.enabled); + return useContract([cacheKeys.tokenAllowance, spender, token, owner], { ...activeOptions['3m'], retry: 2, ...options, - abi: abi || erc20WrapperAbi, + abi: erc20WrapperAbi, address: token, - owner, method: 'allowance', args: [owner, spender], enabled: isEnabled, diff --git a/src/shared/useTokenApproval.ts b/src/shared/useTokenApproval.ts index 76cbd5b9..ea35bd18 100644 --- a/src/shared/useTokenApproval.ts +++ b/src/shared/useTokenApproval.ts @@ -2,7 +2,7 @@ import { useMemo, useState } from 'preact/compat'; import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; import { getMessageCallValue } from './helpers'; -import { decimalToNative, nativeToDecimal } from './parseNumbers'; +import { decimalToRaw, rawToDecimal } from './parseNumbers'; import { useSharedState } from './Provider'; import { useContractWrite, UseContractWriteProps } from './useContractWrite'; import { useTokenAllowance } from './useTokenAllowance'; @@ -13,34 +13,33 @@ export enum ApprovalState { PENDING, NOT_APPROVED, APPROVED, + NO_ACCOUNT, } interface UseTokenApprovalParams { - spender?: string; - token?: string; - amount?: number; - approveMax?: boolean; + spender: string; + token: string; + decimalAmount: number; enabled?: boolean; - decimals?: number; + decimals: number; onError?: (err: any) => void; onSuccess?: UseContractWriteProps['onSuccess']; } export const useTokenApproval = ({ token, - amount = 0, + decimalAmount, spender, enabled = true, - approveMax, decimals, onError, onSuccess, }: UseTokenApprovalParams) => { const { address } = useSharedState(); const [pending, setPending] = useState(false); - const amountBI = decimalToNative(amount, decimals); - const isEnabled = Boolean(token && spender && address && enabled); - const maxInt = useMemo(() => decimalToNative(Number.MAX_SAFE_INTEGER, decimals).toString(), [decimals]); + const nativeAmount = decimalToRaw(decimalAmount, decimals); + const isEnabled = Boolean(spender && address && enabled); + const { data: allowanceData, isLoading: isAllowanceLoading, @@ -58,7 +57,7 @@ export const useTokenApproval = ({ abi: erc20WrapperAbi, address: token, method: 'approve', - args: [spender, approveMax ? maxInt : amountBI.toString()], + args: [spender, nativeAmount.toString()], onError: (err) => { setPending(false); if (onError) onError(err); @@ -74,22 +73,32 @@ export const useTokenApproval = ({ }); const allowanceValue = getMessageCallValue(allowanceData); - const allowance = useMemo( - () => nativeToDecimal(parseFloat(allowanceValue || '0'), decimals).toNumber(), + const allowanceDecimalAmount = useMemo( + () => (allowanceValue !== undefined ? rawToDecimal(allowanceValue.toString(), decimals).toNumber() : undefined), [allowanceValue, decimals], ); return useMemo<[ApprovalState, typeof mutation]>(() => { let state = ApprovalState.UNKNOWN; - // if (amount?.currency.isNative) state = ApprovalState.APPROVED; - if (isAllowanceLoading) state = ApprovalState.LOADING; + + if (address === undefined) state = ApprovalState.NO_ACCOUNT; + else if (isAllowanceLoading) state = ApprovalState.LOADING; else if (!mutation.isReady) state = ApprovalState.UNKNOWN; - else if (allowance !== undefined && amount !== undefined && allowance >= amount) { + else if ( + allowanceDecimalAmount !== undefined && + decimalAmount !== undefined && + allowanceDecimalAmount >= decimalAmount + ) { state = ApprovalState.APPROVED; } else if (pending || mutation.isLoading) state = ApprovalState.PENDING; - else if (allowance !== undefined && amount !== undefined && allowance < amount) { + else if ( + allowanceDecimalAmount !== undefined && + decimalAmount !== undefined && + allowanceDecimalAmount < decimalAmount + ) { state = ApprovalState.NOT_APPROVED; } + return [state, mutation]; - }, [allowance, amount, mutation, isAllowanceLoading, pending]); + }, [allowanceDecimalAmount, decimalAmount, mutation, isAllowanceLoading, pending, address]); }; From 03d10657ef3c80b13c2d5540984aeb3d6bf0b4d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Thu, 22 Feb 2024 06:06:48 -0300 Subject: [PATCH 21/58] Some smaller fixes --- src/components/{Balance => Erc20Balance}/index.tsx | 8 ++++---- src/components/nabla/Pools/Backstop/index.tsx | 4 ++-- .../nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts | 7 ++++--- src/components/nabla/Pools/Swap/columns.tsx | 8 ++++++-- src/components/nabla/Swap/To/index.tsx | 11 +++++++++-- src/config/apps/nabla.ts | 4 ++-- src/hooks/nabla/useSharesTargetWorth.ts | 4 ++-- src/shared/parseNumbers.ts | 2 +- src/shared/useContractWrite.ts | 8 ++++++++ 9 files changed, 38 insertions(+), 18 deletions(-) rename src/components/{Balance => Erc20Balance}/index.tsx (72%) diff --git a/src/components/Balance/index.tsx b/src/components/Erc20Balance/index.tsx similarity index 72% rename from src/components/Balance/index.tsx rename to src/components/Erc20Balance/index.tsx index b0a931d8..d14b4826 100644 --- a/src/components/Balance/index.tsx +++ b/src/components/Erc20Balance/index.tsx @@ -1,19 +1,19 @@ import { useContractBalance } from '../../shared/useContractBalance'; import { numberLoader } from '../Loader'; -export type BalanceProps = { +export type Erc20BalanceProps = { address: string | undefined; decimals: number | undefined; abi: Dict; }; -const Balance = ({ address, decimals, abi }: BalanceProps): JSX.Element | null => { +const Erc20Balance = ({ address, decimals, abi }: Erc20BalanceProps): JSX.Element | null => { const { isLoading, formatted, enabled } = useContractBalance({ contractAddress: address, decimals, abi }); - if (address === undefined || decimals === undefined || !enabled) return <>{0}; + if (address === undefined || decimals === undefined || !enabled) return numberLoader; if (isLoading) return numberLoader; return {formatted ?? 0}; }; -export default Balance; +export default Erc20Balance; diff --git a/src/components/nabla/Pools/Backstop/index.tsx b/src/components/nabla/Pools/Backstop/index.tsx index 4a86c0aa..46f23992 100644 --- a/src/components/nabla/Pools/Backstop/index.tsx +++ b/src/components/nabla/Pools/Backstop/index.tsx @@ -1,6 +1,6 @@ import { Button, Card } from 'react-daisyui'; import ModalProvider, { useModalToggle } from '../../../../services/modal'; -import Balance from '../../../Balance'; +import Erc20Balance from '../../../Erc20Balance'; import { Skeleton } from '../../../Skeleton'; import Modals from './Modals'; import { LiquidityModalProps, ModalTypes } from './Modals/types'; @@ -23,7 +23,7 @@ const BackstopPoolsBody = (): JSX.Element | null => {

My pool balance

- +
diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index 18ebaa32..3bf7c0f4 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -54,9 +54,10 @@ export const useAddLiquidity = ( }, }); - const onSubmit = form.handleSubmit((variables) => - mutation.mutate([decimalToRaw(variables.amount, poolTokenDecimals).toString()]), - ); + const onSubmit = form.handleSubmit((variables) => { + console.log('submit add liquidity', variables.amount, decimalToRaw(variables.amount, poolTokenDecimals).toString()); + return mutation.mutate([decimalToRaw(variables.amount, poolTokenDecimals).toString()]); + }); const decimalAmount = Number( diff --git a/src/components/nabla/Pools/Swap/columns.tsx b/src/components/nabla/Pools/Swap/columns.tsx index 2b236f22..95f83a04 100644 --- a/src/components/nabla/Pools/Swap/columns.tsx +++ b/src/components/nabla/Pools/Swap/columns.tsx @@ -4,6 +4,8 @@ import { useModalToggle } from '../../../../services/modal'; import { rawToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; import { LiquidityModalProps, ModalTypes } from './Modals/types'; import { NablaInstanceBackstopPool, NablaInstanceSwapPool } from '../../../../hooks/nabla/useNablaInstance'; +import Erc20Balance from '../../../Erc20Balance'; +import { swapPoolAbi } from '../../../../contracts/nabla/SwapPool'; export type SwapPoolColumn = NablaInstanceSwapPool & { myAmount?: number; @@ -55,8 +57,10 @@ export const aprColumn: ColumnDef = { export const myAmountColumn: ColumnDef = { header: 'My Pool Amount', accessorKey: 'myAmount', - accessorFn: (row) => prettyNumbers(rawToDecimal(row.myAmount || 0, row.lpTokenDecimals).toNumber()), - enableSorting: true, + cell: ({ row: { original } }) => ( + + ), + enableSorting: false, meta: { className: 'text-right justify-end', }, diff --git a/src/components/nabla/Swap/To/index.tsx b/src/components/nabla/Swap/To/index.tsx index d11d188b..7d3d0132 100644 --- a/src/components/nabla/Swap/To/index.tsx +++ b/src/components/nabla/Swap/To/index.tsx @@ -11,7 +11,7 @@ import useBoolean from '../../../../hooks/useBoolean'; import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; import { getMessageCallValue } from '../../../../shared/helpers'; import { rawToDecimal, prettyNumbers, roundNumber } from '../../../../shared/parseNumbers'; -import Balance from '../../../Balance'; +import Erc20Balance from '../../../Erc20Balance'; import { numberLoader } from '../../../Loader'; import { Skeleton } from '../../../Skeleton'; import TokenPrice from '../../Price'; @@ -105,6 +105,13 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu const outValue = getMessageCallValue(data); const value = outValue && toToken !== undefined ? prettyNumbers(rawToDecimal(outValue, toToken.decimals).toNumber()) : 0; + + console.log( + 'roundNumber(Number(value) / fromDecimalAmount, 6)', + roundNumber(Number(value) / fromDecimalAmount, 6), + value, + fromDecimalAmount, + ); return ( <>
@@ -138,7 +145,7 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu
{toToken ? : '$ -'}
- Balance: + Balance:
diff --git a/src/config/apps/nabla.ts b/src/config/apps/nabla.ts index 3a0c0842..b8a027ba 100644 --- a/src/config/apps/nabla.ts +++ b/src/config/apps/nabla.ts @@ -17,7 +17,7 @@ export const nablaConfig: NablaConfig = { environment: ['staging', 'development'], foucoco: { indexerUrl: 'https://squid.subsquid.io/foucoco-squid/graphql', - router: '6mS8roUTrZe7fFDYLa2NgWbMrG1YGK6roC6WtDo82dqd7TP6', - oracle: '6jrZjQgfbmW6yD3BkQhKfhT1xV4EoRpCve3RRvGiAdfff5T9', + router: '6h5xgcRE7wsRzr8ekpNud52A1n3rLXdoEcZvor6gpwobY4SM', + oracle: '6kuQBzpjpAbkb88Er45dpsm9L5Cxkm1nGGCYGWheJ4cD8yE4', }, }; diff --git a/src/hooks/nabla/useSharesTargetWorth.ts b/src/hooks/nabla/useSharesTargetWorth.ts index 7b0dcabb..9297acc5 100644 --- a/src/hooks/nabla/useSharesTargetWorth.ts +++ b/src/hooks/nabla/useSharesTargetWorth.ts @@ -14,13 +14,13 @@ export const useSharesTargetWorth = ( { address, lpTokenDecimalAmount, abi, lpTokenDecimals }: UseSharesTargetWorthProps, options?: QueryOptions, ) => { - return useContract([cacheKeys.sharesTargetWorth], { + return useContract([cacheKeys.sharesTargetWorth, lpTokenDecimalAmount], { ...inactiveOptions['1m'], ...options, address, abi, method: 'sharesTargetWorth', - args: [decimalToRaw(lpTokenDecimalAmount || 0, lpTokenDecimals).toString()], + args: [decimalToRaw(lpTokenDecimalAmount, lpTokenDecimals).toString()], enabled: Boolean(address && lpTokenDecimalAmount && options?.enabled !== false), }); }; diff --git a/src/shared/parseNumbers.ts b/src/shared/parseNumbers.ts index 0b61810b..e4dafcf1 100644 --- a/src/shared/parseNumbers.ts +++ b/src/shared/parseNumbers.ts @@ -103,7 +103,7 @@ export const nativeToFormat = ( ) => format(rawToDecimal(value, StellarDecimals).toNumber(), tokenSymbol, oneCharOnly); export const prettyNumbers = (number: number, lang?: string, opts?: Intl.NumberFormatOptions) => - number.toLocaleString(lang || navigator.language, { + number.toLocaleString('en-US', { minimumFractionDigits: 2, maximumFractionDigits: 2, ...opts, diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index 06c68797..f9dd1eb1 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -40,12 +40,17 @@ export const useContractWrite = >({ [abi, api?.registry], ); + console.log('useContractWrite', address, method, args); + const isReady = !!contractAbi && !!address && !!api && !!walletAddress && !!signer; const submit = async (submitArgs?: any[] | void): Promise => { if (!isReady) throw 'Missing data'; //setTransaction({ status: 'Pending' }); const fnArgs = submitArgs || args || []; const contractOptions = (typeof options === 'function' ? options(api) : options) || createWriteOptions(api); + + console.log('call message write', address, method, args, submitArgs); + const response = await messageCall({ abi: contractAbi, api, @@ -61,6 +66,9 @@ export const useContractWrite = >({ messageArguments: fnArgs, limits: { ...defaultWriteLimits, ...contractOptions }, }); + + console.log('call message write response', address, method, fnArgs, response); + if (response?.result?.type !== 'success') throw response; return response; }; From 718a9d802da7cc76501c3f8655f1f69fc799417f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Sun, 25 Feb 2024 18:12:38 -0300 Subject: [PATCH 22/58] Use higher contract resource limits --- src/shared/helpers.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/shared/helpers.ts b/src/shared/helpers.ts index 447fa8be..e564f105 100644 --- a/src/shared/helpers.ts +++ b/src/shared/helpers.ts @@ -27,16 +27,16 @@ export const parseTransactionError = (result: SubmittableResultValue | undefined export const defaultReadLimits: Limits = { gas: { - refTime: '500000000000', - proofSize: '4000000', + refTime: '10000000000000000', + proofSize: '10000000000000000', }, storageDeposit: undefined, }; export const defaultWriteLimits: Limits = { gas: { - refTime: '30000000000', - proofSize: '2400000', + refTime: '10000000000000', + proofSize: '10000000000', }, storageDeposit: undefined, }; From a53f44abd29dc351824a297d967d097cf1d00284 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Mon, 26 Feb 2024 07:43:54 +0000 Subject: [PATCH 23/58] Allow tolerance for estimated gas limits --- package.json | 2 +- src/shared/useContractWrite.ts | 1 + yarn.lock | 10 +++++----- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index cd55fc7d..67d80b1b 100644 --- a/package.json +++ b/package.json @@ -22,7 +22,7 @@ "@heroicons/react": "^2.1.1", "@hookform/resolvers": "^2.9.11", "@pendulum-chain/api": "^0.3.1", - "@pendulum-chain/api-solang": "~0.1.1", + "@pendulum-chain/api-solang": "0.2.0", "@polkadot/api": "^9.9.1", "@polkadot/api-base": "^9.9.1", "@polkadot/api-contract": "^9.9.1", diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index f9dd1eb1..6a4d2d23 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -65,6 +65,7 @@ export const useContractWrite = >({ messageName: method, messageArguments: fnArgs, limits: { ...defaultWriteLimits, ...contractOptions }, + gasLimitTolerancePercentage: 200, // Allow 3 fold gas tolerance }); console.log('call message write response', address, method, fnArgs, response); diff --git a/yarn.lock b/yarn.lock index d6b2b641..ad37b7ee 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3498,9 +3498,9 @@ __metadata: languageName: node linkType: hard -"@pendulum-chain/api-solang@npm:~0.1.1": - version: 0.1.1 - resolution: "@pendulum-chain/api-solang@npm:0.1.1" +"@pendulum-chain/api-solang@npm:0.2.0": + version: 0.2.0 + resolution: "@pendulum-chain/api-solang@npm:0.2.0" peerDependencies: "@polkadot/api": ^10.9.1 "@polkadot/api-contract": ^10.9.1 @@ -3509,7 +3509,7 @@ __metadata: "@polkadot/types-codec": ^10.9.1 "@polkadot/util": ^12.3.2 "@polkadot/util-crypto": ^12.3.2 - checksum: 18e9502374c4ca35e79ac13f97bf450cbd7b372d9238906b5bf91fba50839cf9a10a4af6a00532468405f0a5eae9801d91eca0ec3db078c5f686d6717c47afd9 + checksum: a118e81af407c15c5dfb94cc3ee52f251bd5dfd57b3f60b10b081854ec5ff5acb1845a62a5fcb509c67c0e6cc9e7c4df3fbe1b53535f6cf9270b148658fac282 languageName: node linkType: hard @@ -14063,7 +14063,7 @@ __metadata: "@heroicons/react": "npm:^2.1.1" "@hookform/resolvers": "npm:^2.9.11" "@pendulum-chain/api": "npm:^0.3.1" - "@pendulum-chain/api-solang": "npm:~0.1.1" + "@pendulum-chain/api-solang": "npm:0.2.0" "@pendulum-chain/types": "npm:^0.2.4" "@polkadot/api": "npm:^9.9.1" "@polkadot/api-base": "npm:^9.9.1" From c9abcbe6591a68e4807f3b7eb8d47e029e308c24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Sat, 6 Apr 2024 16:00:36 -0300 Subject: [PATCH 24/58] Funny commit --- src/blurp.tsx | 15 ++++++++++ .../Backstop/WithdrawLiquidity/index.tsx | 3 +- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 7 +++-- .../Swap/{Approval/index.tsx => Approval.tsx} | 8 ++--- .../nabla/Swap/{From/index.tsx => From.tsx} | 12 ++++---- .../Swap/{Progress/index.tsx => Progress.tsx} | 4 +-- .../nabla/Swap/{To/index.tsx => To.tsx} | 30 +++++++++---------- src/components/nabla/Swap/index.tsx | 3 +- src/components/nabla/Swap/schema.ts | 10 ++++++- src/components/nabla/Swap/types.ts | 8 ----- src/components/nabla/Swap/useSwapComponent.ts | 2 +- .../common/AssetSelectorModal.tsx} | 27 +++++++++-------- src/config/apps/nabla.ts | 25 ++++++++++++++-- src/shared/useContract.ts | 23 +++++++++++--- src/shared/useContractWrite.ts | 11 ++++--- 15 files changed, 123 insertions(+), 65 deletions(-) create mode 100644 src/blurp.tsx rename src/components/nabla/Swap/{Approval/index.tsx => Approval.tsx} (76%) rename src/components/nabla/Swap/{From/index.tsx => From.tsx} (88%) rename src/components/nabla/Swap/{Progress/index.tsx => Progress.tsx} (90%) rename src/components/nabla/Swap/{To/index.tsx => To.tsx} (89%) delete mode 100644 src/components/nabla/Swap/types.ts rename src/components/{Asset/Selector/Modal/index.tsx => nabla/common/AssetSelectorModal.tsx} (82%) diff --git a/src/blurp.tsx b/src/blurp.tsx new file mode 100644 index 00000000..8499466d --- /dev/null +++ b/src/blurp.tsx @@ -0,0 +1,15 @@ +// TODO Torsten + +const blurpConfig = { + read: false, + write: true, +}; + +export type BlurpType = keyof typeof blurpConfig; + +/* eslint-disable @typescript-eslint/no-explicit-any */ +export function blurp(type: BlurpType, ...args: any[]) { + if (blurpConfig[type]) { + console.log(...args); + } +} diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index a3dd3a11..3f4c5364 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -6,7 +6,6 @@ import { PoolProgress } from '../..'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { calcSharePercentage, getPoolSurplusNativeAmount, minMax } from '../../../../../helpers/calc'; import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; -import { AssetSelectorModal } from '../../../../Asset/Selector/Modal'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; import FormLoader from '../../../../Loader/Form'; @@ -15,6 +14,7 @@ import { TransactionSettingsDropdown } from '../../../../Transaction/Settings'; import TokenAmount from '../../TokenAmount'; import { useWithdrawLiquidity } from './useWithdrawLiquidity'; import { NablaInstance, NablaInstanceSwapPool, useNablaInstance } from '../../../../../hooks/nabla/useNablaInstance'; +import { AssetSelectorModal } from '../../../common/AssetSelectorModal'; const filter = (swapPools: NablaInstanceSwapPool[]): NablaInstanceSwapPool[] => { return swapPools?.filter((pool) => getPoolSurplusNativeAmount(pool) > 0n); @@ -205,6 +205,7 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element setValue('address', pools.find((pool) => pool.token.id === value.id)?.id); tokenModal[1].setFalse(); }} + excludedToken={undefined} selected={selectedPool.token.id} onClose={tokenModal[1].setFalse} /> diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts index c5d5cf6c..43bb8d32 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -16,7 +16,7 @@ import schema from './schema'; import { WithdrawLiquidityValues } from './types'; import { useBackstopWithdraw } from './useBackstopWithdraw'; import { useSwapPoolWithdraw } from './useSwapPoolWithdraw'; -import { NablaInstance } from '../../../../../hooks/nabla/useNablaInstance'; +import { NablaInstance, NablaInstanceSwapPool } from '../../../../../hooks/nabla/useNablaInstance'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; @@ -66,7 +66,10 @@ export const useWithdrawLiquidity = (nabla: NablaInstance) => { name: 'address', }); - const selectedPool = useMemo(() => swapPools.find((t) => t.id === address)!, [address, swapPools]); + const selectedPool: NablaInstanceSwapPool | undefined = useMemo( + () => swapPools.find((t) => t.id === address)!, + [address, swapPools], + ); const onWithdrawSuccess = useCallback(() => { reset(); diff --git a/src/components/nabla/Swap/Approval/index.tsx b/src/components/nabla/Swap/Approval.tsx similarity index 76% rename from src/components/nabla/Swap/Approval/index.tsx rename to src/components/nabla/Swap/Approval.tsx index 537f8b73..5eb7aa89 100644 --- a/src/components/nabla/Swap/Approval/index.tsx +++ b/src/components/nabla/Swap/Approval.tsx @@ -1,9 +1,9 @@ import { Button } from 'react-daisyui'; import { useFormContext, useWatch } from 'react-hook-form'; -import { useGetAppDataByTenant } from '../../../../hooks/useGetAppDataByTenant'; -import TokenApproval from '../../../Asset/Approval'; -import { SwapFormValues } from '../types'; -import { NablaInstanceToken } from '../../../../hooks/nabla/useNablaInstance'; +import { useGetAppDataByTenant } from '../../../hooks/useGetAppDataByTenant'; +import TokenApproval from '../../Asset/Approval'; +import { SwapFormValues } from './schema'; +import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; export interface ApprovalProps { token: NablaInstanceToken | undefined; diff --git a/src/components/nabla/Swap/From/index.tsx b/src/components/nabla/Swap/From.tsx similarity index 88% rename from src/components/nabla/Swap/From/index.tsx rename to src/components/nabla/Swap/From.tsx index 281f8ad0..584c87de 100644 --- a/src/components/nabla/Swap/From/index.tsx +++ b/src/components/nabla/Swap/From.tsx @@ -2,12 +2,12 @@ import { ChevronDownIcon } from '@heroicons/react/20/solid'; import { Fragment } from 'preact'; import { Button } from 'react-daisyui'; import { useFormContext, useWatch } from 'react-hook-form'; -import pendulumIcon from '../../../../assets/pendulum-icon.svg'; -import { useContractBalance } from '../../../../shared/useContractBalance'; -import TokenPrice from '../../Price'; -import { SwapFormValues } from '../types'; -import { NablaInstanceToken } from '../../../../hooks/nabla/useNablaInstance'; -import { erc20WrapperAbi } from '../../../../contracts/nabla/ERC20Wrapper'; +import pendulumIcon from '../../../assets/pendulum-icon.svg'; +import { useContractBalance } from '../../../shared/useContractBalance'; +import TokenPrice from '../Price'; +import { SwapFormValues } from './schema'; +import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; +import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; export interface FromProps { tokensMap: Record; diff --git a/src/components/nabla/Swap/Progress/index.tsx b/src/components/nabla/Swap/Progress.tsx similarity index 90% rename from src/components/nabla/Swap/Progress/index.tsx rename to src/components/nabla/Swap/Progress.tsx index 686226f7..b72d84a2 100644 --- a/src/components/nabla/Swap/Progress/index.tsx +++ b/src/components/nabla/Swap/Progress.tsx @@ -1,7 +1,7 @@ import { JSX } from 'preact'; import { Modal } from 'react-daisyui'; -import ModalCloseButton from '../../../Button/ModalClose'; -import TransactionProgress, { TransactionProgressProps } from '../../../Transaction/Progress'; +import ModalCloseButton from '../../Button/ModalClose'; +import TransactionProgress, { TransactionProgressProps } from '../../Transaction/Progress'; export type SwapProgressProps = { open: boolean; diff --git a/src/components/nabla/Swap/To/index.tsx b/src/components/nabla/Swap/To.tsx similarity index 89% rename from src/components/nabla/Swap/To/index.tsx rename to src/components/nabla/Swap/To.tsx index 7d3d0132..98759b22 100644 --- a/src/components/nabla/Swap/To/index.tsx +++ b/src/components/nabla/Swap/To.tsx @@ -3,21 +3,21 @@ import { InformationCircleIcon } from '@heroicons/react/24/outline'; import { useEffect } from 'preact/compat'; import { Button } from 'react-daisyui'; import { useFormContext, useWatch } from 'react-hook-form'; -import pendulumIcon from '../../../../assets/pendulum-icon.svg'; -import { config } from '../../../../config'; -import { subtractPercentage } from '../../../../helpers/calc'; -import { useTokenOutAmount } from '../../../../hooks/nabla/useTokenOutAmount'; -import useBoolean from '../../../../hooks/useBoolean'; -import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; -import { getMessageCallValue } from '../../../../shared/helpers'; -import { rawToDecimal, prettyNumbers, roundNumber } from '../../../../shared/parseNumbers'; -import Erc20Balance from '../../../Erc20Balance'; -import { numberLoader } from '../../../Loader'; -import { Skeleton } from '../../../Skeleton'; -import TokenPrice from '../../Price'; -import { SwapFormValues } from '../types'; -import { NablaInstanceToken } from '../../../../hooks/nabla/useNablaInstance'; -import { erc20WrapperAbi } from '../../../../contracts/nabla/ERC20Wrapper'; +import pendulumIcon from '../../../assets/pendulum-icon.svg'; +import { config } from '../../../config'; +import { subtractPercentage } from '../../../helpers/calc'; +import { useTokenOutAmount } from '../../../hooks/nabla/useTokenOutAmount'; +import useBoolean from '../../../hooks/useBoolean'; +import { useDebouncedValue } from '../../../hooks/useDebouncedValue'; +import { getMessageCallValue } from '../../../shared/helpers'; +import { rawToDecimal, prettyNumbers, roundNumber } from '../../../shared/parseNumbers'; +import Erc20Balance from '../../Erc20Balance'; +import { numberLoader } from '../../Loader'; +import { Skeleton } from '../../Skeleton'; +import TokenPrice from '../Price'; +import { SwapFormValues } from './schema'; +import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; +import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; export interface ToProps { tokensMap: Record; diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index a1c9f630..b6c21ee3 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -3,13 +3,13 @@ import { useMemo } from 'preact/compat'; import { Button, Card } from 'react-daisyui'; import { FormProvider } from 'react-hook-form'; import { errorClass } from '../../../helpers/form'; -import { AssetSelectorModal } from '../../Asset/Selector/Modal'; import { TransactionSettingsDropdown } from '../../Transaction/Settings'; import ApprovalSubmit from './Approval'; import From from './From'; import SwapProgress from './Progress'; import To from './To'; import { useSwapComponent, UseSwapComponentProps } from './useSwapComponent'; +import { AssetSelectorModal } from '../common/AssetSelectorModal'; const Swap = (props: UseSwapComponentProps): JSX.Element | null => { const { @@ -101,6 +101,7 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { open={!!modalType} onSelect={modalType === 'from' ? onFromChange : onToChange} selected={modalType ? (modalType === 'from' ? getValues('from') : getValues('to')) : undefined} + excludedToken={modalType === 'from' ? getValues('to') : getValues('from')} onClose={() => setModalType(undefined)} isLoading={isLoading} /> diff --git a/src/components/nabla/Swap/schema.ts b/src/components/nabla/Swap/schema.ts index 4f9b128c..96acdc53 100644 --- a/src/components/nabla/Swap/schema.ts +++ b/src/components/nabla/Swap/schema.ts @@ -1,6 +1,14 @@ import * as Yup from 'yup'; import { transformNumber } from '../../../helpers/yup'; -import { SwapFormValues } from './types'; + +export type SwapFormValues = { + from: string; + fromAmount: number; + to: string; + toAmount: number; + slippage: number | undefined; + deadline: number; +}; const schema = Yup.object().shape({ from: Yup.string().min(5).required(), diff --git a/src/components/nabla/Swap/types.ts b/src/components/nabla/Swap/types.ts deleted file mode 100644 index 0b3a63d7..00000000 --- a/src/components/nabla/Swap/types.ts +++ /dev/null @@ -1,8 +0,0 @@ -export type SwapFormValues = { - from: string; - fromAmount: number; - to: string; - toAmount: number; - slippage: number | undefined; - deadline: number; -}; diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index c89c274b..3d0e2360 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -16,7 +16,7 @@ import { storageService } from '../../../services/storage/local'; import { calcDeadline, decimalToRaw } from '../../../shared/parseNumbers'; import { useContractWrite } from '../../../shared/useContractWrite'; import schema from './schema'; -import { SwapFormValues } from './types'; +import { SwapFormValues } from './schema'; import { NablaInstanceToken, useNablaInstance } from '../../../hooks/nabla/useNablaInstance'; export interface UseSwapComponentProps { diff --git a/src/components/Asset/Selector/Modal/index.tsx b/src/components/nabla/common/AssetSelectorModal.tsx similarity index 82% rename from src/components/Asset/Selector/Modal/index.tsx rename to src/components/nabla/common/AssetSelectorModal.tsx index 3b7fe462..39df82fb 100644 --- a/src/components/Asset/Selector/Modal/index.tsx +++ b/src/components/nabla/common/AssetSelectorModal.tsx @@ -2,28 +2,30 @@ import { CheckIcon } from '@heroicons/react/20/solid'; import { matchSorter } from 'match-sorter'; import { ChangeEvent, useMemo, useState } from 'preact/compat'; import { Avatar, AvatarProps, Button, Input, Modal, ModalProps } from 'react-daisyui'; -import { repeat } from '../../../../helpers/general'; -import ModalCloseButton from '../../../Button/ModalClose'; -import { Skeleton } from '../../../Skeleton'; -import { NablaInstanceToken } from '../../../../hooks/nabla/useNablaInstance'; +import { repeat } from '../../../helpers/general'; +import ModalCloseButton from '../../Button/ModalClose'; +import { Skeleton } from '../../Skeleton'; +import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; -export interface AssetListProps { +interface AssetListProps { assets?: NablaInstanceToken[]; onSelect: (asset: NablaInstanceToken) => void; + excludedToken: string | undefined; selected?: string; } -function AssetList({ assets, onSelect, selected }: AssetListProps) { +function AssetList({ assets, onSelect, selected, excludedToken }: AssetListProps) { const [filter, setFilter] = useState(); const filteredTokens = useMemo( () => - filter && assets + (filter && assets ? matchSorter(assets, filter, { keys: ['name', 'address', 'symbol'], }) - : assets, - [assets, filter], + : assets + )?.filter((token) => token.id !== excludedToken), + [assets, filter, excludedToken], ); return ( @@ -71,7 +73,7 @@ function AssetList({ assets, onSelect, selected }: AssetListProps) { ); } -export type AssetSelectorModalProps = { +type AssetSelectorModalProps = { isLoading?: boolean; onClose: () => void; } & AssetListProps & @@ -80,6 +82,7 @@ export type AssetSelectorModalProps = { export function AssetSelectorModal({ assets, selected, + excludedToken, isLoading, onSelect, onClose, @@ -96,12 +99,10 @@ export function AssetSelectorModal({ {isLoading ? ( repeat() ) : ( - + )}
); } - -export default AssetList; diff --git a/src/config/apps/nabla.ts b/src/config/apps/nabla.ts index b8a027ba..d6152354 100644 --- a/src/config/apps/nabla.ts +++ b/src/config/apps/nabla.ts @@ -12,12 +12,31 @@ export type NablaConfig = AppConfigBase & > >; +// TODO: Torsten +const swapPools = 3 as 3 | 5 | 6; + +const foucoco3 = { + router: '6h5xgcRE7wsRzr8ekpNud52A1n3rLXdoEcZvor6gpwobY4SM', + oracle: '6kuQBzpjpAbkb88Er45dpsm9L5Cxkm1nGGCYGWheJ4cD8yE4', +}; + +const foucoco5 = { + router: '6ktcNuyJAEorkhYvDhMr8Xwx52wiVTMgtSF4mGXEHHrJTg15', + oracle: '6he7uQ7o79yJnjnWxRa4ekP6zuZm6pNd75pdJQkj88sRYce5', +}; + +const foucoco6 = { + router: '6iLPDFGXze6bGCc2Wp6VG74dQ6duA752H6iaRcoQkvLdBubz', + oracle: '6kn1seDUnJMWTqn316eQe6QCYTJFoy8MUdpiXfy4kuc42HTu', +}; + +const foucoco = swapPools === 3 ? foucoco3 : swapPools === 5 ? foucoco5 : foucoco6; + export const nablaConfig: NablaConfig = { tenants: [TenantName.Foucoco], environment: ['staging', 'development'], foucoco: { - indexerUrl: 'https://squid.subsquid.io/foucoco-squid/graphql', - router: '6h5xgcRE7wsRzr8ekpNud52A1n3rLXdoEcZvor6gpwobY4SM', - oracle: '6kuQBzpjpAbkb88Er45dpsm9L5Cxkm1nGGCYGWheJ4cD8yE4', + indexerUrl: 'https://squid.subsquid.io/foucoco-squid/v/v17/graphql', + ...foucoco, }, }; diff --git a/src/shared/useContract.ts b/src/shared/useContract.ts index 78e36a43..77f6dd28 100644 --- a/src/shared/useContract.ts +++ b/src/shared/useContract.ts @@ -6,6 +6,8 @@ import { QueryKey, useQuery, UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; import { defaultReadLimits, emptyCacheKey, emptyFn, QueryOptions } from './helpers'; import { useSharedState } from './Provider'; +// TODO Torsten +import { blurp } from '../blurp'; type ContractOpts = Limits | ((api: ApiPromise) => Limits); export type UseContractProps = QueryOptions & { @@ -45,7 +47,7 @@ export function useContract( enabled ? async () => { const limits = getLimits(options, api); - console.log('Call message', address, method, args); + blurp('read', 'Call message', address, method, args); const response = await messageCall({ abi: contractAbi, @@ -57,7 +59,7 @@ export function useContract( messageArguments: args || [], limits, }); - console.log('messageCall result', method, response); + blurp('read', 'messageCall result', method, response); return response; } @@ -68,8 +70,21 @@ export function useContract( }, ); - console.log(!!contractAbi, rest.enabled !== false, !!address, !!api, !!actualWalletAddress); - console.log('useContract result', method, enabled, key, address, method, args, query.status, query.data, query); + blurp('read', !!contractAbi, rest.enabled !== false, !!address, !!api, !!actualWalletAddress); + blurp( + 'read', + 'useContract result', + method, + enabled, + key, + address, + method, + args, + query.status, + query.data, + (query.data?.result as any)?.value, + (query.data?.result as any)?.value?.toString(), + ); return { refetch: query.refetch, diff --git a/src/shared/useContractWrite.ts b/src/shared/useContractWrite.ts index 6a4d2d23..5b4be116 100644 --- a/src/shared/useContractWrite.ts +++ b/src/shared/useContractWrite.ts @@ -8,6 +8,8 @@ import { useMemo, useState } from 'preact/compat'; import { createWriteOptions } from '../services/api/helpers'; import { defaultWriteLimits } from './helpers'; import { useSharedState } from './Provider'; +// TODO Torsten +import { blurp } from '../blurp'; // TODO: fix/improve types - parse abi file export type TransactionsStatus = { @@ -40,7 +42,7 @@ export const useContractWrite = >({ [abi, api?.registry], ); - console.log('useContractWrite', address, method, args); + blurp('write', 'useContractWrite', address, method, args); const isReady = !!contractAbi && !!address && !!api && !!walletAddress && !!signer; const submit = async (submitArgs?: any[] | void): Promise => { @@ -49,7 +51,8 @@ export const useContractWrite = >({ const fnArgs = submitArgs || args || []; const contractOptions = (typeof options === 'function' ? options(api) : options) || createWriteOptions(api); - console.log('call message write', address, method, args, submitArgs); + blurp('write', 'call message write', address, method, args, submitArgs); + blurp('write', 'limits', { ...defaultWriteLimits, ...contractOptions }); const response = await messageCall({ abi: contractAbi, @@ -65,10 +68,10 @@ export const useContractWrite = >({ messageName: method, messageArguments: fnArgs, limits: { ...defaultWriteLimits, ...contractOptions }, - gasLimitTolerancePercentage: 200, // Allow 3 fold gas tolerance + gasLimitTolerancePercentage: 10, // Allow 3 fold gas tolerance }); - console.log('call message write response', address, method, fnArgs, response); + blurp('write', 'call message write response', address, method, fnArgs, response); if (response?.result?.type !== 'success') throw response; return response; From 85ab543b94b81b40acb5ec251fb52218f4d13be0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Mon, 29 Apr 2024 07:54:22 -0300 Subject: [PATCH 25/58] Temporary commit --- codegen.ts | 3 +- gql/gql.ts | 4 +- gql/graphql.ts | 48 +++++- src/components/Transaction/Settings/index.tsx | 20 +-- .../Pools/Backstop/AddLiquidity/index.tsx | 2 +- .../Backstop/WithdrawLiquidity/index.tsx | 6 +- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 2 +- .../nabla/Pools/Swap/Redeem/index.tsx | 2 +- .../Pools/Swap/WithdrawLiquidity/index.tsx | 2 +- src/components/nabla/Swap/From.tsx | 107 ++++++------ src/components/nabla/Swap/Progress.tsx | 2 +- src/components/nabla/Swap/To.tsx | 158 +++++++++--------- src/components/nabla/Swap/index.tsx | 4 +- src/components/nabla/Swap/useSwapComponent.ts | 8 +- src/components/nabla/common/NumberInput.tsx | 30 ++++ .../common/TransactionProgress.tsx} | 16 +- src/config/apps/nabla.ts | 26 +-- src/helpers/form.ts | 4 - src/helpers/transaction.ts | 22 +-- src/hooks/nabla/useNablaInstance.ts | 2 + 20 files changed, 255 insertions(+), 213 deletions(-) create mode 100644 src/components/nabla/common/NumberInput.tsx rename src/components/{Transaction/Progress/index.tsx => nabla/common/TransactionProgress.tsx} (87%) delete mode 100644 src/helpers/form.ts diff --git a/codegen.ts b/codegen.ts index 4fb63852..858262c9 100644 --- a/codegen.ts +++ b/codegen.ts @@ -1,7 +1,8 @@ import { CodegenConfig } from '@graphql-codegen/cli'; const config: CodegenConfig = { - schema: 'https://squid.subsquid.io/foucoco-squid/graphql', + // TODO Torsten + schema: 'https://pendulum.squids.live/foucoco-squid/v/v21/graphql', documents: ['**/*.{ts,tsx}', '!gql/**/*'], generates: { './gql/': { diff --git a/gql/gql.ts b/gql/gql.ts index 3f680d29..d08d5b81 100644 --- a/gql/gql.ts +++ b/gql/gql.ts @@ -13,7 +13,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/ * Therefore it is highly recommended to use the babel or swc plugin for production. */ const documents = { - "\n query getRouter($id: String!) {\n routerById(id: $id) {\n id\n swapPools {\n id\n paused\n name\n reserve\n reserveWithSlippage\n totalLiabilities\n totalSupply\n lpTokenDecimals\n apr\n symbol\n token {\n id\n decimals\n name\n symbol\n }\n }\n backstopPool {\n id\n name\n paused\n symbol\n totalSupply\n apr\n reserves\n lpTokenDecimals\n token {\n id\n decimals\n name\n symbol\n }\n }\n paused\n }\n }\n": types.GetRouterDocument, + "\n query getRouter($id: String!) {\n routerById(id: $id) {\n id\n swapPools {\n id\n paused\n name\n reserve\n reserveWithSlippage\n totalLiabilities\n totalSupply\n lpTokenDecimals\n apr\n symbol\n token {\n id\n decimals\n name\n symbol\n }\n insuranceFeeBps\n protocolTreasuryAddress\n }\n backstopPool {\n id\n name\n paused\n symbol\n totalSupply\n apr\n reserves\n lpTokenDecimals\n token {\n id\n decimals\n name\n symbol\n }\n }\n paused\n }\n }\n": types.GetRouterDocument, }; /** @@ -33,7 +33,7 @@ export function graphql(source: string): unknown; /** * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. */ -export function graphql(source: "\n query getRouter($id: String!) {\n routerById(id: $id) {\n id\n swapPools {\n id\n paused\n name\n reserve\n reserveWithSlippage\n totalLiabilities\n totalSupply\n lpTokenDecimals\n apr\n symbol\n token {\n id\n decimals\n name\n symbol\n }\n }\n backstopPool {\n id\n name\n paused\n symbol\n totalSupply\n apr\n reserves\n lpTokenDecimals\n token {\n id\n decimals\n name\n symbol\n }\n }\n paused\n }\n }\n"): (typeof documents)["\n query getRouter($id: String!) {\n routerById(id: $id) {\n id\n swapPools {\n id\n paused\n name\n reserve\n reserveWithSlippage\n totalLiabilities\n totalSupply\n lpTokenDecimals\n apr\n symbol\n token {\n id\n decimals\n name\n symbol\n }\n }\n backstopPool {\n id\n name\n paused\n symbol\n totalSupply\n apr\n reserves\n lpTokenDecimals\n token {\n id\n decimals\n name\n symbol\n }\n }\n paused\n }\n }\n"]; +export function graphql(source: "\n query getRouter($id: String!) {\n routerById(id: $id) {\n id\n swapPools {\n id\n paused\n name\n reserve\n reserveWithSlippage\n totalLiabilities\n totalSupply\n lpTokenDecimals\n apr\n symbol\n token {\n id\n decimals\n name\n symbol\n }\n insuranceFeeBps\n protocolTreasuryAddress\n }\n backstopPool {\n id\n name\n paused\n symbol\n totalSupply\n apr\n reserves\n lpTokenDecimals\n token {\n id\n decimals\n name\n symbol\n }\n }\n paused\n }\n }\n"): (typeof documents)["\n query getRouter($id: String!) {\n routerById(id: $id) {\n id\n swapPools {\n id\n paused\n name\n reserve\n reserveWithSlippage\n totalLiabilities\n totalSupply\n lpTokenDecimals\n apr\n symbol\n token {\n id\n decimals\n name\n symbol\n }\n insuranceFeeBps\n protocolTreasuryAddress\n }\n backstopPool {\n id\n name\n paused\n symbol\n totalSupply\n apr\n reserves\n lpTokenDecimals\n token {\n id\n decimals\n name\n symbol\n }\n }\n paused\n }\n }\n"]; export function graphql(source: string) { return (documents as any)[source] ?? {}; diff --git a/gql/graphql.ts b/gql/graphql.ts index fc06fa38..6c5f9bef 100644 --- a/gql/graphql.ts +++ b/gql/graphql.ts @@ -3598,6 +3598,10 @@ export enum NablaSwapFeeOrderByInput { SwapPoolIdAscNullsFirst = 'swapPool_id_ASC_NULLS_FIRST', SwapPoolIdDesc = 'swapPool_id_DESC', SwapPoolIdDescNullsLast = 'swapPool_id_DESC_NULLS_LAST', + SwapPoolInsuranceFeeBpsAsc = 'swapPool_insuranceFeeBps_ASC', + SwapPoolInsuranceFeeBpsAscNullsFirst = 'swapPool_insuranceFeeBps_ASC_NULLS_FIRST', + SwapPoolInsuranceFeeBpsDesc = 'swapPool_insuranceFeeBps_DESC', + SwapPoolInsuranceFeeBpsDescNullsLast = 'swapPool_insuranceFeeBps_DESC_NULLS_LAST', SwapPoolLpTokenDecimalsAsc = 'swapPool_lpTokenDecimals_ASC', SwapPoolLpTokenDecimalsAscNullsFirst = 'swapPool_lpTokenDecimals_ASC_NULLS_FIRST', SwapPoolLpTokenDecimalsDesc = 'swapPool_lpTokenDecimals_DESC', @@ -3610,6 +3614,10 @@ export enum NablaSwapFeeOrderByInput { SwapPoolPausedAscNullsFirst = 'swapPool_paused_ASC_NULLS_FIRST', SwapPoolPausedDesc = 'swapPool_paused_DESC', SwapPoolPausedDescNullsLast = 'swapPool_paused_DESC_NULLS_LAST', + SwapPoolProtocolTreasuryAddressAsc = 'swapPool_protocolTreasuryAddress_ASC', + SwapPoolProtocolTreasuryAddressAscNullsFirst = 'swapPool_protocolTreasuryAddress_ASC_NULLS_FIRST', + SwapPoolProtocolTreasuryAddressDesc = 'swapPool_protocolTreasuryAddress_DESC', + SwapPoolProtocolTreasuryAddressDescNullsLast = 'swapPool_protocolTreasuryAddress_DESC_NULLS_LAST', SwapPoolReserveWithSlippageAsc = 'swapPool_reserveWithSlippage_ASC', SwapPoolReserveWithSlippageAscNullsFirst = 'swapPool_reserveWithSlippage_ASC_NULLS_FIRST', SwapPoolReserveWithSlippageDesc = 'swapPool_reserveWithSlippage_DESC', @@ -9961,9 +9969,11 @@ export type SwapPool = { backstop: BackstopPool; feesHistory: Array; id: Scalars['String']['output']; + insuranceFeeBps: Scalars['BigInt']['output']; lpTokenDecimals: Scalars['Int']['output']; name: Scalars['String']['output']; paused: Scalars['Boolean']['output']; + protocolTreasuryAddress?: Maybe; reserve: Scalars['BigInt']['output']; reserveWithSlippage: Scalars['BigInt']['output']; router?: Maybe; @@ -10028,6 +10038,10 @@ export enum SwapPoolOrderByInput { IdAscNullsFirst = 'id_ASC_NULLS_FIRST', IdDesc = 'id_DESC', IdDescNullsLast = 'id_DESC_NULLS_LAST', + InsuranceFeeBpsAsc = 'insuranceFeeBps_ASC', + InsuranceFeeBpsAscNullsFirst = 'insuranceFeeBps_ASC_NULLS_FIRST', + InsuranceFeeBpsDesc = 'insuranceFeeBps_DESC', + InsuranceFeeBpsDescNullsLast = 'insuranceFeeBps_DESC_NULLS_LAST', LpTokenDecimalsAsc = 'lpTokenDecimals_ASC', LpTokenDecimalsAscNullsFirst = 'lpTokenDecimals_ASC_NULLS_FIRST', LpTokenDecimalsDesc = 'lpTokenDecimals_DESC', @@ -10040,6 +10054,10 @@ export enum SwapPoolOrderByInput { PausedAscNullsFirst = 'paused_ASC_NULLS_FIRST', PausedDesc = 'paused_DESC', PausedDescNullsLast = 'paused_DESC_NULLS_LAST', + ProtocolTreasuryAddressAsc = 'protocolTreasuryAddress_ASC', + ProtocolTreasuryAddressAscNullsFirst = 'protocolTreasuryAddress_ASC_NULLS_FIRST', + ProtocolTreasuryAddressDesc = 'protocolTreasuryAddress_DESC', + ProtocolTreasuryAddressDescNullsLast = 'protocolTreasuryAddress_DESC_NULLS_LAST', ReserveWithSlippageAsc = 'reserveWithSlippage_ASC', ReserveWithSlippageAscNullsFirst = 'reserveWithSlippage_ASC_NULLS_FIRST', ReserveWithSlippageDesc = 'reserveWithSlippage_DESC', @@ -10120,6 +10138,15 @@ export type SwapPoolWhereInput = { id_not_in?: InputMaybe>; id_not_startsWith?: InputMaybe; id_startsWith?: InputMaybe; + insuranceFeeBps_eq?: InputMaybe; + insuranceFeeBps_gt?: InputMaybe; + insuranceFeeBps_gte?: InputMaybe; + insuranceFeeBps_in?: InputMaybe>; + insuranceFeeBps_isNull?: InputMaybe; + insuranceFeeBps_lt?: InputMaybe; + insuranceFeeBps_lte?: InputMaybe; + insuranceFeeBps_not_eq?: InputMaybe; + insuranceFeeBps_not_in?: InputMaybe>; lpTokenDecimals_eq?: InputMaybe; lpTokenDecimals_gt?: InputMaybe; lpTokenDecimals_gte?: InputMaybe; @@ -10149,6 +10176,23 @@ export type SwapPoolWhereInput = { paused_eq?: InputMaybe; paused_isNull?: InputMaybe; paused_not_eq?: InputMaybe; + protocolTreasuryAddress_contains?: InputMaybe; + protocolTreasuryAddress_containsInsensitive?: InputMaybe; + protocolTreasuryAddress_endsWith?: InputMaybe; + protocolTreasuryAddress_eq?: InputMaybe; + protocolTreasuryAddress_gt?: InputMaybe; + protocolTreasuryAddress_gte?: InputMaybe; + protocolTreasuryAddress_in?: InputMaybe>; + protocolTreasuryAddress_isNull?: InputMaybe; + protocolTreasuryAddress_lt?: InputMaybe; + protocolTreasuryAddress_lte?: InputMaybe; + protocolTreasuryAddress_not_contains?: InputMaybe; + protocolTreasuryAddress_not_containsInsensitive?: InputMaybe; + protocolTreasuryAddress_not_endsWith?: InputMaybe; + protocolTreasuryAddress_not_eq?: InputMaybe; + protocolTreasuryAddress_not_in?: InputMaybe>; + protocolTreasuryAddress_not_startsWith?: InputMaybe; + protocolTreasuryAddress_startsWith?: InputMaybe; reserveWithSlippage_eq?: InputMaybe; reserveWithSlippage_gt?: InputMaybe; reserveWithSlippage_gte?: InputMaybe; @@ -12320,7 +12364,7 @@ export type GetRouterQueryVariables = Exact<{ }>; -export type GetRouterQuery = { __typename?: 'Query', routerById?: { __typename?: 'Router', id: string, paused: boolean, swapPools: Array<{ __typename?: 'SwapPool', id: string, paused: boolean, name: string, reserve: any, reserveWithSlippage: any, totalLiabilities: any, totalSupply: any, lpTokenDecimals: number, apr: any, symbol: string, token: { __typename?: 'NablaToken', id: string, decimals: number, name: string, symbol: string } }>, backstopPool: Array<{ __typename?: 'BackstopPool', id: string, name: string, paused: boolean, symbol: string, totalSupply: any, apr: any, reserves: any, lpTokenDecimals: number, token: { __typename?: 'NablaToken', id: string, decimals: number, name: string, symbol: string } }> } | null }; +export type GetRouterQuery = { __typename?: 'Query', routerById?: { __typename?: 'Router', id: string, paused: boolean, swapPools: Array<{ __typename?: 'SwapPool', id: string, paused: boolean, name: string, reserve: any, reserveWithSlippage: any, totalLiabilities: any, totalSupply: any, lpTokenDecimals: number, apr: any, symbol: string, insuranceFeeBps: any, protocolTreasuryAddress?: string | null, token: { __typename?: 'NablaToken', id: string, decimals: number, name: string, symbol: string } }>, backstopPool: Array<{ __typename?: 'BackstopPool', id: string, name: string, paused: boolean, symbol: string, totalSupply: any, apr: any, reserves: any, lpTokenDecimals: number, token: { __typename?: 'NablaToken', id: string, decimals: number, name: string, symbol: string } }> } | null }; -export const GetRouterDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getRouter"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"id"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"routerById"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"id"},"value":{"kind":"Variable","name":{"kind":"Name","value":"id"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"reserve"}},{"kind":"Field","name":{"kind":"Name","value":"reserveWithSlippage"}},{"kind":"Field","name":{"kind":"Name","value":"totalLiabilities"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"lpTokenDecimals"}},{"kind":"Field","name":{"kind":"Name","value":"apr"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"backstopPool"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"apr"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"lpTokenDecimals"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"paused"}}]}}]}}]} as unknown as DocumentNode; \ No newline at end of file +export const GetRouterDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"getRouter"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"id"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"routerById"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"id"},"value":{"kind":"Variable","name":{"kind":"Name","value":"id"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"swapPools"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"reserve"}},{"kind":"Field","name":{"kind":"Name","value":"reserveWithSlippage"}},{"kind":"Field","name":{"kind":"Name","value":"totalLiabilities"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"lpTokenDecimals"}},{"kind":"Field","name":{"kind":"Name","value":"apr"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}},{"kind":"Field","name":{"kind":"Name","value":"insuranceFeeBps"}},{"kind":"Field","name":{"kind":"Name","value":"protocolTreasuryAddress"}}]}},{"kind":"Field","name":{"kind":"Name","value":"backstopPool"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"paused"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}},{"kind":"Field","name":{"kind":"Name","value":"totalSupply"}},{"kind":"Field","name":{"kind":"Name","value":"apr"}},{"kind":"Field","name":{"kind":"Name","value":"reserves"}},{"kind":"Field","name":{"kind":"Name","value":"lpTokenDecimals"}},{"kind":"Field","name":{"kind":"Name","value":"token"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"decimals"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"symbol"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"paused"}}]}}]}}]} as unknown as DocumentNode; \ No newline at end of file diff --git a/src/components/Transaction/Settings/index.tsx b/src/components/Transaction/Settings/index.tsx index 42b2a187..bc0d47c6 100644 --- a/src/components/Transaction/Settings/index.tsx +++ b/src/components/Transaction/Settings/index.tsx @@ -20,12 +20,7 @@ const TransactionSettings = ({

Settings

-
- Slippage tolerance -
- -
-
+
Slippage tolerance
-
- Transaction Deadline -
- -
-
+
Transaction Deadline
{deadlineProps && (
{ return swapPools?.filter((pool) => getPoolSurplusNativeAmount(pool) > 0n); @@ -119,7 +119,7 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element type="button" onClick={tokenModal[1].setTrue} > - {selectedPool.token.symbol} + {selectedPool?.token.symbol}
diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index ef05785e..d53fe5d5 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -6,9 +6,9 @@ import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import TokenApproval from '../../../../Asset/Approval'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; -import TransactionProgress from '../../../../Transaction/Progress'; import { SwapPoolColumn } from '../columns'; import { useAddLiquidity } from './useAddLiquidity'; +import TransactionProgress from '../../../common/TransactionProgress'; export interface AddLiquidityProps { data: SwapPoolColumn; diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index d3450861..cde2e47c 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -7,11 +7,11 @@ import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; -import TransactionProgress from '../../../../Transaction/Progress'; import { TransactionSettingsDropdown } from '../../../../Transaction/Settings'; import TokenPrice from '../../../Price'; import { SwapPoolColumn } from '../columns'; import { useRedeem } from './useRedeem'; +import TransactionProgress from '../../../common/TransactionProgress'; export interface RedeemProps { data: SwapPoolColumn; diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index be09b670..5a0c9651 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -7,11 +7,11 @@ import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; -import TransactionProgress from '../../../../Transaction/Progress'; import TokenAmount from '../../TokenAmount'; import { SwapPoolColumn } from '../columns'; import { ModalTypes } from '../Modals/types'; import { useSwapPoolWithdrawLiquidity } from './useWithdrawLiquidity'; +import TransactionProgress from '../../../common/TransactionProgress'; export interface WithdrawLiquidityProps { data: SwapPoolColumn; diff --git a/src/components/nabla/Swap/From.tsx b/src/components/nabla/Swap/From.tsx index 584c87de..79794345 100644 --- a/src/components/nabla/Swap/From.tsx +++ b/src/components/nabla/Swap/From.tsx @@ -8,20 +8,25 @@ import TokenPrice from '../Price'; import { SwapFormValues } from './schema'; import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; +//import NumberInput from '../common/NumberInput'; export interface FromProps { tokensMap: Record; onOpenSelector: () => void; errorMessage?: string; - className?: string; } -const From = ({ tokensMap, onOpenSelector, className, errorMessage }: FromProps): JSX.Element | null => { +function NumberInput(props: any) { + return ; +} + +const From = ({ tokensMap, onOpenSelector, errorMessage }: FromProps): JSX.Element | null => { const { register, setValue, control } = useFormContext(); const from = useWatch({ control, name: 'from', }); + const token = tokensMap[from]; const { formatted, balance } = useContractBalance({ contractAddress: token?.id, @@ -29,58 +34,60 @@ const From = ({ tokensMap, onOpenSelector, className, errorMessage }: FromProps) abi: erc20WrapperAbi, }); + const inputHasError = errorMessage !== undefined; + return ( - <> -
-
-
- undefined })} - /> -
- +
+
+
+
-
-
{token ? : '$ -'}
-
- {balance !== undefined && ( - - Balance: {formatted} - - - - )} -
- {errorMessage !== undefined &&
{errorMessage}
} + +
+
+
{token ? : '$ -'}
+
+ {balance !== undefined && ( + + Balance: {formatted} + + + + )}
+ {errorMessage !== undefined &&
{errorMessage}
}
- +
); }; export default From; diff --git a/src/components/nabla/Swap/Progress.tsx b/src/components/nabla/Swap/Progress.tsx index b72d84a2..fc5602d0 100644 --- a/src/components/nabla/Swap/Progress.tsx +++ b/src/components/nabla/Swap/Progress.tsx @@ -1,7 +1,7 @@ import { JSX } from 'preact'; import { Modal } from 'react-daisyui'; import ModalCloseButton from '../../Button/ModalClose'; -import TransactionProgress, { TransactionProgressProps } from '../../Transaction/Progress'; +import TransactionProgress, { TransactionProgressProps } from '../common/TransactionProgress'; export type SwapProgressProps = { open: boolean; diff --git a/src/components/nabla/Swap/To.tsx b/src/components/nabla/Swap/To.tsx index 98759b22..ebb78d66 100644 --- a/src/components/nabla/Swap/To.tsx +++ b/src/components/nabla/Swap/To.tsx @@ -22,10 +22,10 @@ import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; export interface ToProps { tokensMap: Record; onOpenSelector: () => void; - className?: string; + inputHasError: boolean; } -const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | null => { +const To = ({ tokensMap, onOpenSelector, inputHasError }: ToProps): JSX.Element | null => { const [isOpen, { toggle }] = useBoolean(true); const { setValue, setError, clearErrors, control } = useFormContext(); @@ -47,6 +47,8 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu }), ); + console.log('fromDecimalAmount', fromDecimalAmount); + const slippage = Number( useWatch({ control, @@ -113,94 +115,94 @@ const To = ({ tokensMap, onOpenSelector, className }: ToProps): JSX.Element | nu fromDecimalAmount, ); return ( - <> -
-
-
- {loading ? ( - numberLoader - ) : value ? ( - `${value}` - ) : fromDecimalAmount > 0 ? ( - +
+
+
+ {loading ? ( + numberLoader + ) : value ? ( + `${value}` + ) : fromDecimalAmount > 0 ? ( + + ) : ( + <>0 + )} +
+ +
+
+
{toToken ? : '$ -'}
+
+ Balance: +
+
+
+
+
+
+ {fromToken && toToken && value && fromDecimalAmount ? ( + <> +
+ +
+ {`1 ${fromToken.symbol} = ${roundNumber(Number(value) / fromDecimalAmount, 6)} ${toToken.symbol}`} + ) : ( - <>0 + `- ${toToken?.symbol || ''}` )}
- -
-
-
{toToken ? : '$ -'}
-
- Balance: +
+
+ +
-
-
-
-
- {fromToken && toToken && value && fromDecimalAmount ? ( - <> -
- -
- {`1 ${fromToken.symbol} = ${roundNumber(Number(value) / fromDecimalAmount, 6)} ${toToken.symbol}`} - - ) : ( - `- ${toToken?.symbol || ''}` - )} -
+
+
+
Expected Output:
-
- -
+ + {value} {toToken?.symbol || ''} +
-
-
-
Expected Output:
-
- - {value} {toToken?.symbol || ''} - -
-
-
-
Minimum received after slippage ({slippage}%)
-
- - {subtractPercentage(Number(value), slippage)} {toToken?.symbol || ''} - -
-
-
-
Swap fee:
-
-
+
+
Minimum received after slippage ({slippage}%)
+
+ + {subtractPercentage(Number(value), slippage)} {toToken?.symbol || ''} +
+
+
Swap fee:
+
-
+
- +
); }; export default To; diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index b6c21ee3..7ec15a54 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -2,7 +2,6 @@ import { Cog8ToothIcon } from '@heroicons/react/24/outline'; import { useMemo } from 'preact/compat'; import { Button, Card } from 'react-daisyui'; import { FormProvider } from 'react-hook-form'; -import { errorClass } from '../../../helpers/form'; import { TransactionSettingsDropdown } from '../../Transaction/Settings'; import ApprovalSubmit from './Approval'; import From from './From'; @@ -81,13 +80,12 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { setModalType('from')} - className={`border ${errorClass(errors.fromAmount, 'border-red-600', 'border-transparent')}`} errorMessage={errors.fromAmount?.message} /> setModalType('to')} - className={`border ${errorClass(errors.to, 'border-red-600', 'border-transparent')}`} + inputHasError={errors.to !== undefined} />
{/* */} diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index 3d0e2360..57811a6a 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -48,6 +48,7 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { const tokensModal = useState(); const setTokenModal = tokensModal[1]; const storageState = useRef(getInitialValues()); + const initFrom = props.from || storageState.current.from; const initTo = props.to || storageState.current.to; const defaultFormValues = { @@ -139,12 +140,6 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { [getValues, onChange, setTokenModal, setValue, updateStorage], ); - const onReverse = useCallback(() => { - const prev = getValues(); - if (prev.from) onToChange(prev.from); - else if (prev.to) onFromChange(prev.to); - }, [getValues, onFromChange, onToChange]); - // when props change (url updated) useEffect(() => { if (hadMountedRef) { @@ -162,7 +157,6 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { tokensModal, onFromChange, onToChange, - onReverse, updateStorage, from, isLoading, diff --git a/src/components/nabla/common/NumberInput.tsx b/src/components/nabla/common/NumberInput.tsx new file mode 100644 index 00000000..a35345f3 --- /dev/null +++ b/src/components/nabla/common/NumberInput.tsx @@ -0,0 +1,30 @@ +import { HTMLAttributes, useCallback } from 'react'; + +export interface NumberInputPropse { + attributes: HTMLAttributes; +} + +/* +// Hack required for Preact compatibility with react-hook-form +export default function NumberInput(attributes: HTMLAttributes) { + const { onChange } = attributes; + const attributesWithoutOnChange = { ...attributes }; + // delete attributesWithoutOnChange.onChange; + + const onInput = useCallback( + (e: React.ChangeEvent) => { + let number = e.currentTarget.value.replace(/[^0-9.]/g, ''); + const periodIndex = number.indexOf('.'); + if (periodIndex > -1) { + number = number.slice(0, periodIndex + 1) + number.slice(periodIndex + 1).replace(/\./g, ''); + } + + e.currentTarget.value = number; + e.target.value = number; + onChange?.(e); + }, + [onChange], + ); + + return ; +} */ diff --git a/src/components/Transaction/Progress/index.tsx b/src/components/nabla/common/TransactionProgress.tsx similarity index 87% rename from src/components/Transaction/Progress/index.tsx rename to src/components/nabla/common/TransactionProgress.tsx index fb64d5db..e97a1d32 100644 --- a/src/components/Transaction/Progress/index.tsx +++ b/src/components/nabla/common/TransactionProgress.tsx @@ -1,8 +1,8 @@ import { CheckCircleIcon, ExclamationCircleIcon } from '@heroicons/react/24/outline'; +import { MessageCallResult } from '@pendulum-chain/api-solang'; import { ComponentChildren } from 'preact'; import { Button } from 'react-daisyui'; import Spinner from '../../../assets/spinner'; -import { getErrorMessage } from '../../../helpers/transaction'; import { useGetTenantConfig } from '../../../hooks/useGetTenantConfig'; import { UseContractWriteResponse } from '../../../shared/useContractWrite'; @@ -15,6 +15,20 @@ export interface TransactionProgressProps { onClose: () => void; } +const getErrorMessage = (data?: MessageCallResult['result']) => { + if (!data) return undefined; + switch (data.type) { + case 'error': + return data.error; + case 'panic': + return data.explanation; + case 'reverted': + return data.description; + default: + return undefined; + } +}; + const TransactionProgress = ({ mutation, children, onClose }: TransactionProgressProps): JSX.Element | null => { const { explorer } = useGetTenantConfig(); if (mutation.isIdle) return null; diff --git a/src/config/apps/nabla.ts b/src/config/apps/nabla.ts index d6152354..750295b4 100644 --- a/src/config/apps/nabla.ts +++ b/src/config/apps/nabla.ts @@ -12,31 +12,13 @@ export type NablaConfig = AppConfigBase & > >; -// TODO: Torsten -const swapPools = 3 as 3 | 5 | 6; - -const foucoco3 = { - router: '6h5xgcRE7wsRzr8ekpNud52A1n3rLXdoEcZvor6gpwobY4SM', - oracle: '6kuQBzpjpAbkb88Er45dpsm9L5Cxkm1nGGCYGWheJ4cD8yE4', -}; - -const foucoco5 = { - router: '6ktcNuyJAEorkhYvDhMr8Xwx52wiVTMgtSF4mGXEHHrJTg15', - oracle: '6he7uQ7o79yJnjnWxRa4ekP6zuZm6pNd75pdJQkj88sRYce5', -}; - -const foucoco6 = { - router: '6iLPDFGXze6bGCc2Wp6VG74dQ6duA752H6iaRcoQkvLdBubz', - oracle: '6kn1seDUnJMWTqn316eQe6QCYTJFoy8MUdpiXfy4kuc42HTu', -}; - -const foucoco = swapPools === 3 ? foucoco3 : swapPools === 5 ? foucoco5 : foucoco6; - export const nablaConfig: NablaConfig = { tenants: [TenantName.Foucoco], environment: ['staging', 'development'], foucoco: { - indexerUrl: 'https://squid.subsquid.io/foucoco-squid/v/v17/graphql', - ...foucoco, + // TODO Torsten + indexerUrl: 'https://pendulum.squids.live/foucoco-squid/v/v21/graphql', + router: '6ijJtaZuwpZCiaVo6pSHRJbd8qejgywYsejnjfo2AVanN14E', + oracle: '6jscuYjvoPesdnzdnUNYEntLmGY3R6F5hJoTum1oaV7VVcxE', }, }; diff --git a/src/helpers/form.ts b/src/helpers/form.ts deleted file mode 100644 index 15f08536..00000000 --- a/src/helpers/form.ts +++ /dev/null @@ -1,4 +0,0 @@ -import { FieldError } from 'react-hook-form'; - -export const errorClass = (err: FieldError | undefined, errClass = 'input-error', successClass = '') => - err ? errClass : successClass; diff --git a/src/helpers/transaction.ts b/src/helpers/transaction.ts index 8220cdeb..a6d943e3 100644 --- a/src/helpers/transaction.ts +++ b/src/helpers/transaction.ts @@ -1,28 +1,8 @@ -import { MessageCallResult } from '@pendulum-chain/api-solang'; -import { toast } from 'react-toastify'; import { config } from '../config'; -export const transactionErrorToast = (err: unknown) => { - const cancelled = String(err).startsWith('Error: Cancelled'); - toast(cancelled ? 'Transaction cancelled' : 'Transaction failed', { type: 'error' }); -}; - -export const getErrorMessage = (data?: MessageCallResult['result']) => { - if (!data) return undefined; - switch (data.type) { - case 'error': - return data.error; - case 'panic': - return data.explanation; - case 'reverted': - return data.description; - default: - return undefined; - } -}; - const { slippage, deadline } = config.transaction.settings; export const getValidSlippage = (val?: number): number | undefined => val !== undefined ? Math.min(Math.max(val, slippage.min), slippage.max) : val; + export const getValidDeadline = (val: number): number => Math.min(Math.max(val, deadline.min), deadline.max); diff --git a/src/hooks/nabla/useNablaInstance.ts b/src/hooks/nabla/useNablaInstance.ts index 469e853e..0c45839e 100644 --- a/src/hooks/nabla/useNablaInstance.ts +++ b/src/hooks/nabla/useNablaInstance.ts @@ -73,6 +73,8 @@ export const getNablaInstance = graphql(` name symbol } + insuranceFeeBps + protocolTreasuryAddress } backstopPool { id From 9473ace307cc8453f90e37c1072e4901ed83c64c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Mon, 29 Apr 2024 13:15:06 -0300 Subject: [PATCH 26/58] Add NumberInput hack --- src/components/nabla/Swap/From.tsx | 12 ++++------- src/components/nabla/common/NumberInput.tsx | 24 ++++++++++++--------- 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/src/components/nabla/Swap/From.tsx b/src/components/nabla/Swap/From.tsx index 79794345..788bec19 100644 --- a/src/components/nabla/Swap/From.tsx +++ b/src/components/nabla/Swap/From.tsx @@ -8,7 +8,7 @@ import TokenPrice from '../Price'; import { SwapFormValues } from './schema'; import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; -//import NumberInput from '../common/NumberInput'; +import NumberInput from '../common/NumberInput'; export interface FromProps { tokensMap: Record; @@ -16,12 +16,8 @@ export interface FromProps { errorMessage?: string; } -function NumberInput(props: any) { - return ; -} - const From = ({ tokensMap, onOpenSelector, errorMessage }: FromProps): JSX.Element | null => { - const { register, setValue, control } = useFormContext(); + const { setValue, control } = useFormContext(); const from = useWatch({ control, name: 'from', @@ -42,11 +38,11 @@ const From = ({ tokensMap, onOpenSelector, errorMessage }: FromProps): JSX.Eleme >
-
-
{token ? : '$ -'}
+
{token ? : '$ -'}
{balance !== undefined && ( diff --git a/src/components/nabla/Swap/Progress.tsx b/src/components/nabla/Swap/Progress.tsx index fc5602d0..fcf489a1 100644 --- a/src/components/nabla/Swap/Progress.tsx +++ b/src/components/nabla/Swap/Progress.tsx @@ -1,7 +1,7 @@ import { JSX } from 'preact'; import { Modal } from 'react-daisyui'; import ModalCloseButton from '../../Button/ModalClose'; -import TransactionProgress, { TransactionProgressProps } from '../common/TransactionProgress'; +import { TransactionProgress, TransactionProgressProps } from '../common/TransactionProgress'; export type SwapProgressProps = { open: boolean; diff --git a/src/components/nabla/Swap/To.tsx b/src/components/nabla/Swap/To.tsx index ebb78d66..06ea375a 100644 --- a/src/components/nabla/Swap/To.tsx +++ b/src/components/nabla/Swap/To.tsx @@ -11,13 +11,13 @@ import useBoolean from '../../../hooks/useBoolean'; import { useDebouncedValue } from '../../../hooks/useDebouncedValue'; import { getMessageCallValue } from '../../../shared/helpers'; import { rawToDecimal, prettyNumbers, roundNumber } from '../../../shared/parseNumbers'; -import Erc20Balance from '../../Erc20Balance'; import { numberLoader } from '../../Loader'; import { Skeleton } from '../../Skeleton'; -import TokenPrice from '../Price'; import { SwapFormValues } from './schema'; import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; +import { NablaTokenPrice } from '../common/NablaTokenPrice'; +import { Erc20Balance } from '../common/Erc20Balance'; export interface ToProps { tokensMap: Record; @@ -25,7 +25,7 @@ export interface ToProps { inputHasError: boolean; } -const To = ({ tokensMap, onOpenSelector, inputHasError }: ToProps): JSX.Element | null => { +export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps): JSX.Element | null { const [isOpen, { toggle }] = useBoolean(true); const { setValue, setError, clearErrors, control } = useFormContext(); @@ -47,8 +47,6 @@ const To = ({ tokensMap, onOpenSelector, inputHasError }: ToProps): JSX.Element }), ); - console.log('fromDecimalAmount', fromDecimalAmount); - const slippage = Number( useWatch({ control, @@ -60,6 +58,8 @@ const To = ({ tokensMap, onOpenSelector, inputHasError }: ToProps): JSX.Element const toToken: NablaInstanceToken | undefined = tokensMap?.[to]; const debouncedFromDecimalAmount = useDebouncedValue(fromDecimalAmount, 800); + + console.log('Before call useTokenOutAmount'); const { isLoading, fetchStatus, data, refetch } = useTokenOutAmount({ fromDecimalAmount: debouncedFromDecimalAmount, from, @@ -146,7 +146,7 @@ const To = ({ tokensMap, onOpenSelector, inputHasError }: ToProps): JSX.Element
-
{toToken ? : '$ -'}
+
{toToken ? : '$ -'}
Balance:
@@ -204,5 +204,4 @@ const To = ({ tokensMap, onOpenSelector, inputHasError }: ToProps): JSX.Element
); -}; -export default To; +} diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index 7ec15a54..f7400324 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -3,7 +3,7 @@ import { useMemo } from 'preact/compat'; import { Button, Card } from 'react-daisyui'; import { FormProvider } from 'react-hook-form'; import { TransactionSettingsDropdown } from '../../Transaction/Settings'; -import ApprovalSubmit from './Approval'; +import ApprovalSubmit from './ApprovalSubmit'; import From from './From'; import SwapProgress from './Progress'; import To from './To'; diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index 57811a6a..355df944 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -14,10 +14,10 @@ import { useGetAppDataByTenant } from '../../../hooks/useGetAppDataByTenant'; import { SwapSettings } from '../../../models/Swap'; import { storageService } from '../../../services/storage/local'; import { calcDeadline, decimalToRaw } from '../../../shared/parseNumbers'; -import { useContractWrite } from '../../../shared/useContractWrite'; import schema from './schema'; import { SwapFormValues } from './schema'; import { NablaInstanceToken, useNablaInstance } from '../../../hooks/nabla/useNablaInstance'; +import { useContractWrite } from '../../../hooks/nabla/useContractWrite'; export interface UseSwapComponentProps { from?: string; diff --git a/src/components/Erc20Balance/index.tsx b/src/components/nabla/common/Erc20Balance.tsx similarity index 63% rename from src/components/Erc20Balance/index.tsx rename to src/components/nabla/common/Erc20Balance.tsx index d14b4826..6fb0cd06 100644 --- a/src/components/Erc20Balance/index.tsx +++ b/src/components/nabla/common/Erc20Balance.tsx @@ -1,5 +1,5 @@ -import { useContractBalance } from '../../shared/useContractBalance'; -import { numberLoader } from '../Loader'; +import { useContractBalance } from '../../../hooks/nabla/useContractBalance'; +import { numberLoader } from '../../Loader'; export type Erc20BalanceProps = { address: string | undefined; @@ -7,7 +7,7 @@ export type Erc20BalanceProps = { abi: Dict; }; -const Erc20Balance = ({ address, decimals, abi }: Erc20BalanceProps): JSX.Element | null => { +export function Erc20Balance({ address, decimals, abi }: Erc20BalanceProps): JSX.Element | null { const { isLoading, formatted, enabled } = useContractBalance({ contractAddress: address, decimals, abi }); if (address === undefined || decimals === undefined || !enabled) return numberLoader; @@ -15,5 +15,4 @@ const Erc20Balance = ({ address, decimals, abi }: Erc20BalanceProps): JSX.Elemen if (isLoading) return numberLoader; return {formatted ?? 0}; -}; -export default Erc20Balance; +} diff --git a/src/components/nabla/Price/index.tsx b/src/components/nabla/common/NablaTokenPrice.tsx similarity index 78% rename from src/components/nabla/Price/index.tsx rename to src/components/nabla/common/NablaTokenPrice.tsx index 35c68421..f9104ddd 100644 --- a/src/components/nabla/Price/index.tsx +++ b/src/components/nabla/common/NablaTokenPrice.tsx @@ -1,8 +1,8 @@ import { UseQueryOptions } from '@tanstack/react-query'; -import { useTokenPrice } from '../../../hooks/nabla/useTokenPrice'; import { getMessageCallValue } from '../../../shared/helpers'; import { rawToDecimal, prettyNumbers } from '../../../shared/parseNumbers'; import { numberLoader } from '../../Loader'; +import { useNablaTokenPrice } from '../../../hooks/nabla/useNablaTokenPrice'; export type TokenPriceProps = { address: string; @@ -15,15 +15,15 @@ export type TokenPriceProps = { const TOKEN_PRICE_DECIMALS = 12; -const TokenPrice = ({ +export function NablaTokenPrice({ address, prefix = null, loader, fallback = null, amount = 1, options, -}: TokenPriceProps): JSX.Element | null => { - const { data, isLoading } = useTokenPrice(address, options); +}: TokenPriceProps): JSX.Element | null { + const { data, isLoading } = useNablaTokenPrice(address, options); if (isLoading) return loader ? <>{loader} : numberLoader; const price = getMessageCallValue(data); @@ -34,5 +34,4 @@ const TokenPrice = ({ {prefix}${prettyNumbers(amount * rawToDecimal(price, TOKEN_PRICE_DECIMALS).toNumber())} ); -}; -export default TokenPrice; +} diff --git a/src/components/nabla/common/NumberInput.tsx b/src/components/nabla/common/NumberInput.tsx index 5a846853..9ad14da3 100644 --- a/src/components/nabla/common/NumberInput.tsx +++ b/src/components/nabla/common/NumberInput.tsx @@ -6,7 +6,7 @@ export interface NumberInputProps extends HT } // Hack required for Preact compatibility with react-hook-form -export default function NumberInput(attributes: NumberInputProps) { +export function NumberInput(attributes: NumberInputProps) { const { register } = useFormContext(); const { registerName } = attributes; diff --git a/src/components/Asset/Approval/index.tsx b/src/components/nabla/common/TokenApproval.tsx similarity index 83% rename from src/components/Asset/Approval/index.tsx rename to src/components/nabla/common/TokenApproval.tsx index a4951748..fcb865c0 100644 --- a/src/components/Asset/Approval/index.tsx +++ b/src/components/nabla/common/TokenApproval.tsx @@ -1,5 +1,5 @@ import { Button, ButtonProps } from 'react-daisyui'; -import { ApprovalState, useTokenApproval } from '../../../shared/useTokenApproval'; +import { ApprovalState, useErc20TokenApproval } from '../../../hooks/nabla/useErc20TokenApproval'; export type TokenApprovalProps = ButtonProps & { token: string; @@ -11,7 +11,7 @@ export type TokenApprovalProps = ButtonProps & { decimals: number; }; -const TokenApproval = ({ +export function TokenApproval({ decimalAmount, token, spender, @@ -20,8 +20,8 @@ const TokenApproval = ({ children, className = '', ...rest -}: TokenApprovalProps): JSX.Element | null => { - const approval = useTokenApproval({ +}: TokenApprovalProps): JSX.Element | null { + const approval = useErc20TokenApproval({ decimalAmount, token, spender, @@ -48,5 +48,4 @@ const TokenApproval = ({ {noAccount ? 'Please connect your wallet' : isPending ? 'Approving' : isLoading ? 'Loading' : 'Approve'} ); -}; -export default TokenApproval; +} diff --git a/src/components/nabla/common/TransactionProgress.tsx b/src/components/nabla/common/TransactionProgress.tsx index e97a1d32..5b8a6bdc 100644 --- a/src/components/nabla/common/TransactionProgress.tsx +++ b/src/components/nabla/common/TransactionProgress.tsx @@ -4,7 +4,7 @@ import { ComponentChildren } from 'preact'; import { Button } from 'react-daisyui'; import Spinner from '../../../assets/spinner'; import { useGetTenantConfig } from '../../../hooks/useGetTenantConfig'; -import { UseContractWriteResponse } from '../../../shared/useContractWrite'; +import { UseContractWriteResponse } from '../../../hooks/nabla/useContractWrite'; export interface TransactionProgressProps { mutation: Pick< @@ -29,7 +29,7 @@ const getErrorMessage = (data?: MessageCallResult['result']) => { } }; -const TransactionProgress = ({ mutation, children, onClose }: TransactionProgressProps): JSX.Element | null => { +export function TransactionProgress({ mutation, children, onClose }: TransactionProgressProps): JSX.Element | null { const { explorer } = useGetTenantConfig(); if (mutation.isIdle) return null; const status = mutation.data?.result?.type; @@ -83,5 +83,4 @@ const TransactionProgress = ({ mutation, children, onClose }: TransactionProgres )} ); -}; -export default TransactionProgress; +} diff --git a/src/shared/useContractBalance.ts b/src/hooks/nabla/useContractBalance.ts similarity index 80% rename from src/shared/useContractBalance.ts rename to src/hooks/nabla/useContractBalance.ts index 34ff9244..7c39229d 100644 --- a/src/shared/useContractBalance.ts +++ b/src/hooks/nabla/useContractBalance.ts @@ -1,11 +1,11 @@ import { MessageCallResult } from '@pendulum-chain/api-solang'; import { UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; -import { cacheKeys } from './constants'; -import { getMessageCallValue, QueryOptions } from './helpers'; -import { rawToDecimal, prettyNumbers } from './parseNumbers'; -import { useSharedState } from './Provider'; -import { useContract } from './useContract'; +import { cacheKeys } from '../../shared/constants'; +import { getMessageCallValue, QueryOptions } from '../../shared/helpers'; +import { rawToDecimal, prettyNumbers } from '../../shared/parseNumbers'; +import { useSharedState } from '../../shared/Provider'; +import { useContractRead } from './useContractRead'; export type UseBalanceProps = { /** token or contract address */ @@ -34,7 +34,7 @@ export const useContractBalance = ( const address = account || defAddress; const enabled = !!api && !!address && options?.enabled !== false; - const query = useContract([cacheKeys.balance, contractAddress, address], { + const query = useContractRead([cacheKeys.balance, contractAddress, address], { cacheTime: 120000, staleTime: 120000, retry: 2, diff --git a/src/shared/useContract.ts b/src/hooks/nabla/useContractRead.ts similarity index 94% rename from src/shared/useContract.ts rename to src/hooks/nabla/useContractRead.ts index 77f6dd28..8da6dab2 100644 --- a/src/shared/useContract.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -4,10 +4,12 @@ import { ApiPromise } from '@polkadot/api'; import { Abi } from '@polkadot/api-contract'; import { QueryKey, useQuery, UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; -import { defaultReadLimits, emptyCacheKey, emptyFn, QueryOptions } from './helpers'; -import { useSharedState } from './Provider'; + +import { defaultReadLimits, emptyCacheKey, emptyFn, QueryOptions } from '../../shared/helpers'; +import { useSharedState } from '../../shared/Provider'; + // TODO Torsten -import { blurp } from '../blurp'; +import { blurp } from '../../blurp'; type ContractOpts = Limits | ((api: ApiPromise) => Limits); export type UseContractProps = QueryOptions & { @@ -29,7 +31,7 @@ const ALICE = '6mfqoTMHrMeVMyKwjqomUjVomPMJ4AjdCm1VReFtk7Be8wqr'; const getLimits = (options: ContractOpts | undefined, api: ApiPromise) => typeof options === 'function' ? options(api) : options || defaultReadLimits; -export function useContract( +export function useContractRead( key: QueryKey, { abi, address, method, options, args, noWalletAddressRequired, ...rest }: UseContractProps, ): UseContractResult { diff --git a/src/shared/useContractWrite.ts b/src/hooks/nabla/useContractWrite.ts similarity index 92% rename from src/shared/useContractWrite.ts rename to src/hooks/nabla/useContractWrite.ts index 5b4be116..4d0b2a6f 100644 --- a/src/shared/useContractWrite.ts +++ b/src/hooks/nabla/useContractWrite.ts @@ -5,11 +5,11 @@ import { Abi } from '@polkadot/api-contract'; import { DispatchError, ExtrinsicStatus } from '@polkadot/types/interfaces'; import { MutationOptions, useMutation } from '@tanstack/react-query'; import { useMemo, useState } from 'preact/compat'; -import { createWriteOptions } from '../services/api/helpers'; -import { defaultWriteLimits } from './helpers'; -import { useSharedState } from './Provider'; +import { defaultWriteLimits } from '../../shared/helpers'; +import { useSharedState } from '../../shared/Provider'; // TODO Torsten -import { blurp } from '../blurp'; +import { blurp } from '../../blurp'; +import { createWriteOptions } from '../../services/api/helpers'; // TODO: fix/improve types - parse abi file export type TransactionsStatus = { diff --git a/src/hooks/nabla/useErc20TokenAllowance.ts b/src/hooks/nabla/useErc20TokenAllowance.ts new file mode 100644 index 00000000..27383bb0 --- /dev/null +++ b/src/hooks/nabla/useErc20TokenAllowance.ts @@ -0,0 +1,29 @@ +import { erc20WrapperAbi } from '../../contracts/nabla/ERC20Wrapper'; +import { cacheKeys } from '../../shared/constants'; +import { QueryOptions } from '../../shared/helpers'; +import { activeOptions } from '../../constants/cache'; +import { useContractRead } from './useContractRead'; + +export type UseTokenAllowance = { + /** contract/token address */ + token: string; + /** spender address */ + spender: string | undefined; + /** owner address */ + owner: string | undefined; +}; + +export function useErc20TokenAllowance({ token, owner, spender }: UseTokenAllowance, options?: QueryOptions) { + const isEnabled = Boolean(owner && spender && options?.enabled); + + return useContractRead([cacheKeys.tokenAllowance, spender, token, owner], { + ...activeOptions['3m'], + retry: 2, + ...options, + abi: erc20WrapperAbi, + address: token, + method: 'allowance', + args: [owner, spender], + enabled: isEnabled, + }); +} diff --git a/src/shared/useTokenApproval.ts b/src/hooks/nabla/useErc20TokenApproval.ts similarity index 84% rename from src/shared/useTokenApproval.ts rename to src/hooks/nabla/useErc20TokenApproval.ts index ea35bd18..a4d8c1eb 100644 --- a/src/shared/useTokenApproval.ts +++ b/src/hooks/nabla/useErc20TokenApproval.ts @@ -1,11 +1,11 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ import { useMemo, useState } from 'preact/compat'; -import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; -import { getMessageCallValue } from './helpers'; -import { decimalToRaw, rawToDecimal } from './parseNumbers'; -import { useSharedState } from './Provider'; -import { useContractWrite, UseContractWriteProps } from './useContractWrite'; -import { useTokenAllowance } from './useTokenAllowance'; +import { erc20WrapperAbi } from '../../contracts/nabla/ERC20Wrapper'; +import { getMessageCallValue } from '../../shared/helpers'; +import { decimalToRaw, rawToDecimal } from '../../shared/parseNumbers'; +import { useSharedState } from '../../shared/Provider'; +import { useErc20TokenAllowance } from './useErc20TokenAllowance'; +import { UseContractWriteProps, useContractWrite } from './useContractWrite'; export enum ApprovalState { UNKNOWN, @@ -26,7 +26,7 @@ interface UseTokenApprovalParams { onSuccess?: UseContractWriteProps['onSuccess']; } -export const useTokenApproval = ({ +export function useErc20TokenApproval({ token, decimalAmount, spender, @@ -34,7 +34,7 @@ export const useTokenApproval = ({ decimals, onError, onSuccess, -}: UseTokenApprovalParams) => { +}: UseTokenApprovalParams) { const { address } = useSharedState(); const [pending, setPending] = useState(false); const nativeAmount = decimalToRaw(decimalAmount, decimals); @@ -44,7 +44,7 @@ export const useTokenApproval = ({ data: allowanceData, isLoading: isAllowanceLoading, refetch, - } = useTokenAllowance( + } = useErc20TokenAllowance( { token, owner: address, @@ -101,4 +101,4 @@ export const useTokenApproval = ({ return [state, mutation]; }, [allowanceDecimalAmount, decimalAmount, mutation, isAllowanceLoading, pending, address]); -}; +} diff --git a/src/hooks/nabla/useTokenPrice.ts b/src/hooks/nabla/useNablaTokenPrice.ts similarity index 72% rename from src/hooks/nabla/useTokenPrice.ts rename to src/hooks/nabla/useNablaTokenPrice.ts index 5790922e..8ef53914 100644 --- a/src/hooks/nabla/useTokenPrice.ts +++ b/src/hooks/nabla/useNablaTokenPrice.ts @@ -1,14 +1,14 @@ import { cacheKeys, inactiveOptions, QueryOptions } from '../../constants/cache'; import { priceOracleAbi } from '../../contracts/nabla/PriceOracle'; -import { useContract } from '../../shared/useContract'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; +import { useContractRead } from './useContractRead'; -export const useTokenPrice = (address: string | undefined, options?: QueryOptions) => { +export function useNablaTokenPrice(address: string | undefined, options?: QueryOptions) { const { oracle } = useGetAppDataByTenant('nabla').data || {}; const enabled = !!address && !!oracle && options?.enabled !== false; - return useContract([cacheKeys.tokenPrice, address], { + return useContractRead([cacheKeys.tokenPrice, address], { ...inactiveOptions['1m'], ...options, enabled, @@ -18,4 +18,4 @@ export const useTokenPrice = (address: string | undefined, options?: QueryOption noWalletAddressRequired: true, args: [address], }); -}; +} diff --git a/src/hooks/nabla/useSharesTargetWorth.ts b/src/hooks/nabla/useSharesTargetWorth.ts index 9297acc5..d32cdbb7 100644 --- a/src/hooks/nabla/useSharesTargetWorth.ts +++ b/src/hooks/nabla/useSharesTargetWorth.ts @@ -1,7 +1,7 @@ import { cacheKeys, inactiveOptions } from '../../constants/cache'; import { QueryOptions } from '../../shared/helpers'; import { decimalToRaw } from '../../shared/parseNumbers'; -import { useContract } from '../../shared/useContract'; +import { useContractRead } from './useContractRead'; export type UseSharesTargetWorthProps = { address: string | undefined; @@ -10,11 +10,11 @@ export type UseSharesTargetWorthProps = { abi: Dict; }; -export const useSharesTargetWorth = ( +export function useSharesTargetWorth( { address, lpTokenDecimalAmount, abi, lpTokenDecimals }: UseSharesTargetWorthProps, options?: QueryOptions, -) => { - return useContract([cacheKeys.sharesTargetWorth, lpTokenDecimalAmount], { +) { + return useContractRead([cacheKeys.sharesTargetWorth, lpTokenDecimalAmount], { ...inactiveOptions['1m'], ...options, address, @@ -23,4 +23,4 @@ export const useSharesTargetWorth = ( args: [decimalToRaw(lpTokenDecimalAmount, lpTokenDecimals).toString()], enabled: Boolean(address && lpTokenDecimalAmount && options?.enabled !== false), }); -}; +} diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index da538503..2ee0fd4a 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -2,8 +2,8 @@ import { MessageCallResult } from '@pendulum-chain/api-solang'; import { activeOptions, cacheKeys } from '../../constants/cache'; import { routerAbi } from '../../contracts/nabla/Router'; import { decimalToRaw } from '../../shared/parseNumbers'; -import { useContract } from '../../shared/useContract'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; +import { useContractRead } from './useContractRead'; export type UseTokenOutAmountProps = { fromDecimalAmount: number; @@ -14,21 +14,23 @@ export type UseTokenOutAmountProps = { onError?: (err: Error | MessageCallResult) => void; }; -export const useTokenOutAmount = ({ +export function useTokenOutAmount({ fromDecimalAmount: decimalAmount, from, to, fromTokenDecimals, onSuccess, onError, -}: UseTokenOutAmountProps) => { +}: UseTokenOutAmountProps) { + console.log('Call useTokenOutAmount'); + const { router } = useGetAppDataByTenant('nabla').data || {}; const enabled = fromTokenDecimals !== undefined && !!decimalAmount && !!from && !!to; const amountIn = fromTokenDecimals !== undefined ? decimalToRaw(decimalAmount, fromTokenDecimals).toString() : undefined; - return useContract([cacheKeys.tokenOutAmount, from, to, amountIn], { + return useContractRead([cacheKeys.tokenOutAmount, from, to, amountIn], { ...activeOptions['30s'], abi: routerAbi, address: router, @@ -42,4 +44,4 @@ export const useTokenOutAmount = ({ console.error(err); }, }); -}; +} diff --git a/src/pages/nabla/dev/index.tsx b/src/pages/nabla/dev/index.tsx index 083423df..14f74603 100644 --- a/src/pages/nabla/dev/index.tsx +++ b/src/pages/nabla/dev/index.tsx @@ -5,8 +5,8 @@ import { config } from '../../../config'; import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; import { useGlobalState } from '../../../GlobalStateProvider'; import { decimalToRaw } from '../../../shared/parseNumbers'; -import { useContractWrite } from '../../../shared/useContractWrite'; import { NablaInstanceToken, useNablaInstance } from '../../../hooks/nabla/useNablaInstance'; +import { useContractWrite } from '../../../hooks/nabla/useContractWrite'; const TokenItem = ({ token }: { token: NablaInstanceToken }) => { const { address } = useGlobalState().walletAccount || {}; diff --git a/src/shared/useTokenAllowance.ts b/src/shared/useTokenAllowance.ts deleted file mode 100644 index b1cae5d1..00000000 --- a/src/shared/useTokenAllowance.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { activeOptions } from '../constants/cache'; -import { erc20WrapperAbi } from '../contracts/nabla/ERC20Wrapper'; -import { cacheKeys } from './constants'; -import { QueryOptions } from './helpers'; -import { useContract } from './useContract'; - -export type UseTokenAllowance = { - /** contract/token address */ - token: string; - /** spender address */ - spender: string | undefined; - /** owner address */ - owner: string | undefined; -}; - -export const useTokenAllowance = ({ token, owner, spender }: UseTokenAllowance, options?: QueryOptions) => { - const isEnabled = Boolean(owner && spender && options?.enabled); - - return useContract([cacheKeys.tokenAllowance, spender, token, owner], { - ...activeOptions['3m'], - retry: 2, - ...options, - abi: erc20WrapperAbi, - address: token, - method: 'allowance', - args: [owner, spender], - enabled: isEnabled, - }); -}; From 758e9ba08634dd7af73f94c586c5beecb89ddd41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 02:57:48 -0300 Subject: [PATCH 28/58] Restructure options of contract hooks --- .../Backstop/AddLiquidity/useAddLiquidity.ts | 18 +++++++------- .../WithdrawLiquidity/useBackstopWithdraw.ts | 4 +++- .../WithdrawLiquidity/useSwapPoolWithdraw.ts | 4 +++- .../Swap/AddLiquidity/useAddLiquidity.ts | 18 +++++++------- .../nabla/Pools/Swap/Redeem/useRedeem.ts | 16 +++++++------ .../WithdrawLiquidity/useWithdrawLiquidity.ts | 18 +++++++------- src/components/nabla/Swap/To.tsx | 1 - src/components/nabla/Swap/useSwapComponent.ts | 14 ++++++----- src/hooks/nabla/useContractBalance.ts | 22 +++++++++-------- src/hooks/nabla/useContractRead.ts | 21 +++++++--------- src/hooks/nabla/useContractWrite.ts | 16 +++++-------- src/hooks/nabla/useErc20TokenAllowance.ts | 14 ++++++----- src/hooks/nabla/useErc20TokenApproval.ts | 24 ++++++++++--------- src/hooks/nabla/useNablaTokenPrice.ts | 16 +++++++------ src/hooks/nabla/useSharesTargetWorth.ts | 12 ++++++---- src/hooks/nabla/useTokenOutAmount.ts | 16 ++++++------- src/pages/nabla/dev/index.tsx | 4 +++- 17 files changed, 127 insertions(+), 111 deletions(-) diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts index 120cae3a..04b28f25 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts @@ -45,14 +45,16 @@ export const useAddLiquidity = ( abi: backstopPoolAbi, address: poolAddress, method: 'deposit', - onError: () => { - // ? log error - alert not needed as the transaction modal displays the error - }, - onSuccess: () => { - form.reset(); - balanceQuery.refetch(); - depositQuery.refetch(); - queryClient.refetchQueries([cacheKeys.backstopPools, indexerUrl]); + mutateOptions: { + onError: () => { + // ? log error - alert not needed as the transaction modal displays the error + }, + onSuccess: () => { + form.reset(); + balanceQuery.refetch(); + depositQuery.refetch(); + queryClient.refetchQueries([cacheKeys.backstopPools, indexerUrl]); + }, }, }); diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts index e6c134b1..22f767fa 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts @@ -24,7 +24,9 @@ export const useBackstopWithdraw = ({ abi: backstopPoolAbi, address, method: 'withdraw', - onSuccess, + mutateOptions: { + onSuccess, + }, }); const { mutate } = mutation; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts index 854c8482..2a9898f7 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts @@ -32,7 +32,9 @@ export const useSwapPoolWithdraw = ({ abi: backstopPoolAbi, address: backstopPool.id, method: 'withdrawExcessSwapLiquidity', - onSuccess, + mutateOptions: { + onSuccess, + }, }); const { mutate } = mutation; diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index a0c98759..36a665fd 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -43,14 +43,16 @@ export const useAddLiquidity = ( abi: swapPoolAbi, address: poolAddress, method: 'deposit', - onError: () => { - // ? log error - alert not needed as the transaction modal displays the error - }, - onSuccess: () => { - form.reset(); - balanceQuery.refetch(); - depositQuery.refetch(); - queryClient.refetchQueries([cacheKeys.swapPools, indexerUrl]); + mutateOptions: { + onError: () => { + // ? log error - alert not needed as the transaction modal displays the error + }, + onSuccess: () => { + form.reset(); + balanceQuery.refetch(); + depositQuery.refetch(); + queryClient.refetchQueries([cacheKeys.swapPools, indexerUrl]); + }, }, }); diff --git a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts index bf3959d5..9e3a5325 100644 --- a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts +++ b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts @@ -69,13 +69,15 @@ export const useRedeem = (swapPoolData: SwapPoolColumn) => { abi: backstopPoolAbi, address: backstopPoolAddress, method: 'redeemSwapPoolShares', - onError: () => { - // ? log error - alert not needed as the transaction modal displays the error - }, - onSuccess: () => { - balanceQuery.refetch(); - depositQuery.refetch(); - queryClient.refetchQueries([cacheKeys.swapPools, indexerUrl]); + mutateOptions: { + onError: () => { + // ? log error - alert not needed as the transaction modal displays the error + }, + onSuccess: () => { + balanceQuery.refetch(); + depositQuery.refetch(); + queryClient.refetchQueries([cacheKeys.swapPools, indexerUrl]); + }, }, }); const { mutate } = mutation; diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts index ba7797d9..e022918c 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -48,14 +48,16 @@ export const useSwapPoolWithdrawLiquidity = ( abi: swapPoolAbi, address: poolAddress, method: 'withdraw', - onError: () => { - // ? log error - alert not needed as the transaction modal displays the error - }, - onSuccess: () => { - reset(); - balanceQuery.refetch(); - depositQuery.refetch(); - queryClient.refetchQueries([cacheKeys.swapPools, indexerUrl]); + mutateOptions: { + onError: () => { + // ? log error - alert not needed as the transaction modal displays the error + }, + onSuccess: () => { + reset(); + balanceQuery.refetch(); + depositQuery.refetch(); + queryClient.refetchQueries([cacheKeys.swapPools, indexerUrl]); + }, }, }); const { mutate } = mutation; diff --git a/src/components/nabla/Swap/To.tsx b/src/components/nabla/Swap/To.tsx index 06ea375a..80be615d 100644 --- a/src/components/nabla/Swap/To.tsx +++ b/src/components/nabla/Swap/To.tsx @@ -59,7 +59,6 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps const debouncedFromDecimalAmount = useDebouncedValue(fromDecimalAmount, 800); - console.log('Before call useTokenOutAmount'); const { isLoading, fetchStatus, data, refetch } = useTokenOutAmount({ fromDecimalAmount: debouncedFromDecimalAmount, from, diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index 355df944..52f52a28 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -84,12 +84,14 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { abi: routerAbi, address: router, method: 'swapExactTokensForTokens', - onSuccess: () => { - // update token balances - queryClient.refetchQueries({ queryKey: [cacheKeys.walletBalance, getValues('from')], type: 'active' }); - queryClient.refetchQueries({ queryKey: [cacheKeys.walletBalance, getValues('to')], type: 'active' }); - // reset form - reset(); + mutateOptions: { + onSuccess: () => { + // update token balances + queryClient.refetchQueries({ queryKey: [cacheKeys.walletBalance, getValues('from')], type: 'active' }); + queryClient.refetchQueries({ queryKey: [cacheKeys.walletBalance, getValues('to')], type: 'active' }); + // reset form + reset(); + }, }, }); diff --git a/src/hooks/nabla/useContractBalance.ts b/src/hooks/nabla/useContractBalance.ts index 7c39229d..9589ebe7 100644 --- a/src/hooks/nabla/useContractBalance.ts +++ b/src/hooks/nabla/useContractBalance.ts @@ -28,25 +28,27 @@ export type UseBalanceResponse = Pick< export const useContractBalance = ( { contractAddress, account, abi, decimals }: UseBalanceProps, - options?: QueryOptions, + queryOptions?: QueryOptions, ): UseBalanceResponse => { const { api, address: defAddress } = useSharedState(); const address = account || defAddress; - const enabled = !!api && !!address && options?.enabled !== false; + const enabled = !!api && !!address && queryOptions?.enabled !== false; const query = useContractRead([cacheKeys.balance, contractAddress, address], { - cacheTime: 120000, - staleTime: 120000, - retry: 2, - refetchOnReconnect: false, - refetchOnWindowFocus: false, - onError: console.error, - ...options, abi, address: contractAddress, method: 'balanceOf', args: [address], - enabled, + queryOptions: { + ...(queryOptions ?? {}), + cacheTime: 120000, + staleTime: 120000, + retry: 2, + refetchOnReconnect: false, + refetchOnWindowFocus: false, + onError: console.error, + enabled, + }, }); const { data } = query; diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index 8da6dab2..55778811 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -1,6 +1,5 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ -import { Limits, messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; -import { ApiPromise } from '@polkadot/api'; +import { messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; import { Abi } from '@polkadot/api-contract'; import { QueryKey, useQuery, UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; @@ -11,14 +10,13 @@ import { useSharedState } from '../../shared/Provider'; // TODO Torsten import { blurp } from '../../blurp'; -type ContractOpts = Limits | ((api: ApiPromise) => Limits); -export type UseContractProps = QueryOptions & { +export type UseContractProps = { abi: Dict; address: string | undefined; method: string; args?: any[]; - options?: ContractOpts; noWalletAddressRequired?: boolean; + queryOptions: QueryOptions; }; export type UseContractResult = Pick< @@ -28,12 +26,9 @@ export type UseContractResult = Pick< const ALICE = '6mfqoTMHrMeVMyKwjqomUjVomPMJ4AjdCm1VReFtk7Be8wqr'; -const getLimits = (options: ContractOpts | undefined, api: ApiPromise) => - typeof options === 'function' ? options(api) : options || defaultReadLimits; - export function useContractRead( key: QueryKey, - { abi, address, method, options, args, noWalletAddressRequired, ...rest }: UseContractProps, + { abi, address, method, args, noWalletAddressRequired, queryOptions }: UseContractProps, ): UseContractResult { const { api, address: walletAddress } = useSharedState(); const contractAbi = useMemo( @@ -43,12 +38,12 @@ export function useContractRead( const actualWalletAddress = noWalletAddressRequired ? ALICE : walletAddress; - const enabled = !!contractAbi && rest.enabled !== false && !!address && !!api && !!actualWalletAddress; + const enabled = !!contractAbi && queryOptions.enabled !== false && !!address && !!api && !!actualWalletAddress; const query = useQuery( enabled ? key : emptyCacheKey, enabled ? async () => { - const limits = getLimits(options, api); + const limits = defaultReadLimits; blurp('read', 'Call message', address, method, args); const response = await messageCall({ @@ -67,12 +62,12 @@ export function useContractRead( } : emptyFn, { - ...rest, + ...queryOptions, enabled, }, ); - blurp('read', !!contractAbi, rest.enabled !== false, !!address, !!api, !!actualWalletAddress); + blurp('read', !!contractAbi, queryOptions.enabled !== false, !!address, !!api, !!actualWalletAddress); blurp( 'read', 'useContract result', diff --git a/src/hooks/nabla/useContractWrite.ts b/src/hooks/nabla/useContractWrite.ts index 4d0b2a6f..ad511074 100644 --- a/src/hooks/nabla/useContractWrite.ts +++ b/src/hooks/nabla/useContractWrite.ts @@ -1,6 +1,5 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ -import { Limits, messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; -import { ApiPromise } from '@polkadot/api'; +import { messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; import { Abi } from '@polkadot/api-contract'; import { DispatchError, ExtrinsicStatus } from '@polkadot/types/interfaces'; import { MutationOptions, useMutation } from '@tanstack/react-query'; @@ -17,14 +16,12 @@ export type TransactionsStatus = { status?: ExtrinsicStatus['type'] | 'Pending'; }; -export type UseContractWriteProps> = Partial< - MutationOptions -> & { +export type UseContractWriteProps> = { abi: TAbi; address?: string; method: string; args?: any[]; - options?: Limits | ((api: ApiPromise) => Limits); + mutateOptions: Partial>; }; export const useContractWrite = >({ @@ -32,8 +29,7 @@ export const useContractWrite = >({ address, method, args, - options, - ...rest + mutateOptions, }: UseContractWriteProps) => { const { api, signer, address: walletAddress } = useSharedState(); const [transaction /* setTransaction */] = useState(); @@ -49,7 +45,7 @@ export const useContractWrite = >({ if (!isReady) throw 'Missing data'; //setTransaction({ status: 'Pending' }); const fnArgs = submitArgs || args || []; - const contractOptions = (typeof options === 'function' ? options(api) : options) || createWriteOptions(api); + const contractOptions = createWriteOptions(api); blurp('write', 'call message write', address, method, args, submitArgs); blurp('write', 'limits', { ...defaultWriteLimits, ...contractOptions }); @@ -76,7 +72,7 @@ export const useContractWrite = >({ if (response?.result?.type !== 'success') throw response; return response; }; - const mutation = useMutation(submit, rest); + const mutation = useMutation(submit, mutateOptions); return { ...mutation, transaction, isReady }; }; diff --git a/src/hooks/nabla/useErc20TokenAllowance.ts b/src/hooks/nabla/useErc20TokenAllowance.ts index 27383bb0..ff7e8355 100644 --- a/src/hooks/nabla/useErc20TokenAllowance.ts +++ b/src/hooks/nabla/useErc20TokenAllowance.ts @@ -13,17 +13,19 @@ export type UseTokenAllowance = { owner: string | undefined; }; -export function useErc20TokenAllowance({ token, owner, spender }: UseTokenAllowance, options?: QueryOptions) { - const isEnabled = Boolean(owner && spender && options?.enabled); +export function useErc20TokenAllowance({ token, owner, spender }: UseTokenAllowance, queryOptions?: QueryOptions) { + const isEnabled = Boolean(owner && spender && queryOptions?.enabled); return useContractRead([cacheKeys.tokenAllowance, spender, token, owner], { - ...activeOptions['3m'], - retry: 2, - ...options, abi: erc20WrapperAbi, address: token, method: 'allowance', args: [owner, spender], - enabled: isEnabled, + queryOptions: { + ...activeOptions['3m'], + ...queryOptions, + retry: 2, + enabled: isEnabled, + }, }); } diff --git a/src/hooks/nabla/useErc20TokenApproval.ts b/src/hooks/nabla/useErc20TokenApproval.ts index a4d8c1eb..2ec4a234 100644 --- a/src/hooks/nabla/useErc20TokenApproval.ts +++ b/src/hooks/nabla/useErc20TokenApproval.ts @@ -23,7 +23,7 @@ interface UseTokenApprovalParams { enabled?: boolean; decimals: number; onError?: (err: any) => void; - onSuccess?: UseContractWriteProps['onSuccess']; + onSuccess?: UseContractWriteProps['mutateOptions']['onSuccess']; } export function useErc20TokenApproval({ @@ -58,17 +58,19 @@ export function useErc20TokenApproval({ address: token, method: 'approve', args: [spender, nativeAmount.toString()], - onError: (err) => { - setPending(false); - if (onError) onError(err); - }, - onSuccess: (...args) => { - setPending(true); - if (onSuccess) onSuccess(...args); - setTimeout(() => { - refetch(); + mutateOptions: { + onError: (err) => { setPending(false); - }, 2000); // delay refetch as sometimes the allowance takes some time to reflect + if (onError) onError(err); + }, + onSuccess: (...args) => { + setPending(true); + if (onSuccess) onSuccess(...args); + setTimeout(() => { + refetch(); + setPending(false); + }, 2000); // delay refetch as sometimes the allowance takes some time to reflect + }, }, }); diff --git a/src/hooks/nabla/useNablaTokenPrice.ts b/src/hooks/nabla/useNablaTokenPrice.ts index 8ef53914..b1702251 100644 --- a/src/hooks/nabla/useNablaTokenPrice.ts +++ b/src/hooks/nabla/useNablaTokenPrice.ts @@ -3,19 +3,21 @@ import { priceOracleAbi } from '../../contracts/nabla/PriceOracle'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; import { useContractRead } from './useContractRead'; -export function useNablaTokenPrice(address: string | undefined, options?: QueryOptions) { +export function useNablaTokenPrice(address: string | undefined, queryOptions?: QueryOptions) { const { oracle } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!address && !!oracle && options?.enabled !== false; + const enabled = !!address && !!oracle && queryOptions?.enabled !== false; return useContractRead([cacheKeys.tokenPrice, address], { - ...inactiveOptions['1m'], - ...options, - enabled, - address: oracle, abi: priceOracleAbi, + address: oracle, method: 'getAssetPrice', - noWalletAddressRequired: true, args: [address], + noWalletAddressRequired: true, + queryOptions: { + ...inactiveOptions['1m'], + ...queryOptions, + enabled, + }, }); } diff --git a/src/hooks/nabla/useSharesTargetWorth.ts b/src/hooks/nabla/useSharesTargetWorth.ts index d32cdbb7..67009c3e 100644 --- a/src/hooks/nabla/useSharesTargetWorth.ts +++ b/src/hooks/nabla/useSharesTargetWorth.ts @@ -12,15 +12,17 @@ export type UseSharesTargetWorthProps = { export function useSharesTargetWorth( { address, lpTokenDecimalAmount, abi, lpTokenDecimals }: UseSharesTargetWorthProps, - options?: QueryOptions, + queryOptions?: QueryOptions, ) { return useContractRead([cacheKeys.sharesTargetWorth, lpTokenDecimalAmount], { - ...inactiveOptions['1m'], - ...options, - address, abi, + address, method: 'sharesTargetWorth', args: [decimalToRaw(lpTokenDecimalAmount, lpTokenDecimals).toString()], - enabled: Boolean(address && lpTokenDecimalAmount && options?.enabled !== false), + queryOptions: { + ...inactiveOptions['1m'], + ...queryOptions, + enabled: Boolean(address && lpTokenDecimalAmount && queryOptions?.enabled !== false), + }, }); } diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index 2ee0fd4a..075ad5c0 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -22,8 +22,6 @@ export function useTokenOutAmount({ onSuccess, onError, }: UseTokenOutAmountProps) { - console.log('Call useTokenOutAmount'); - const { router } = useGetAppDataByTenant('nabla').data || {}; const enabled = fromTokenDecimals !== undefined && !!decimalAmount && !!from && !!to; @@ -31,17 +29,19 @@ export function useTokenOutAmount({ fromTokenDecimals !== undefined ? decimalToRaw(decimalAmount, fromTokenDecimals).toString() : undefined; return useContractRead([cacheKeys.tokenOutAmount, from, to, amountIn], { - ...activeOptions['30s'], abi: routerAbi, address: router, method: 'getAmountOut', args: [amountIn, [from, to]], - enabled, noWalletAddressRequired: true, - onSuccess, - onError: (err) => { - if (onError) onError(err); - console.error(err); + queryOptions: { + ...activeOptions['30s'], + enabled, + onSuccess, + onError: (err) => { + if (onError) onError(err); + console.error(err); + }, }, }); } diff --git a/src/pages/nabla/dev/index.tsx b/src/pages/nabla/dev/index.tsx index 14f74603..91b20afe 100644 --- a/src/pages/nabla/dev/index.tsx +++ b/src/pages/nabla/dev/index.tsx @@ -14,7 +14,9 @@ const TokenItem = ({ token }: { token: NablaInstanceToken }) => { abi: erc20WrapperAbi, address: token.id, method: 'mint', - onError: console.error, + mutateOptions: { + onError: console.error, + }, }); return (
From 17fc304ff88c902df458af4f4a22d4f2b70e591f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 03:06:21 -0300 Subject: [PATCH 29/58] Use new contracts metadata --- src/contracts/nabla/BackstopPool.ts | 2836 ++++++++++----------- src/contracts/nabla/ERC20Wrapper.ts | 1116 ++++----- src/contracts/nabla/NablaCurve.ts | 2 +- src/contracts/nabla/PriceOracle.ts | 985 ++++---- src/contracts/nabla/Router.ts | 1383 +++++------ src/contracts/nabla/SwapPool.ts | 3562 ++++++++++++--------------- 6 files changed, 4377 insertions(+), 5507 deletions(-) diff --git a/src/contracts/nabla/BackstopPool.ts b/src/contracts/nabla/BackstopPool.ts index d3be6580..3200c2d9 100644 --- a/src/contracts/nabla/BackstopPool.ts +++ b/src/contracts/nabla/BackstopPool.ts @@ -1,1866 +1,1546 @@ export const backstopPoolAbi = { - "contract": { - "authors": [ - "unknown" - ], - "description": "The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees.", - "name": "BackstopPool", - "version": "0.0.1" + contract: { + authors: ['unknown'], + description: + 'The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees.', + name: 'BackstopPool', + version: '0.0.1', }, - "source": { - "compiler": "solang 0.3.2", - "hash": "0x026ff1b46ca6ae1d60aed9cea110e48ee635da3087675e463bc717a9c23ffbe1", - "language": "Solidity 0.3.2" + source: { + compiler: 'solang 0.3.2', + hash: '0xe07d252b0830943a932a082d3b7a46249af166287420ec4cfbc49b3384e48b6c', + language: 'Solidity 0.3.2', }, - "spec": { - "constructors": [ + spec: { + constructors: [ { - "args": [ - { - "label": "_router", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_name", - "type": { - "displayName": [ - "string" - ], - "type": 5 - } - }, - { - "label": "_symbol", - "type": { - "displayName": [ - "string" - ], - "type": 5 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: '_router', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_name', + type: { + displayName: ['string'], + type: 5, + }, + }, + { + label: '_symbol', + type: { + displayName: ['string'], + type: 5, + }, + }, ], - "label": "new", - "payable": false, - "returnType": null, - "selector": "0xf01fa595" - } + default: false, + docs: [''], + label: 'new', + payable: false, + returnType: null, + selector: '0xf01fa595', + }, ], - "docs": [ - "The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees." + docs: [ + 'The backstop pool takes most of the risk of a set of swap pools\nbacked by it. Whenever a swap pool is low on reserves and a LPer\nwants to withdraw some liquidity, they can conduct an insurance\nwithdrawal (burn swap pool shares, reimbursed in backstop liquidity)\nto avoid paying a high slippage.\nThe backstop pool owns all excess liquidity in its swap pools,\nbut is also liable for potential liquidity gaps.\nIn return, the backstop pool receives a cut of the swap fees.', ], - "environment": { - "accountId": { - "displayName": [ - "AccountId" - ], - "type": 2 + environment: { + accountId: { + displayName: ['AccountId'], + type: 2, }, - "balance": { - "displayName": [ - "Balance" - ], - "type": 11 + balance: { + displayName: ['Balance'], + type: 11, }, - "blockNumber": { - "displayName": [ - "BlockNumber" - ], - "type": 12 + blockNumber: { + displayName: ['BlockNumber'], + type: 12, }, - "chainExtension": { - "displayName": [], - "type": 0 + chainExtension: { + displayName: [], + type: 0, }, - "hash": { - "displayName": [ - "Hash" - ], - "type": 13 + hash: { + displayName: ['Hash'], + type: 13, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 12, }, - "maxEventTopics": 4, - "timestamp": { - "displayName": [ - "Timestamp" - ], - "type": 12 - } }, - "events": [ + events: [ { - "args": [ - { - "docs": [], - "indexed": true, - "label": "from", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": true, - "label": "to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "value", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: true, + label: 'from', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: true, + label: 'to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'value', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "Transfer" + docs: [''], + label: 'Transfer', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": true, - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "value", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: true, + label: 'owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: true, + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'value', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "Approval" + docs: [''], + label: 'Approval', }, { - "args": [ - { - "docs": [], - "indexed": false, - "label": "account", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: false, + label: 'account', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "Paused" + docs: [''], + label: 'Paused', }, { - "args": [ - { - "docs": [], - "indexed": false, - "label": "account", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: false, + label: 'account', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "Unpaused" + docs: [''], + label: 'Unpaused', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "previousOwner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": true, - "label": "newOwner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: true, + label: 'previousOwner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: true, + label: 'newOwner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "OwnershipTransferred" + docs: [''], + label: 'OwnershipTransferred', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "sender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "poolSharesMinted", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountPrincipleDeposited", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "docs": [ - "emitted on every deposit" + args: [ + { + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "Mint" + docs: ['emitted when a new swap pool is added to the backstop pool for coverage'], + label: 'SwapPoolAdded', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "sender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "poolSharesBurned", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountPrincipleWithdrawn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: true, + label: 'swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'insuranceFeeBps', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "docs": [ - "emitted on every withdrawal special case withdrawal using swap liquidiity: amountPrincipleWithdrawn = 0" + docs: ['emitted when the insurance fee is set for a swap pool'], + label: 'InsuranceFeeSet', + }, + { + args: [ + { + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'poolSharesMinted', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + docs: [], + indexed: false, + label: 'amountPrincipleDeposited', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "Burn" + docs: ['emitted on every deposit'], + label: 'Mint', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "swapPool", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountSwapShares", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountSwapTokens", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountBackstopTokens", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'poolSharesBurned', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + docs: [], + indexed: false, + label: 'amountPrincipleWithdrawn', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "docs": [ - "emitted when a swap pool LP withdraws from backstop pool" + docs: [ + 'emitted on every withdrawal special case withdrawal using swap liquidiity: amountPrincipleWithdrawn = 0', ], - "label": "CoverSwapWithdrawal" + label: 'Burn', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "swapPool", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountSwapTokens", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountBackstopTokens", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + docs: [], + indexed: true, + label: 'owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'amountSwapShares', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + docs: [], + indexed: false, + label: 'amountSwapTokens', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + docs: [], + indexed: false, + label: 'amountBackstopTokens', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "docs": [ - "emitted when a backstop pool LP withdraws liquidity from swap pool" + docs: ['emitted when a swap pool LP withdraws from backstop pool'], + label: 'CoverSwapWithdrawal', + }, + { + args: [ + { + docs: [], + indexed: true, + label: 'owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'amountSwapTokens', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + docs: [], + indexed: false, + label: 'amountBackstopTokens', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "WithdrawSwapLiquidity" - } + docs: ['emitted when a backstop pool LP withdraws liquidity from swap pool'], + label: 'WithdrawSwapLiquidity', + }, ], - "lang_error": { - "displayName": [ - "SolidityError" - ], - "type": 16 + lang_error: { + displayName: ['SolidityError'], + type: 16, }, - "messages": [ + messages: [ { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "name", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "string" - ], - "type": 5 + args: [], + default: false, + docs: [''], + label: 'name', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 5, }, - "selector": "0x06fdde03" + selector: '0x06fdde03', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "symbol", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "string" - ], - "type": 5 + args: [], + default: false, + docs: [''], + label: 'symbol', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 5, }, - "selector": "0x95d89b41" + selector: '0x95d89b41', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "totalSupply", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + args: [], + default: false, + docs: [''], + label: 'totalSupply', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x18160ddd" + selector: '0x18160ddd', }, { - "args": [ - { - "label": "account", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'account', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "balanceOf", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: [''], + label: 'balanceOf', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x70a08231" + selector: '0x70a08231', }, { - "args": [ - { - "label": "to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "transfer", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'transfer', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0xa9059cbb" + selector: '0xa9059cbb', }, { - "args": [ - { - "label": "owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "allowance", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: [''], + label: 'allowance', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0xdd62ed3e" + selector: '0xdd62ed3e', }, { - "args": [ - { - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "approve", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'approve', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0x095ea7b3" + selector: '0x095ea7b3', }, { - "args": [ - { - "label": "from", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'from', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "transferFrom", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'transferFrom', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0x23b872dd" + selector: '0x23b872dd', }, { - "args": [ - { - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "addedValue", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'addedValue', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "increaseAllowance", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'increaseAllowance', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0x39509351" + selector: '0x39509351', }, { - "args": [ - { - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "subtractedValue", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'subtractedValue', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "decreaseAllowance", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'decreaseAllowance', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0xa457c2d7" + selector: '0xa457c2d7', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "paused", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + args: [], + default: false, + docs: [''], + label: 'paused', + mutates: false, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0x5c975abb" + selector: '0x5c975abb', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "owner", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 + args: [], + default: false, + docs: [''], + label: 'owner', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, - "selector": "0x8da5cb5b" + selector: '0x8da5cb5b', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "renounceOwnership", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0x715018a6" + args: [], + default: false, + docs: [''], + label: 'renounceOwnership', + mutates: true, + payable: false, + returnType: null, + selector: '0x715018a6', }, { - "args": [ - { - "label": "newOwner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'newOwner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "transferOwnership", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0xf2fde38b" + default: false, + docs: [''], + label: 'transferOwnership', + mutates: true, + payable: false, + returnType: null, + selector: '0xf2fde38b', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "poolCap", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + args: [], + default: false, + docs: [''], + label: 'poolCap', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0xb954dc57" + selector: '0xb954dc57', }, { - "args": [], - "default": false, - "docs": [ - "Returns the pooled token's address" - ], - "label": "asset", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 + args: [], + default: false, + docs: ["Returns the pooled token's address"], + label: 'asset', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, - "selector": "0x38d52e0f" + selector: '0x38d52e0f', }, { - "args": [], - "default": false, - "docs": [ - "Returns the decimals of the pool asset" - ], - "label": "assetDecimals", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint8" - ], - "type": 0 + args: [], + default: false, + docs: ['Returns the decimals of the pool asset'], + label: 'assetDecimals', + mutates: false, + payable: false, + returnType: { + displayName: ['uint8'], + type: 0, }, - "selector": "0xc2d41601" + selector: '0xc2d41601', }, { - "args": [], - "default": false, - "docs": [ - "Returns the decimals of the LP token of this pool\nThis is defined to have the same decimals as the pool token itself\nin order to greatly simplify calculations that involve pool token amounts\nand LP token amounts" - ], - "label": "decimals", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint8" - ], - "type": 0 + args: [], + default: false, + docs: [ + 'Returns the decimals of the LP token of this pool\nThis is defined to have the same decimals as the pool token itself\nin order to greatly simplify calculations that involve pool token amounts\nand LP token amounts', + ], + label: 'decimals', + mutates: false, + payable: false, + returnType: { + displayName: ['uint8'], + type: 0, }, - "selector": "0x313ce567" + selector: '0x313ce567', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "router", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 + args: [], + default: false, + docs: [''], + label: 'router', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, - "selector": "0xf887ea40" + selector: '0xf887ea40', }, { - "args": [ - { - "label": "_maxTokens", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + label: '_maxTokens', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "default": false, - "docs": [ - "Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits." + default: false, + docs: [ + 'Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits.', ], - "label": "setPoolCap", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0xd835f535" + label: 'setPoolCap', + mutates: true, + payable: false, + returnType: null, + selector: '0xd835f535', }, { - "args": [ - { - "label": "_swapPool", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_insuranceFeeBps", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + label: '_swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_insuranceFeeBps', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "default": false, - "docs": [ - "Make this backstop pool cover another swap pool Beware: Adding a swap pool holding the same token as the backstop pool\ncan easily cause undesirable conditions and must be secured (i.e. long time lock)!" + default: false, + docs: [ + 'Make this backstop pool cover another swap pool Beware: Adding a swap pool holding the same token as the backstop pool\ncan easily cause undesirable conditions and must be secured (i.e. long time lock)!', ], - "label": "addSwapPool", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0xabb26587" + label: 'addSwapPool', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, + }, + selector: '0xabb26587', }, { - "args": [ - { - "label": "_swapPool", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_insuranceFeeBps", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Change a swap pool's insurance withdrawal fee" + args: [ + { + label: '_swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_insuranceFeeBps', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "setInsuranceFee", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0xc6a78196" + default: false, + docs: ["Change a swap pool's insurance withdrawal fee"], + label: 'setInsuranceFee', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, + }, + selector: '0xc6a78196', }, { - "args": [ - { - "label": "_index", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "enumerate swap pools backed by this backstop pool" + args: [ + { + label: '_index', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "getBackedPool", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 + default: false, + docs: ['enumerate swap pools backed by this backstop pool'], + label: 'getBackedPool', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, - "selector": "0xa04345f2" + selector: '0xa04345f2', }, { - "args": [], - "default": false, - "docs": [ - "get swap pool count backed by this backstop pool" - ], - "label": "getBackedPoolCount", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + args: [], + default: false, + docs: ['get swap pool count backed by this backstop pool'], + label: 'getBackedPoolCount', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x5fda8689" + selector: '0x5fda8689', }, { - "args": [ - { - "label": "_swapPool", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "get insurance withdrawal fee for a given swap pool" + args: [ + { + label: '_swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "getInsuranceFee", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: ['get insurance withdrawal fee for a given swap pool'], + label: 'getInsuranceFee', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x504e0153" + selector: '0x504e0153', }, { - "args": [ - { - "label": "_depositAmount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0" + args: [ + { + label: '_depositAmount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "deposit", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "BackstopPool", - "deposit", - "return_type" - ], - "type": 8 + default: false, + docs: ['Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0'], + label: 'deposit', + mutates: true, + payable: false, + returnType: { + displayName: ['BackstopPool', 'deposit', 'return_type'], + type: 8, }, - "selector": "0xb6b55f25" + selector: '0xb6b55f25', }, { - "args": [ - { - "label": "_sharesToBurn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "label": "_minimumAmount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + label: '_sharesToBurn', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + label: '_minimumAmount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "default": false, - "docs": [ - "Withdraws liquidity amount of asset ensuring minimum amount required Slippage is applied (withdrawal fee)" + default: false, + docs: [ + 'Withdraws liquidity amount of asset ensuring minimum amount required Slippage is applied (withdrawal fee)', ], - "label": "withdraw", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "BackstopPool", - "withdraw", - "return_type" - ], - "type": 9 + label: 'withdraw', + mutates: true, + payable: false, + returnType: { + displayName: ['BackstopPool', 'withdraw', 'return_type'], + type: 9, }, - "selector": "0x441a3e70" + selector: '0x441a3e70', }, { - "args": [ - { - "label": "_swapPool", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_shares", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "label": "_minAmount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + label: '_swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_shares', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + label: '_minAmount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "default": false, - "docs": [ - "withdraw from a swap pool using backstop liquidity without slippage only possible if swap pool's coverage ratio < 100%" + default: false, + docs: [ + "withdraw from a swap pool using backstop liquidity without slippage only possible if swap pool's coverage ratio < 100%", ], - "label": "redeemSwapPoolShares", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + label: 'redeemSwapPoolShares', + mutates: true, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x6e7e91fd" + selector: '0x6e7e91fd', }, { - "args": [ - { - "label": "_swapPool", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_shares", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "label": "_minAmount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + label: '_swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_shares', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + label: '_minAmount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "default": false, - "docs": [ - "withdraw from backstop pool, but receive excess liquidity\nof a swap pool without slippage, instead of backstop liquidity" + default: false, + docs: [ + 'withdraw from backstop pool, but receive excess liquidity\nof a swap pool without slippage, instead of backstop liquidity', ], - "label": "withdrawExcessSwapLiquidity", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + label: 'withdrawExcessSwapLiquidity', + mutates: true, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0xcaf8c105" + selector: '0xcaf8c105', }, { - "args": [], - "default": false, - "docs": [ - "return worth of the whole backstop pool in `asset()`, incl. all\nswap pools' excess liquidity and the backstop pool's liabilities\nthis is a fixed point number, using the backstop pool decimals" - ], - "label": "getTotalPoolWorth", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "int256" - ], - "type": 7 + args: [], + default: false, + docs: [ + "return worth of the whole backstop pool in `asset()`, incl. all\nswap pools' excess liquidity and the backstop pool's liabilities\nthis is a fixed point number, using the backstop pool decimals", + ], + label: 'getTotalPoolWorth', + mutates: false, + payable: false, + returnType: { + displayName: ['int256'], + type: 7, }, - "selector": "0x18ba24c4" + selector: '0x18ba24c4', }, { - "args": [ - { - "label": "_sharesToBurn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Returns the worth of an amount of pool shares (LP tokens) in underlying principle" + args: [ + { + label: '_sharesToBurn', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "sharesTargetWorth", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: ['Returns the worth of an amount of pool shares (LP tokens) in underlying principle'], + label: 'sharesTargetWorth', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0xcc045745" + selector: '0xcc045745', }, { - "args": [], - "default": false, - "docs": [ - "returns the backstop pool state" - ], - "label": "getPoolState", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "BackstopPool", - "getPoolState", - "return_type" - ], - "type": 10 + args: [], + default: false, + docs: ['returns the backstop pool state'], + label: 'getPoolState', + mutates: false, + payable: false, + returnType: { + displayName: ['BackstopPool', 'getPoolState', 'return_type'], + type: 10, }, - "selector": "0x217ac237" - } - ] + selector: '0x217ac237', + }, + ], }, - "storage": { - "struct": { - "fields": [ + storage: { + struct: { + fields: [ { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000000", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000000', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "root_key": "0x00000000" - } + root_key: '0x00000000', + }, }, - "name": "_owner" + name: '_owner', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000001", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000001', + ty: 3, + }, }, - "root_key": "0x00000001" - } + root_key: '0x00000001', + }, }, - "name": "_status" + name: '_status', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000002", - "ty": 4 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000002', + ty: 4, + }, }, - "root_key": "0x00000002" - } + root_key: '0x00000002', + }, }, - "name": "_paused" + name: '_paused', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000003", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000003', + ty: 3, + }, }, - "root_key": "0x00000003" - } + root_key: '0x00000003', + }, }, - "name": "_balances" + name: '_balances', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000004", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000004', + ty: 3, + }, }, - "root_key": "0x00000004" - } + root_key: '0x00000004', + }, }, - "name": "_allowances" + name: '_allowances', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000005", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000005', + ty: 3, + }, }, - "root_key": "0x00000005" - } + root_key: '0x00000005', + }, }, - "name": "_totalSupply" + name: '_totalSupply', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000006", - "ty": 5 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000006', + ty: 5, + }, }, - "root_key": "0x00000006" - } + root_key: '0x00000006', + }, }, - "name": "_name" + name: '_name', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000007", - "ty": 5 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000007', + ty: 5, + }, }, - "root_key": "0x00000007" - } + root_key: '0x00000007', + }, }, - "name": "_symbol" + name: '_symbol', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000008", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000008', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "root_key": "0x00000008" - } + root_key: '0x00000008', + }, }, - "name": "poolAsset" + name: 'poolAsset', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000009", - "ty": 0 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000009', + ty: 0, + }, }, - "root_key": "0x00000009" - } + root_key: '0x00000009', + }, }, - "name": "poolAssetDecimals" + name: 'poolAssetDecimals', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x0000000a", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000a', + ty: 3, + }, }, - "root_key": "0x0000000a" - } + root_key: '0x0000000a', + }, }, - "name": "poolCap" + name: 'poolCap', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x0000000b", - "ty": 1 - } + layout: { + leaf: { + key: '0x0000000b', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "root_key": "0x0000000b" - } + root_key: '0x0000000b', + }, }, - "name": "router" + name: 'router', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x0000000c", - "ty": 6 - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000c', + ty: 6, + }, }, - "root_key": "0x0000000c" - } + root_key: '0x0000000c', + }, }, - "name": "swapPools" + name: 'swapPools', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x0000000d", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000d', + ty: 3, + }, }, - "root_key": "0x0000000d" - } + root_key: '0x0000000d', + }, }, - "name": "swapPoolInsuranceFeeBps" + name: 'swapPoolInsuranceFeeBps', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x0000000e", - "ty": 4 - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000e', + ty: 4, + }, }, - "root_key": "0x0000000e" - } + root_key: '0x0000000e', + }, }, - "name": "swapPoolCovered" - } + name: 'swapPoolCovered', + }, ], - "name": "BackstopPool" - } + name: 'BackstopPool', + }, }, - "types": [ + types: [ { - "id": 0, - "type": { - "def": { - "primitive": "u8" + id: 0, + type: { + def: { + primitive: 'u8', }, - "path": [ - "uint8" - ] - } + path: ['uint8'], + }, }, { - "id": 1, - "type": { - "def": { - "array": { - "len": 32, - "type": 0 - } - } - } + id: 1, + type: { + def: { + array: { + len: 32, + type: 0, + }, + }, + }, }, { - "id": 2, - "type": { - "def": { - "composite": { - "fields": [ + id: 2, + type: { + def: { + composite: { + fields: [ { - "type": 1 - } - ] - } + type: 1, + }, + ], + }, }, - "path": [ - "ink_primitives", - "types", - "AccountId" - ] - } + path: ['ink_primitives', 'types', 'AccountId'], + }, }, { - "id": 3, - "type": { - "def": { - "primitive": "u256" + id: 3, + type: { + def: { + primitive: 'u256', }, - "path": [ - "uint256" - ] - } + path: ['uint256'], + }, }, { - "id": 4, - "type": { - "def": { - "primitive": "bool" + id: 4, + type: { + def: { + primitive: 'bool', }, - "path": [ - "bool" - ] - } + path: ['bool'], + }, }, { - "id": 5, - "type": { - "def": { - "primitive": "str" + id: 5, + type: { + def: { + primitive: 'str', }, - "path": [ - "string" - ] - } + path: ['string'], + }, }, { - "id": 6, - "type": { - "def": { - "sequence": { - "type": 2 - } - } - } + id: 6, + type: { + def: { + sequence: { + type: 2, + }, + }, + }, }, { - "id": 7, - "type": { - "def": { - "primitive": "i256" + id: 7, + type: { + def: { + primitive: 'i256', }, - "path": [ - "int256" - ] - } + path: ['int256'], + }, }, { - "id": 8, - "type": { - "def": { - "tuple": [ - 3, - 7 - ] + id: 8, + type: { + def: { + tuple: [3, 7], }, - "path": [ - "BackstopPool", - "deposit", - "return_type" - ] - } + path: ['BackstopPool', 'deposit', 'return_type'], + }, }, { - "id": 9, - "type": { - "def": { - "tuple": [ - 3, - 7 - ] + id: 9, + type: { + def: { + tuple: [3, 7], }, - "path": [ - "BackstopPool", - "withdraw", - "return_type" - ] - } + path: ['BackstopPool', 'withdraw', 'return_type'], + }, }, { - "id": 10, - "type": { - "def": { - "tuple": [ - 3, - 7, - 3 - ] + id: 10, + type: { + def: { + tuple: [3, 7, 3], }, - "path": [ - "BackstopPool", - "getPoolState", - "return_type" - ] - } + path: ['BackstopPool', 'getPoolState', 'return_type'], + }, }, { - "id": 11, - "type": { - "def": { - "primitive": "u128" + id: 11, + type: { + def: { + primitive: 'u128', }, - "path": [ - "uint128" - ] - } + path: ['uint128'], + }, }, { - "id": 12, - "type": { - "def": { - "primitive": "u64" + id: 12, + type: { + def: { + primitive: 'u64', }, - "path": [ - "uint64" - ] - } + path: ['uint64'], + }, }, { - "id": 13, - "type": { - "def": { - "composite": { - "fields": [ + id: 13, + type: { + def: { + composite: { + fields: [ { - "type": 1 - } - ] - } + type: 1, + }, + ], + }, }, - "path": [ - "ink_primitives", - "types", - "Hash" - ] - } + path: ['ink_primitives', 'types', 'Hash'], + }, }, { - "id": 14, - "type": { - "def": { - "composite": { - "fields": [ + id: 14, + type: { + def: { + composite: { + fields: [ { - "type": 5 - } - ] - } + type: 5, + }, + ], + }, }, - "path": [ - "0x08c379a0" - ] - } + path: ['0x08c379a0'], + }, }, { - "id": 15, - "type": { - "def": { - "composite": { - "fields": [ + id: 15, + type: { + def: { + composite: { + fields: [ { - "type": 3 - } - ] - } + type: 3, + }, + ], + }, }, - "path": [ - "0x4e487b71" - ] - } + path: ['0x4e487b71'], + }, }, { - "id": 16, - "type": { - "def": { - "variant": { - "variants": [ + id: 16, + type: { + def: { + variant: { + variants: [ { - "fields": [ + fields: [ { - "type": 14 - } + type: 14, + }, ], - "index": 0, - "name": "Error" + index: 0, + name: 'Error', }, { - "fields": [ + fields: [ { - "type": 15 - } + type: 15, + }, ], - "index": 1, - "name": "Panic" - } - ] - } + index: 1, + name: 'Panic', + }, + ], + }, }, - "path": [ - "SolidityError" - ] - } - } + path: ['SolidityError'], + }, + }, ], - "version": "4" -} as const; + version: '4', +}; diff --git a/src/contracts/nabla/ERC20Wrapper.ts b/src/contracts/nabla/ERC20Wrapper.ts index 021b6a98..671f2e10 100644 --- a/src/contracts/nabla/ERC20Wrapper.ts +++ b/src/contracts/nabla/ERC20Wrapper.ts @@ -1,798 +1,654 @@ export const erc20WrapperAbi = { - "contract": { - "authors": [ - "unknown" - ], - "name": "ERC20Wrapper", - "version": "0.0.1" + contract: { + authors: ['unknown'], + name: 'ERC20Wrapper', + version: '0.0.1', }, - "source": { - "compiler": "solang 0.3.2", - "hash": "0xd070e8f0df66f4f13a8ee42d5bf90220b1867883444c8f73f400f8c57ae2c9cd", - "language": "Solidity 0.3.2" + source: { + compiler: 'solang 0.3.2', + hash: '0xfd052826432f969b18f912400fc92fbb97ed4122dd6fa1ee3828bfc81b93e316', + language: 'Solidity 0.3.2', }, - "spec": { - "constructors": [ + spec: { + constructors: [ { - "args": [ + args: [ { - "label": "name_", - "type": { - "displayName": [ - "string" - ], - "type": 0 - } + label: 'name_', + type: { + displayName: ['string'], + type: 0, + }, }, { - "label": "symbol_", - "type": { - "displayName": [ - "string" - ], - "type": 0 - } + label: 'symbol_', + type: { + displayName: ['string'], + type: 0, + }, }, { - "label": "decimals_", - "type": { - "displayName": [ - "uint8" - ], - "type": 1 - } + label: 'decimals_', + type: { + displayName: ['uint8'], + type: 1, + }, }, { - "label": "variant_", - "type": { - "displayName": [], - "type": 2 - } + label: 'variant_', + type: { + displayName: [], + type: 2, + }, }, { - "label": "index_", - "type": { - "displayName": [], - "type": 2 - } + label: 'index_', + type: { + displayName: [], + type: 2, + }, }, { - "label": "code_", - "type": { - "displayName": [], - "type": 3 - } + label: 'code_', + type: { + displayName: [], + type: 3, + }, }, { - "label": "issuer_", - "type": { - "displayName": [], - "type": 4 - } - } - ], - "default": false, - "docs": [ - "" + label: 'issuer_', + type: { + displayName: [], + type: 4, + }, + }, ], - "label": "new", - "payable": false, - "returnType": null, - "selector": "0xd3b751bd" - } - ], - "docs": [ - "" + default: false, + docs: [''], + label: 'new', + payable: false, + returnType: null, + selector: '0xd3b751bd', + }, ], - "environment": { - "accountId": { - "displayName": [ - "AccountId" - ], - "type": 6 + docs: [''], + environment: { + accountId: { + displayName: ['AccountId'], + type: 6, }, - "balance": { - "displayName": [ - "Balance" - ], - "type": 8 + balance: { + displayName: ['Balance'], + type: 8, }, - "blockNumber": { - "displayName": [ - "BlockNumber" - ], - "type": 9 + blockNumber: { + displayName: ['BlockNumber'], + type: 9, }, - "chainExtension": { - "displayName": [], - "type": 0 + chainExtension: { + displayName: [], + type: 0, }, - "hash": { - "displayName": [ - "Hash" - ], - "type": 10 + hash: { + displayName: ['Hash'], + type: 10, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 9, }, - "maxEventTopics": 4, - "timestamp": { - "displayName": [ - "Timestamp" - ], - "type": 9 - } }, - "events": [ + events: [ { - "args": [ + args: [ { - "docs": [], - "indexed": true, - "label": "from", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } + docs: [], + indexed: true, + label: 'from', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, }, { - "docs": [], - "indexed": true, - "label": "to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } + docs: [], + indexed: true, + label: 'to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, }, { - "docs": [], - "indexed": false, - "label": "value", - "type": { - "displayName": [ - "uint256" - ], - "type": 5 - } - } - ], - "docs": [ - "" + docs: [], + indexed: false, + label: 'value', + type: { + displayName: ['uint256'], + type: 5, + }, + }, ], - "label": "Transfer" + docs: [''], + label: 'Transfer', }, { - "args": [ + args: [ { - "docs": [], - "indexed": true, - "label": "owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } + docs: [], + indexed: true, + label: 'owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, }, { - "docs": [], - "indexed": true, - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } + docs: [], + indexed: true, + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, }, { - "docs": [], - "indexed": false, - "label": "value", - "type": { - "displayName": [ - "uint256" - ], - "type": 5 - } - } - ], - "docs": [ - "" + docs: [], + indexed: false, + label: 'value', + type: { + displayName: ['uint256'], + type: 5, + }, + }, ], - "label": "Approval" - } + docs: [''], + label: 'Approval', + }, ], - "lang_error": { - "displayName": [ - "SolidityError" - ], - "type": 13 + lang_error: { + displayName: ['SolidityError'], + type: 13, }, - "messages": [ + messages: [ { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "name", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "string" - ], - "type": 0 + args: [], + default: false, + docs: [''], + label: 'name', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 0, }, - "selector": "0x06fdde03" + selector: '0x06fdde03', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "symbol", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "string" - ], - "type": 0 + args: [], + default: false, + docs: [''], + label: 'symbol', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 0, }, - "selector": "0x95d89b41" + selector: '0x95d89b41', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "decimals", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint8" - ], - "type": 1 + args: [], + default: false, + docs: [''], + label: 'decimals', + mutates: false, + payable: false, + returnType: { + displayName: ['uint8'], + type: 1, }, - "selector": "0x313ce567" + selector: '0x313ce567', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "totalSupply", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 5 + args: [], + default: false, + docs: [''], + label: 'totalSupply', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 5, }, - "selector": "0x18160ddd" + selector: '0x18160ddd', }, { - "args": [ + args: [ { - "label": "_owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } - } - ], - "default": false, - "docs": [ - "" + label: '_owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, ], - "label": "balanceOf", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 5 + default: false, + docs: [''], + label: 'balanceOf', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 5, }, - "selector": "0x70a08231" + selector: '0x70a08231', }, { - "args": [ + args: [ { - "label": "_to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } + label: '_to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, }, { - "label": "_amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 5 - } - } - ], - "default": false, - "docs": [ - "" + label: '_amount', + type: { + displayName: ['uint256'], + type: 5, + }, + }, ], - "label": "transfer", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 7 + default: false, + docs: [''], + label: 'transfer', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 7, }, - "selector": "0xa9059cbb" + selector: '0xa9059cbb', }, { - "args": [ + args: [ { - "label": "_owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } + label: '_owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, }, { - "label": "_spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } - } - ], - "default": false, - "docs": [ - "" + label: '_spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, + }, ], - "label": "allowance", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 5 + default: false, + docs: [''], + label: 'allowance', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 5, }, - "selector": "0xdd62ed3e" + selector: '0xdd62ed3e', }, { - "args": [ + args: [ { - "label": "_spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } + label: '_spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, }, { - "label": "_amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 5 - } - } - ], - "default": false, - "docs": [ - "" + label: '_amount', + type: { + displayName: ['uint256'], + type: 5, + }, + }, ], - "label": "approve", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 7 + default: false, + docs: [''], + label: 'approve', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 7, }, - "selector": "0x095ea7b3" + selector: '0x095ea7b3', }, { - "args": [ + args: [ { - "label": "_from", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } + label: '_from', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, }, { - "label": "_to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 6 - } + label: '_to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 6, + }, }, { - "label": "_amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 5 - } - } - ], - "default": false, - "docs": [ - "" + label: '_amount', + type: { + displayName: ['uint256'], + type: 5, + }, + }, ], - "label": "transferFrom", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 7 + default: false, + docs: [''], + label: 'transferFrom', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 7, }, - "selector": "0x23b872dd" - } - ] + selector: '0x23b872dd', + }, + ], }, - "storage": { - "struct": { - "fields": [ + storage: { + struct: { + fields: [ { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000000", - "ty": 0 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000000', + ty: 0, + }, }, - "root_key": "0x00000000" - } + root_key: '0x00000000', + }, }, - "name": "_name" + name: '_name', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000001", - "ty": 0 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000001', + ty: 0, + }, }, - "root_key": "0x00000001" - } + root_key: '0x00000001', + }, }, - "name": "_symbol" + name: '_symbol', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000002", - "ty": 1 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000002', + ty: 1, + }, }, - "root_key": "0x00000002" - } + root_key: '0x00000002', + }, }, - "name": "_decimals" + name: '_decimals', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000003", - "ty": 2 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000003', + ty: 2, + }, }, - "root_key": "0x00000003" - } + root_key: '0x00000003', + }, }, - "name": "_variant" + name: '_variant', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000004", - "ty": 2 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000004', + ty: 2, + }, }, - "root_key": "0x00000004" - } + root_key: '0x00000004', + }, }, - "name": "_index" + name: '_index', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000005", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000005', + ty: 3, + }, }, - "root_key": "0x00000005" - } + root_key: '0x00000005', + }, }, - "name": "_code" + name: '_code', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000006", - "ty": 4 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000006', + ty: 4, + }, }, - "root_key": "0x00000006" - } + root_key: '0x00000006', + }, }, - "name": "_issuer" - } + name: '_issuer', + }, ], - "name": "ERC20Wrapper" - } + name: 'ERC20Wrapper', + }, }, - "types": [ + types: [ { - "id": 0, - "type": { - "def": { - "primitive": "str" + id: 0, + type: { + def: { + primitive: 'str', }, - "path": [ - "string" - ] - } + path: ['string'], + }, }, { - "id": 1, - "type": { - "def": { - "primitive": "u8" + id: 1, + type: { + def: { + primitive: 'u8', }, - "path": [ - "uint8" - ] - } + path: ['uint8'], + }, }, { - "id": 2, - "type": { - "def": { - "array": { - "len": 1, - "type": 1 - } - } - } + id: 2, + type: { + def: { + array: { + len: 1, + type: 1, + }, + }, + }, }, { - "id": 3, - "type": { - "def": { - "array": { - "len": 12, - "type": 1 - } - } - } + id: 3, + type: { + def: { + array: { + len: 12, + type: 1, + }, + }, + }, }, { - "id": 4, - "type": { - "def": { - "array": { - "len": 32, - "type": 1 - } - } - } + id: 4, + type: { + def: { + array: { + len: 32, + type: 1, + }, + }, + }, }, { - "id": 5, - "type": { - "def": { - "primitive": "u256" + id: 5, + type: { + def: { + primitive: 'u256', }, - "path": [ - "uint256" - ] - } + path: ['uint256'], + }, }, { - "id": 6, - "type": { - "def": { - "composite": { - "fields": [ + id: 6, + type: { + def: { + composite: { + fields: [ { - "type": 4 - } - ] - } + type: 4, + }, + ], + }, }, - "path": [ - "ink_primitives", - "types", - "AccountId" - ] - } + path: ['ink_primitives', 'types', 'AccountId'], + }, }, { - "id": 7, - "type": { - "def": { - "primitive": "bool" + id: 7, + type: { + def: { + primitive: 'bool', }, - "path": [ - "bool" - ] - } + path: ['bool'], + }, }, { - "id": 8, - "type": { - "def": { - "primitive": "u128" + id: 8, + type: { + def: { + primitive: 'u128', }, - "path": [ - "uint128" - ] - } + path: ['uint128'], + }, }, { - "id": 9, - "type": { - "def": { - "primitive": "u64" + id: 9, + type: { + def: { + primitive: 'u64', }, - "path": [ - "uint64" - ] - } + path: ['uint64'], + }, }, { - "id": 10, - "type": { - "def": { - "composite": { - "fields": [ + id: 10, + type: { + def: { + composite: { + fields: [ { - "type": 4 - } - ] - } + type: 4, + }, + ], + }, }, - "path": [ - "ink_primitives", - "types", - "Hash" - ] - } + path: ['ink_primitives', 'types', 'Hash'], + }, }, { - "id": 11, - "type": { - "def": { - "composite": { - "fields": [ + id: 11, + type: { + def: { + composite: { + fields: [ { - "type": 0 - } - ] - } + type: 0, + }, + ], + }, }, - "path": [ - "0x08c379a0" - ] - } + path: ['0x08c379a0'], + }, }, { - "id": 12, - "type": { - "def": { - "composite": { - "fields": [ + id: 12, + type: { + def: { + composite: { + fields: [ { - "type": 5 - } - ] - } + type: 5, + }, + ], + }, }, - "path": [ - "0x4e487b71" - ] - } + path: ['0x4e487b71'], + }, }, { - "id": 13, - "type": { - "def": { - "variant": { - "variants": [ + id: 13, + type: { + def: { + variant: { + variants: [ { - "fields": [ + fields: [ { - "type": 11 - } + type: 11, + }, ], - "index": 0, - "name": "Error" + index: 0, + name: 'Error', }, { - "fields": [ + fields: [ { - "type": 12 - } + type: 12, + }, ], - "index": 1, - "name": "Panic" - } - ] - } + index: 1, + name: 'Panic', + }, + ], + }, }, - "path": [ - "SolidityError" - ] - } - } + path: ['SolidityError'], + }, + }, ], - "version": "4" -} as const; + version: '4', +}; diff --git a/src/contracts/nabla/NablaCurve.ts b/src/contracts/nabla/NablaCurve.ts index 6565604d..720d4d84 100644 --- a/src/contracts/nabla/NablaCurve.ts +++ b/src/contracts/nabla/NablaCurve.ts @@ -529,4 +529,4 @@ export const nablaCurveAbi = { } ], "version": "4" -} as const; +} diff --git a/src/contracts/nabla/PriceOracle.ts b/src/contracts/nabla/PriceOracle.ts index 9565cd66..bb84d9f6 100644 --- a/src/contracts/nabla/PriceOracle.ts +++ b/src/contracts/nabla/PriceOracle.ts @@ -1,713 +1,590 @@ export const priceOracleAbi = { - "contract": { - "authors": [ - "unknown" - ], - "description": "PriceOracleWrapper\nPrice oracle that uses the native chain via chain extension. It stores _asset, _blockchain and _symbol for use by function getAssetPrice() which is called by Nabla.", - "name": "PriceOracleWrapper", - "version": "0.0.1" + contract: { + authors: ['unknown'], + description: + 'PriceOracleWrapper\nPrice oracle that uses the native chain via chain extension. It stores _asset, _blockchain and _symbol for use by function getAssetPrice() which is called by Nabla.', + name: 'PriceOracleWrapper', + version: '0.0.1', }, - "source": { - "compiler": "solang 0.3.2", - "hash": "0x03b6e72dd745ae29cddc8f15ad73b91bd1b32f2c7369b8f4dc8be1c363116740", - "language": "Solidity 0.3.2" + source: { + compiler: 'solang 0.3.2', + hash: '0xd0aecf9849632929fd6f77117fd5205af2638d0c9693aa4dd7dc65cd23b74a62', + language: 'Solidity 0.3.2', }, - "spec": { - "constructors": [ + spec: { + constructors: [ { - "args": [ + args: [ { - "label": "oracleKeys", - "type": { - "displayName": [], - "type": 5 - } - } - ], - "default": false, - "docs": [ - "" + label: 'oracleKeys', + type: { + displayName: [], + type: 5, + }, + }, ], - "label": "new", - "payable": false, - "returnType": null, - "selector": "0xd0656c89" - } + default: false, + docs: [''], + label: 'new', + payable: false, + returnType: null, + selector: '0xd0656c89', + }, ], - "docs": [ - "PriceOracleWrapper\n\nPrice oracle that uses the native chain via chain extension. It stores _asset, _blockchain and _symbol for use by function getAssetPrice() which is called by Nabla." + docs: [ + 'PriceOracleWrapper\n\nPrice oracle that uses the native chain via chain extension. It stores _asset, _blockchain and _symbol for use by function getAssetPrice() which is called by Nabla.', ], - "environment": { - "accountId": { - "displayName": [ - "AccountId" - ], - "type": 2 + environment: { + accountId: { + displayName: ['AccountId'], + type: 2, }, - "balance": { - "displayName": [ - "Balance" - ], - "type": 8 + balance: { + displayName: ['Balance'], + type: 8, }, - "blockNumber": { - "displayName": [ - "BlockNumber" - ], - "type": 9 + blockNumber: { + displayName: ['BlockNumber'], + type: 9, }, - "chainExtension": { - "displayName": [], - "type": 0 + chainExtension: { + displayName: [], + type: 0, }, - "hash": { - "displayName": [ - "Hash" - ], - "type": 12 + hash: { + displayName: ['Hash'], + type: 12, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 9, }, - "maxEventTopics": 4, - "timestamp": { - "displayName": [ - "Timestamp" - ], - "type": 9 - } }, - "events": [], - "lang_error": { - "displayName": [ - "SolidityError" - ], - "type": 15 + events: [], + lang_error: { + displayName: ['SolidityError'], + type: 15, }, - "messages": [ + messages: [ { - "args": [ + args: [ { - "label": "", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + label: '', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "oracleByAsset", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "PriceOracleWrapper", - "oracleByAsset", - "return_type" - ], - "type": 6 + default: false, + docs: [''], + label: 'oracleByAsset', + mutates: false, + payable: false, + returnType: { + displayName: ['PriceOracleWrapper', 'oracleByAsset', 'return_type'], + type: 6, }, - "selector": "0x38163032" + selector: '0x38163032', }, { - "args": [ + args: [ { - "label": "asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + label: 'asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "getOracleKeyAsset", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 + default: false, + docs: [''], + label: 'getOracleKeyAsset', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, - "selector": "0x1d6752d1" + selector: '0x1d6752d1', }, { - "args": [ + args: [ { - "label": "asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + label: 'asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "getOracleKeyBlockchain", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "string" - ], - "type": 3 + default: false, + docs: [''], + label: 'getOracleKeyBlockchain', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 3, }, - "selector": "0xf457eab5" + selector: '0xf457eab5', }, { - "args": [ + args: [ { - "label": "asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + label: 'asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "getOracleKeySymbol", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "string" - ], - "type": 3 + default: false, + docs: [''], + label: 'getOracleKeySymbol', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 3, }, - "selector": "0x416c2844" + selector: '0x416c2844', }, { - "args": [ + args: [ { - "label": "asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } + label: 'asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "default": false, - "docs": [ - "Returns the asset price in USD. This is called by Nabla and expected by their IPriceOracleGetter interface" + default: false, + docs: [ + 'Returns the asset price in USD. This is called by Nabla and expected by their IPriceOracleGetter interface', ], - "label": "getAssetPrice", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 7 + label: 'getAssetPrice', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 7, }, - "selector": "0xb3596f07" + selector: '0xb3596f07', }, { - "args": [ + args: [ { - "label": "blockchain", - "type": { - "displayName": [ - "string" - ], - "type": 3 - } + label: 'blockchain', + type: { + displayName: ['string'], + type: 3, + }, }, { - "label": "symbol", - "type": { - "displayName": [ - "string" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + label: 'symbol', + type: { + displayName: ['string'], + type: 3, + }, + }, ], - "label": "getAnyAssetSupply", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint128" - ], - "type": 8 + default: false, + docs: [''], + label: 'getAnyAssetSupply', + mutates: false, + payable: false, + returnType: { + displayName: ['uint128'], + type: 8, }, - "selector": "0xb27f53dd" + selector: '0xb27f53dd', }, { - "args": [ + args: [ { - "label": "blockchain", - "type": { - "displayName": [ - "string" - ], - "type": 3 - } + label: 'blockchain', + type: { + displayName: ['string'], + type: 3, + }, }, { - "label": "symbol", - "type": { - "displayName": [ - "string" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + label: 'symbol', + type: { + displayName: ['string'], + type: 3, + }, + }, ], - "label": "getAnyAssetLastUpdateTimestamp", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint64" - ], - "type": 9 + default: false, + docs: [''], + label: 'getAnyAssetLastUpdateTimestamp', + mutates: false, + payable: false, + returnType: { + displayName: ['uint64'], + type: 9, }, - "selector": "0x30c8d868" + selector: '0x30c8d868', }, { - "args": [ + args: [ { - "label": "blockchain", - "type": { - "displayName": [ - "string" - ], - "type": 3 - } + label: 'blockchain', + type: { + displayName: ['string'], + type: 3, + }, }, { - "label": "symbol", - "type": { - "displayName": [ - "string" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + label: 'symbol', + type: { + displayName: ['string'], + type: 3, + }, + }, ], - "label": "getAnyAssetPrice", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint128" - ], - "type": 8 + default: false, + docs: [''], + label: 'getAnyAssetPrice', + mutates: false, + payable: false, + returnType: { + displayName: ['uint128'], + type: 8, }, - "selector": "0x96e182f6" + selector: '0x96e182f6', }, { - "args": [ + args: [ { - "label": "blockchain", - "type": { - "displayName": [ - "string" - ], - "type": 3 - } + label: 'blockchain', + type: { + displayName: ['string'], + type: 3, + }, }, { - "label": "symbol", - "type": { - "displayName": [ - "string" - ], - "type": 3 - } - } + label: 'symbol', + type: { + displayName: ['string'], + type: 3, + }, + }, ], - "default": false, - "docs": [ - "performs the actual chain extension call to get the price feed. blockchain and symbol are the keys used to access a particular price feed from the chain." + default: false, + docs: [ + 'performs the actual chain extension call to get the price feed. blockchain and symbol are the keys used to access a particular price feed from the chain.', ], - "label": "getAnyAsset", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "CoinInfo" - ], - "type": 11 + label: 'getAnyAsset', + mutates: false, + payable: false, + returnType: { + displayName: ['CoinInfo'], + type: 11, }, - "selector": "0xb57ba499" - } - ] + selector: '0xb57ba499', + }, + ], }, - "storage": { - "struct": { - "fields": [ + storage: { + struct: { + fields: [ { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "struct": { - "fields": [ + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000000", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000000', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "name": "asset" + name: 'asset', }, { - "layout": { - "leaf": { - "key": "0x00000000", - "ty": 3 - } + layout: { + leaf: { + key: '0x00000000', + ty: 3, + }, }, - "name": "blockchain" + name: 'blockchain', }, { - "layout": { - "leaf": { - "key": "0x00000000", - "ty": 3 - } + layout: { + leaf: { + key: '0x00000000', + ty: 3, + }, }, - "name": "symbol" - } + name: 'symbol', + }, ], - "name": "OracleKey" - } + name: 'OracleKey', + }, }, - "root_key": "0x00000000" - } + root_key: '0x00000000', + }, }, - "name": "oracleByAsset" - } + name: 'oracleByAsset', + }, ], - "name": "PriceOracleWrapper" - } + name: 'PriceOracleWrapper', + }, }, - "types": [ + types: [ { - "id": 0, - "type": { - "def": { - "primitive": "u8" + id: 0, + type: { + def: { + primitive: 'u8', }, - "path": [ - "uint8" - ] - } + path: ['uint8'], + }, }, { - "id": 1, - "type": { - "def": { - "array": { - "len": 32, - "type": 0 - } - } - } + id: 1, + type: { + def: { + array: { + len: 32, + type: 0, + }, + }, + }, }, { - "id": 2, - "type": { - "def": { - "composite": { - "fields": [ + id: 2, + type: { + def: { + composite: { + fields: [ { - "type": 1 - } - ] - } + type: 1, + }, + ], + }, }, - "path": [ - "ink_primitives", - "types", - "AccountId" - ] - } + path: ['ink_primitives', 'types', 'AccountId'], + }, }, { - "id": 3, - "type": { - "def": { - "primitive": "str" + id: 3, + type: { + def: { + primitive: 'str', }, - "path": [ - "string" - ] - } + path: ['string'], + }, }, { - "id": 4, - "type": { - "def": { - "composite": { - "fields": [ + id: 4, + type: { + def: { + composite: { + fields: [ { - "name": "asset", - "type": 2 + name: 'asset', + type: 2, }, { - "name": "blockchain", - "type": 3 + name: 'blockchain', + type: 3, }, { - "name": "symbol", - "type": 3 - } - ] - } + name: 'symbol', + type: 3, + }, + ], + }, }, - "path": [ - "OracleKey" - ] - } + path: ['OracleKey'], + }, }, { - "id": 5, - "type": { - "def": { - "sequence": { - "type": 4 - } - } - } + id: 5, + type: { + def: { + sequence: { + type: 4, + }, + }, + }, }, { - "id": 6, - "type": { - "def": { - "tuple": [ - 2, - 3, - 3 - ] + id: 6, + type: { + def: { + tuple: [2, 3, 3], }, - "path": [ - "PriceOracleWrapper", - "oracleByAsset", - "return_type" - ] - } + path: ['PriceOracleWrapper', 'oracleByAsset', 'return_type'], + }, }, { - "id": 7, - "type": { - "def": { - "primitive": "u256" + id: 7, + type: { + def: { + primitive: 'u256', }, - "path": [ - "uint256" - ] - } + path: ['uint256'], + }, }, { - "id": 8, - "type": { - "def": { - "primitive": "u128" + id: 8, + type: { + def: { + primitive: 'u128', }, - "path": [ - "uint128" - ] - } + path: ['uint128'], + }, }, { - "id": 9, - "type": { - "def": { - "primitive": "u64" + id: 9, + type: { + def: { + primitive: 'u64', }, - "path": [ - "uint64" - ] - } + path: ['uint64'], + }, }, { - "id": 10, - "type": { - "def": { - "sequence": { - "type": 0 - } - } - } + id: 10, + type: { + def: { + sequence: { + type: 0, + }, + }, + }, }, { - "id": 11, - "type": { - "def": { - "composite": { - "fields": [ + id: 11, + type: { + def: { + composite: { + fields: [ { - "name": "symbol", - "type": 10 + name: 'symbol', + type: 10, }, { - "name": "name", - "type": 10 + name: 'name', + type: 10, }, { - "name": "blockchain", - "type": 10 + name: 'blockchain', + type: 10, }, { - "name": "supply", - "type": 8 + name: 'supply', + type: 8, }, { - "name": "last_update_timestamp", - "type": 9 + name: 'last_update_timestamp', + type: 9, }, { - "name": "price", - "type": 8 - } - ] - } + name: 'price', + type: 8, + }, + ], + }, }, - "path": [ - "CoinInfo" - ] - } + path: ['CoinInfo'], + }, }, { - "id": 12, - "type": { - "def": { - "composite": { - "fields": [ + id: 12, + type: { + def: { + composite: { + fields: [ { - "type": 1 - } - ] - } + type: 1, + }, + ], + }, }, - "path": [ - "ink_primitives", - "types", - "Hash" - ] - } + path: ['ink_primitives', 'types', 'Hash'], + }, }, { - "id": 13, - "type": { - "def": { - "composite": { - "fields": [ + id: 13, + type: { + def: { + composite: { + fields: [ { - "type": 3 - } - ] - } + type: 3, + }, + ], + }, }, - "path": [ - "0x08c379a0" - ] - } + path: ['0x08c379a0'], + }, }, { - "id": 14, - "type": { - "def": { - "composite": { - "fields": [ + id: 14, + type: { + def: { + composite: { + fields: [ { - "type": 7 - } - ] - } + type: 7, + }, + ], + }, }, - "path": [ - "0x4e487b71" - ] - } + path: ['0x4e487b71'], + }, }, { - "id": 15, - "type": { - "def": { - "variant": { - "variants": [ + id: 15, + type: { + def: { + variant: { + variants: [ { - "fields": [ + fields: [ { - "type": 13 - } + type: 13, + }, ], - "index": 0, - "name": "Error" + index: 0, + name: 'Error', }, { - "fields": [ + fields: [ { - "type": 14 - } + type: 14, + }, ], - "index": 1, - "name": "Panic" - } - ] - } + index: 1, + name: 'Panic', + }, + ], + }, }, - "path": [ - "SolidityError" - ] - } - } + path: ['SolidityError'], + }, + }, ], - "version": "4" -} as const; + version: '4', +}; diff --git a/src/contracts/nabla/Router.ts b/src/contracts/nabla/Router.ts index 7e7a3742..8c4c2c84 100644 --- a/src/contracts/nabla/Router.ts +++ b/src/contracts/nabla/Router.ts @@ -1,986 +1,797 @@ export const routerAbi = { - "contract": { - "authors": [ - "unknown" - ], - "name": "Router", - "version": "0.0.1" + contract: { + authors: ['unknown'], + name: 'Router', + version: '0.0.1', }, - "source": { - "compiler": "solang 0.3.2", - "hash": "0xe2399cb35f8b6165c02038216d66719e2f91be30096c0324fc759c0826684bcc", - "language": "Solidity 0.3.2" + source: { + compiler: 'solang 0.3.2', + hash: '0x1461e0f01fe866142df918dc0c65f8a185e5079d6a642da2b79436f6839db44e', + language: 'Solidity 0.3.2', }, - "spec": { - "constructors": [ + spec: { + constructors: [ { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "new", - "payable": false, - "returnType": null, - "selector": "0x861731d5" - } - ], - "docs": [ - "" + args: [], + default: false, + docs: [''], + label: 'new', + payable: false, + returnType: null, + selector: '0x861731d5', + }, ], - "environment": { - "accountId": { - "displayName": [ - "AccountId" - ], - "type": 2 + docs: [''], + environment: { + accountId: { + displayName: ['AccountId'], + type: 2, }, - "balance": { - "displayName": [ - "Balance" - ], - "type": 7 + balance: { + displayName: ['Balance'], + type: 8, }, - "blockNumber": { - "displayName": [ - "BlockNumber" - ], - "type": 8 + blockNumber: { + displayName: ['BlockNumber'], + type: 9, }, - "chainExtension": { - "displayName": [], - "type": 0 + chainExtension: { + displayName: [], + type: 0, }, - "hash": { - "displayName": [ - "Hash" - ], - "type": 9 + hash: { + displayName: ['Hash'], + type: 10, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 9, }, - "maxEventTopics": 4, - "timestamp": { - "displayName": [ - "Timestamp" - ], - "type": 8 - } }, - "events": [ + events: [ { - "args": [ + args: [ { - "docs": [], - "indexed": false, - "label": "account", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "" + docs: [], + indexed: false, + label: 'account', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "Paused" + docs: [''], + label: 'Paused', }, { - "args": [ + args: [ { - "docs": [], - "indexed": false, - "label": "account", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "" + docs: [], + indexed: false, + label: 'account', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "Unpaused" + docs: [''], + label: 'Unpaused', }, { - "args": [ + args: [ { - "docs": [], - "indexed": true, - "label": "previousOwner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + docs: [], + indexed: true, + label: 'previousOwner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "docs": [], - "indexed": true, - "label": "newOwner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "" + docs: [], + indexed: true, + label: 'newOwner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "OwnershipTransferred" + docs: [''], + label: 'OwnershipTransferred', }, { - "args": [ + args: [ { - "docs": [], - "indexed": true, - "label": "sender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "docs": [], - "indexed": false, - "label": "pool", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + docs: [], + indexed: false, + label: 'pool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "docs": [], - "indexed": false, - "label": "asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "Emitted when a new pool is registered" + docs: [], + indexed: false, + label: 'asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "SwapPoolRegistered" + docs: ['Emitted when a new pool is registered'], + label: 'SwapPoolRegistered', }, { - "args": [ + args: [ { - "docs": [], - "indexed": true, - "label": "sender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "docs": [], - "indexed": false, - "label": "asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "Emitted when pool is unregistered" + docs: [], + indexed: false, + label: 'asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "SwapPoolUnregistered" + docs: ['Emitted when pool is unregistered'], + label: 'SwapPoolUnregistered', }, { - "args": [ + args: [ { - "docs": [], - "indexed": true, - "label": "sender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "docs": [], - "indexed": false, - "label": "amountIn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } + docs: [], + indexed: false, + label: 'amountIn', + type: { + displayName: ['uint256'], + type: 3, + }, }, { - "docs": [], - "indexed": false, - "label": "amountOut", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } + docs: [], + indexed: false, + label: 'amountOut', + type: { + displayName: ['uint256'], + type: 3, + }, }, { - "docs": [], - "indexed": false, - "label": "tokenIn", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + docs: [], + indexed: false, + label: 'tokenIn', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "docs": [], - "indexed": false, - "label": "tokenOut", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + docs: [], + indexed: false, + label: 'tokenOut', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "docs": [], - "indexed": true, - "label": "to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "Emitted on each swap" + docs: [], + indexed: true, + label: 'to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "Swap" - } + docs: ['Emitted on each swap'], + label: 'Swap', + }, ], - "lang_error": { - "displayName": [ - "SolidityError" - ], - "type": 13 + lang_error: { + displayName: ['SolidityError'], + type: 14, }, - "messages": [ + messages: [ { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "paused", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + args: [], + default: false, + docs: [''], + label: 'paused', + mutates: false, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0x5c975abb" + selector: '0x5c975abb', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "owner", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 + args: [], + default: false, + docs: [''], + label: 'owner', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, - "selector": "0x8da5cb5b" + selector: '0x8da5cb5b', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "renounceOwnership", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0x715018a6" + args: [], + default: false, + docs: [''], + label: 'renounceOwnership', + mutates: true, + payable: false, + returnType: null, + selector: '0x715018a6', }, { - "args": [ + args: [ { - "label": "newOwner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + label: 'newOwner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "transferOwnership", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0xf2fde38b" + default: false, + docs: [''], + label: 'transferOwnership', + mutates: true, + payable: false, + returnType: null, + selector: '0xf2fde38b', }, { - "args": [ + args: [ { - "label": "asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + label: 'asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "poolByAsset", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 + default: false, + docs: [''], + label: 'poolByAsset', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, - "selector": "0x06de94d8" + selector: '0x06de94d8', }, { - "args": [ + args: [ { - "label": "asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + label: 'asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "oracleByAsset", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 + default: false, + docs: [''], + label: 'oracleByAsset', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, }, - "selector": "0x38163032" + selector: '0x38163032', }, { - "args": [ + args: [ { - "label": "_asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + label: '_asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "label": "_priceOracle", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "Changes the pools priceOracle. Can only be set by the contract owner." + label: '_priceOracle', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "setPriceOracle", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0x67a74ddc" + default: false, + docs: ['Changes the pools priceOracle. Can only be set by the contract owner.'], + label: 'setPriceOracle', + mutates: true, + payable: false, + returnType: null, + selector: '0x67a74ddc', }, { - "args": [ + args: [ { - "label": "_asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + label: '_asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "label": "_swapPool", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "Registers a newly created swap pool" + label: '_swapPool', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "registerPool", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: ['Registers a newly created swap pool'], + label: 'registerPool', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0x7286e5e5" + selector: '0x7286e5e5', }, { - "args": [ + args: [ { - "label": "_asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "Unregisters a swap pool" + label: '_asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "unregisterPool", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: ['Unregisters a swap pool'], + label: 'unregisterPool', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0xada61cc3" + selector: '0xada61cc3', }, { - "args": [], - "default": false, - "docs": [ - "Disable all swaps" - ], - "label": "pause", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0x8456cb59" + args: [], + default: false, + docs: ['Disable all swaps'], + label: 'pause', + mutates: true, + payable: false, + returnType: null, + selector: '0x8456cb59', }, { - "args": [], - "default": false, - "docs": [ - "Resume all swaps" - ], - "label": "unpause", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0x3f4ba83a" + args: [], + default: false, + docs: ['Resume all swaps'], + label: 'unpause', + mutates: true, + payable: false, + returnType: null, + selector: '0x3f4ba83a', }, { - "args": [ + args: [ { - "label": "_amountIn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } + label: '_amountIn', + type: { + displayName: ['uint256'], + type: 3, + }, }, { - "label": "_amountOutMin", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } + label: '_amountOutMin', + type: { + displayName: ['uint256'], + type: 3, + }, }, { - "label": "_tokenInOut", - "type": { - "displayName": [], - "type": 6 - } + label: '_tokenInOut', + type: { + displayName: [], + type: 6, + }, }, { - "label": "_to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } + label: '_to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, }, { - "label": "_deadline", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + label: '_deadline', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "default": false, - "docs": [ - "Swap some `_fromToken` tokens for `_toToken` tokens,\nensures `_amountOutMin` and `_deadline`, sends funds to `_to` address `msg.sender` needs to grant the chef contract a sufficient allowance beforehand" + default: false, + docs: [ + 'Swap some `_fromToken` tokens for `_toToken` tokens,\nensures `_amountOutMin` and `_deadline`, sends funds to `_to` address `msg.sender` needs to grant the chef contract a sufficient allowance beforehand', ], - "label": "swapExactTokensForTokens", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [], - "type": 5 + label: 'swapExactTokensForTokens', + mutates: true, + payable: false, + returnType: { + displayName: [], + type: 5, }, - "selector": "0x38ed1739" + selector: '0x38ed1739', }, { - "args": [ + args: [ { - "label": "_amountIn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } + label: '_amountIn', + type: { + displayName: ['uint256'], + type: 3, + }, }, { - "label": "_tokenInOut", - "type": { - "displayName": [], - "type": 6 - } - } + label: '_tokenInOut', + type: { + displayName: [], + type: 6, + }, + }, ], - "default": false, - "docs": [ - "Get a quote for how many `_toToken` tokens `_amountIn` many `tokenIn`\ntokens can currently be swapped for." + default: false, + docs: [ + 'Get a quote for how many `_toToken` tokens `_amountIn` many `tokenIn`\ntokens can currently be swapped for.', ], - "label": "getAmountOut", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + label: 'getAmountOut', + mutates: false, + payable: false, + returnType: { + displayName: ['Router', 'getAmountOut', 'return_type'], + type: 7, }, - "selector": "0xb8239ebb" - } - ] + selector: '0xb8239ebb', + }, + ], }, - "storage": { - "struct": { - "fields": [ + storage: { + struct: { + fields: [ { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000000", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000000', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "root_key": "0x00000000" - } + root_key: '0x00000000', + }, }, - "name": "_owner" + name: '_owner', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000001", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000001', + ty: 3, + }, }, - "root_key": "0x00000001" - } + root_key: '0x00000001', + }, }, - "name": "_status" + name: '_status', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000002", - "ty": 4 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000002', + ty: 4, + }, }, - "root_key": "0x00000002" - } + root_key: '0x00000002', + }, }, - "name": "_paused" + name: '_paused', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000003", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000003', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "root_key": "0x00000003" - } + root_key: '0x00000003', + }, }, - "name": "poolByAsset" + name: 'poolByAsset', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000004", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000004', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "root_key": "0x00000004" - } + root_key: '0x00000004', + }, }, - "name": "oracleByAsset" - } + name: 'oracleByAsset', + }, ], - "name": "Router" - } + name: 'Router', + }, }, - "types": [ + types: [ { - "id": 0, - "type": { - "def": { - "primitive": "u8" + id: 0, + type: { + def: { + primitive: 'u8', }, - "path": [ - "uint8" - ] - } + path: ['uint8'], + }, }, { - "id": 1, - "type": { - "def": { - "array": { - "len": 32, - "type": 0 - } - } - } + id: 1, + type: { + def: { + array: { + len: 32, + type: 0, + }, + }, + }, }, { - "id": 2, - "type": { - "def": { - "composite": { - "fields": [ + id: 2, + type: { + def: { + composite: { + fields: [ { - "type": 1 - } - ] - } + type: 1, + }, + ], + }, }, - "path": [ - "ink_primitives", - "types", - "AccountId" - ] - } + path: ['ink_primitives', 'types', 'AccountId'], + }, }, { - "id": 3, - "type": { - "def": { - "primitive": "u256" + id: 3, + type: { + def: { + primitive: 'u256', }, - "path": [ - "uint256" - ] - } + path: ['uint256'], + }, }, { - "id": 4, - "type": { - "def": { - "primitive": "bool" + id: 4, + type: { + def: { + primitive: 'bool', }, - "path": [ - "bool" - ] - } + path: ['bool'], + }, }, { - "id": 5, - "type": { - "def": { - "sequence": { - "type": 3 - } - } - } + id: 5, + type: { + def: { + sequence: { + type: 3, + }, + }, + }, }, { - "id": 6, - "type": { - "def": { - "sequence": { - "type": 2 - } - } - } + id: 6, + type: { + def: { + sequence: { + type: 2, + }, + }, + }, }, { - "id": 7, - "type": { - "def": { - "primitive": "u128" + id: 7, + type: { + def: { + tuple: [3, 3], }, - "path": [ - "uint128" - ] - } + path: ['Router', 'getAmountOut', 'return_type'], + }, + }, + { + id: 8, + type: { + def: { + primitive: 'u128', + }, + path: ['uint128'], + }, }, { - "id": 8, - "type": { - "def": { - "primitive": "u64" + id: 9, + type: { + def: { + primitive: 'u64', }, - "path": [ - "uint64" - ] - } + path: ['uint64'], + }, }, { - "id": 9, - "type": { - "def": { - "composite": { - "fields": [ + id: 10, + type: { + def: { + composite: { + fields: [ { - "type": 1 - } - ] - } + type: 1, + }, + ], + }, }, - "path": [ - "ink_primitives", - "types", - "Hash" - ] - } + path: ['ink_primitives', 'types', 'Hash'], + }, }, { - "id": 10, - "type": { - "def": { - "primitive": "str" + id: 11, + type: { + def: { + primitive: 'str', }, - "path": [ - "string" - ] - } + path: ['string'], + }, }, { - "id": 11, - "type": { - "def": { - "composite": { - "fields": [ + id: 12, + type: { + def: { + composite: { + fields: [ { - "type": 10 - } - ] - } + type: 11, + }, + ], + }, }, - "path": [ - "0x08c379a0" - ] - } + path: ['0x08c379a0'], + }, }, { - "id": 12, - "type": { - "def": { - "composite": { - "fields": [ + id: 13, + type: { + def: { + composite: { + fields: [ { - "type": 3 - } - ] - } + type: 3, + }, + ], + }, }, - "path": [ - "0x4e487b71" - ] - } + path: ['0x4e487b71'], + }, }, { - "id": 13, - "type": { - "def": { - "variant": { - "variants": [ + id: 14, + type: { + def: { + variant: { + variants: [ { - "fields": [ + fields: [ { - "type": 11 - } + type: 12, + }, ], - "index": 0, - "name": "Error" + index: 0, + name: 'Error', }, { - "fields": [ + fields: [ { - "type": 12 - } + type: 13, + }, ], - "index": 1, - "name": "Panic" - } - ] - } + index: 1, + name: 'Panic', + }, + ], + }, }, - "path": [ - "SolidityError" - ] - } - } + path: ['SolidityError'], + }, + }, ], - "version": "4" -} as const; + version: '4', +}; diff --git a/src/contracts/nabla/SwapPool.ts b/src/contracts/nabla/SwapPool.ts index 67dc8474..81c07a06 100644 --- a/src/contracts/nabla/SwapPool.ts +++ b/src/contracts/nabla/SwapPool.ts @@ -1,2295 +1,1941 @@ export const swapPoolAbi = { - "contract": { - "authors": [ - "unknown" - ], - "description": "Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool.", - "name": "SwapPool", - "version": "0.0.1" + contract: { + authors: ['unknown'], + description: + 'Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool.', + name: 'SwapPool', + version: '0.0.1', }, - "source": { - "compiler": "solang 0.3.2", - "hash": "0xc473b9f6f31f711534a19a44c15935f3e1ffe0f031cf98b3f5701111dc793f49", - "language": "Solidity 0.3.2" + source: { + compiler: 'solang 0.3.2', + hash: '0x42108ada7515f8f4ab3ed8cea31e4c3456c433ce52fecb9d3a2afb33c727ab94', + language: 'Solidity 0.3.2', }, - "spec": { - "constructors": [ + spec: { + constructors: [ { - "args": [ - { - "label": "_asset", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_slippageCurve", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_router", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_backstop", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_protocolTreasury", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_name", - "type": { - "displayName": [ - "string" - ], - "type": 5 - } - }, - { - "label": "_symbol", - "type": { - "displayName": [ - "string" - ], - "type": 5 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: '_asset', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_slippageCurve', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_router', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_backstop', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_protocolTreasury', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_name', + type: { + displayName: ['string'], + type: 5, + }, + }, + { + label: '_symbol', + type: { + displayName: ['string'], + type: 5, + }, + }, ], - "label": "new", - "payable": false, - "returnType": null, - "selector": "0x15c2c342" - } + default: false, + docs: [''], + label: 'new', + payable: false, + returnType: null, + selector: '0x15c2c342', + }, ], - "docs": [ - "Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool." + docs: [ + 'Swap pool contract. May or may not be covered by a backstop pool. Conceptionally, there are two ways to temporarily disable a pool: The owner can either pause the pool, disabling deposits, swaps & backstop, or the owner can set the pool cap to zero which only prevents deposits. The former is for security incidents, the latter for phasing out a pool.', ], - "environment": { - "accountId": { - "displayName": [ - "AccountId" - ], - "type": 2 + environment: { + accountId: { + displayName: ['AccountId'], + type: 2, }, - "balance": { - "displayName": [ - "Balance" - ], - "type": 13 + balance: { + displayName: ['Balance'], + type: 14, }, - "blockNumber": { - "displayName": [ - "BlockNumber" - ], - "type": 14 + blockNumber: { + displayName: ['BlockNumber'], + type: 15, }, - "chainExtension": { - "displayName": [], - "type": 0 + chainExtension: { + displayName: [], + type: 0, }, - "hash": { - "displayName": [ - "Hash" - ], - "type": 15 + hash: { + displayName: ['Hash'], + type: 16, + }, + maxEventTopics: 4, + timestamp: { + displayName: ['Timestamp'], + type: 15, }, - "maxEventTopics": 4, - "timestamp": { - "displayName": [ - "Timestamp" - ], - "type": 14 - } }, - "events": [ + events: [ { - "args": [ - { - "docs": [], - "indexed": true, - "label": "from", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": true, - "label": "to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "value", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: true, + label: 'from', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: true, + label: 'to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'value', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "Transfer" + docs: [''], + label: 'Transfer', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": true, - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "value", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: true, + label: 'owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: true, + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'value', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "Approval" + docs: [''], + label: 'Approval', }, { - "args": [ - { - "docs": [], - "indexed": false, - "label": "account", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: false, + label: 'account', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "Paused" + docs: [''], + label: 'Paused', }, { - "args": [ - { - "docs": [], - "indexed": false, - "label": "account", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: false, + label: 'account', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "Unpaused" + docs: [''], + label: 'Unpaused', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "previousOwner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": true, - "label": "newOwner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "docs": [ - "" + args: [ + { + docs: [], + indexed: true, + label: 'previousOwner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: true, + label: 'newOwner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "OwnershipTransferred" + docs: [''], + label: 'OwnershipTransferred', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "sender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "poolSharesMinted", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountPrincipleDeposited", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'newProtocolTreasury', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "docs": [ - "emitted on every deposit" + docs: ['emitted when the protocol treasury address is changed'], + label: 'ProtocolTreasuryChanged', + }, + { + args: [ + { + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'poolSharesMinted', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + docs: [], + indexed: false, + label: 'amountPrincipleDeposited', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "Mint" + docs: ['emitted on every deposit'], + label: 'Mint', }, { - "args": [ - { - "docs": [], - "indexed": true, - "label": "sender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "poolSharesBurned", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountPrincipleWithdrawn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + docs: [], + indexed: true, + label: 'sender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'poolSharesBurned', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + docs: [], + indexed: false, + label: 'amountPrincipleWithdrawn', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "docs": [ - "emitted on every withdrawal special case withdrawal using backstop liquidiity: amountPrincipleWithdrawn = 0" + docs: [ + 'emitted on every withdrawal special case withdrawal using backstop liquidiity: amountPrincipleWithdrawn = 0', ], - "label": "Burn" + label: 'Burn', }, { - "args": [ - { - "docs": [], - "indexed": false, - "label": "recipient", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "docs": [], - "indexed": false, - "label": "amountSwapTokens", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + docs: [], + indexed: false, + label: 'recipient', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + docs: [], + indexed: false, + label: 'amountSwapTokens', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "docs": [ - "emitted when a backstop pool LP withdraws liquidity from swap pool only possible if swap pool coverage ratio remains >= 100%" + docs: [ + 'emitted when a backstop pool LP withdraws liquidity from swap pool only possible if swap pool coverage ratio remains >= 100%', ], - "label": "BackstopDrain" + label: 'BackstopDrain', }, { - "args": [ - { - "docs": [], - "indexed": false, - "label": "lpFees", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "docs": [], - "indexed": false, - "label": "backstopFees", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "docs": [], - "indexed": false, - "label": "protocolFees", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "docs": [ - "Tracks the exact amounts of individual fees paid during a swap" + args: [ + { + docs: [], + indexed: false, + label: 'lpFees', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + docs: [], + indexed: false, + label: 'backstopFees', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + docs: [], + indexed: false, + label: 'protocolFees', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "ChargedSwapFees" - } + docs: ['Tracks the exact amounts of individual fees paid during a swap'], + label: 'ChargedSwapFees', + }, ], - "lang_error": { - "displayName": [ - "SolidityError" - ], - "type": 18 + lang_error: { + displayName: ['SolidityError'], + type: 19, }, - "messages": [ + messages: [ { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "name", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "string" - ], - "type": 5 - }, - "selector": "0x06fdde03" + args: [], + default: false, + docs: [''], + label: 'name', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 5, + }, + selector: '0x06fdde03', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "symbol", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "string" - ], - "type": 5 - }, - "selector": "0x95d89b41" + args: [], + default: false, + docs: [''], + label: 'symbol', + mutates: false, + payable: false, + returnType: { + displayName: ['string'], + type: 5, + }, + selector: '0x95d89b41', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "totalSupply", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 - }, - "selector": "0x18160ddd" + args: [], + default: false, + docs: [''], + label: 'totalSupply', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x18160ddd', }, { - "args": [ - { - "label": "account", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'account', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "balanceOf", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: [''], + label: 'balanceOf', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x70a08231" + selector: '0x70a08231', }, { - "args": [ - { - "label": "to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "transfer", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'transfer', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0xa9059cbb" + selector: '0xa9059cbb', }, { - "args": [ - { - "label": "owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "allowance", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: [''], + label: 'allowance', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0xdd62ed3e" + selector: '0xdd62ed3e', }, { - "args": [ - { - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "approve", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'approve', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0x095ea7b3" + selector: '0x095ea7b3', }, { - "args": [ - { - "label": "from", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "to", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'from', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'to', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "transferFrom", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'transferFrom', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0x23b872dd" + selector: '0x23b872dd', }, { - "args": [ - { - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "addedValue", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'addedValue', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "increaseAllowance", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'increaseAllowance', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0x39509351" + selector: '0x39509351', }, { - "args": [ - { - "label": "spender", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "subtractedValue", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'spender', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: 'subtractedValue', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "decreaseAllowance", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 + default: false, + docs: [''], + label: 'decreaseAllowance', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, }, - "selector": "0xa457c2d7" + selector: '0xa457c2d7', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "paused", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "bool" - ], - "type": 4 - }, - "selector": "0x5c975abb" + args: [], + default: false, + docs: [''], + label: 'paused', + mutates: false, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, + }, + selector: '0x5c975abb', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "owner", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - }, - "selector": "0x8da5cb5b" + args: [], + default: false, + docs: [''], + label: 'owner', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + selector: '0x8da5cb5b', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "renounceOwnership", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0x715018a6" + args: [], + default: false, + docs: [''], + label: 'renounceOwnership', + mutates: true, + payable: false, + returnType: null, + selector: '0x715018a6', }, { - "args": [ - { - "label": "newOwner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "" + args: [ + { + label: 'newOwner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "transferOwnership", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0xf2fde38b" + default: false, + docs: [''], + label: 'transferOwnership', + mutates: true, + payable: false, + returnType: null, + selector: '0xf2fde38b', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "poolCap", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 - }, - "selector": "0xb954dc57" + args: [], + default: false, + docs: [''], + label: 'poolCap', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0xb954dc57', }, { - "args": [], - "default": false, - "docs": [ - "Returns the pooled token's address" - ], - "label": "asset", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - }, - "selector": "0x38d52e0f" + args: [], + default: false, + docs: ["Returns the pooled token's address"], + label: 'asset', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + selector: '0x38d52e0f', }, { - "args": [], - "default": false, - "docs": [ - "Returns the decimals of the pool asset" - ], - "label": "assetDecimals", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint8" - ], - "type": 0 - }, - "selector": "0xc2d41601" + args: [], + default: false, + docs: ['Returns the decimals of the pool asset'], + label: 'assetDecimals', + mutates: false, + payable: false, + returnType: { + displayName: ['uint8'], + type: 0, + }, + selector: '0xc2d41601', }, { - "args": [], - "default": false, - "docs": [ - "Returns the decimals of the LP token of this pool\nThis is defined to have the same decimals as the pool token itself\nin order to greatly simplify calculations that involve pool token amounts\nand LP token amounts" - ], - "label": "decimals", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint8" - ], - "type": 0 - }, - "selector": "0x313ce567" + args: [], + default: false, + docs: [ + 'Returns the decimals of the LP token of this pool\nThis is defined to have the same decimals as the pool token itself\nin order to greatly simplify calculations that involve pool token amounts\nand LP token amounts', + ], + label: 'decimals', + mutates: false, + payable: false, + returnType: { + displayName: ['uint8'], + type: 0, + }, + selector: '0x313ce567', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "totalLiabilities", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 - }, - "selector": "0xf73579a9" + args: [], + default: false, + docs: [''], + label: 'totalLiabilities', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0xf73579a9', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "reserve", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 - }, - "selector": "0xcd3293de" + args: [], + default: false, + docs: [''], + label: 'reserve', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0xcd3293de', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "reserveWithSlippage", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 - }, - "selector": "0x0b09d91e" + args: [], + default: false, + docs: [''], + label: 'reserveWithSlippage', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x0b09d91e', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "insuranceWithdrawalTimelock", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 - }, - "selector": "0x0d3a7fd4" + args: [], + default: false, + docs: [''], + label: 'insuranceWithdrawalTimelock', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x0d3a7fd4', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "protocolTreasury", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - }, - "selector": "0x803db96d" + args: [], + default: false, + docs: [''], + label: 'maxCoverageRatioForSwapIn', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0xb2f3447a', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "backstop", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - }, - "selector": "0x7dea1817" + args: [], + default: false, + docs: [''], + label: 'protocolTreasury', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + selector: '0x803db96d', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "router", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - }, - "selector": "0xf887ea40" + args: [], + default: false, + docs: [''], + label: 'backstop', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + selector: '0x7dea1817', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "slippageCurve", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - }, - "selector": "0xebe26b9e" + args: [], + default: false, + docs: [''], + label: 'router', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + selector: '0xf887ea40', }, { - "args": [], - "default": false, - "docs": [ - "" - ], - "label": "maxCoverageRatioForSwapIn", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 - }, - "selector": "0xb2f3447a" + args: [], + default: false, + docs: [''], + label: 'slippageCurve', + mutates: false, + payable: false, + returnType: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + selector: '0xebe26b9e', }, { - "args": [ - { - "label": "_durationInBlocks", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Set new insurance withdrawal time lock. Can only be called by the owner" + args: [ + { + label: '_durationInBlocks', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "setInsuranceWithdrawalTimelock", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0xcfcc238d" + default: false, + docs: ['Set new insurance withdrawal time lock. Can only be called by the owner'], + label: 'setInsuranceWithdrawalTimelock', + mutates: true, + payable: false, + returnType: null, + selector: '0xcfcc238d', }, { - "args": [ - { - "label": "_maxTokens", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + label: '_maxTokens', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "default": false, - "docs": [ - "Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits." + default: false, + docs: [ + 'Set new upper limit of pool reserves. Will disable deposits when reached. Can always set to an amount < current reserves to temporarily restrict deposits.', ], - "label": "setPoolCap", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0xd835f535" + label: 'setPoolCap', + mutates: true, + payable: false, + returnType: null, + selector: '0xd835f535', }, { - "args": [ - { - "label": "_maxCoverageRatio", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Set new upper limit of pool coverage ratio (reserves / liabilities) for swap-in" + args: [ + { + label: '_maxCoverageRatio', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "setMaxCoverageRatioForSwapIn", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0x0668d07c" + default: false, + docs: ['Set new upper limit of pool coverage ratio (reserves / liabilities) for swap-in'], + label: 'setMaxCoverageRatioForSwapIn', + mutates: true, + payable: false, + returnType: null, + selector: '0x0668d07c', }, { - "args": [ - { - "label": "_lpFee", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "label": "_backstopFee", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "label": "_protocolFee", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Set swap fees (applied when swapping funds out of the pool)" + args: [ + { + label: '_lpFee', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + label: '_backstopFee', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + label: '_protocolFee', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "setSwapFees", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0xeb43434e" + default: false, + docs: ['Set swap fees (applied when swapping funds out of the pool)'], + label: 'setSwapFees', + mutates: true, + payable: false, + returnType: null, + selector: '0xeb43434e', }, { - "args": [], - "default": false, - "docs": [ - "Return the configured swap fees for this pool" - ], - "label": "swapFees", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "SwapPool", - "swapFees", - "return_type" - ], - "type": 8 - }, - "selector": "0xb9ccf21d" + args: [], + default: false, + docs: ['Return the configured swap fees for this pool'], + label: 'swapFees', + mutates: false, + payable: false, + returnType: { + displayName: ['SwapPool', 'swapFees', 'return_type'], + type: 8, + }, + selector: '0xb9ccf21d', }, { - "args": [ - { - "label": "_depositAmount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0" + args: [ + { + label: '_newProtocolTreasury', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "label": "deposit", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "SwapPool", - "deposit", - "return_type" - ], - "type": 10 - }, - "selector": "0xb6b55f25" + default: false, + docs: ['Set new treasury address'], + label: 'setProtocolTreasury', + mutates: true, + payable: false, + returnType: { + displayName: ['bool'], + type: 4, + }, + selector: '0x0c5a61f8', }, { - "args": [ - { - "label": "_sharesToBurn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "label": "_minimumAmount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Withdraws liquidity amount of asset ensuring minimum amount required" + args: [ + { + label: '_depositAmount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "withdraw", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "SwapPool", - "withdraw", - "return_type" - ], - "type": 11 - }, - "selector": "0x441a3e70" + default: false, + docs: ['Deposits amount of tokens into pool Will change cov ratio of pool, will increase delta to 0'], + label: 'deposit', + mutates: true, + payable: false, + returnType: { + displayName: ['SwapPool', 'deposit', 'return_type'], + type: 10, + }, + selector: '0xb6b55f25', }, { - "args": [ - { - "label": "_owner", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - }, - { - "label": "_sharesToBurn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Burns LP tokens of owner, will get compensated using backstop liquidity Can only be invoked by backstop pool, disabled when pool is paused" + args: [ + { + label: '_depositAmount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "backstopBurn", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: ['Get a quote for the effective amount of tokens for a deposit'], + label: 'quoteDeposit', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0xe45f37bd" + selector: '0xdb431f06', }, { - "args": [ - { - "label": "_amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - }, - { - "label": "_recipient", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "For backstop pool to withdraw liquidity if swap pool's coverage ratio > 100% Can only be invoked by backstop pool" + args: [ + { + label: '_sharesToBurn', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + label: '_minimumAmount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "backstopDrain", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: ['Withdraws liquidity amount of asset ensuring minimum amount required'], + label: 'withdraw', + mutates: true, + payable: false, + returnType: { + displayName: ['SwapPool', 'withdraw', 'return_type'], + type: 11, }, - "selector": "0xc2cb15de" + selector: '0x441a3e70', }, { - "args": [ - { - "label": "_amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Get called by Router to deposit an amount of pool asset Can only be called by Router" + args: [ + { + label: '_sharesToBurn', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "swapIntoFromRouter", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: ['Get a quote for the effective amount of tokens for a withdrawal'], + label: 'quoteWithdraw', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x4d8ea83f" + selector: '0xec211840', }, { - "args": [ - { - "label": "_amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + label: '_owner', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, + { + label: '_sharesToBurn', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "default": false, - "docs": [ - "Get a quote for the effective amount of tokens for a swap into" + default: false, + docs: [ + 'Burns LP tokens of owner, will get compensated using backstop liquidity Can only be invoked by backstop pool, disabled when pool is paused', ], - "label": "quoteSwapInto", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + label: 'backstopBurn', + mutates: true, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x3c945248" + selector: '0xe45f37bd', }, { - "args": [ - { - "label": "_amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } + args: [ + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, + { + label: '_recipient', + type: { + displayName: ['ink_primitives', 'types', 'AccountId'], + type: 2, + }, + }, ], - "default": false, - "docs": [ - "get called by Router to withdraw amount of pool asset Can only be called by Router" + default: false, + docs: [ + "For backstop pool to withdraw liquidity if swap pool's coverage ratio > 100% Can only be invoked by backstop pool", ], - "label": "swapOutFromRouter", - "mutates": true, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + label: 'backstopDrain', + mutates: true, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x5f79d44f" + selector: '0xc2cb15de', }, { - "args": [ - { - "label": "_amount", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Get a quote for the effective amount of tokens, incl. slippage and fees" + args: [ + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "quoteSwapOut", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 + default: false, + docs: ['Get a quote for the effective amount of tokens for a backstop drain'], + label: 'quoteBackstopDrain', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, }, - "selector": "0x8735c246" + selector: '0xe237fb3d', }, { - "args": [], - "default": false, - "docs": [ - "Pause deposits and swaps" + args: [ + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "pause", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0x8456cb59" + default: false, + docs: ['Get called by Router to deposit an amount of pool asset Can only be called by Router'], + label: 'swapIntoFromRouter', + mutates: true, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x4d8ea83f', }, { - "args": [], - "default": false, - "docs": [ - "Resume deposits and swaps" + args: [ + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "unpause", - "mutates": true, - "payable": false, - "returnType": null, - "selector": "0x3f4ba83a" + default: false, + docs: ['Get a quote for the effective amount of tokens for a swap into'], + label: 'quoteSwapInto', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x3c945248', }, { - "args": [], - "default": false, - "docs": [ - "returns pool coverage ratio" + args: [ + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "coverage", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "SwapPool", - "coverage", - "return_type" - ], - "type": 12 - }, - "selector": "0xee8f6a0e" + default: false, + docs: ['get called by Router to withdraw amount of pool asset Can only be called by Router'], + label: 'swapOutFromRouter', + mutates: true, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0x5f79d44f', }, { - "args": [], - "default": false, - "docs": [ - "Computes the excess liquidity that forms that valuation of the backstop pool is defined as b + C - B - L where - b is reserve - C is the amount of `asset()` tokens in the pool - B is reserveWithSlippage - L is totalLiabilities The excess liquidity is a fixed point number using the decimals of this pool" + args: [ + { + label: '_amount', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "getExcessLiquidity", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "int256" - ], - "type": 9 + default: false, + docs: ['Get a quote for the effective amount of tokens, incl. slippage and fees'], + label: 'quoteSwapOut', + mutates: false, + payable: false, + returnType: { + displayName: ['SwapPool', 'quoteSwapOut', 'return_type'], + type: 12, }, - "selector": "0xace0f0d5" + selector: '0x8735c246', }, { - "args": [ - { - "label": "_liquidityProvider", - "type": { - "displayName": [ - "ink_primitives", - "types", - "AccountId" - ], - "type": 2 - } - } - ], - "default": false, - "docs": [ - "Return the earliest block no that insurance withdrawals are possible." - ], - "label": "insuranceWithdrawalUnlock", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 - }, - "selector": "0x5c6f4279" + args: [], + default: false, + docs: ['Pause deposits and swaps'], + label: 'pause', + mutates: true, + payable: false, + returnType: null, + selector: '0x8456cb59', }, { - "args": [ - { - "label": "_sharesToBurn", - "type": { - "displayName": [ - "uint256" - ], - "type": 3 - } - } - ], - "default": false, - "docs": [ - "Returns the worth of an amount of pool shares (LP tokens) in underlying principle" + args: [], + default: false, + docs: ['Resume deposits and swaps'], + label: 'unpause', + mutates: true, + payable: false, + returnType: null, + selector: '0x3f4ba83a', + }, + { + args: [], + default: false, + docs: ['returns pool coverage ratio'], + label: 'coverage', + mutates: false, + payable: false, + returnType: { + displayName: ['SwapPool', 'coverage', 'return_type'], + type: 13, + }, + selector: '0xee8f6a0e', + }, + { + args: [], + default: false, + docs: [ + 'Computes the excess liquidity that forms that valuation of the backstop pool is defined as b + C - B - L where - b is reserve - C is the amount of `asset()` tokens in the pool - B is reserveWithSlippage - L is totalLiabilities The excess liquidity is a fixed point number using the decimals of this pool', + ], + label: 'getExcessLiquidity', + mutates: false, + payable: false, + returnType: { + displayName: ['int256'], + type: 9, + }, + selector: '0xace0f0d5', + }, + { + args: [ + { + label: '_sharesToBurn', + type: { + displayName: ['uint256'], + type: 3, + }, + }, ], - "label": "sharesTargetWorth", - "mutates": false, - "payable": false, - "returnType": { - "displayName": [ - "uint256" - ], - "type": 3 - }, - "selector": "0xcc045745" - } - ] + default: false, + docs: ['Returns the worth of an amount of pool shares (LP tokens) in underlying principle'], + label: 'sharesTargetWorth', + mutates: false, + payable: false, + returnType: { + displayName: ['uint256'], + type: 3, + }, + selector: '0xcc045745', + }, + ], }, - "storage": { - "struct": { - "fields": [ + storage: { + struct: { + fields: [ { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000000", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000000', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "root_key": "0x00000000" - } + root_key: '0x00000000', + }, }, - "name": "_owner" + name: '_owner', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000001", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000001', + ty: 3, + }, }, - "root_key": "0x00000001" - } + root_key: '0x00000001', + }, }, - "name": "_status" + name: '_status', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000002", - "ty": 4 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000002', + ty: 4, + }, }, - "root_key": "0x00000002" - } + root_key: '0x00000002', + }, }, - "name": "_paused" + name: '_paused', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000003", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000003', + ty: 3, + }, }, - "root_key": "0x00000003" - } + root_key: '0x00000003', + }, }, - "name": "_balances" + name: '_balances', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000004", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000004', + ty: 3, + }, }, - "root_key": "0x00000004" - } + root_key: '0x00000004', + }, }, - "name": "_allowances" + name: '_allowances', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000005", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000005', + ty: 3, + }, }, - "root_key": "0x00000005" - } + root_key: '0x00000005', + }, }, - "name": "_totalSupply" + name: '_totalSupply', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000006", - "ty": 5 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000006', + ty: 5, + }, }, - "root_key": "0x00000006" - } + root_key: '0x00000006', + }, }, - "name": "_name" + name: '_name', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000007", - "ty": 5 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000007', + ty: 5, + }, }, - "root_key": "0x00000007" - } + root_key: '0x00000007', + }, }, - "name": "_symbol" + name: '_symbol', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000008", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000008', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "root_key": "0x00000008" - } + root_key: '0x00000008', + }, }, - "name": "poolAsset" + name: 'poolAsset', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000009", - "ty": 0 - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000009', + ty: 0, + }, }, - "root_key": "0x00000009" - } + root_key: '0x00000009', + }, }, - "name": "poolAssetDecimals" + name: 'poolAssetDecimals', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x0000000a", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000a', + ty: 3, + }, }, - "root_key": "0x0000000a" - } + root_key: '0x0000000a', + }, }, - "name": "poolCap" + name: 'poolCap', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x0000000b", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000b', + ty: 3, + }, }, - "root_key": "0x0000000b" - } + root_key: '0x0000000b', + }, }, - "name": "totalLiabilities" + name: 'totalLiabilities', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x0000000c", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000c', + ty: 3, + }, }, - "root_key": "0x0000000c" - } + root_key: '0x0000000c', + }, }, - "name": "reserve" + name: 'reserve', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x0000000d", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000d', + ty: 3, + }, }, - "root_key": "0x0000000d" - } + root_key: '0x0000000d', + }, }, - "name": "reserveWithSlippage" + name: 'reserveWithSlippage', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x0000000e", - "ty": 3 - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000e', + ty: 3, + }, }, - "root_key": "0x0000000e" - } + root_key: '0x0000000e', + }, }, - "name": "insuranceWithdrawalTimelock" + name: 'insuranceWithdrawalTimelock', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ - { - "layout": { - "leaf": { - "key": "0x0000000f", - "ty": 1 - } - }, - "name": "" - } - ], - "name": "AccountId" - } + layout: { + root: { + layout: { + leaf: { + key: '0x0000000f', + ty: 3, + }, }, - "root_key": "0x0000000f" - } + root_key: '0x0000000f', + }, }, - "name": "protocolTreasury" + name: 'maxCoverageRatioForSwapIn', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000010", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000010', + ty: 1, + }, }, - "name": "" - } + name: '', + }, ], - "name": "AccountId" - } + name: 'AccountId', + }, }, - "root_key": "0x00000010" - } + root_key: '0x00000010', + }, }, - "name": "backstop" + name: 'protocolTreasury', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ - { - "layout": { - "leaf": { - "key": "0x00000011", - "ty": 1 - } - }, - "name": "" - } - ], - "name": "AccountId" - } + layout: { + root: { + layout: { + leaf: { + key: '0x00000011', + ty: 3, + }, }, - "root_key": "0x00000011" - } + root_key: '0x00000011', + }, }, - "name": "router" + name: 'latestDepositAtBlockNo', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000012", - "ty": 1 - } + layout: { + leaf: { + key: '0x00000012', + ty: 6, + }, }, - "name": "" - } + name: 'lpFee', + }, + { + layout: { + leaf: { + key: '0x00000012', + ty: 6, + }, + }, + name: 'backstopFee', + }, + { + layout: { + leaf: { + key: '0x00000012', + ty: 6, + }, + }, + name: 'protocolFee', + }, ], - "name": "AccountId" - } + name: 'SwapFees', + }, }, - "root_key": "0x00000012" - } + root_key: '0x00000012', + }, }, - "name": "slippageCurve" + name: 'swapFeeConfig', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000013", - "ty": 3 - } + layout: { + root: { + layout: { + struct: { + fields: [ + { + layout: { + leaf: { + key: '0x00000015', + ty: 1, + }, + }, + name: '', + }, + ], + name: 'AccountId', + }, }, - "root_key": "0x00000013" - } + root_key: '0x00000015', + }, }, - "name": "latestDepositAtBlockNo" + name: 'backstop', }, { - "layout": { - "root": { - "layout": { - "struct": { - "fields": [ + layout: { + root: { + layout: { + struct: { + fields: [ { - "layout": { - "leaf": { - "key": "0x00000014", - "ty": 6 - } + layout: { + leaf: { + key: '0x00000016', + ty: 1, + }, }, - "name": "lpFee" + name: '', }, - { - "layout": { - "leaf": { - "key": "0x00000014", - "ty": 6 - } - }, - "name": "backstopFee" - }, - { - "layout": { - "leaf": { - "key": "0x00000014", - "ty": 6 - } - }, - "name": "protocolFee" - } ], - "name": "SwapFees" - } + name: 'AccountId', + }, }, - "root_key": "0x00000014" - } + root_key: '0x00000016', + }, }, - "name": "swapFeeConfig" + name: 'router', }, { - "layout": { - "root": { - "layout": { - "leaf": { - "key": "0x00000017", - "ty": 3 - } + layout: { + root: { + layout: { + struct: { + fields: [ + { + layout: { + leaf: { + key: '0x00000017', + ty: 1, + }, + }, + name: '', + }, + ], + name: 'AccountId', + }, }, - "root_key": "0x00000017" - } + root_key: '0x00000017', + }, }, - "name": "maxCoverageRatioForSwapIn" - } + name: 'slippageCurve', + }, ], - "name": "SwapPool" - } + name: 'SwapPool', + }, }, - "types": [ + types: [ { - "id": 0, - "type": { - "def": { - "primitive": "u8" - }, - "path": [ - "uint8" - ] - } + id: 0, + type: { + def: { + primitive: 'u8', + }, + path: ['uint8'], + }, }, { - "id": 1, - "type": { - "def": { - "array": { - "len": 32, - "type": 0 - } - } - } + id: 1, + type: { + def: { + array: { + len: 32, + type: 0, + }, + }, + }, }, { - "id": 2, - "type": { - "def": { - "composite": { - "fields": [ + id: 2, + type: { + def: { + composite: { + fields: [ { - "type": 1 - } - ] - } - }, - "path": [ - "ink_primitives", - "types", - "AccountId" - ] - } + type: 1, + }, + ], + }, + }, + path: ['ink_primitives', 'types', 'AccountId'], + }, }, { - "id": 3, - "type": { - "def": { - "primitive": "u256" - }, - "path": [ - "uint256" - ] - } + id: 3, + type: { + def: { + primitive: 'u256', + }, + path: ['uint256'], + }, }, { - "id": 4, - "type": { - "def": { - "primitive": "bool" - }, - "path": [ - "bool" - ] - } + id: 4, + type: { + def: { + primitive: 'bool', + }, + path: ['bool'], + }, }, { - "id": 5, - "type": { - "def": { - "primitive": "str" - }, - "path": [ - "string" - ] - } + id: 5, + type: { + def: { + primitive: 'str', + }, + path: ['string'], + }, }, { - "id": 6, - "type": { - "def": { - "primitive": "u32" - }, - "path": [ - "uint32" - ] - } + id: 6, + type: { + def: { + primitive: 'u32', + }, + path: ['uint32'], + }, }, { - "id": 7, - "type": { - "def": { - "composite": { - "fields": [ + id: 7, + type: { + def: { + composite: { + fields: [ { - "name": "lpFee", - "type": 6 + name: 'lpFee', + type: 6, }, { - "name": "backstopFee", - "type": 6 + name: 'backstopFee', + type: 6, }, { - "name": "protocolFee", - "type": 6 - } - ] - } - }, - "path": [ - "SwapFees" - ] - } + name: 'protocolFee', + type: 6, + }, + ], + }, + }, + path: ['SwapFees'], + }, }, { - "id": 8, - "type": { - "def": { - "tuple": [ - 3, - 3, - 3 - ] - }, - "path": [ - "SwapPool", - "swapFees", - "return_type" - ] - } + id: 8, + type: { + def: { + tuple: [3, 3, 3], + }, + path: ['SwapPool', 'swapFees', 'return_type'], + }, }, { - "id": 9, - "type": { - "def": { - "primitive": "i256" - }, - "path": [ - "int256" - ] - } + id: 9, + type: { + def: { + primitive: 'i256', + }, + path: ['int256'], + }, }, { - "id": 10, - "type": { - "def": { - "tuple": [ - 3, - 9 - ] - }, - "path": [ - "SwapPool", - "deposit", - "return_type" - ] - } + id: 10, + type: { + def: { + tuple: [3, 9], + }, + path: ['SwapPool', 'deposit', 'return_type'], + }, }, { - "id": 11, - "type": { - "def": { - "tuple": [ - 3, - 9 - ] - }, - "path": [ - "SwapPool", - "withdraw", - "return_type" - ] - } + id: 11, + type: { + def: { + tuple: [3, 9], + }, + path: ['SwapPool', 'withdraw', 'return_type'], + }, }, { - "id": 12, - "type": { - "def": { - "tuple": [ - 3, - 3 - ] - }, - "path": [ - "SwapPool", - "coverage", - "return_type" - ] - } + id: 12, + type: { + def: { + tuple: [3, 3, 3, 3], + }, + path: ['SwapPool', 'quoteSwapOut', 'return_type'], + }, }, { - "id": 13, - "type": { - "def": { - "primitive": "u128" - }, - "path": [ - "uint128" - ] - } + id: 13, + type: { + def: { + tuple: [3, 3], + }, + path: ['SwapPool', 'coverage', 'return_type'], + }, + }, + { + id: 14, + type: { + def: { + primitive: 'u128', + }, + path: ['uint128'], + }, }, { - "id": 14, - "type": { - "def": { - "primitive": "u64" - }, - "path": [ - "uint64" - ] - } + id: 15, + type: { + def: { + primitive: 'u64', + }, + path: ['uint64'], + }, }, { - "id": 15, - "type": { - "def": { - "composite": { - "fields": [ + id: 16, + type: { + def: { + composite: { + fields: [ { - "type": 1 - } - ] - } - }, - "path": [ - "ink_primitives", - "types", - "Hash" - ] - } + type: 1, + }, + ], + }, + }, + path: ['ink_primitives', 'types', 'Hash'], + }, }, { - "id": 16, - "type": { - "def": { - "composite": { - "fields": [ + id: 17, + type: { + def: { + composite: { + fields: [ { - "type": 5 - } - ] - } - }, - "path": [ - "0x08c379a0" - ] - } + type: 5, + }, + ], + }, + }, + path: ['0x08c379a0'], + }, }, { - "id": 17, - "type": { - "def": { - "composite": { - "fields": [ + id: 18, + type: { + def: { + composite: { + fields: [ { - "type": 3 - } - ] - } - }, - "path": [ - "0x4e487b71" - ] - } + type: 3, + }, + ], + }, + }, + path: ['0x4e487b71'], + }, }, { - "id": 18, - "type": { - "def": { - "variant": { - "variants": [ + id: 19, + type: { + def: { + variant: { + variants: [ { - "fields": [ + fields: [ { - "type": 16 - } + type: 17, + }, ], - "index": 0, - "name": "Error" + index: 0, + name: 'Error', }, { - "fields": [ + fields: [ { - "type": 17 - } + type: 18, + }, ], - "index": 1, - "name": "Panic" - } - ] - } - }, - "path": [ - "SolidityError" - ] - } - } + index: 1, + name: 'Panic', + }, + ], + }, + }, + path: ['SolidityError'], + }, + }, ], - "version": "4" -} as const; + version: '4', +}; From 3a9adcd099cc03bb015f42323c6fb559d96840a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 04:33:15 -0300 Subject: [PATCH 30/58] Fix Swap interface --- src/blurp.tsx | 4 +- .../WithdrawLiquidity/useSwapPoolWithdraw.ts | 6 +- src/components/nabla/Swap/ApprovalSubmit.tsx | 13 +++- src/components/nabla/Swap/To.tsx | 61 ++++++++----------- src/components/nabla/Swap/index.tsx | 5 +- .../nabla/common/NablaTokenPrice.tsx | 19 ++---- src/components/nabla/common/TokenApproval.tsx | 5 +- src/hooks/nabla/useContractBalance.ts | 15 ++--- src/hooks/nabla/useContractRead.ts | 18 +----- src/hooks/nabla/useContractWrite.ts | 2 - src/hooks/nabla/useErc20TokenAllowance.ts | 6 +- src/hooks/nabla/useErc20TokenApproval.ts | 2 +- src/hooks/nabla/useNablaTokenPrice.ts | 7 +-- src/hooks/nabla/useSharesTargetWorth.ts | 6 +- src/hooks/nabla/useTokenOutAmount.ts | 7 --- 15 files changed, 69 insertions(+), 107 deletions(-) diff --git a/src/blurp.tsx b/src/blurp.tsx index 8499466d..fca5ada6 100644 --- a/src/blurp.tsx +++ b/src/blurp.tsx @@ -1,7 +1,7 @@ // TODO Torsten const blurpConfig = { - read: false, + read: true, write: true, }; @@ -10,6 +10,6 @@ export type BlurpType = keyof typeof blurpConfig; /* eslint-disable @typescript-eslint/no-explicit-any */ export function blurp(type: BlurpType, ...args: any[]) { if (blurpConfig[type]) { - console.log(...args); + console.log(type, ...args); } } diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts index 2a9898f7..341cd025 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts @@ -61,11 +61,11 @@ export const useSwapPoolWithdraw = ({ abi: backstopPoolAbi, lpTokenDecimals: backstopPool.lpTokenDecimals, }, - { enabled }, + enabled, ); const sharesWorthNativeAmount = getMessageCallValue(sharesQuery.data); - const bpPriceQuery = useNablaTokenPrice(backstopPool.token.id, { enabled }); - const spPriceQuery = useNablaTokenPrice(selectedSwapPool?.token.id, { enabled }); + const bpPriceQuery = useNablaTokenPrice(backstopPool.token.id, enabled); + const spPriceQuery = useNablaTokenPrice(selectedSwapPool?.token.id, enabled); const bpPrice = getMessageCallValue(bpPriceQuery.data); const spPrice = getMessageCallValue(spPriceQuery.data); diff --git a/src/components/nabla/Swap/ApprovalSubmit.tsx b/src/components/nabla/Swap/ApprovalSubmit.tsx index 1f1e4f0c..1e1a84e6 100644 --- a/src/components/nabla/Swap/ApprovalSubmit.tsx +++ b/src/components/nabla/Swap/ApprovalSubmit.tsx @@ -7,9 +7,10 @@ import { TokenApproval } from '../common/TokenApproval'; export interface ApprovalProps { token: NablaInstanceToken | undefined; + disabled: boolean; } -const ApprovalSubmit = ({ token }: ApprovalProps): JSX.Element | null => { +const ApprovalSubmit = ({ token, disabled }: ApprovalProps): JSX.Element | null => { const { router } = useGetAppDataByTenant('nabla').data || {}; const { control } = useFormContext(); const decimalAmount = Number( @@ -23,8 +24,14 @@ const ApprovalSubmit = ({ token }: ApprovalProps): JSX.Element | null => { if (!router || !token) return null; return ( - - diff --git a/src/components/nabla/Swap/To.tsx b/src/components/nabla/Swap/To.tsx index 80be615d..4f96ec36 100644 --- a/src/components/nabla/Swap/To.tsx +++ b/src/components/nabla/Swap/To.tsx @@ -1,6 +1,5 @@ import { ArrowPathRoundedSquareIcon, ChevronDownIcon } from '@heroicons/react/20/solid'; -import { InformationCircleIcon } from '@heroicons/react/24/outline'; -import { useEffect } from 'preact/compat'; +import { useEffect, useMemo } from 'preact/compat'; import { Button } from 'react-daisyui'; import { useFormContext, useWatch } from 'react-hook-form'; import pendulumIcon from '../../../assets/pendulum-icon.svg'; @@ -9,7 +8,6 @@ import { subtractPercentage } from '../../../helpers/calc'; import { useTokenOutAmount } from '../../../hooks/nabla/useTokenOutAmount'; import useBoolean from '../../../hooks/useBoolean'; import { useDebouncedValue } from '../../../hooks/useDebouncedValue'; -import { getMessageCallValue } from '../../../shared/helpers'; import { rawToDecimal, prettyNumbers, roundNumber } from '../../../shared/parseNumbers'; import { numberLoader } from '../../Loader'; import { Skeleton } from '../../Skeleton'; @@ -64,17 +62,6 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps from, to, fromTokenDecimals: fromToken?.decimals, - onSuccess: (response) => { - if (toToken === undefined) return; - - const val = getMessageCallValue(response); - const toAmount = val ? rawToDecimal(val, toToken.decimals).toNumber() : 0; - setValue('toAmount', toAmount, { - shouldDirty: true, - shouldTouch: true, - shouldValidate: true, - }); - }, }); useEffect(() => { @@ -94,25 +81,32 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps : 'Something went wrong'; } - console.log('ToAmount Error', errorMessage); setError('fromAmount', { type: 'manual', message: errorMessage }); } else { clearErrors('fromAmount'); } }, [data, setError, clearErrors]); - const loading = - (isLoading && isLoading && fetchStatus !== 'idle') || fromDecimalAmount !== debouncedFromDecimalAmount; - const outValue = getMessageCallValue(data); - const value = - outValue && toToken !== undefined ? prettyNumbers(rawToDecimal(outValue, toToken.decimals).toNumber()) : 0; - - console.log( - 'roundNumber(Number(value) / fromDecimalAmount, 6)', - roundNumber(Number(value) / fromDecimalAmount, 6), - value, - fromDecimalAmount, - ); + const loading = (isLoading && fetchStatus !== 'idle') || fromDecimalAmount !== debouncedFromDecimalAmount; + + const [value, toAmount, swapFee] = useMemo(() => { + const outValue = data?.result.type === 'success' ? data.result.value : undefined; + + if (outValue === undefined) return ['0', undefined, undefined]; + + const toAmount = rawToDecimal(outValue[0], toToken.decimals).toNumber(); + + return [prettyNumbers(toAmount), toAmount, rawToDecimal(outValue[1], toToken.decimals).toNumber()]; + }, [data?.result, toToken]); + + useEffect(() => { + setValue('toAmount', toAmount ?? 0, { + shouldDirty: true, + shouldTouch: true, + shouldValidate: true, + }); + }, [toAmount, setValue]); + return (
- {fromToken && toToken && value && fromDecimalAmount ? ( - <> -
- -
- {`1 ${fromToken.symbol} = ${roundNumber(Number(value) / fromDecimalAmount, 6)} ${toToken.symbol}`} - + {fromToken && toToken && value && fromDecimalAmount && !loading ? ( + <>{`1 ${fromToken.symbol} = ${roundNumber(Number(value) / fromDecimalAmount, 6)} ${toToken.symbol}`} ) : ( `- ${toToken?.symbol || ''}` )} @@ -197,7 +186,9 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps
Swap fee:
-
-
+
+ {swapFee !== undefined ? prettyNumbers(swapFee) : ''} {toToken?.symbol || ''} +
diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index f7400324..31d4f357 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -89,7 +89,10 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { />
{/* */} - +
diff --git a/src/components/nabla/common/NablaTokenPrice.tsx b/src/components/nabla/common/NablaTokenPrice.tsx index f9104ddd..9853ac82 100644 --- a/src/components/nabla/common/NablaTokenPrice.tsx +++ b/src/components/nabla/common/NablaTokenPrice.tsx @@ -1,4 +1,3 @@ -import { UseQueryOptions } from '@tanstack/react-query'; import { getMessageCallValue } from '../../../shared/helpers'; import { rawToDecimal, prettyNumbers } from '../../../shared/parseNumbers'; import { numberLoader } from '../../Loader'; @@ -6,32 +5,22 @@ import { useNablaTokenPrice } from '../../../hooks/nabla/useNablaTokenPrice'; export type TokenPriceProps = { address: string; - amount?: number; prefix?: ReactNode; - options?: UseQueryOptions; - loader?: ReactNode; fallback?: ReactNode; }; const TOKEN_PRICE_DECIMALS = 12; -export function NablaTokenPrice({ - address, - prefix = null, - loader, - fallback = null, - amount = 1, - options, -}: TokenPriceProps): JSX.Element | null { - const { data, isLoading } = useNablaTokenPrice(address, options); - if (isLoading) return loader ? <>{loader} : numberLoader; +export function NablaTokenPrice({ address, prefix = null, fallback = null }: TokenPriceProps): JSX.Element | null { + const { data, isLoading } = useNablaTokenPrice(address); + if (isLoading) return numberLoader; const price = getMessageCallValue(data); if (price === undefined) return <>{fallback}; return ( - {prefix}${prettyNumbers(amount * rawToDecimal(price, TOKEN_PRICE_DECIMALS).toNumber())} + {prefix}${prettyNumbers(rawToDecimal(price, TOKEN_PRICE_DECIMALS).toNumber())} ); } diff --git a/src/components/nabla/common/TokenApproval.tsx b/src/components/nabla/common/TokenApproval.tsx index fcb865c0..2551e61f 100644 --- a/src/components/nabla/common/TokenApproval.tsx +++ b/src/components/nabla/common/TokenApproval.tsx @@ -9,6 +9,7 @@ export type TokenApprovalProps = ButtonProps & { enabled?: boolean; children: ReactNode; decimals: number; + disabled?: boolean; }; export function TokenApproval({ @@ -19,6 +20,7 @@ export function TokenApproval({ enabled = true, children, className = '', + disabled, ...rest }: TokenApprovalProps): JSX.Element | null { const approval = useErc20TokenApproval({ @@ -28,7 +30,6 @@ export function TokenApproval({ enabled, decimals, }); - console.log('Approval button', approval[0], ApprovalState); if (approval[0] === ApprovalState.APPROVED || !enabled) return <>{children}; @@ -42,7 +43,7 @@ export function TokenApproval({ color="primary" {...rest} type="button" - disabled={noAccount || isPending} + disabled={noAccount || isPending || disabled} onClick={isPending ? undefined : () => approval[1].mutate()} > {noAccount ? 'Please connect your wallet' : isPending ? 'Approving' : isLoading ? 'Loading' : 'Approve'} diff --git a/src/hooks/nabla/useContractBalance.ts b/src/hooks/nabla/useContractBalance.ts index 9589ebe7..c1899e5b 100644 --- a/src/hooks/nabla/useContractBalance.ts +++ b/src/hooks/nabla/useContractBalance.ts @@ -2,7 +2,7 @@ import { MessageCallResult } from '@pendulum-chain/api-solang'; import { UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; import { cacheKeys } from '../../shared/constants'; -import { getMessageCallValue, QueryOptions } from '../../shared/helpers'; +import { getMessageCallValue } from '../../shared/helpers'; import { rawToDecimal, prettyNumbers } from '../../shared/parseNumbers'; import { useSharedState } from '../../shared/Provider'; import { useContractRead } from './useContractRead'; @@ -26,21 +26,22 @@ export type UseBalanceResponse = Pick< enabled: boolean; }; -export const useContractBalance = ( - { contractAddress, account, abi, decimals }: UseBalanceProps, - queryOptions?: QueryOptions, -): UseBalanceResponse => { +export const useContractBalance = ({ + contractAddress, + account, + abi, + decimals, +}: UseBalanceProps): UseBalanceResponse => { const { api, address: defAddress } = useSharedState(); const address = account || defAddress; - const enabled = !!api && !!address && queryOptions?.enabled !== false; + const enabled = !!api && !!address; const query = useContractRead([cacheKeys.balance, contractAddress, address], { abi, address: contractAddress, method: 'balanceOf', args: [address], queryOptions: { - ...(queryOptions ?? {}), cacheTime: 120000, staleTime: 120000, retry: 2, diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index 55778811..44ab950f 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -56,7 +56,7 @@ export function useContractRead( messageArguments: args || [], limits, }); - blurp('read', 'messageCall result', method, response); + //blurp('read', 'messageCall result', method, response); return response; } @@ -67,22 +67,6 @@ export function useContractRead( }, ); - blurp('read', !!contractAbi, queryOptions.enabled !== false, !!address, !!api, !!actualWalletAddress); - blurp( - 'read', - 'useContract result', - method, - enabled, - key, - address, - method, - args, - query.status, - query.data, - (query.data?.result as any)?.value, - (query.data?.result as any)?.value?.toString(), - ); - return { refetch: query.refetch, isLoading: query.isLoading, diff --git a/src/hooks/nabla/useContractWrite.ts b/src/hooks/nabla/useContractWrite.ts index ad511074..e1680f47 100644 --- a/src/hooks/nabla/useContractWrite.ts +++ b/src/hooks/nabla/useContractWrite.ts @@ -38,8 +38,6 @@ export const useContractWrite = >({ [abi, api?.registry], ); - blurp('write', 'useContractWrite', address, method, args); - const isReady = !!contractAbi && !!address && !!api && !!walletAddress && !!signer; const submit = async (submitArgs?: any[] | void): Promise => { if (!isReady) throw 'Missing data'; diff --git a/src/hooks/nabla/useErc20TokenAllowance.ts b/src/hooks/nabla/useErc20TokenAllowance.ts index ff7e8355..bac6daba 100644 --- a/src/hooks/nabla/useErc20TokenAllowance.ts +++ b/src/hooks/nabla/useErc20TokenAllowance.ts @@ -1,6 +1,5 @@ import { erc20WrapperAbi } from '../../contracts/nabla/ERC20Wrapper'; import { cacheKeys } from '../../shared/constants'; -import { QueryOptions } from '../../shared/helpers'; import { activeOptions } from '../../constants/cache'; import { useContractRead } from './useContractRead'; @@ -13,8 +12,8 @@ export type UseTokenAllowance = { owner: string | undefined; }; -export function useErc20TokenAllowance({ token, owner, spender }: UseTokenAllowance, queryOptions?: QueryOptions) { - const isEnabled = Boolean(owner && spender && queryOptions?.enabled); +export function useErc20TokenAllowance({ token, owner, spender }: UseTokenAllowance, enabled: boolean) { + const isEnabled = Boolean(owner && spender && enabled); return useContractRead([cacheKeys.tokenAllowance, spender, token, owner], { abi: erc20WrapperAbi, @@ -23,7 +22,6 @@ export function useErc20TokenAllowance({ token, owner, spender }: UseTokenAllowa args: [owner, spender], queryOptions: { ...activeOptions['3m'], - ...queryOptions, retry: 2, enabled: isEnabled, }, diff --git a/src/hooks/nabla/useErc20TokenApproval.ts b/src/hooks/nabla/useErc20TokenApproval.ts index 2ec4a234..654291d5 100644 --- a/src/hooks/nabla/useErc20TokenApproval.ts +++ b/src/hooks/nabla/useErc20TokenApproval.ts @@ -50,7 +50,7 @@ export function useErc20TokenApproval({ owner: address, spender, }, - { enabled: isEnabled }, + isEnabled, ); const mutation = useContractWrite({ diff --git a/src/hooks/nabla/useNablaTokenPrice.ts b/src/hooks/nabla/useNablaTokenPrice.ts index b1702251..c5c9cb69 100644 --- a/src/hooks/nabla/useNablaTokenPrice.ts +++ b/src/hooks/nabla/useNablaTokenPrice.ts @@ -1,12 +1,12 @@ -import { cacheKeys, inactiveOptions, QueryOptions } from '../../constants/cache'; +import { cacheKeys, inactiveOptions } from '../../constants/cache'; import { priceOracleAbi } from '../../contracts/nabla/PriceOracle'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; import { useContractRead } from './useContractRead'; -export function useNablaTokenPrice(address: string | undefined, queryOptions?: QueryOptions) { +export function useNablaTokenPrice(address: string | undefined, enabled?: boolean) { const { oracle } = useGetAppDataByTenant('nabla').data || {}; - const enabled = !!address && !!oracle && queryOptions?.enabled !== false; + enabled = !!address && !!oracle && enabled !== false; return useContractRead([cacheKeys.tokenPrice, address], { abi: priceOracleAbi, @@ -16,7 +16,6 @@ export function useNablaTokenPrice(address: string | undefined, queryOptions?: Q noWalletAddressRequired: true, queryOptions: { ...inactiveOptions['1m'], - ...queryOptions, enabled, }, }); diff --git a/src/hooks/nabla/useSharesTargetWorth.ts b/src/hooks/nabla/useSharesTargetWorth.ts index 67009c3e..ca6dceb9 100644 --- a/src/hooks/nabla/useSharesTargetWorth.ts +++ b/src/hooks/nabla/useSharesTargetWorth.ts @@ -1,5 +1,4 @@ import { cacheKeys, inactiveOptions } from '../../constants/cache'; -import { QueryOptions } from '../../shared/helpers'; import { decimalToRaw } from '../../shared/parseNumbers'; import { useContractRead } from './useContractRead'; @@ -12,7 +11,7 @@ export type UseSharesTargetWorthProps = { export function useSharesTargetWorth( { address, lpTokenDecimalAmount, abi, lpTokenDecimals }: UseSharesTargetWorthProps, - queryOptions?: QueryOptions, + enabled?: boolean, ) { return useContractRead([cacheKeys.sharesTargetWorth, lpTokenDecimalAmount], { abi, @@ -21,8 +20,7 @@ export function useSharesTargetWorth( args: [decimalToRaw(lpTokenDecimalAmount, lpTokenDecimals).toString()], queryOptions: { ...inactiveOptions['1m'], - ...queryOptions, - enabled: Boolean(address && lpTokenDecimalAmount && queryOptions?.enabled !== false), + enabled: Boolean(address && lpTokenDecimalAmount && enabled !== false), }, }); } diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index 075ad5c0..006d9388 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -1,4 +1,3 @@ -import { MessageCallResult } from '@pendulum-chain/api-solang'; import { activeOptions, cacheKeys } from '../../constants/cache'; import { routerAbi } from '../../contracts/nabla/Router'; import { decimalToRaw } from '../../shared/parseNumbers'; @@ -10,8 +9,6 @@ export type UseTokenOutAmountProps = { from?: string; to?: string; fromTokenDecimals: number; - onSuccess?: (val: MessageCallResult) => void; - onError?: (err: Error | MessageCallResult) => void; }; export function useTokenOutAmount({ @@ -19,8 +16,6 @@ export function useTokenOutAmount({ from, to, fromTokenDecimals, - onSuccess, - onError, }: UseTokenOutAmountProps) { const { router } = useGetAppDataByTenant('nabla').data || {}; @@ -37,9 +32,7 @@ export function useTokenOutAmount({ queryOptions: { ...activeOptions['30s'], enabled, - onSuccess, onError: (err) => { - if (onError) onError(err); console.error(err); }, }, From f5fc88d91fa6610d7dee07a19823b74c4cb6de60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 04:55:06 -0300 Subject: [PATCH 31/58] Fix formatting errors --- .../Pools/Backstop/AddLiquidity/index.tsx | 6 +- .../Backstop/WithdrawLiquidity/index.tsx | 22 +++--- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 4 -- .../nabla/Pools/Swap/Redeem/index.tsx | 2 +- .../Pools/Swap/WithdrawLiquidity/index.tsx | 14 ++-- .../index.tsx => common/TokenAmount.tsx} | 17 +++-- vite.config.ts.timestamp-1714462483331.mjs | 71 +++++++++++++++++++ 7 files changed, 104 insertions(+), 32 deletions(-) rename src/components/nabla/{Pools/TokenAmount/index.tsx => common/TokenAmount.tsx} (69%) create mode 100644 vite.config.ts.timestamp-1714462483331.mjs diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index 3926d1e4..4a7345ff 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -97,7 +97,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { size="sm" value={decimalAmount ? (decimalAmount / balance) * 100 : 0} onChange={(ev: ChangeEvent) => - setValue('amount', (Number(ev.currentTarget.value) / 100) * balance, { + setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * balance, 4), { shouldDirty: true, shouldTouch: false, }) @@ -105,10 +105,6 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { />
-
-
Fee
-
! TODO
-
Total deposit
{depositQuery.isLoading ? numberLoader : `${roundNumber(deposit)} LP`}
diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index 69fda537..6140cb68 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -5,16 +5,16 @@ import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { calcSharePercentage, getPoolSurplusNativeAmount, minMax } from '../../../../../helpers/calc'; -import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; +import { prettyNumbers, rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; import FormLoader from '../../../../Loader/Form'; import { TransactionSettingsDropdown } from '../../../../Transaction/Settings'; -import TokenAmount from '../../TokenAmount'; import { useWithdrawLiquidity } from './useWithdrawLiquidity'; import { NablaInstance, NablaInstanceSwapPool, useNablaInstance } from '../../../../../hooks/nabla/useNablaInstance'; import { AssetSelectorModal } from '../../../common/AssetSelectorModal'; import { TransactionProgress } from '../../../common/TransactionProgress'; +import { TokenAmount } from '../../../common/TokenAmount'; const filter = (swapPools: NablaInstanceSwapPool[]): NablaInstanceSwapPool[] => { return swapPools?.filter((pool) => getPoolSurplusNativeAmount(pool) > 0n); @@ -44,6 +44,7 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element const isIdle = bpw.mutation.isIdle && spw.mutation.isIdle; const isLoading = bpw.mutation.isLoading || spw.mutation.isLoading; const depositedBackstopLpTokenDecimalAmount = depositQuery.balance || 0; + const withdrawLimit = rawToDecimal( spw.withdrawLimitDecimalAmount?.toString() || 0, nabla.backstopPool.lpTokenDecimals, @@ -54,10 +55,11 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element const hideCss = !isIdle ? 'hidden' : ''; const backstopPool = nabla.backstopPool; + return (
{ bpw.mutation.reset(); spw.mutation.reset(); @@ -100,7 +102,7 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element
Withdraw limit: - {spw.isLoading ? numberLoader : <>{withdrawLimit} LP} + {spw.isLoading ? numberLoader : <>{prettyNumbers(withdrawLimit)} LP}
)} @@ -148,10 +150,14 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element : 0 } onChange={(ev: ChangeEvent) => - setValue('amount', (Number(ev.currentTarget.value) / 100) * depositedBackstopLpTokenDecimalAmount, { - shouldDirty: true, - shouldTouch: false, - }) + setValue( + 'amount', + roundNumber((Number(ev.currentTarget.value) / 100) * depositedBackstopLpTokenDecimalAmount, 4), + { + shouldDirty: true, + shouldTouch: false, + }, + ) } />
diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index 064c308e..2b802383 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -89,10 +89,6 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
-
-
Fee
-
{'! TODO'}
-
Total deposit
{depositQuery.isLoading ? numberLoader : `${roundNumber(deposit)} ${data.token.symbol}`}
diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index 9cf2f480..1ce78159 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -98,7 +98,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => { size="sm" value={lpTokensDecimalAmount ? (lpTokensDecimalAmount / deposit) * 100 : 0} onChange={(ev: ChangeEvent) => - setValue('amount', (Number(ev.currentTarget.value) / 100) * deposit, { + setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * deposit, 4), { shouldDirty: true, shouldTouch: false, }) diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index a1bc9c9d..81c8c6d8 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -7,11 +7,11 @@ import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers'; import Validation from '../../../../Form/Validation'; import { numberLoader } from '../../../../Loader'; -import TokenAmount from '../../TokenAmount'; import { SwapPoolColumn } from '../columns'; import { ModalTypes } from '../Modals/types'; import { useSwapPoolWithdrawLiquidity } from './useWithdrawLiquidity'; import { TransactionProgress } from '../../../common/TransactionProgress'; +import { TokenAmount } from '../../../common/TokenAmount'; export interface WithdrawLiquidityProps { data: SwapPoolColumn; @@ -97,10 +97,14 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null size="sm" value={amount ? (amount / depositedLpTokensDecimalAmount) * 100 : 0} onChange={(ev: ChangeEvent) => - setValue('amount', (Number(ev.currentTarget.value) / 100) * depositedLpTokensDecimalAmount, { - shouldDirty: true, - shouldTouch: false, - }) + setValue( + 'amount', + roundNumber((Number(ev.currentTarget.value) / 100) * depositedLpTokensDecimalAmount, 4), + { + shouldDirty: true, + shouldTouch: false, + }, + ) } />
diff --git a/src/components/nabla/Pools/TokenAmount/index.tsx b/src/components/nabla/common/TokenAmount.tsx similarity index 69% rename from src/components/nabla/Pools/TokenAmount/index.tsx rename to src/components/nabla/common/TokenAmount.tsx index 460e9971..6b7428f2 100644 --- a/src/components/nabla/Pools/TokenAmount/index.tsx +++ b/src/components/nabla/common/TokenAmount.tsx @@ -1,8 +1,8 @@ -import { useSharesTargetWorth } from '../../../../hooks/nabla/useSharesTargetWorth'; -import { useDebouncedValue } from '../../../../hooks/useDebouncedValue'; -import { getMessageCallValue } from '../../../../shared/helpers'; -import { rawToDecimal, prettyNumbers } from '../../../../shared/parseNumbers'; -import { numberLoader } from '../../../Loader'; +import { useSharesTargetWorth } from '../../../hooks/nabla/useSharesTargetWorth'; +import { useDebouncedValue } from '../../../hooks/useDebouncedValue'; +import { getMessageCallValue } from '../../../shared/helpers'; +import { rawToDecimal, prettyNumbers } from '../../../shared/parseNumbers'; +import { numberLoader } from '../../Loader'; export interface TokenAmountProps { address: string; @@ -16,7 +16,7 @@ export interface TokenAmountProps { loader?: boolean; } -const TokenAmount = ({ +export function TokenAmount({ symbol, abi, fallback, @@ -26,7 +26,7 @@ const TokenAmount = ({ lpTokenDecimalAmount, loader = true, debounce = 800, -}: TokenAmountProps): JSX.Element | null => { +}: TokenAmountProps): JSX.Element | null { const debouncedAmount = useDebouncedValue(lpTokenDecimalAmount, debounce); const { isLoading, data } = useSharesTargetWorth({ address, @@ -47,5 +47,4 @@ const TokenAmount = ({ {symbol ? symbol : null} ); -}; -export default TokenAmount; +} diff --git a/vite.config.ts.timestamp-1714462483331.mjs b/vite.config.ts.timestamp-1714462483331.mjs new file mode 100644 index 00000000..69dc7960 --- /dev/null +++ b/vite.config.ts.timestamp-1714462483331.mjs @@ -0,0 +1,71 @@ +// vite.config.ts +import preact from "file:///Users/torsten/Development/pendulum/portal/node_modules/@preact/preset-vite/dist/esm/index.mjs"; +import { defineConfig } from "file:///Users/torsten/Development/pendulum/portal/node_modules/vite/dist/node/index.js"; +import { NodeGlobalsPolyfillPlugin } from "file:///Users/torsten/Development/pendulum/portal/node_modules/@esbuild-plugins/node-globals-polyfill/dist/index.js"; +import { NodeModulesPolyfillPlugin } from "file:///Users/torsten/Development/pendulum/portal/node_modules/@esbuild-plugins/node-modules-polyfill/dist/index.js"; +import rollupNodePolyFill from "file:///Users/torsten/Development/pendulum/portal/node_modules/rollup-plugin-node-polyfills/dist/index.js"; +var vite_config_default = defineConfig({ + plugins: [preact()], + esbuild: { + logOverride: { "this-is-undefined-in-esm": "silent" } + }, + resolve: { + alias: { + assert: "rollup-plugin-node-polyfills/polyfills/assert", + buffer: "rollup-plugin-node-polyfills/polyfills/buffer-es6", + console: "rollup-plugin-node-polyfills/polyfills/console", + constants: "rollup-plugin-node-polyfills/polyfills/constants", + domain: "rollup-plugin-node-polyfills/polyfills/domain", + events: "rollup-plugin-node-polyfills/polyfills/events", + http: "rollup-plugin-node-polyfills/polyfills/http", + https: "rollup-plugin-node-polyfills/polyfills/http", + os: "rollup-plugin-node-polyfills/polyfills/os", + path: "rollup-plugin-node-polyfills/polyfills/path", + process: "rollup-plugin-node-polyfills/polyfills/process-es6", + punycode: "rollup-plugin-node-polyfills/polyfills/punycode", + querystring: "rollup-plugin-node-polyfills/polyfills/qs", + stream: "rollup-plugin-node-polyfills/polyfills/stream", + string_decoder: "rollup-plugin-node-polyfills/polyfills/string-decoder", + sys: "util", + timers: "rollup-plugin-node-polyfills/polyfills/timers", + tty: "rollup-plugin-node-polyfills/polyfills/tty", + url: "rollup-plugin-node-polyfills/polyfills/url", + util: "rollup-plugin-node-polyfills/polyfills/util", + vm: "rollup-plugin-node-polyfills/polyfills/vm", + zlib: "rollup-plugin-node-polyfills/polyfills/zlib", + _stream_duplex: "rollup-plugin-node-polyfills/polyfills/readable-stream/duplex", + _stream_passthrough: "rollup-plugin-node-polyfills/polyfills/readable-stream/passthrough", + _stream_readable: "rollup-plugin-node-polyfills/polyfills/readable-stream/readable", + _stream_writable: "rollup-plugin-node-polyfills/polyfills/readable-stream/writable", + _stream_transform: "rollup-plugin-node-polyfills/polyfills/readable-stream/transform" + } + }, + optimizeDeps: { + exclude: [], + esbuildOptions: { + target: "esnext", + define: { + global: "globalThis" + }, + plugins: [ + NodeGlobalsPolyfillPlugin({ + process: true, + buffer: true + }), + NodeModulesPolyfillPlugin() + ] + } + }, + build: { + target: ["esnext"], + rollupOptions: { + plugins: [ + rollupNodePolyFill() + ] + } + } +}); +export { + vite_config_default as default +}; +//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsidml0ZS5jb25maWcudHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbImNvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9kaXJuYW1lID0gXCIvVXNlcnMvdG9yc3Rlbi9EZXZlbG9wbWVudC9wZW5kdWx1bS9wb3J0YWxcIjtjb25zdCBfX3ZpdGVfaW5qZWN0ZWRfb3JpZ2luYWxfZmlsZW5hbWUgPSBcIi9Vc2Vycy90b3JzdGVuL0RldmVsb3BtZW50L3BlbmR1bHVtL3BvcnRhbC92aXRlLmNvbmZpZy50c1wiO2NvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9pbXBvcnRfbWV0YV91cmwgPSBcImZpbGU6Ly8vVXNlcnMvdG9yc3Rlbi9EZXZlbG9wbWVudC9wZW5kdWx1bS9wb3J0YWwvdml0ZS5jb25maWcudHNcIjtpbXBvcnQgcHJlYWN0IGZyb20gJ0BwcmVhY3QvcHJlc2V0LXZpdGUnO1xuaW1wb3J0IHsgZGVmaW5lQ29uZmlnIH0gZnJvbSAndml0ZSc7XG5cbmltcG9ydCB7IE5vZGVHbG9iYWxzUG9seWZpbGxQbHVnaW4gfSBmcm9tICdAZXNidWlsZC1wbHVnaW5zL25vZGUtZ2xvYmFscy1wb2x5ZmlsbCc7XG5pbXBvcnQgeyBOb2RlTW9kdWxlc1BvbHlmaWxsUGx1Z2luIH0gZnJvbSAnQGVzYnVpbGQtcGx1Z2lucy9ub2RlLW1vZHVsZXMtcG9seWZpbGwnO1xuaW1wb3J0IHJvbGx1cE5vZGVQb2x5RmlsbCBmcm9tICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzJztcblxuLy8gaHR0cHM6Ly92aXRlanMuZGV2L2NvbmZpZy9cbmV4cG9ydCBkZWZhdWx0IGRlZmluZUNvbmZpZyh7XG4gIHBsdWdpbnM6IFtwcmVhY3QoKV0sXG4gIGVzYnVpbGQ6IHtcbiAgICBsb2dPdmVycmlkZTogeyAndGhpcy1pcy11bmRlZmluZWQtaW4tZXNtJzogJ3NpbGVudCcgfSxcbiAgfSxcbiAgcmVzb2x2ZToge1xuICAgIGFsaWFzOiB7XG4gICAgICAvLyBUaGlzIFJvbGx1cCBhbGlhc2VzIGFyZSBleHRyYWN0ZWQgZnJvbSBAZXNidWlsZC1wbHVnaW5zL25vZGUtbW9kdWxlcy1wb2x5ZmlsbCxcbiAgICAgIC8vIHNlZSBodHRwczovL2dpdGh1Yi5jb20vcmVtb3JzZXMvZXNidWlsZC1wbHVnaW5zL2Jsb2IvbWFzdGVyL25vZGUtbW9kdWxlcy1wb2x5ZmlsbC9zcmMvcG9seWZpbGxzLnRzXG4gICAgICBhc3NlcnQ6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9hc3NlcnQnLFxuICAgICAgYnVmZmVyOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvYnVmZmVyLWVzNicsXG4gICAgICBjb25zb2xlOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvY29uc29sZScsXG4gICAgICBjb25zdGFudHM6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9jb25zdGFudHMnLFxuICAgICAgZG9tYWluOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvZG9tYWluJyxcbiAgICAgIGV2ZW50czogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL2V2ZW50cycsXG4gICAgICBodHRwOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvaHR0cCcsXG4gICAgICBodHRwczogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL2h0dHAnLFxuICAgICAgb3M6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9vcycsXG4gICAgICBwYXRoOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvcGF0aCcsXG4gICAgICBwcm9jZXNzOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvcHJvY2Vzcy1lczYnLFxuICAgICAgcHVueWNvZGU6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9wdW55Y29kZScsXG4gICAgICBxdWVyeXN0cmluZzogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3FzJyxcbiAgICAgIHN0cmVhbTogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3N0cmVhbScsXG4gICAgICBzdHJpbmdfZGVjb2RlcjogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3N0cmluZy1kZWNvZGVyJyxcbiAgICAgIHN5czogJ3V0aWwnLFxuICAgICAgdGltZXJzOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvdGltZXJzJyxcbiAgICAgIHR0eTogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3R0eScsXG4gICAgICB1cmw6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy91cmwnLFxuICAgICAgdXRpbDogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3V0aWwnLFxuICAgICAgdm06ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy92bScsXG4gICAgICB6bGliOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvemxpYicsXG4gICAgICBfc3RyZWFtX2R1cGxleDogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3JlYWRhYmxlLXN0cmVhbS9kdXBsZXgnLFxuICAgICAgX3N0cmVhbV9wYXNzdGhyb3VnaDogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3JlYWRhYmxlLXN0cmVhbS9wYXNzdGhyb3VnaCcsXG4gICAgICBfc3RyZWFtX3JlYWRhYmxlOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvcmVhZGFibGUtc3RyZWFtL3JlYWRhYmxlJyxcbiAgICAgIF9zdHJlYW1fd3JpdGFibGU6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9yZWFkYWJsZS1zdHJlYW0vd3JpdGFibGUnLFxuICAgICAgX3N0cmVhbV90cmFuc2Zvcm06ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9yZWFkYWJsZS1zdHJlYW0vdHJhbnNmb3JtJyxcbiAgICB9LFxuICB9LFxuICBvcHRpbWl6ZURlcHM6IHtcbiAgICBleGNsdWRlOiBbXSxcbiAgICBlc2J1aWxkT3B0aW9uczoge1xuICAgICAgdGFyZ2V0OiAnZXNuZXh0JyxcbiAgICAgIC8vIE5vZGUuanMgZ2xvYmFsIHRvIGJyb3dzZXIgZ2xvYmFsVGhpc1xuICAgICAgZGVmaW5lOiB7XG4gICAgICAgIGdsb2JhbDogJ2dsb2JhbFRoaXMnLFxuICAgICAgfSxcbiAgICAgIC8vIEVuYWJsZSBlc2J1aWxkIHBvbHlmaWxsIHBsdWdpbnNcbiAgICAgIHBsdWdpbnM6IFtcbiAgICAgICAgTm9kZUdsb2JhbHNQb2x5ZmlsbFBsdWdpbih7XG4gICAgICAgICAgcHJvY2VzczogdHJ1ZSxcbiAgICAgICAgICBidWZmZXI6IHRydWUsXG4gICAgICAgIH0pLFxuICAgICAgICBOb2RlTW9kdWxlc1BvbHlmaWxsUGx1Z2luKCksXG4gICAgICBdLFxuICAgIH0sXG4gIH0sXG4gIGJ1aWxkOiB7XG4gICAgdGFyZ2V0OiBbJ2VzbmV4dCddLFxuICAgIHJvbGx1cE9wdGlvbnM6IHtcbiAgICAgIHBsdWdpbnM6IFtcbiAgICAgICAgLy8gRW5hYmxlIHJvbGx1cCBwb2x5ZmlsbHMgcGx1Z2luXG4gICAgICAgIC8vIHVzZWQgZHVyaW5nIHByb2R1Y3Rpb24gYnVuZGxpbmdcbiAgICAgICAgcm9sbHVwTm9kZVBvbHlGaWxsKCksXG4gICAgICBdLFxuICAgIH0sXG4gIH0sXG59KTtcbiJdLAogICJtYXBwaW5ncyI6ICI7QUFBZ1QsT0FBTyxZQUFZO0FBQ25VLFNBQVMsb0JBQW9CO0FBRTdCLFNBQVMsaUNBQWlDO0FBQzFDLFNBQVMsaUNBQWlDO0FBQzFDLE9BQU8sd0JBQXdCO0FBRy9CLElBQU8sc0JBQVEsYUFBYTtBQUFBLEVBQzFCLFNBQVMsQ0FBQyxPQUFPLENBQUM7QUFBQSxFQUNsQixTQUFTO0FBQUEsSUFDUCxhQUFhLEVBQUUsNEJBQTRCLFNBQVM7QUFBQSxFQUN0RDtBQUFBLEVBQ0EsU0FBUztBQUFBLElBQ1AsT0FBTztBQUFBLE1BR0wsUUFBUTtBQUFBLE1BQ1IsUUFBUTtBQUFBLE1BQ1IsU0FBUztBQUFBLE1BQ1QsV0FBVztBQUFBLE1BQ1gsUUFBUTtBQUFBLE1BQ1IsUUFBUTtBQUFBLE1BQ1IsTUFBTTtBQUFBLE1BQ04sT0FBTztBQUFBLE1BQ1AsSUFBSTtBQUFBLE1BQ0osTUFBTTtBQUFBLE1BQ04sU0FBUztBQUFBLE1BQ1QsVUFBVTtBQUFBLE1BQ1YsYUFBYTtBQUFBLE1BQ2IsUUFBUTtBQUFBLE1BQ1IsZ0JBQWdCO0FBQUEsTUFDaEIsS0FBSztBQUFBLE1BQ0wsUUFBUTtBQUFBLE1BQ1IsS0FBSztBQUFBLE1BQ0wsS0FBSztBQUFBLE1BQ0wsTUFBTTtBQUFBLE1BQ04sSUFBSTtBQUFBLE1BQ0osTUFBTTtBQUFBLE1BQ04sZ0JBQWdCO0FBQUEsTUFDaEIscUJBQXFCO0FBQUEsTUFDckIsa0JBQWtCO0FBQUEsTUFDbEIsa0JBQWtCO0FBQUEsTUFDbEIsbUJBQW1CO0FBQUEsSUFDckI7QUFBQSxFQUNGO0FBQUEsRUFDQSxjQUFjO0FBQUEsSUFDWixTQUFTLENBQUM7QUFBQSxJQUNWLGdCQUFnQjtBQUFBLE1BQ2QsUUFBUTtBQUFBLE1BRVIsUUFBUTtBQUFBLFFBQ04sUUFBUTtBQUFBLE1BQ1Y7QUFBQSxNQUVBLFNBQVM7QUFBQSxRQUNQLDBCQUEwQjtBQUFBLFVBQ3hCLFNBQVM7QUFBQSxVQUNULFFBQVE7QUFBQSxRQUNWLENBQUM7QUFBQSxRQUNELDBCQUEwQjtBQUFBLE1BQzVCO0FBQUEsSUFDRjtBQUFBLEVBQ0Y7QUFBQSxFQUNBLE9BQU87QUFBQSxJQUNMLFFBQVEsQ0FBQyxRQUFRO0FBQUEsSUFDakIsZUFBZTtBQUFBLE1BQ2IsU0FBUztBQUFBLFFBR1AsbUJBQW1CO0FBQUEsTUFDckI7QUFBQSxJQUNGO0FBQUEsRUFDRjtBQUNGLENBQUM7IiwKICAibmFtZXMiOiBbXQp9Cg== From b7297981fcfdce481680b463457a0c3903601713 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 05:08:59 -0300 Subject: [PATCH 32/58] Remove console.logs --- codegen.ts | 3 +-- src/blurp.tsx | 15 --------------- .../Pools/Swap/AddLiquidity/useAddLiquidity.ts | 1 - src/config/apps/nabla.ts | 3 +-- src/hooks/nabla/useContractRead.ts | 14 ++++++++++---- src/hooks/nabla/useContractWrite.ts | 16 +++++++++++----- src/shared/helpers.ts | 16 ---------------- 7 files changed, 23 insertions(+), 45 deletions(-) delete mode 100644 src/blurp.tsx diff --git a/codegen.ts b/codegen.ts index 858262c9..be24fc09 100644 --- a/codegen.ts +++ b/codegen.ts @@ -1,8 +1,7 @@ import { CodegenConfig } from '@graphql-codegen/cli'; const config: CodegenConfig = { - // TODO Torsten - schema: 'https://pendulum.squids.live/foucoco-squid/v/v21/graphql', + schema: 'https://pendulum.squids.live/foucoco-squid/graphql', documents: ['**/*.{ts,tsx}', '!gql/**/*'], generates: { './gql/': { diff --git a/src/blurp.tsx b/src/blurp.tsx deleted file mode 100644 index fca5ada6..00000000 --- a/src/blurp.tsx +++ /dev/null @@ -1,15 +0,0 @@ -// TODO Torsten - -const blurpConfig = { - read: true, - write: true, -}; - -export type BlurpType = keyof typeof blurpConfig; - -/* eslint-disable @typescript-eslint/no-explicit-any */ -export function blurp(type: BlurpType, ...args: any[]) { - if (blurpConfig[type]) { - console.log(type, ...args); - } -} diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index 36a665fd..2205854e 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -57,7 +57,6 @@ export const useAddLiquidity = ( }); const onSubmit = form.handleSubmit((variables) => { - console.log('submit add liquidity', variables.amount, decimalToRaw(variables.amount, poolTokenDecimals).toString()); return mutation.mutate([decimalToRaw(variables.amount, poolTokenDecimals).toString()]); }); diff --git a/src/config/apps/nabla.ts b/src/config/apps/nabla.ts index 750295b4..e6b52825 100644 --- a/src/config/apps/nabla.ts +++ b/src/config/apps/nabla.ts @@ -16,8 +16,7 @@ export const nablaConfig: NablaConfig = { tenants: [TenantName.Foucoco], environment: ['staging', 'development'], foucoco: { - // TODO Torsten - indexerUrl: 'https://pendulum.squids.live/foucoco-squid/v/v21/graphql', + indexerUrl: 'https://pendulum.squids.live/foucoco-squid/graphql', router: '6ijJtaZuwpZCiaVo6pSHRJbd8qejgywYsejnjfo2AVanN14E', oracle: '6jscuYjvoPesdnzdnUNYEntLmGY3R6F5hJoTum1oaV7VVcxE', }, diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index 44ab950f..e8a63238 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -6,9 +6,9 @@ import { useMemo } from 'preact/compat'; import { defaultReadLimits, emptyCacheKey, emptyFn, QueryOptions } from '../../shared/helpers'; import { useSharedState } from '../../shared/Provider'; +import { config } from '../../config'; -// TODO Torsten -import { blurp } from '../../blurp'; +const isDevelopment = config.isDev; export type UseContractProps = { abi: Dict; @@ -44,7 +44,10 @@ export function useContractRead( enabled ? async () => { const limits = defaultReadLimits; - blurp('read', 'Call message', address, method, args); + + if (isDevelopment) { + console.log('read', 'Call message', address, method, args); + } const response = await messageCall({ abi: contractAbi, @@ -56,7 +59,10 @@ export function useContractRead( messageArguments: args || [], limits, }); - //blurp('read', 'messageCall result', method, response); + + if (isDevelopment) { + console.log('read', 'messageCall result', method, response); + } return response; } diff --git a/src/hooks/nabla/useContractWrite.ts b/src/hooks/nabla/useContractWrite.ts index e1680f47..16d2af3b 100644 --- a/src/hooks/nabla/useContractWrite.ts +++ b/src/hooks/nabla/useContractWrite.ts @@ -4,11 +4,13 @@ import { Abi } from '@polkadot/api-contract'; import { DispatchError, ExtrinsicStatus } from '@polkadot/types/interfaces'; import { MutationOptions, useMutation } from '@tanstack/react-query'; import { useMemo, useState } from 'preact/compat'; + import { defaultWriteLimits } from '../../shared/helpers'; import { useSharedState } from '../../shared/Provider'; -// TODO Torsten -import { blurp } from '../../blurp'; import { createWriteOptions } from '../../services/api/helpers'; +import { config } from '../../config'; + +const isDevelopment = config.isDev; // TODO: fix/improve types - parse abi file export type TransactionsStatus = { @@ -45,8 +47,10 @@ export const useContractWrite = >({ const fnArgs = submitArgs || args || []; const contractOptions = createWriteOptions(api); - blurp('write', 'call message write', address, method, args, submitArgs); - blurp('write', 'limits', { ...defaultWriteLimits, ...contractOptions }); + if (isDevelopment) { + console.log('write', 'call message write', address, method, args, submitArgs); + console.log('write', 'limits', { ...defaultWriteLimits, ...contractOptions }); + } const response = await messageCall({ abi: contractAbi, @@ -65,7 +69,9 @@ export const useContractWrite = >({ gasLimitTolerancePercentage: 10, // Allow 3 fold gas tolerance }); - blurp('write', 'call message write response', address, method, fnArgs, response); + if (isDevelopment) { + console.log('write', 'call message write response', address, method, fnArgs, response); + } if (response?.result?.type !== 'success') throw response; return response; diff --git a/src/shared/helpers.ts b/src/shared/helpers.ts index e564f105..610bd7a6 100644 --- a/src/shared/helpers.ts +++ b/src/shared/helpers.ts @@ -1,6 +1,4 @@ import { Limits, MessageCallResult } from '@pendulum-chain/api-solang'; -import { ApiPromise } from '@polkadot/api'; -import { SubmittableResultValue } from '@polkadot/api-base/types'; import type { QueryKey, UseQueryOptions } from '@tanstack/react-query'; // eslint-disable-next-line @typescript-eslint/no-explicit-any @@ -11,20 +9,6 @@ export type QueryOptions = Partial< export const emptyFn = () => undefined; export const emptyCacheKey = ['']; -// TODO: complete - improve error parsing -export const parseTransactionError = (result: SubmittableResultValue | undefined, api: ApiPromise) => { - if (!result?.dispatchError) return undefined; - if (result.dispatchError.isModule) { - // for module errors, we have the section indexed, lookup - const decoded = api.registry.findMetaError(result.dispatchError.asModule); - const { docs, name, section } = decoded; - console.log(`${section}.${name}: ${docs.join(' ')}`); - } else { - // Other, CannotLookup, BadOrigin, no extra info - console.log(result.dispatchError.toString()); - } -}; - export const defaultReadLimits: Limits = { gas: { refTime: '10000000000000000', From 821e44c21ea1619451f7bc62bd2ec53b9f10302e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 06:16:01 -0300 Subject: [PATCH 33/58] Fix maximum amount on swap pool deposit --- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 210 ++++++++++-------- 1 file changed, 115 insertions(+), 95 deletions(-) diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index 2b802383..c8cc1c2e 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -9,28 +9,41 @@ import { SwapPoolColumn } from '../columns'; import { useAddLiquidity } from './useAddLiquidity'; import { TransactionProgress } from '../../../common/TransactionProgress'; import { TokenApproval } from '../../../common/TokenApproval'; +import { useEffect } from 'preact/hooks'; +import { NumberInput } from '../../../common/NumberInput'; +import { FormProvider } from 'react-hook-form'; export interface AddLiquidityProps { data: SwapPoolColumn; } const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { - const { - toggle, - mutation, - onSubmit, - balanceQuery, - depositQuery, - decimalAmount, - form: { - register, - setValue, - formState: { errors }, - }, - } = useAddLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); + const { toggle, mutation, onSubmit, balanceQuery, depositQuery, decimalAmount, form } = useAddLiquidity( + data.id, + data.token.id, + data.token.decimals, + data.lpTokenDecimals, + ); const balance = balanceQuery.balance || 0; const deposit = depositQuery.balance || 0; + const { + setError, + clearErrors, + setValue, + formState: { errors }, + } = form; + + useEffect(() => { + if (balanceQuery.balance !== undefined && decimalAmount > balanceQuery.balance) { + setError('amount', { type: 'custom', message: 'Amount exceeds balance' }); + } else { + clearErrors('amount'); + } + }, [decimalAmount, balanceQuery.balance, setError, clearErrors]); + + console.log(errors, Object.keys(errors)); + const hideCss = !mutation.isIdle ? 'hidden' : ''; return (
@@ -44,95 +57,102 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {

Confirm deposit

-
-
-
-

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

-

- Balance: {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} -

+ + +
+
+

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

+

+ Balance:{' '} + {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} +

+
+
+ + + +
-
- - + +
-
-
-
-
Total deposit
-
{depositQuery.isLoading ? numberLoader : `${roundNumber(deposit)} ${data.token.symbol}`}
-
-
-
Pool Share
-
- {depositQuery.isLoading - ? numberLoader - : minMax( - calcSharePercentage( - rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), - deposit, - ), - )} - % -
-
-
-
- - 0} - > - - - -
- + +
); From 7d0364677a2043139ab9b2542c406687d02c64e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 06:19:59 -0300 Subject: [PATCH 34/58] Fix maximum amount on backstop pool deposit --- .../Pools/Backstop/AddLiquidity/index.tsx | 238 ++++++++++-------- 1 file changed, 129 insertions(+), 109 deletions(-) diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index 4a7345ff..950badc0 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -1,5 +1,5 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; -import { ChangeEvent } from 'preact/compat'; +import { ChangeEvent, useEffect } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; @@ -10,25 +10,36 @@ import { useAddLiquidity } from './useAddLiquidity'; import { NablaInstanceBackstopPool } from '../../../../../hooks/nabla/useNablaInstance'; import { TransactionProgress } from '../../../common/TransactionProgress'; import { TokenApproval } from '../../../common/TokenApproval'; +import { FormProvider } from 'react-hook-form'; +import { NumberInput } from '../../../common/NumberInput'; export type AddLiquidityProps = { data: NablaInstanceBackstopPool; }; const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { + const { toggle, onSubmit, mutation, balanceQuery, depositQuery, decimalAmount, form } = useAddLiquidity( + data.id, + data.token.id, + data.token.decimals, + data.lpTokenDecimals, + ); + const { - toggle, - onSubmit, - mutation, - balanceQuery, - depositQuery, - decimalAmount, - form: { - register, - setValue, - formState: { errors }, - }, - } = useAddLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); + setError, + clearErrors, + setValue, + formState: { errors }, + } = form; + + useEffect(() => { + if (balanceQuery.balance !== undefined && decimalAmount > balanceQuery.balance) { + setError('amount', { type: 'custom', message: 'Amount exceeds balance' }); + } else { + clearErrors('amount'); + } + }, [decimalAmount, balanceQuery.balance, setError, clearErrors]); + const balance = balanceQuery.balance || 0; const deposit = depositQuery.balance || 0; @@ -45,107 +56,116 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {

Deposit {data.token.symbol}

-
-
-

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

-

- Balance: {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} -

-
-
-
-
- - - -
+ + +
+

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

+

+ Balance: {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} +

- ) => - setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * balance, 4), { - shouldDirty: true, - shouldTouch: false, - }) - } - /> -
-
-
-
Total deposit
-
{depositQuery.isLoading ? numberLoader : `${roundNumber(deposit)} LP`}
+
+
+
+ + + +
+
+ ) => + setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * balance, 4), { + shouldDirty: true, + shouldTouch: false, + }) + } + />
-
-
Pool Share
-
- {depositQuery.isLoading - ? numberLoader - : minMax( - calcSharePercentage(rawToDecimal(data.totalSupply || 0, data.token.decimals).toNumber(), deposit), - )} - % +
+
+
Total deposit
+
{depositQuery.isLoading ? numberLoader : `${roundNumber(deposit)} LP`}
+
+
+
Pool Share
+
+ {depositQuery.isLoading + ? numberLoader + : minMax( + calcSharePercentage( + rawToDecimal(data.totalSupply || 0, data.token.decimals).toNumber(), + deposit, + ), + )} + % +
-
-
- - 0} - > - + + - - -
- +
+ +
); From 063348008cc26a43abf0f0a38fe88f915ac6b7d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 06:26:18 -0300 Subject: [PATCH 35/58] Fix maximum amount on backstop pool withdrawal --- .../Backstop/WithdrawLiquidity/index.tsx | 274 ++++++++++-------- 1 file changed, 147 insertions(+), 127 deletions(-) diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index 6140cb68..127fe7c0 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -1,6 +1,6 @@ import { ChevronDownIcon } from '@heroicons/react/20/solid'; import { ArrowLeftIcon } from '@heroicons/react/24/outline'; -import { ChangeEvent, useMemo } from 'preact/compat'; +import { ChangeEvent, useEffect, useMemo } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; @@ -15,6 +15,8 @@ import { NablaInstance, NablaInstanceSwapPool, useNablaInstance } from '../../.. import { AssetSelectorModal } from '../../../common/AssetSelectorModal'; import { TransactionProgress } from '../../../common/TransactionProgress'; import { TokenAmount } from '../../../common/TokenAmount'; +import { FormProvider } from 'react-hook-form'; +import { NumberInput } from '../../../common/NumberInput'; const filter = (swapPools: NablaInstanceSwapPool[]): NablaInstanceSwapPool[] => { return swapPools?.filter((pool) => getPoolSurplusNativeAmount(pool) > 0n); @@ -25,11 +27,7 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element toggle, balanceQuery, depositQuery, - form: { - register, - setValue, - formState: { errors }, - }, + form, backstopLpTokenDecimalAmountToRedeem, pools, selectedPool, @@ -41,6 +39,22 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element onSubmit, } = useWithdrawLiquidity(nabla); + const { + setError, + clearErrors, + register, + setValue, + formState: { errors }, + } = form; + + useEffect(() => { + if (depositQuery.balance !== undefined && backstopLpTokenDecimalAmountToRedeem > depositQuery.balance) { + setError('amount', { type: 'custom', message: 'Amount exceeds owned LP tokens' }); + } else { + clearErrors('amount'); + } + }, [backstopLpTokenDecimalAmountToRedeem, depositQuery.balance, setError, clearErrors]); + const isIdle = bpw.mutation.isIdle && spw.mutation.isIdle; const isLoading = bpw.mutation.isLoading || spw.mutation.isLoading; const depositedBackstopLpTokenDecimalAmount = depositQuery.balance || 0; @@ -74,135 +88,141 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element

Withdraw {backstopPool.token.symbol}

-
-
-

- Deposited:{' '} - {depositQuery.isLoading ? ( - numberLoader - ) : ( - - setValue('amount', depositedBackstopLpTokenDecimalAmount, { - shouldDirty: true, - shouldTouch: true, - }) - } - >{`${depositQuery.formatted || 0} LP`} + + +

+

+ Deposited:{' '} + {depositQuery.isLoading ? ( + numberLoader + ) : ( + + setValue('amount', depositedBackstopLpTokenDecimalAmount, { + shouldDirty: true, + shouldTouch: true, + }) + } + >{`${depositQuery.formatted || 0} LP`} + )} +

+

+ Balance:{' '} + {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${backstopPool.token.symbol}`} +

+
+
+ {isSwapPoolWithdraw && ( +
+
+ Withdraw limit: + {spw.isLoading ? numberLoader : <>{prettyNumbers(withdrawLimit)} LP} +
+
)} -

-

- Balance:{' '} - {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${backstopPool.token.symbol}`} -

-
-
- {isSwapPoolWithdraw && ( -
+
+
+ + + { + setValue('slippage', slippage); + updateStorage({ slippage }); + }} + slippageProps={register('slippage', { + valueAsNumber: true, + onChange: (ev) => + updateStorage({ + slippage: Number(ev.currentTarget.value), + }), + })} + /> +
+
+ ) => + setValue( + 'amount', + roundNumber((Number(ev.currentTarget.value) / 100) * depositedBackstopLpTokenDecimalAmount, 4), + { + shouldDirty: true, + shouldTouch: false, + }, + ) + } + /> +
+
+
+
Amount
- Withdraw limit: - {spw.isLoading ? numberLoader : <>{prettyNumbers(withdrawLimit)} LP} +
- )} -
-
- - - { - setValue('slippage', slippage); - updateStorage({ slippage }); - }} - slippageProps={register('slippage', { - valueAsNumber: true, - onChange: (ev) => - updateStorage({ - slippage: Number(ev.currentTarget.value), - }), - })} - /> +
+
Deposit
+
{roundNumber(depositedBackstopLpTokenDecimalAmount || 0)} LP
-
- ) => - setValue( - 'amount', - roundNumber((Number(ev.currentTarget.value) / 100) * depositedBackstopLpTokenDecimalAmount, 4), - { - shouldDirty: true, - shouldTouch: false, - }, - ) - } - /> -
-
-
-
Amount
-
- +
+
Pool share
+
+ {minMax( + calcSharePercentage( + rawToDecimal(backstopPool.totalSupply || 0, backstopPool.lpTokenDecimals).toNumber(), + depositedBackstopLpTokenDecimalAmount, + ), + )} + % +
-
-
Deposit
-
{roundNumber(depositedBackstopLpTokenDecimalAmount || 0)} LP
-
-
-
Pool share
-
- {minMax( - calcSharePercentage( - rawToDecimal(backstopPool.totalSupply || 0, backstopPool.lpTokenDecimals).toNumber(), - depositedBackstopLpTokenDecimalAmount, - ), - )} - % -
+
+ + +
-
-
- - - -
- + +
Date: Tue, 30 Apr 2024 06:34:03 -0300 Subject: [PATCH 36/58] Fix maxmium amount on swap pool withdrawal and redeem --- .../nabla/Pools/Swap/Redeem/index.tsx | 216 +++++++------- .../Pools/Swap/WithdrawLiquidity/index.tsx | 269 +++++++++--------- 2 files changed, 253 insertions(+), 232 deletions(-) diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index 1ce78159..4b3ac52c 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -1,5 +1,5 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; -import { ChangeEvent } from 'preact/compat'; +import { ChangeEvent, useEffect } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { config } from '../../../../../config'; @@ -12,26 +12,33 @@ import { SwapPoolColumn } from '../columns'; import { useRedeem } from './useRedeem'; import { TransactionProgress } from '../../../common/TransactionProgress'; import { NablaTokenPrice } from '../../../common/NablaTokenPrice'; +import { FormProvider } from 'react-hook-form'; +import { NumberInput } from '../../../common/NumberInput'; export interface RedeemProps { data: SwapPoolColumn; } const Redeem = ({ data }: RedeemProps): JSX.Element | null => { + const { toggle, mutation, onSubmit, balanceQuery, depositQuery, lpTokensDecimalAmount, updateStorage, form } = + useRedeem(data); + const { - toggle, - mutation, - onSubmit, - balanceQuery, - depositQuery, - lpTokensDecimalAmount, - updateStorage, - form: { - register, - setValue, - formState: { errors }, - }, - } = useRedeem(data); + setError, + clearErrors, + register, + setValue, + formState: { errors }, + } = form; + + useEffect(() => { + if (depositQuery.balance !== undefined && lpTokensDecimalAmount > depositQuery.balance) { + setError('amount', { type: 'custom', message: 'Amount exceeds owned LP tokens' }); + } else { + clearErrors('amount'); + } + }, [lpTokensDecimalAmount, depositQuery.balance, setError, clearErrors]); + const deposit = depositQuery.balance || 0; const hideCss = !mutation.isIdle ? 'hidden' : ''; @@ -47,105 +54,106 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => {

Redeem {data.token?.symbol}

-
-
-

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

-

- Balance: {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} -

-
-
-
- - + { + setValue('slippage', slippage); + updateStorage({ slippage }); + }} + slippageProps={register('slippage', { + valueAsNumber: true, + onChange: (ev) => + updateStorage({ + slippage: Number(ev.currentTarget.value), + }), + })} + /> +
+ - setValue('amount', deposit, { + value={lpTokensDecimalAmount ? (lpTokensDecimalAmount / deposit) * 100 : 0} + onChange={(ev: ChangeEvent) => + setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * deposit, 4), { shouldDirty: true, - shouldTouch: true, + shouldTouch: false, }) } - > - MAX - - { - setValue('slippage', slippage); - updateStorage({ slippage }); - }} - slippageProps={register('slippage', { - valueAsNumber: true, - onChange: (ev) => - updateStorage({ - slippage: Number(ev.currentTarget.value), - }), - })} />
- ) => - setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * deposit, 4), { - shouldDirty: true, - shouldTouch: false, - }) - } - /> -
-
-
-
Security fee
-
{config.backstop.securityFee * 100}%
-
-
-
Price
-
- +
+
+
Security fee
+
{config.backstop.securityFee * 100}%
-
-
-
Deposit
-
{roundNumber(deposit)}
-
-
-
Pool share
-
- {minMax( - calcSharePercentage(rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), deposit), - )} - % +
+
Price
+
+ +
+
+
+
Deposit
+
{roundNumber(deposit)}
+
+
Pool share
+
+ {minMax( + calcSharePercentage(rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), deposit), + )} + % +
+
+
+
+ + +
-
-
- - - -
- + +
); diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index 81c8c6d8..f3484a8c 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -1,5 +1,5 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; -import { ChangeEvent } from 'preact/compat'; +import { ChangeEvent, useEffect } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; @@ -12,25 +12,37 @@ import { ModalTypes } from '../Modals/types'; import { useSwapPoolWithdrawLiquidity } from './useWithdrawLiquidity'; import { TransactionProgress } from '../../../common/TransactionProgress'; import { TokenAmount } from '../../../common/TokenAmount'; +import { FormProvider } from 'react-hook-form'; +import { NumberInput } from '../../../common/NumberInput'; export interface WithdrawLiquidityProps { data: SwapPoolColumn; } const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null => { + const { toggle, mutation, onSubmit, balanceQuery, depositQuery, amount, form } = useSwapPoolWithdrawLiquidity( + data.id, + data.token.id, + data.token.decimals, + data.lpTokenDecimals, + ); + const { - toggle, - mutation, - onSubmit, - balanceQuery, - depositQuery, - amount, - form: { - register, - setValue, - formState: { errors }, - }, - } = useSwapPoolWithdrawLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); + setError, + clearErrors, + register, + setValue, + formState: { errors }, + } = form; + + useEffect(() => { + if (depositQuery.balance !== undefined && amount > depositQuery.balance) { + setError('amount', { type: 'custom', message: 'Amount exceeds owned LP tokens' }); + } else { + clearErrors('amount'); + } + }, [amount, depositQuery.balance, setError, clearErrors]); + const depositedLpTokensDecimalAmount = depositQuery.balance || 0; const hideCss = !mutation.isIdle ? 'hidden' : ''; @@ -46,130 +58,131 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null

Withdraw {data.token?.symbol}

-
-
-

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

-

- Balance: {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} -

-
-
-
- - - + + +
+

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

+

+ Balance: {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} +

- ) => - setValue( - 'amount', - roundNumber((Number(ev.currentTarget.value) / 100) * depositedLpTokensDecimalAmount, 4), - { - shouldDirty: true, - shouldTouch: false, - }, - ) - } - /> -
-
-
-
Amount
-
- +
+ + +
+ ) => + setValue( + 'amount', + roundNumber((Number(ev.currentTarget.value) / 100) * depositedLpTokensDecimalAmount, 4), + { + shouldDirty: true, + shouldTouch: false, + }, + ) + } + />
-
-
Deposit
-
{roundNumber(depositedLpTokensDecimalAmount)}
-
-
-
Pool share
-
- {minMax( - calcSharePercentage( - rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), - depositedLpTokensDecimalAmount, - ), - )} - % +
+
+
Amount
+
+ +
+
+
+
Deposit
+
{roundNumber(depositedLpTokensDecimalAmount)}
+
+
+
Pool share
+
+ {minMax( + calcSharePercentage( + rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), + depositedLpTokensDecimalAmount, + ), + )} + % +
-
-
-
- +
+ + + Cancel +
- - - -
- + +
); From fac7c06029dee78ee48a9139531046d6279280ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 15:32:10 -0300 Subject: [PATCH 37/58] Remove unused import --- src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index f3484a8c..c0b77589 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -30,7 +30,6 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null const { setError, clearErrors, - register, setValue, formState: { errors }, } = form; From 938a5faee3f82d6b8701b3714481cb76bbda7895 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 30 Apr 2024 18:55:08 -0300 Subject: [PATCH 38/58] Correct types for fix https://github.com/preactjs/preact/issues/4285 --- src/components/Form/From/index.tsx | 4 +- .../Selector/AssetSelector/helpers.ts | 4 +- src/hooks/spacewalk/useBridgeSettings.ts | 8 +-- src/hooks/useBuyout/index.ts | 10 ++-- src/pages/bridge/index.tsx | 4 +- .../CollatorRewards/CollatorRewards.tsx | 6 +- .../collators/CollatorRewards/helpers.ts | 6 +- src/pages/collators/dialogs/helpers.ts | 55 ++++++++++--------- src/pages/gas/GasForm.tsx | 4 +- 9 files changed, 51 insertions(+), 50 deletions(-) diff --git a/src/components/Form/From/index.tsx b/src/components/Form/From/index.tsx index f741b019..7a32ed72 100644 --- a/src/components/Form/From/index.tsx +++ b/src/components/Form/From/index.tsx @@ -1,5 +1,5 @@ import { UseFormRegisterReturn } from 'react-hook-form'; -import { StateUpdater } from 'preact/hooks'; +import { StateUpdater, Dispatch } from 'preact/hooks'; import { Asset } from 'stellar-sdk'; import { BlockchainAsset } from '../../Selector/AssetSelector/helpers'; @@ -22,7 +22,7 @@ export interface FromProps { asset: { assets?: BlockchainAsset[]; selectedAsset?: BlockchainAsset; - setSelectedAsset?: StateUpdater | StateUpdater; + setSelectedAsset?: Dispatch> | Dispatch>; assetSuffix?: string; }; description: { diff --git a/src/components/Selector/AssetSelector/helpers.ts b/src/components/Selector/AssetSelector/helpers.ts index 85741c44..4cbdf089 100644 --- a/src/components/Selector/AssetSelector/helpers.ts +++ b/src/components/Selector/AssetSelector/helpers.ts @@ -1,12 +1,12 @@ import { Asset } from 'stellar-sdk'; -import { StateUpdater } from 'preact/hooks'; +import { StateUpdater, Dispatch } from 'preact/hooks'; import { getIcon } from '../../../shared/AssetIcons'; import { OrmlTraitsAssetRegistryAssetMetadata } from '../../../hooks/useBuyout/types'; import { assetDisplayName } from '../../../helpers/spacewalk'; /* Types */ export type BlockchainAsset = Asset | OrmlTraitsAssetRegistryAssetMetadata; -export type AssetSelectorOnChange = StateUpdater; +export type AssetSelectorOnChange = Dispatch>; /* Type Guards */ export function isStellarAsset(obj?: BlockchainAsset): obj is Asset { diff --git a/src/hooks/spacewalk/useBridgeSettings.ts b/src/hooks/spacewalk/useBridgeSettings.ts index 9639eeb3..e30861d9 100644 --- a/src/hooks/spacewalk/useBridgeSettings.ts +++ b/src/hooks/spacewalk/useBridgeSettings.ts @@ -1,7 +1,7 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ import _ from 'lodash'; import { useContext, useEffect, useMemo, useState } from 'preact/compat'; -import { StateUpdater } from 'preact/hooks'; +import { StateUpdater, Dispatch } from 'preact/hooks'; import { Asset } from 'stellar-sdk'; import { useGlobalState } from '../../GlobalStateProvider'; import { convertCurrencyToStellarAsset, shouldFilterOut } from '../../helpers/spacewalk'; @@ -18,9 +18,9 @@ export interface BridgeSettings { vaultsForCurrency?: ExtendedRegistryVault[]; wrappedAssets?: Asset[]; selectedAsset?: Asset; - setSelectedAsset: StateUpdater; - setSelectedVault: StateUpdater; - setManualVaultSelection: StateUpdater; + setSelectedAsset: Dispatch>; + setSelectedVault: Dispatch>; + setManualVaultSelection: Dispatch>; } function useBridgeSettings(): BridgeSettings { diff --git a/src/hooks/useBuyout/index.ts b/src/hooks/useBuyout/index.ts index b44be8b6..cc7a756c 100644 --- a/src/hooks/useBuyout/index.ts +++ b/src/hooks/useBuyout/index.ts @@ -1,4 +1,4 @@ -import { StateUpdater, useEffect, useState } from 'preact/hooks'; +import { StateUpdater, Dispatch, useEffect, useState } from 'preact/hooks'; import { isEmpty } from 'lodash'; import { Option } from '@polkadot/types-codec'; import { Codec } from '@polkadot/types-codec/types'; @@ -25,8 +25,8 @@ export interface BuyoutSettings { handleBuyout: ( currency: OrmlTraitsAssetRegistryAssetMetadata, amount: number, - setSubmissionPending: StateUpdater, - setConfirmationDialogVisible: StateUpdater, + setSubmissionPending: Dispatch>, + setConfirmationDialogVisible: Dispatch>, isExchangeAmount: boolean, ) => void; } @@ -119,8 +119,8 @@ export const useBuyout = (): BuyoutSettings => { async function handleBuyout( currency: OrmlTraitsAssetRegistryAssetMetadata, amount: number, - setSubmissionPending: StateUpdater, - setConfirmationDialogVisible: StateUpdater, + setSubmissionPending: Dispatch>, + setConfirmationDialogVisible: Dispatch>, isExchangeAmount: boolean, ) { if (!api || !walletAccount) { diff --git a/src/pages/bridge/index.tsx b/src/pages/bridge/index.tsx index ad62cc19..10d877aa 100644 --- a/src/pages/bridge/index.tsx +++ b/src/pages/bridge/index.tsx @@ -1,5 +1,5 @@ import React from 'preact/compat'; -import { StateUpdater, useMemo, useState } from 'preact/hooks'; +import { StateUpdater, Dispatch, useMemo, useState } from 'preact/hooks'; import { Button, Card, Tabs } from 'react-daisyui'; import { Asset } from 'stellar-sdk'; import AmplitudeLogo from '../../assets/AmplitudeLogo'; @@ -21,7 +21,7 @@ enum BridgeTabs { interface BridgeContextValue { selectedAsset?: Asset; - setSelectedAsset: StateUpdater; + setSelectedAsset: Dispatch>; } export const BridgeContext = React.createContext({ setSelectedAsset: () => undefined }); diff --git a/src/pages/collators/CollatorRewards/CollatorRewards.tsx b/src/pages/collators/CollatorRewards/CollatorRewards.tsx index c1a1580b..158836ac 100644 --- a/src/pages/collators/CollatorRewards/CollatorRewards.tsx +++ b/src/pages/collators/CollatorRewards/CollatorRewards.tsx @@ -2,7 +2,7 @@ import Big from 'big.js'; import { JSX, useCallback, useEffect, useMemo, useState } from 'preact/compat'; import { Signer } from '@polkadot/types/types'; import { ApiPromise } from '@polkadot/api'; -import { StateUpdater } from 'preact/hooks'; +import { StateUpdater, Dispatch } from 'preact/hooks'; import { BTreeMap } from '@polkadot/types-codec'; import { useGlobalState } from '../../../GlobalStateProvider'; @@ -82,7 +82,7 @@ export function CollatorRewards() { unstakingDataJSON: UnstakingDataType, api: ApiPromise, tokenSymbol: string, - setTokensTipText: StateUpdater, + setTokensTipText: Dispatch>, ) { const tooltipText = await generateUnstakingTooltipText(unstakingDataJSON, api, tokenSymbol); setTokensTipText(tooltipText); @@ -93,7 +93,7 @@ export function CollatorRewards() { setUserAvailableBalanceForUnlock(tokensReadyToUnlock); } - function setUnstakingTokens(unstakingData: BTreeMap, setUnstaking: StateUpdater) { + function setUnstakingTokens(unstakingData: BTreeMap, setUnstaking: Dispatch>) { const unstakingParts: number[] = []; unstakingData.forEach((n) => unstakingParts.push(Number(n.toString()))); const allUnstakingTokens = unstakingParts.reduce((a, b) => a + b, 0); diff --git a/src/pages/collators/CollatorRewards/helpers.ts b/src/pages/collators/CollatorRewards/helpers.ts index 85a306c9..3d6a782b 100644 --- a/src/pages/collators/CollatorRewards/helpers.ts +++ b/src/pages/collators/CollatorRewards/helpers.ts @@ -1,5 +1,5 @@ import { ApiPromise } from '@polkadot/api'; -import { StateUpdater } from 'preact/hooks'; +import { StateUpdater, Dispatch } from 'preact/hooks'; import { EventRecord, ExtrinsicStatus } from '@polkadot/types/interfaces'; import { ShowToast, ToastMessage } from '../../../shared/showToast'; @@ -65,9 +65,9 @@ export const handleTransactionStatus = ( events: EventRecord[], api: ApiPromise, showToast: ShowToast, - setSubmissionPending: StateUpdater, + setSubmissionPending: Dispatch>, refreshRewards: () => void, - setUpdateEnabled: StateUpdater, + setUpdateEnabled: Dispatch>, ) => { const errors = getErrors(events, api); if (status.isInBlock) { diff --git a/src/pages/collators/dialogs/helpers.ts b/src/pages/collators/dialogs/helpers.ts index 822f199e..c181fe40 100644 --- a/src/pages/collators/dialogs/helpers.ts +++ b/src/pages/collators/dialogs/helpers.ts @@ -1,7 +1,7 @@ import { ApiPromise } from '@polkadot/api'; import { SubmittableExtrinsic } from '@polkadot/api/promise/types'; import { WalletAccount } from '@talismn/connect-wallets'; -import { StateUpdater } from 'preact/hooks'; +import { StateUpdater, Dispatch } from 'preact/hooks'; import { getErrors } from '../../../helpers/substrate'; import { ToastMessage, showToast } from '../../../shared/showToast'; @@ -9,39 +9,40 @@ export const doSubmitExtrinsic = ( api: ApiPromise, extrinsic: SubmittableExtrinsic | undefined, walletAccount: WalletAccount, - setSubmissionPending: StateUpdater, - setConfirmationDialogVisible: StateUpdater, + setSubmissionPending: Dispatch>, + setConfirmationDialogVisible: Dispatch>, hideToast?: boolean, ) => { setSubmissionPending(true); - return new Promise((resolve, reject) => - extrinsic - // eslint-disable-next-line @typescript-eslint/no-explicit-any - ?.signAndSend(walletAccount.address, { signer: walletAccount.signer as any }, (result) => { - const { status, events } = result; + return new Promise( + (resolve, reject) => + extrinsic + // eslint-disable-next-line @typescript-eslint/no-explicit-any + ?.signAndSend(walletAccount.address, { signer: walletAccount.signer as any }, (result) => { + const { status, events } = result; - const errors = getErrors(events, api); + const errors = getErrors(events, api); - if (status.isInBlock) { - if (errors.length > 0) { - const errorMessage = `Transaction failed with errors: ${errors.join('\n')}`; - showToast(ToastMessage.ERROR, errorMessage); - throw errorMessage; - } - } else if (status.isFinalized) { - setSubmissionPending(false); + if (status.isInBlock) { + if (errors.length > 0) { + const errorMessage = `Transaction failed with errors: ${errors.join('\n')}`; + showToast(ToastMessage.ERROR, errorMessage); + throw errorMessage; + } + } else if (status.isFinalized) { + setSubmissionPending(false); - if (errors.length === 0) { - setConfirmationDialogVisible(true); - resolve(); + if (errors.length === 0) { + setConfirmationDialogVisible(true); + resolve(); + } } - } - }) - .catch((error) => { - !hideToast && showToast(ToastMessage.TX_SUBMISSION_FAILED); - setSubmissionPending(false); - reject(error.message); - }), + }) + .catch((error) => { + !hideToast && showToast(ToastMessage.TX_SUBMISSION_FAILED); + setSubmissionPending(false); + reject(error.message); + }), ); }; diff --git a/src/pages/gas/GasForm.tsx b/src/pages/gas/GasForm.tsx index 71bbd51f..5569b0b3 100644 --- a/src/pages/gas/GasForm.tsx +++ b/src/pages/gas/GasForm.tsx @@ -1,4 +1,4 @@ -import { StateUpdater, useMemo } from 'preact/hooks'; +import { StateUpdater, Dispatch, useMemo } from 'preact/hooks'; import { useForm } from 'react-hook-form'; import { OrmlTraitsAssetRegistryAssetMetadata } from '../../hooks/useBuyout/types'; @@ -20,7 +20,7 @@ export type IssueFormValues = { interface GasFormProps { onSubmit: (data: IssueFormValues) => void; currencies: OrmlTraitsAssetRegistryAssetMetadata[]; - setSelectedFromToken: StateUpdater; + setSelectedFromToken: Dispatch>; selectedFromToken?: BlockchainAsset; nativeCurrency: OrmlTraitsAssetRegistryAssetMetadata; calcMin: () => { amount: string; native: number }; From 2f6893ba8bf79e2a0744810cb7e762a701a26e64 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Thu, 2 May 2024 06:54:20 -0300 Subject: [PATCH 39/58] Make balance handling more precise and strict --- src/components/Asset/Price/index.tsx | 36 ----- src/components/Loader/Form/index.tsx | 1 - src/components/Loader/index.tsx | 4 +- .../Pools/Backstop/AddLiquidity/index.tsx | 146 ++++++++++++------ .../Pools/Backstop/AddLiquidity/schema.ts | 9 -- .../Pools/Backstop/AddLiquidity/types.ts | 3 - .../Backstop/AddLiquidity/useAddLiquidity.ts | 54 +++++-- .../Backstop/WithdrawLiquidity/index.tsx | 24 +-- .../WithdrawLiquidity/useSwapPoolWithdraw.ts | 1 + .../WithdrawLiquidity/useWithdrawLiquidity.ts | 10 +- src/components/nabla/Pools/Backstop/index.tsx | 8 +- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 26 ++-- .../Swap/AddLiquidity/useAddLiquidity.ts | 8 +- .../nabla/Pools/Swap/Redeem/index.tsx | 7 +- .../nabla/Pools/Swap/Redeem/useRedeem.ts | 8 +- .../Pools/Swap/WithdrawLiquidity/index.tsx | 7 +- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 8 +- src/components/nabla/Pools/Swap/columns.tsx | 7 +- src/components/nabla/Pools/index.tsx | 2 +- src/components/nabla/Swap/From.tsx | 28 ++-- src/components/nabla/Swap/To.tsx | 12 +- src/components/nabla/Swap/index.tsx | 2 + src/components/nabla/Swap/schema.ts | 2 +- src/components/nabla/Swap/useSwapComponent.ts | 2 +- .../nabla/common/AmountSelector.tsx | 60 +++++++ src/components/nabla/common/Erc20Balance.tsx | 22 +-- .../nabla/common/NablaTokenPrice.tsx | 4 +- src/components/nabla/common/TokenAmount.tsx | 4 +- src/components/nabla/common/TokenApproval.tsx | 27 +++- .../nabla/common/TransactionProgress.tsx | 18 +-- src/hooks/nabla/useContractBalance.ts | 69 --------- src/hooks/nabla/useContractRead.ts | 2 +- src/hooks/nabla/useContractWrite.ts | 90 ++++++----- src/hooks/nabla/useErc20ContractBalance.ts | 84 ++++++++++ src/hooks/nabla/useErc20TokenApproval.ts | 30 ++-- src/shared/parseNumbers/metric.ts | 19 +++ 36 files changed, 498 insertions(+), 346 deletions(-) delete mode 100644 src/components/Asset/Price/index.tsx delete mode 100644 src/components/nabla/Pools/Backstop/AddLiquidity/schema.ts delete mode 100644 src/components/nabla/Pools/Backstop/AddLiquidity/types.ts create mode 100644 src/components/nabla/common/AmountSelector.tsx delete mode 100644 src/hooks/nabla/useContractBalance.ts create mode 100644 src/hooks/nabla/useErc20ContractBalance.ts diff --git a/src/components/Asset/Price/index.tsx b/src/components/Asset/Price/index.tsx deleted file mode 100644 index d1e33763..00000000 --- a/src/components/Asset/Price/index.tsx +++ /dev/null @@ -1,36 +0,0 @@ -import { UseQueryOptions } from '@tanstack/react-query'; -import { memo, useEffect, useState } from 'preact/compat'; -import { usePriceFetcher } from '../../../hooks/usePriceFetcher'; -import { numberLoader } from '../../Loader'; - -export type TokenPriceProps = { - address?: string; - symbol: string; - //amount?: number; - prefix?: ReactNode; - options?: UseQueryOptions; - loader?: ReactNode; - fallback?: ReactNode; -}; - -const TokenPrice = memo(({ symbol, prefix = null, loader, fallback = null }: TokenPriceProps): JSX.Element | null => { - const { pricesCache } = usePriceFetcher(); - const [price, setPrice] = useState(null); - useEffect(() => { - const run = async () => { - const p = (await pricesCache)[symbol]; - setPrice(p); - }; - run(); - }, [pricesCache, symbol]); - - const isLoading = price === null; - if (isLoading) return <>{loader} || numberLoader; - if (!price) return <>{fallback}; - return ( - - {prefix}${price} - - ); -}); -export default TokenPrice; diff --git a/src/components/Loader/Form/index.tsx b/src/components/Loader/Form/index.tsx index 8c50cc4a..543a7957 100644 --- a/src/components/Loader/Form/index.tsx +++ b/src/components/Loader/Form/index.tsx @@ -36,5 +36,4 @@ const FormLoader = ({ ); }; -export const defaultPageLoader = ; export default FormLoader; diff --git a/src/components/Loader/index.tsx b/src/components/Loader/index.tsx index 4da69ba7..beaf0bc1 100644 --- a/src/components/Loader/index.tsx +++ b/src/components/Loader/index.tsx @@ -1,3 +1,5 @@ import { Skeleton } from '../Skeleton'; -export const numberLoader = 10000; +export function NumberLoader() { + return 10000; +} diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index 336cf0bd..01973abf 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -1,11 +1,13 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; import { ChangeEvent, useEffect } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; +import { Big } from 'big.js'; + import { PoolProgress } from '../..'; -import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; +import { minMax } from '../../../../../helpers/calc'; +import { rawToDecimal } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; -import { numberLoader } from '../../../../Loader'; +import { NumberLoader } from '../../../../Loader'; import { useAddLiquidity } from './useAddLiquidity'; import { NablaInstanceBackstopPool } from '../../../../../hooks/nabla/useNablaInstance'; import { TransactionProgress } from '../../../common/TransactionProgress'; @@ -13,17 +15,17 @@ import { TokenApproval } from '../../../common/TokenApproval'; import { FormProvider } from 'react-hook-form'; import { NumberInput } from '../../../common/NumberInput'; -export type AddLiquidityProps = { +interface AddLiquidityProps { data: NablaInstanceBackstopPool; -}; +} + +function calcSharePercentage(total: Big, share: Big) { + return share.div(total).mul(new Big(100)).toNumber(); +} const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { - const { toggle, onSubmit, mutation, balanceQuery, depositQuery, decimalAmount, form } = useAddLiquidity( - data.id, - data.token.id, - data.token.decimals, - data.lpTokenDecimals, - ); + const { toggle, onSubmit, mutation, poolTokenBalance, lpTokenBalance, amountString, amountBigDecimal, form } = + useAddLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); const { setError, @@ -33,21 +35,27 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { } = form; useEffect(() => { - if (balanceQuery.balance !== undefined && decimalAmount > balanceQuery.balance) { + console.log('amountString', amountString); + console.log('amountBigDecimal', amountBigDecimal); + if (amountString.length > 0 && amountBigDecimal === undefined) { + setError('amount', { type: 'custom', message: 'Enter a proper number' }); + } + if ( + poolTokenBalance !== undefined && + amountBigDecimal !== undefined && + amountBigDecimal.gt(poolTokenBalance.preciseBigDecimal) + ) { setError('amount', { type: 'custom', message: 'Amount exceeds balance' }); } else { clearErrors('amount'); } - }, [decimalAmount, balanceQuery.balance, setError, clearErrors]); - - const balance = balanceQuery.balance || 0; - const deposit = depositQuery.balance || 0; + }, [amountString, amountBigDecimal, poolTokenBalance, setError, clearErrors]); const hideCss = !mutation.isIdle ? 'hidden' : ''; return (
- +
@@ -90,12 +116,14 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { className="bg-neutral-200 dark:bg-neutral-800 px-3 rounded-2xl" size="sm" type="button" - onClick={() => - setValue('amount', balance, { - shouldDirty: true, - shouldTouch: true, - }) - } + onClick={() => { + if (poolTokenBalance !== undefined) { + setValue('amount', poolTokenBalance.approximateStrings.atLeast2Decimals, { + shouldDirty: true, + shouldTouch: true, + }); + } + }} > MAX @@ -106,31 +134,51 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { min={0} max={100} size="sm" - value={decimalAmount ? (decimalAmount / balance) * 100 : 0} - onChange={(ev: ChangeEvent) => - setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * balance, 4), { - shouldDirty: true, - shouldTouch: false, - }) + value={ + amountBigDecimal && poolTokenBalance + ? amountBigDecimal.div(poolTokenBalance.preciseBigDecimal).toNumber() * 100 + : 0 } + onChange={(ev: ChangeEvent) => { + if (poolTokenBalance === undefined) return; + setValue( + 'amount', + new Big(ev.currentTarget.value) + .div(new Big('100')) + .mul(poolTokenBalance.preciseBigDecimal) + .toFixed(2, 0), + { + shouldDirty: true, + shouldTouch: false, + }, + ); + }} />
Total deposit
-
{depositQuery.isLoading ? numberLoader : `${roundNumber(deposit)} LP`}
+
+ {lpTokenBalance === undefined ? ( + + ) : ( + `${lpTokenBalance.approximateStrings.atLeast2Decimals} LP` + )} +
Pool Share
- {depositQuery.isLoading - ? numberLoader - : minMax( - calcSharePercentage( - rawToDecimal(data.totalSupply || 0, data.token.decimals).toNumber(), - deposit, - ), - )} + {lpTokenBalance === undefined ? ( + + ) : ( + minMax( + calcSharePercentage( + rawToDecimal(data.totalSupply, data.token.decimals), + lpTokenBalance.preciseBigDecimal, + ), + ) + )} %
@@ -142,14 +190,14 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { spender={data.id} token={data.token.id} decimals={data.token.decimals} - decimalAmount={decimalAmount} - enabled={decimalAmount > 0 && Object.keys(errors).length === 0} + decimalAmount={amountBigDecimal} + enabled={amountBigDecimal?.gt(new Big(0)) && Object.keys(errors).length === 0} > diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/schema.ts b/src/components/nabla/Pools/Backstop/AddLiquidity/schema.ts deleted file mode 100644 index 3b5af510..00000000 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/schema.ts +++ /dev/null @@ -1,9 +0,0 @@ -import * as Yup from 'yup'; -import { transformNumber } from '../../../../../helpers/yup'; -import { AddLiquidityValues } from './types'; - -const schema = Yup.object().shape({ - amount: Yup.number().positive().required().transform(transformNumber), -}); - -export default schema; diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/types.ts b/src/components/nabla/Pools/Backstop/AddLiquidity/types.ts deleted file mode 100644 index 79046f40..00000000 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/types.ts +++ /dev/null @@ -1,3 +0,0 @@ -export type AddLiquidityValues = { - amount: number; -}; diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts index ecc3b7e5..9f50e811 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts @@ -1,16 +1,26 @@ import { yupResolver } from '@hookform/resolvers/yup'; +import * as Yup from 'yup'; import { useQueryClient } from '@tanstack/react-query'; import { useForm, useWatch } from 'react-hook-form'; +import { Big } from 'big.js'; + import { cacheKeys } from '../../../../../constants/cache'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenant'; import { useModalToggle } from '../../../../../services/modal'; import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; -import schema from './schema'; -import { AddLiquidityValues } from './types'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; -import { useContractBalance } from '../../../../../hooks/nabla/useContractBalance'; +import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; +import { useMemo } from 'preact/hooks'; + +interface AddLiquidityValues { + amount: string; +} + +const schema = Yup.object().shape({ + amount: Yup.string().required(), +}); export const useAddLiquidity = ( poolAddress: string, @@ -22,16 +32,14 @@ export const useAddLiquidity = ( const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); - const balanceQuery = useContractBalance({ + const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { contractAddress: tokenAddress, decimals: poolTokenDecimals, - abi: erc20WrapperAbi, }); - const depositQuery = useContractBalance({ + const depositQuery = useErc20ContractBalance(backstopPoolAbi, { contractAddress: poolAddress, decimals: lpTokenDecimals, - abi: backstopPoolAbi, }); const form = useForm({ @@ -62,14 +70,28 @@ export const useAddLiquidity = ( mutation.mutate([decimalToRaw(variables.amount, poolTokenDecimals).toString()]), ); - const decimalAmount = - Number( - useWatch({ - control: form.control, - name: 'amount', - defaultValue: 0, - }), - ) || 0; + const amountString = useWatch({ + control: form.control, + name: 'amount', + defaultValue: '0', + }); + + const amountBigDecimal = useMemo(() => { + try { + return new Big(amountString); + } catch { + return undefined; + } + }, [amountString]); - return { form, decimalAmount, mutation, onSubmit, toggle, balanceQuery, depositQuery }; + return { + form, + amountString, + amountBigDecimal, + mutation, + poolTokenBalance: balanceQuery.balance, + lpTokenBalance: depositQuery.balance, + onSubmit, + toggle, + }; }; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index aa0d9690..f47c6480 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -7,7 +7,7 @@ import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { calcSharePercentage, getPoolSurplusNativeAmount, minMax } from '../../../../../helpers/calc'; import { prettyNumbers, rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; -import { numberLoader } from '../../../../Loader'; +import { NumberLoader } from '../../../../Loader'; import FormLoader from '../../../../Loader/Form'; import { TransactionSettingsDropdown } from '../../../../Transaction/Settings'; import { useWithdrawLiquidity } from './useWithdrawLiquidity'; @@ -18,10 +18,6 @@ import { TokenAmount } from '../../../common/TokenAmount'; import { FormProvider } from 'react-hook-form'; import { NumberInput } from '../../../common/NumberInput'; -const filter = (swapPools: NablaInstanceSwapPool[]): NablaInstanceSwapPool[] => { - return swapPools?.filter((pool) => getPoolSurplusNativeAmount(pool) > 0n); -}; - const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element | null => { const { toggle, @@ -94,7 +90,7 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element

Deposited:{' '} {depositQuery.isLoading ? ( - numberLoader + ) : (

Balance:{' '} - {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${backstopPool.token.symbol}`} + {balanceQuery.isLoading ? ( + + ) : ( + `${balanceQuery.formatted || 0} ${backstopPool.token.symbol}` + )}

@@ -117,7 +117,7 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element
Withdraw limit: - {spw.isLoading ? numberLoader : <>{prettyNumbers(withdrawLimit)} LP} + {spw.isLoading ? : <>{prettyNumbers(withdrawLimit)} LP}
)} @@ -239,7 +239,11 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element ); }; -const WithdrawLiquidity = () => { +function filter(swapPools: NablaInstanceSwapPool[]): NablaInstanceSwapPool[] { + return swapPools?.filter((pool) => getPoolSurplusNativeAmount(pool) > 0n); +} + +function WithdrawLiquidity() { const { nabla, isLoading } = useNablaInstance(); const filteredNabla = useMemo( @@ -258,6 +262,6 @@ const WithdrawLiquidity = () => { if (!filteredNabla) return <>Nothing found; return ; -}; +} export default WithdrawLiquidity; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts index 32ae8e7e..4ce2411f 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts @@ -54,6 +54,7 @@ export const useSwapPoolWithdraw = ({ [mutate, swapPoolAddress, backstopPool.token.decimals, selectedSwapPool?.token.decimals], ); + // TODO Torsten: check whether this calculation makes any sense const sharesQuery = useSharesTargetWorth( { address: swapPoolAddress, diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts index a84fd167..505979c7 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -18,7 +18,7 @@ import { useSwapPoolWithdraw } from './useSwapPoolWithdraw'; import { NablaInstance, NablaInstanceSwapPool } from '../../../../../hooks/nabla/useNablaInstance'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; -import { useContractBalance } from '../../../../../hooks/nabla/useContractBalance'; +import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; const storageSet = debounce(storageService.set, 1000); export const useWithdrawLiquidity = (nabla: NablaInstance) => { @@ -32,16 +32,14 @@ export const useWithdrawLiquidity = (nabla: NablaInstance) => { const toggle = useModalToggle(); const tokenModal = useBoolean(); - const balanceQuery = useContractBalance({ + const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { contractAddress: tokenAddress, decimals: nabla.backstopPool.token.decimals, - abi: erc20WrapperAbi, }); - const depositQuery = useContractBalance({ + const depositQuery = useErc20ContractBalance(backstopPoolAbi, { contractAddress: poolAddress, decimals: nabla.backstopPool.lpTokenDecimals, - abi: backstopPoolAbi, }); const { refetch: balanceRefetch } = balanceQuery; @@ -88,7 +86,7 @@ export const useWithdrawLiquidity = (nabla: NablaInstance) => { const isSwapPoolWithdraw = !!address && address.length > 5; const swapPoolWithdraw = useSwapPoolWithdraw({ backstopPool: nabla.backstopPool, - depositedBackstopLpTokenDecimalAmount: depositQuery.balance || 0, + depositedBackstopLpTokenDecimalAmount: depositQuery.balance?.approximateNumber ?? 0, selectedSwapPool: selectedPool, enabled: isSwapPoolWithdraw, onSuccess: onWithdrawSuccess, diff --git a/src/components/nabla/Pools/Backstop/index.tsx b/src/components/nabla/Pools/Backstop/index.tsx index d09ed9b9..b83462cd 100644 --- a/src/components/nabla/Pools/Backstop/index.tsx +++ b/src/components/nabla/Pools/Backstop/index.tsx @@ -23,7 +23,12 @@ const BackstopPoolsBody = (): JSX.Element | null => {

My pool balance

- +
@@ -45,7 +50,6 @@ const BackstopPoolsBody = (): JSX.Element | null => { onClick={() => toggle({ type: ModalTypes.WithdrawLiquidity, - props: { data: pool }, }) } > diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index 9530a80d..5169b43f 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -4,7 +4,7 @@ import { PoolProgress } from '../..'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; -import { numberLoader } from '../../../../Loader'; +import { NumberLoader } from '../../../../Loader'; import { SwapPoolColumn } from '../columns'; import { useAddLiquidity } from './useAddLiquidity'; import { TransactionProgress } from '../../../common/TransactionProgress'; @@ -61,10 +61,10 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
-

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

+

Deposited: {depositQuery.isLoading ? : `${depositQuery.formatted || 0} LP`}

Balance:{' '} - {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} + {balanceQuery.isLoading ? : `${balanceQuery.formatted || 0} ${data.token.symbol}`}

@@ -105,19 +105,21 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
Total deposit
-
{depositQuery.isLoading ? numberLoader : `${roundNumber(deposit)} ${data.token.symbol}`}
+
{depositQuery.isLoading ? : `${roundNumber(deposit)} ${data.token.symbol}`}
Pool Share
- {depositQuery.isLoading - ? numberLoader - : minMax( - calcSharePercentage( - rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), - deposit, - ), - )} + {depositQuery.isLoading ? ( + + ) : ( + minMax( + calcSharePercentage( + rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), + deposit, + ), + ) + )} %
diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index 492a7c0c..9f10874c 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -9,7 +9,7 @@ import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; import schema from './schema'; import { AddLiquidityValues } from './types'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; -import { useContractBalance } from '../../../../../hooks/nabla/useContractBalance'; +import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; export const useAddLiquidity = ( @@ -22,16 +22,14 @@ export const useAddLiquidity = ( const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); - const balanceQuery = useContractBalance({ + const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { contractAddress: tokenAddress, decimals: poolTokenDecimals, - abi: erc20WrapperAbi, }); - const depositQuery = useContractBalance({ + const depositQuery = useErc20ContractBalance(swapPoolAbi, { contractAddress: poolAddress, decimals: lpTokenDecimals, - abi: swapPoolAbi, }); const form = useForm({ diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index 71a2579e..b0167540 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -6,7 +6,7 @@ import { config } from '../../../../../config'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; -import { numberLoader } from '../../../../Loader'; +import { NumberLoader } from '../../../../Loader'; import { TransactionSettingsDropdown } from '../../../../Transaction/Settings'; import { SwapPoolColumn } from '../columns'; import { useRedeem } from './useRedeem'; @@ -57,9 +57,10 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => {
-

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

+

Deposited: {depositQuery.isLoading ? : `${depositQuery.formatted || 0} LP`}

- Balance: {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} + Balance:{' '} + {balanceQuery.isLoading ? : `${balanceQuery.formatted || 0} ${data.token.symbol}`}

diff --git a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts index 5411ac46..78224641 100644 --- a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts +++ b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts @@ -19,7 +19,7 @@ import schema from './schema'; import { RedeemLiquidityValues } from './types'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; -import { useContractBalance } from '../../../../../hooks/nabla/useContractBalance'; +import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; export const setValueProps = { @@ -47,16 +47,14 @@ export const useRedeem = (swapPoolData: SwapPoolColumn) => { const tokenAddress = swapPoolData.token.id; const backstopPoolAddress = swapPoolData.backstopPool.id; - const balanceQuery = useContractBalance({ + const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { contractAddress: tokenAddress, decimals: swapPoolData.token.decimals, - abi: erc20WrapperAbi, }); - const depositQuery = useContractBalance({ + const depositQuery = useErc20ContractBalance(swapPoolAbi, { contractAddress: poolAddress, decimals: swapPoolData.lpTokenDecimals, - abi: swapPoolAbi, }); const form = useForm({ diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index d0e3c8ab..db91c722 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -6,7 +6,7 @@ import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; -import { numberLoader } from '../../../../Loader'; +import { NumberLoader } from '../../../../Loader'; import { SwapPoolColumn } from '../columns'; import { ModalTypes } from '../Modals/types'; import { useSwapPoolWithdrawLiquidity } from './useWithdrawLiquidity'; @@ -60,9 +60,10 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null
-

Deposited: {depositQuery.isLoading ? numberLoader : `${depositQuery.formatted || 0} LP`}

+

Deposited: {depositQuery.isLoading ? : `${depositQuery.formatted || 0} LP`}

- Balance: {balanceQuery.isLoading ? numberLoader : `${balanceQuery.formatted || 0} ${data.token.symbol}`} + Balance:{' '} + {balanceQuery.isLoading ? : `${balanceQuery.formatted || 0} ${data.token.symbol}`}

diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts index e078e210..131712b1 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -11,7 +11,7 @@ import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; import schema from './schema'; import { WithdrawLiquidityValues } from './types'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; -import { useContractBalance } from '../../../../../hooks/nabla/useContractBalance'; +import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; export const useSwapPoolWithdrawLiquidity = ( @@ -24,16 +24,14 @@ export const useSwapPoolWithdrawLiquidity = ( const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); - const balanceQuery = useContractBalance({ + const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { contractAddress: tokenAddress, decimals: poolTokenDecimals, - abi: erc20WrapperAbi, }); - const depositQuery = useContractBalance({ + const depositQuery = useErc20ContractBalance(swapPoolAbi, { contractAddress: poolAddress, decimals: lpTokenDecimals, - abi: swapPoolAbi, }); const form = useForm({ diff --git a/src/components/nabla/Pools/Swap/columns.tsx b/src/components/nabla/Pools/Swap/columns.tsx index 5f9243c7..16159fa2 100644 --- a/src/components/nabla/Pools/Swap/columns.tsx +++ b/src/components/nabla/Pools/Swap/columns.tsx @@ -58,7 +58,12 @@ export const myAmountColumn: ColumnDef = { header: 'My Pool Amount', accessorKey: 'myAmount', cell: ({ row: { original } }) => ( - + ), enableSorting: false, meta: { diff --git a/src/components/nabla/Pools/index.tsx b/src/components/nabla/Pools/index.tsx index 6a3b1e22..cac37856 100644 --- a/src/components/nabla/Pools/index.tsx +++ b/src/components/nabla/Pools/index.tsx @@ -1,6 +1,6 @@ export type PoolProgressProps = { symbol: string; - amount: number; + amount: string; className?: string; }; diff --git a/src/components/nabla/Swap/From.tsx b/src/components/nabla/Swap/From.tsx index 8faa5319..4cc6feba 100644 --- a/src/components/nabla/Swap/From.tsx +++ b/src/components/nabla/Swap/From.tsx @@ -7,7 +7,7 @@ import { SwapFormValues } from './schema'; import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; import { NablaTokenPrice } from '../common/NablaTokenPrice'; -import { useContractBalance } from '../../../hooks/nabla/useContractBalance'; +import { useErc20ContractBalance } from '../../../hooks/nabla/useErc20ContractBalance'; import { NumberInput } from '../common/NumberInput'; export interface FromProps { @@ -23,12 +23,16 @@ const From = ({ tokensMap, onOpenSelector, errorMessage }: FromProps): JSX.Eleme name: 'from', }); - const token = tokensMap[from]; - const { formatted, balance } = useContractBalance({ - contractAddress: token?.id, - decimals: token?.decimals, - abi: erc20WrapperAbi, - }); + const token: NablaInstanceToken = tokensMap[from]; + const { balance } = useErc20ContractBalance( + erc20WrapperAbi, + token + ? { + contractAddress: token.id, + decimals: token.decimals, + } + : undefined, + ); const inputHasError = errorMessage !== undefined; @@ -63,17 +67,20 @@ const From = ({ tokensMap, onOpenSelector, errorMessage }: FromProps): JSX.Eleme
{balance !== undefined && ( - Balance: {formatted} + + Your Balance:{' '} + {`${balance.approximateStrings.atLeast2Decimals}${token?.symbol ? ` ${token?.symbol}` : ''}`} +
- {errorMessage !== undefined &&
{errorMessage}
}
); diff --git a/src/components/nabla/Swap/To.tsx b/src/components/nabla/Swap/To.tsx index 8fb92f98..742cc709 100644 --- a/src/components/nabla/Swap/To.tsx +++ b/src/components/nabla/Swap/To.tsx @@ -9,7 +9,7 @@ import { useTokenOutAmount } from '../../../hooks/nabla/useTokenOutAmount'; import useBoolean from '../../../hooks/useBoolean'; import { useDebouncedValue } from '../../../hooks/useDebouncedValue'; import { rawToDecimal, prettyNumbers, roundNumber } from '../../../shared/parseNumbers/metric'; -import { numberLoader } from '../../Loader'; +import { NumberLoader } from '../../Loader'; import { Skeleton } from '../../Skeleton'; import { SwapFormValues } from './schema'; import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; @@ -114,7 +114,7 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps
{loading ? ( - numberLoader + ) : value ? ( `${value}` ) : fromDecimalAmount > 0 ? ( @@ -141,7 +141,13 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps
{toToken ? : '$ -'}
- Balance: + Your balance:{' '} +
diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index 31d4f357..43260602 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -9,6 +9,7 @@ import SwapProgress from './Progress'; import To from './To'; import { useSwapComponent, UseSwapComponentProps } from './useSwapComponent'; import { AssetSelectorModal } from '../common/AssetSelectorModal'; +import Validation from '../../Form/Validation'; const Swap = (props: UseSwapComponentProps): JSX.Element | null => { const { @@ -87,6 +88,7 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { onOpenSelector={() => setModalType('to')} inputHasError={errors.to !== undefined} /> +
{/* */} ().shape({ from: Yup.string().min(5).required(), fromAmount: Yup.number().positive().required().transform(transformNumber), to: Yup.string().min(5).required(), - toAmount: Yup.number().positive().required(), + toAmount: Yup.number().required(), slippage: Yup.number().nullable().transform(transformNumber), deadline: Yup.number().nullable().transform(transformNumber), }); diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index 54083ec2..42382f25 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -118,7 +118,7 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { }; updateStorage(updated); setValue('from', updated.from); - if (updated.to && prev?.to === f) setValue('to', updated.to); + //if (updated.to && prev?.to === f) setValue('to', updated.to); if (onChange && event) onChange(updated.from, updated.to); setTokenModal(undefined); }, diff --git a/src/components/nabla/common/AmountSelector.tsx b/src/components/nabla/common/AmountSelector.tsx new file mode 100644 index 00000000..61de6cd1 --- /dev/null +++ b/src/components/nabla/common/AmountSelector.tsx @@ -0,0 +1,60 @@ +interface AmountSelectorProps { + maxBalance: bigint; + balanceDecimals: number; +} + +export function AmountSelector() { + return ( +
+
+
+ + + +
+
+ ) => + setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * balance, 4), { + shouldDirty: true, + shouldTouch: false, + }) + } + /> +
+ ); +} diff --git a/src/components/nabla/common/Erc20Balance.tsx b/src/components/nabla/common/Erc20Balance.tsx index 6fb0cd06..053747ff 100644 --- a/src/components/nabla/common/Erc20Balance.tsx +++ b/src/components/nabla/common/Erc20Balance.tsx @@ -1,18 +1,20 @@ -import { useContractBalance } from '../../../hooks/nabla/useContractBalance'; -import { numberLoader } from '../../Loader'; +import { useErc20ContractBalance } from '../../../hooks/nabla/useErc20ContractBalance'; +import { NumberLoader } from '../../Loader'; export type Erc20BalanceProps = { - address: string | undefined; - decimals: number | undefined; abi: Dict; + erc20ContractDefinition: { contractAddress: string; decimals: number; symbol?: string } | undefined; }; -export function Erc20Balance({ address, decimals, abi }: Erc20BalanceProps): JSX.Element | null { - const { isLoading, formatted, enabled } = useContractBalance({ contractAddress: address, decimals, abi }); +export function Erc20Balance({ erc20ContractDefinition, abi }: Erc20BalanceProps): JSX.Element | null { + const { isLoading, balance } = useErc20ContractBalance(abi, erc20ContractDefinition); + if (balance === undefined || erc20ContractDefinition === undefined || isLoading) return ; - if (address === undefined || decimals === undefined || !enabled) return numberLoader; + const { symbol } = erc20ContractDefinition; + const { + preciseString, + approximateStrings: { atLeast2Decimals }, + } = balance; - if (isLoading) return numberLoader; - - return {formatted ?? 0}; + return {`${atLeast2Decimals}${symbol ? ` ${symbol}` : ''}`}; } diff --git a/src/components/nabla/common/NablaTokenPrice.tsx b/src/components/nabla/common/NablaTokenPrice.tsx index e472b467..68ec80c4 100644 --- a/src/components/nabla/common/NablaTokenPrice.tsx +++ b/src/components/nabla/common/NablaTokenPrice.tsx @@ -1,6 +1,6 @@ import { getMessageCallValue } from '../../../shared/helpers'; import { rawToDecimal, prettyNumbers } from '../../../shared/parseNumbers/metric'; -import { numberLoader } from '../../Loader'; +import { NumberLoader } from '../../Loader'; import { useNablaTokenPrice } from '../../../hooks/nabla/useNablaTokenPrice'; export type TokenPriceProps = { @@ -13,7 +13,7 @@ const TOKEN_PRICE_DECIMALS = 12; export function NablaTokenPrice({ address, prefix = null, fallback = null }: TokenPriceProps): JSX.Element | null { const { data, isLoading } = useNablaTokenPrice(address); - if (isLoading) return numberLoader; + if (isLoading) return ; const price = getMessageCallValue(data); if (price === undefined) return <>{fallback}; diff --git a/src/components/nabla/common/TokenAmount.tsx b/src/components/nabla/common/TokenAmount.tsx index 638b3db0..f7f5a695 100644 --- a/src/components/nabla/common/TokenAmount.tsx +++ b/src/components/nabla/common/TokenAmount.tsx @@ -2,7 +2,7 @@ import { useSharesTargetWorth } from '../../../hooks/nabla/useSharesTargetWorth' import { useDebouncedValue } from '../../../hooks/useDebouncedValue'; import { getMessageCallValue } from '../../../shared/helpers'; import { rawToDecimal, prettyNumbers } from '../../../shared/parseNumbers/metric'; -import { numberLoader } from '../../Loader'; +import { NumberLoader } from '../../Loader'; export interface TokenAmountProps { address: string; @@ -36,7 +36,7 @@ export function TokenAmount({ }); if (lpTokenDecimalAmount && (isLoading || (!!debounce && lpTokenDecimalAmount !== debouncedAmount))) { - return loader ? numberLoader : null; + return loader ? : null; } return ( diff --git a/src/components/nabla/common/TokenApproval.tsx b/src/components/nabla/common/TokenApproval.tsx index 2551e61f..7e140247 100644 --- a/src/components/nabla/common/TokenApproval.tsx +++ b/src/components/nabla/common/TokenApproval.tsx @@ -1,9 +1,13 @@ import { Button, ButtonProps } from 'react-daisyui'; +import { Big } from 'big.js'; + import { ApprovalState, useErc20TokenApproval } from '../../../hooks/nabla/useErc20TokenApproval'; +import { useCallback } from 'preact/hooks'; +import { multiplyByPowerOfTen } from '../../../shared/parseNumbers/metric'; export type TokenApprovalProps = ButtonProps & { token: string; - decimalAmount: number; + decimalAmount: Big | undefined; /** contract address (eg. router address) */ spender: string; enabled?: boolean; @@ -23,7 +27,7 @@ export function TokenApproval({ disabled, ...rest }: TokenApprovalProps): JSX.Element | null { - const approval = useErc20TokenApproval({ + const { state, mutate } = useErc20TokenApproval({ decimalAmount, token, spender, @@ -31,11 +35,18 @@ export function TokenApproval({ decimals, }); - if (approval[0] === ApprovalState.APPROVED || !enabled) return <>{children}; + const onClick = useCallback(() => { + if (state === ApprovalState.PENDING || decimalAmount === undefined) return; + + const nativeAmount = multiplyByPowerOfTen(decimalAmount, decimals); + mutate([spender, nativeAmount.toFixed()]); + }, [state, mutate, decimalAmount, decimals, spender]); + + if (state === ApprovalState.APPROVED || !enabled) return <>{children}; - const noAccount = approval[0] === ApprovalState.NO_ACCOUNT; - const isPending = approval[0] === ApprovalState.PENDING; - const isLoading = approval[0] === ApprovalState.LOADING; + const noAccount = state === ApprovalState.NO_ACCOUNT; + const isPending = state === ApprovalState.PENDING; + const isLoading = state === ApprovalState.LOADING; return ( diff --git a/src/components/nabla/common/TransactionProgress.tsx b/src/components/nabla/common/TransactionProgress.tsx index 5b8a6bdc..c60baca0 100644 --- a/src/components/nabla/common/TransactionProgress.tsx +++ b/src/components/nabla/common/TransactionProgress.tsx @@ -3,14 +3,10 @@ import { MessageCallResult } from '@pendulum-chain/api-solang'; import { ComponentChildren } from 'preact'; import { Button } from 'react-daisyui'; import Spinner from '../../../assets/spinner'; -import { useGetTenantConfig } from '../../../hooks/useGetTenantConfig'; import { UseContractWriteResponse } from '../../../hooks/nabla/useContractWrite'; export interface TransactionProgressProps { - mutation: Pick< - UseContractWriteResponse, - 'isIdle' | 'isLoading' | 'isSuccess' | 'isError' | 'data' | 'status' | 'transaction' - >; + mutation: UseContractWriteResponse; children?: ComponentChildren; onClose: () => void; } @@ -30,7 +26,6 @@ const getErrorMessage = (data?: MessageCallResult['result']) => { }; export function TransactionProgress({ mutation, children, onClose }: TransactionProgressProps): JSX.Element | null { - const { explorer } = useGetTenantConfig(); if (mutation.isIdle) return null; const status = mutation.data?.result?.type; const isSuccess = status === 'success'; @@ -70,17 +65,6 @@ export function TransactionProgress({ mutation, children, onClose }: Transaction Close )} - {!!mutation.transaction?.hex && ( - - Transaction details - - )} ); } diff --git a/src/hooks/nabla/useContractBalance.ts b/src/hooks/nabla/useContractBalance.ts deleted file mode 100644 index b8408a18..00000000 --- a/src/hooks/nabla/useContractBalance.ts +++ /dev/null @@ -1,69 +0,0 @@ -import { MessageCallResult } from '@pendulum-chain/api-solang'; -import { UseQueryResult } from '@tanstack/react-query'; -import { useMemo } from 'preact/compat'; -import { cacheKeys } from '../../shared/constants'; -import { getMessageCallValue } from '../../shared/helpers'; -import { rawToDecimal, prettyNumbers } from '../../shared/parseNumbers/metric'; -import { useSharedState } from '../../shared/Provider'; -import { useContractRead } from './useContractRead'; - -export type UseBalanceProps = { - /** token or contract address */ - contractAddress: string | undefined; - /** account address */ - account?: string; - /** contract abi */ - abi: Dict; - /** parse decimals */ - decimals: number | undefined; -}; -export type UseBalanceResponse = Pick< - UseQueryResult, - 'refetch' | 'isLoading' -> & { - balance?: number; - formatted?: string; - enabled: boolean; -}; - -export const useContractBalance = ({ - contractAddress, - account, - abi, - decimals, -}: UseBalanceProps): UseBalanceResponse => { - const { api, address: defAddress } = useSharedState(); - const address = account || defAddress; - - const enabled = !!api && !!address; - const query = useContractRead([cacheKeys.balance, contractAddress, address], { - abi, - address: contractAddress, - method: 'balanceOf', - args: [address], - queryOptions: { - cacheTime: 120000, - staleTime: 120000, - retry: 2, - refetchOnReconnect: false, - refetchOnWindowFocus: false, - onError: console.error, - enabled, - }, - }); - - const { data } = query; - const val = useMemo(() => { - if (!data || data.result.type !== 'success') return undefined; - const value = getMessageCallValue(data); - const balance = rawToDecimal(value.toString(), decimals!).toNumber(); - return { balance, formatted: prettyNumbers(balance) }; - }, [data, decimals]); - - return { - isLoading: query.isLoading, - refetch: query.refetch, - enabled, - ...val, - }; -}; diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index e8a63238..48f29484 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -61,7 +61,7 @@ export function useContractRead( }); if (isDevelopment) { - console.log('read', 'messageCall result', method, response); + console.log('read', 'Call message result', address, method, args, response); } return response; diff --git a/src/hooks/nabla/useContractWrite.ts b/src/hooks/nabla/useContractWrite.ts index 16d2af3b..8fb2632f 100644 --- a/src/hooks/nabla/useContractWrite.ts +++ b/src/hooks/nabla/useContractWrite.ts @@ -1,9 +1,9 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ import { messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; import { Abi } from '@polkadot/api-contract'; -import { DispatchError, ExtrinsicStatus } from '@polkadot/types/interfaces'; -import { MutationOptions, useMutation } from '@tanstack/react-query'; -import { useMemo, useState } from 'preact/compat'; +import { ExtrinsicStatus } from '@polkadot/types/interfaces'; +import { MutationOptions, useMutation, UseMutationResult } from '@tanstack/react-query'; +import { useCallback, useMemo } from 'preact/compat'; import { defaultWriteLimits } from '../../shared/helpers'; import { useSharedState } from '../../shared/Provider'; @@ -23,61 +23,69 @@ export type UseContractWriteProps> = { address?: string; method: string; args?: any[]; - mutateOptions: Partial>; + mutateOptions: Partial>; }; -export const useContractWrite = >({ +export type UseContractWriteResponse = UseMutationResult & { + isReady: boolean; +}; + +export function useContractWrite>({ abi, address, method, args, mutateOptions, -}: UseContractWriteProps) => { +}: UseContractWriteProps): UseContractWriteResponse { const { api, signer, address: walletAddress } = useSharedState(); - const [transaction /* setTransaction */] = useState(); + const contractAbi = useMemo( () => (abi && api?.registry ? new Abi(abi, api.registry.getChainProperties()) : undefined), [abi, api?.registry], ); const isReady = !!contractAbi && !!address && !!api && !!walletAddress && !!signer; - const submit = async (submitArgs?: any[] | void): Promise => { - if (!isReady) throw 'Missing data'; - //setTransaction({ status: 'Pending' }); - const fnArgs = submitArgs || args || []; - const contractOptions = createWriteOptions(api); + const submit = useCallback( + async (submitArgs?: any[]): Promise => { + if (!isReady) throw 'Missing data'; + //setTransaction({ status: 'Pending' }); + const fnArgs = submitArgs || args || []; + const contractOptions = createWriteOptions(api); - if (isDevelopment) { - console.log('write', 'call message write', address, method, args, submitArgs); - console.log('write', 'limits', { ...defaultWriteLimits, ...contractOptions }); - } + if (isDevelopment) { + console.log('write', 'call message write', address, method, args, submitArgs); + console.log('write', 'limits', { ...defaultWriteLimits, ...contractOptions }); + } - const response = await messageCall({ - abi: contractAbi, - api, - callerAddress: walletAddress, - contractDeploymentAddress: address, - getSigner: () => - Promise.resolve({ - type: 'signer', - address: walletAddress, - signer, - }), - messageName: method, - messageArguments: fnArgs, - limits: { ...defaultWriteLimits, ...contractOptions }, - gasLimitTolerancePercentage: 10, // Allow 3 fold gas tolerance - }); + const response = await messageCall({ + abi: contractAbi, + api, + callerAddress: walletAddress, + contractDeploymentAddress: address, + getSigner: () => + Promise.resolve({ + type: 'signer', + address: walletAddress, + signer, + }), + messageName: method, + messageArguments: fnArgs, + limits: { ...defaultWriteLimits, ...contractOptions }, + gasLimitTolerancePercentage: 10, // Allow 3 fold gas tolerance + }); - if (isDevelopment) { - console.log('write', 'call message write response', address, method, fnArgs, response); - } + if (isDevelopment) { + console.log('write', 'call message write response', address, method, fnArgs, response); + } + + if (response?.result?.type !== 'success') throw response; + return response; + }, + [address, api, args, contractAbi, isReady, method, signer, walletAddress], + ); - if (response?.result?.type !== 'success') throw response; - return response; - }; const mutation = useMutation(submit, mutateOptions); - return { ...mutation, transaction, isReady }; -}; + return { ...mutation, isReady }; +} -export type UseContractWriteResponse = ReturnType; +// export type UseContractWriteResponse = ReturnType; diff --git a/src/hooks/nabla/useErc20ContractBalance.ts b/src/hooks/nabla/useErc20ContractBalance.ts new file mode 100644 index 00000000..e4a5836e --- /dev/null +++ b/src/hooks/nabla/useErc20ContractBalance.ts @@ -0,0 +1,84 @@ +import { Big } from 'big.js'; +import { useMemo } from 'preact/compat'; + +import { cacheKeys } from '../../shared/constants'; +import { getMessageCallValue } from '../../shared/helpers'; +import { roundToSignificantDecimals } from '../../shared/parseNumbers/metric'; +import { useSharedState } from '../../shared/Provider'; +import { UseContractResult, useContractRead } from './useContractRead'; + +export interface UseBalanceResponse { + balance: ContractBalance | undefined; + refetch: UseContractResult['refetch']; + isLoading: UseContractResult['isLoading']; +} + +export interface ContractBalance { + rawBalance: bigint; + decimals: number; + preciseBigDecimal: Big; + preciseString: string; + approximateStrings: { + atLeast2Decimals: string; + atLeast4Decimals: string; + }; + approximateNumber: number; +} + +export const useErc20ContractBalance = ( + abi: Dict, + erc20ContractDefinition: { contractAddress: string; decimals: number } | undefined, +): UseBalanceResponse => { + const { api, address } = useSharedState(); + + const contractAddress = erc20ContractDefinition?.contractAddress; + + const enabled = !!api && !!address; + const query = useContractRead([cacheKeys.balance, contractAddress, address], { + abi, + address: contractAddress, + method: 'balanceOf', + args: [address], + queryOptions: { + cacheTime: 10000, + staleTime: 10000, + retry: 2, + refetchInterval: 10000, + onError: console.error, + enabled, + }, + }); + + const { data } = query; + const balance: ContractBalance | undefined = useMemo(() => { + if (!data || data.result.type !== 'success' || erc20ContractDefinition === undefined) return undefined; + const decimals = erc20ContractDefinition.decimals; + + const balanceResponse = getMessageCallValue(data); + const rawBalanceBigInt = balanceResponse.toBigInt(); + const rawBalanceString = balanceResponse.toString(); + const preciseBigDecimal = new Big(rawBalanceString); + preciseBigDecimal.e -= decimals; + + const roundedTo2SignificantDecimals = roundToSignificantDecimals(preciseBigDecimal, 2); + const roundedTo4SignificantDecimals = roundToSignificantDecimals(preciseBigDecimal, 4); + + return { + rawBalance: rawBalanceBigInt, + decimals, + preciseBigDecimal, + preciseString: preciseBigDecimal.toFixed(), + approximateStrings: { + atLeast2Decimals: roundedTo2SignificantDecimals.toFixed(), + atLeast4Decimals: roundedTo4SignificantDecimals.toFixed(), + }, + approximateNumber: preciseBigDecimal.toNumber(), + }; + }, [data, erc20ContractDefinition]); + + return { + isLoading: query.isLoading, + refetch: query.refetch, + balance, + }; +}; diff --git a/src/hooks/nabla/useErc20TokenApproval.ts b/src/hooks/nabla/useErc20TokenApproval.ts index 5c829e36..6b7770fc 100644 --- a/src/hooks/nabla/useErc20TokenApproval.ts +++ b/src/hooks/nabla/useErc20TokenApproval.ts @@ -1,11 +1,13 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ import { useMemo, useState } from 'preact/compat'; +import { Big } from 'big.js'; + import { erc20WrapperAbi } from '../../contracts/nabla/ERC20Wrapper'; import { getMessageCallValue } from '../../shared/helpers'; -import { decimalToRaw, rawToDecimal } from '../../shared/parseNumbers/metric'; +import { rawToDecimal } from '../../shared/parseNumbers/metric'; import { useSharedState } from '../../shared/Provider'; import { useErc20TokenAllowance } from './useErc20TokenAllowance'; -import { UseContractWriteProps, useContractWrite } from './useContractWrite'; +import { UseContractWriteProps, UseContractWriteResult, useContractWrite } from './useContractWrite'; export enum ApprovalState { UNKNOWN, @@ -16,16 +18,21 @@ export enum ApprovalState { NO_ACCOUNT, } -interface UseTokenApprovalParams { +interface UseErc20TokenApprovalParams { spender: string; token: string; - decimalAmount: number; + decimalAmount: Big | undefined; enabled?: boolean; decimals: number; onError?: (err: any) => void; onSuccess?: UseContractWriteProps['mutateOptions']['onSuccess']; } +interface UseErc20TokenApprovalResult { + state: ApprovalState; + mutate: UseContractWriteResult['mutate']; +} + export function useErc20TokenApproval({ token, decimalAmount, @@ -34,10 +41,10 @@ export function useErc20TokenApproval({ decimals, onError, onSuccess, -}: UseTokenApprovalParams) { +}: UseErc20TokenApprovalParams): UseErc20TokenApprovalResult { const { address } = useSharedState(); const [pending, setPending] = useState(false); - const nativeAmount = decimalToRaw(decimalAmount, decimals); + const isEnabled = Boolean(spender && address && enabled); const { @@ -57,7 +64,6 @@ export function useErc20TokenApproval({ abi: erc20WrapperAbi, address: token, method: 'approve', - args: [spender, nativeAmount.toString()], mutateOptions: { onError: (err) => { setPending(false); @@ -76,11 +82,11 @@ export function useErc20TokenApproval({ const allowanceValue = getMessageCallValue(allowanceData); const allowanceDecimalAmount = useMemo( - () => (allowanceValue !== undefined ? rawToDecimal(allowanceValue.toString(), decimals).toNumber() : undefined), + () => (allowanceValue !== undefined ? rawToDecimal(allowanceValue.toString(), decimals) : undefined), [allowanceValue, decimals], ); - return useMemo<[ApprovalState, typeof mutation]>(() => { + return useMemo(() => { let state = ApprovalState.UNKNOWN; if (address === undefined) state = ApprovalState.NO_ACCOUNT; @@ -89,18 +95,18 @@ export function useErc20TokenApproval({ else if ( allowanceDecimalAmount !== undefined && decimalAmount !== undefined && - allowanceDecimalAmount >= decimalAmount + allowanceDecimalAmount.gte(decimalAmount) ) { state = ApprovalState.APPROVED; } else if (pending || mutation.isLoading) state = ApprovalState.PENDING; else if ( allowanceDecimalAmount !== undefined && decimalAmount !== undefined && - allowanceDecimalAmount < decimalAmount + allowanceDecimalAmount.lt(decimalAmount) ) { state = ApprovalState.NOT_APPROVED; } - return [state, mutation]; + return { state, mutate: mutation.mutate }; }, [allowanceDecimalAmount, decimalAmount, mutation, isAllowanceLoading, pending, address]); } diff --git a/src/shared/parseNumbers/metric.ts b/src/shared/parseNumbers/metric.ts index b830585f..9a5d70fd 100644 --- a/src/shared/parseNumbers/metric.ts +++ b/src/shared/parseNumbers/metric.ts @@ -119,5 +119,24 @@ export const roundNumber = (value: number | string = 0, round = 6) => { return +Number(value).toFixed(round); }; +// Round a number to a specified number of decimals +// If the number is small, ensure that the required number of significant +// decimals is retained +// e.g., if decimals = 2, then +// - 12345 -> 12345 +// - 12.345 -> 12.34 +// - 1.2345 -> 1.23 +// - 0.012345 -> 0.012 +// - 0.00012345 -> 0.00012 +export function roundToSignificantDecimals(big: BigNumber, decimals: number) { + return big.prec(Math.max(0, big.e + 1) + decimals, 0); +} + +export function multiplyByPowerOfTen(bigDecimal: BigNumber, power: number) { + const newBigDecimal = new BigNumber(bigDecimal); + newBigDecimal.e += power; + return newBigDecimal; +} + /** Calculate deadline from minutes */ export const calcDeadline = (min: number) => `${Math.floor(Date.now() / 1000) + min * 60}`; From 2ca45df27e55cf5339af8e71e0f1ff398d7ae046 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Fri, 3 May 2024 06:11:08 -0300 Subject: [PATCH 40/58] Create AmountSelector component --- .../Pools/Backstop/AddLiquidity/index.tsx | 34 ++---- .../Backstop/WithdrawLiquidity/index.tsx | 2 +- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 6 +- .../nabla/Pools/Swap/Redeem/index.tsx | 2 +- .../Pools/Swap/WithdrawLiquidity/index.tsx | 2 +- .../nabla/common/AmountSelector.tsx | 115 ++++++++++++++---- src/components/nabla/common/TokenApproval.tsx | 1 - src/hooks/nabla/useContractRead.ts | 46 +++---- src/hooks/nabla/useErc20ContractBalance.ts | 23 ++-- src/hooks/nabla/useErc20TokenApproval.ts | 4 +- src/shared/helpers.ts | 2 - src/shared/parseNumbers/metric.ts | 4 +- src/shared/useAccountBalance.ts | 17 ++- 13 files changed, 152 insertions(+), 106 deletions(-) diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index 01973abf..d5acfabe 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -1,6 +1,5 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; -import { ChangeEvent, useEffect } from 'preact/compat'; -import { Button, Range } from 'react-daisyui'; +import { Button } from 'react-daisyui'; import { Big } from 'big.js'; import { PoolProgress } from '../..'; @@ -13,7 +12,7 @@ import { NablaInstanceBackstopPool } from '../../../../../hooks/nabla/useNablaIn import { TransactionProgress } from '../../../common/TransactionProgress'; import { TokenApproval } from '../../../common/TokenApproval'; import { FormProvider } from 'react-hook-form'; -import { NumberInput } from '../../../common/NumberInput'; +import { AmountSelector } from '../../../common/AmountSelector'; interface AddLiquidityProps { data: NablaInstanceBackstopPool; @@ -28,29 +27,9 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { useAddLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); const { - setError, - clearErrors, - setValue, formState: { errors }, } = form; - useEffect(() => { - console.log('amountString', amountString); - console.log('amountBigDecimal', amountBigDecimal); - if (amountString.length > 0 && amountBigDecimal === undefined) { - setError('amount', { type: 'custom', message: 'Enter a proper number' }); - } - if ( - poolTokenBalance !== undefined && - amountBigDecimal !== undefined && - amountBigDecimal.gt(poolTokenBalance.preciseBigDecimal) - ) { - setError('amount', { type: 'custom', message: 'Amount exceeds balance' }); - } else { - clearErrors('amount'); - } - }, [amountString, amountBigDecimal, poolTokenBalance, setError, clearErrors]); - const hideCss = !mutation.isIdle ? 'hidden' : ''; return (
@@ -88,7 +67,8 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {

-
+ + {/*
{ ); }} /> -
+
*/}
Total deposit
@@ -183,8 +163,8 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
+
- { >
+
-
+
- { >
+
- diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index db91c722..93f2992a 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -152,8 +152,8 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null
+
-
@@ -31,29 +96,33 @@ export function AmountSelector() { className="bg-neutral-200 dark:bg-neutral-800 px-3 rounded-2xl" size="sm" type="button" - onClick={() => - setValue('amount', balance, { - shouldDirty: true, - shouldTouch: true, - }) - } + onClick={() => { + if (maxBalance !== undefined) { + setValue(formFieldName, fractionOfValue(maxBalance.preciseBigDecimal, 100) as K, { + shouldDirty: true, + shouldTouch: true, + }); + } + }} > MAX
) => - setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * balance, 4), { + disabled={maxBalance === undefined} + value={amountBigDecimal && maxBalance ? amountBigDecimal.div(maxBalance.preciseBigDecimal).toNumber() * 100 : 0} + onChange={(ev: ChangeEvent) => { + if (maxBalance === undefined) return; + setValue(formFieldName, fractionOfValue(maxBalance.preciseBigDecimal, Number(ev.currentTarget.value)) as K, { shouldDirty: true, shouldTouch: false, - }) - } + }); + }} />
); diff --git a/src/components/nabla/common/TokenApproval.tsx b/src/components/nabla/common/TokenApproval.tsx index 7e140247..66bdeb08 100644 --- a/src/components/nabla/common/TokenApproval.tsx +++ b/src/components/nabla/common/TokenApproval.tsx @@ -31,7 +31,6 @@ export function TokenApproval({ decimalAmount, token, spender, - enabled, decimals, }); diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index 48f29484..c9fa4c91 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -4,7 +4,7 @@ import { Abi } from '@polkadot/api-contract'; import { QueryKey, useQuery, UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; -import { defaultReadLimits, emptyCacheKey, emptyFn, QueryOptions } from '../../shared/helpers'; +import { defaultReadLimits, emptyCacheKey, QueryOptions } from '../../shared/helpers'; import { useSharedState } from '../../shared/Provider'; import { config } from '../../config'; @@ -41,32 +41,32 @@ export function useContractRead( const enabled = !!contractAbi && queryOptions.enabled !== false && !!address && !!api && !!actualWalletAddress; const query = useQuery( enabled ? key : emptyCacheKey, - enabled - ? async () => { - const limits = defaultReadLimits; + async () => { + if (!enabled) return; - if (isDevelopment) { - console.log('read', 'Call message', address, method, args); - } + const limits = defaultReadLimits; - const response = await messageCall({ - abi: contractAbi, - api, - callerAddress: actualWalletAddress, - contractDeploymentAddress: address, - getSigner: () => Promise.resolve({} as any), // TODO: cleanup in api-solang lib - messageName: method, - messageArguments: args || [], - limits, - }); + if (isDevelopment) { + console.log('read', 'Call message', address, method, args); + } - if (isDevelopment) { - console.log('read', 'Call message result', address, method, args, response); - } + const response = await messageCall({ + abi: contractAbi, + api, + callerAddress: actualWalletAddress, + contractDeploymentAddress: address, + getSigner: () => Promise.resolve({} as any), // TODO: cleanup in api-solang lib + messageName: method, + messageArguments: args || [], + limits, + }); - return response; - } - : emptyFn, + if (isDevelopment) { + console.log('read', 'Call message result', address, method, args, response); + } + + return response; + }, { ...queryOptions, enabled, diff --git a/src/hooks/nabla/useErc20ContractBalance.ts b/src/hooks/nabla/useErc20ContractBalance.ts index e4a5836e..b7d9f4c1 100644 --- a/src/hooks/nabla/useErc20ContractBalance.ts +++ b/src/hooks/nabla/useErc20ContractBalance.ts @@ -3,7 +3,7 @@ import { useMemo } from 'preact/compat'; import { cacheKeys } from '../../shared/constants'; import { getMessageCallValue } from '../../shared/helpers'; -import { roundToSignificantDecimals } from '../../shared/parseNumbers/metric'; +import { multiplyByPowerOfTen, roundDownToSignificantDecimals } from '../../shared/parseNumbers/metric'; import { useSharedState } from '../../shared/Provider'; import { UseContractResult, useContractRead } from './useContractRead'; @@ -49,19 +49,20 @@ export const useErc20ContractBalance = ( }, }); + const decimals = erc20ContractDefinition?.decimals; + const { data } = query; + const balanceResponse = getMessageCallValue(data); + const rawBalanceBigInt = balanceResponse?.toBigInt(); + const balance: ContractBalance | undefined = useMemo(() => { - if (!data || data.result.type !== 'success' || erc20ContractDefinition === undefined) return undefined; - const decimals = erc20ContractDefinition.decimals; + if (rawBalanceBigInt === undefined || decimals === undefined) return undefined; - const balanceResponse = getMessageCallValue(data); - const rawBalanceBigInt = balanceResponse.toBigInt(); - const rawBalanceString = balanceResponse.toString(); - const preciseBigDecimal = new Big(rawBalanceString); - preciseBigDecimal.e -= decimals; + const rawBalanceString = rawBalanceBigInt.toString(); + const preciseBigDecimal = multiplyByPowerOfTen(new Big(rawBalanceString), -decimals); - const roundedTo2SignificantDecimals = roundToSignificantDecimals(preciseBigDecimal, 2); - const roundedTo4SignificantDecimals = roundToSignificantDecimals(preciseBigDecimal, 4); + const roundedTo2SignificantDecimals = roundDownToSignificantDecimals(preciseBigDecimal, 2); + const roundedTo4SignificantDecimals = roundDownToSignificantDecimals(preciseBigDecimal, 4); return { rawBalance: rawBalanceBigInt, @@ -74,7 +75,7 @@ export const useErc20ContractBalance = ( }, approximateNumber: preciseBigDecimal.toNumber(), }; - }, [data, erc20ContractDefinition]); + }, [rawBalanceBigInt, decimals]); return { isLoading: query.isLoading, diff --git a/src/hooks/nabla/useErc20TokenApproval.ts b/src/hooks/nabla/useErc20TokenApproval.ts index 6b7770fc..e426dca8 100644 --- a/src/hooks/nabla/useErc20TokenApproval.ts +++ b/src/hooks/nabla/useErc20TokenApproval.ts @@ -22,7 +22,6 @@ interface UseErc20TokenApprovalParams { spender: string; token: string; decimalAmount: Big | undefined; - enabled?: boolean; decimals: number; onError?: (err: any) => void; onSuccess?: UseContractWriteProps['mutateOptions']['onSuccess']; @@ -37,7 +36,6 @@ export function useErc20TokenApproval({ token, decimalAmount, spender, - enabled = true, decimals, onError, onSuccess, @@ -45,7 +43,7 @@ export function useErc20TokenApproval({ const { address } = useSharedState(); const [pending, setPending] = useState(false); - const isEnabled = Boolean(spender && address && enabled); + const isEnabled = Boolean(spender && address); const { data: allowanceData, diff --git a/src/shared/helpers.ts b/src/shared/helpers.ts index 610bd7a6..189971ff 100644 --- a/src/shared/helpers.ts +++ b/src/shared/helpers.ts @@ -5,8 +5,6 @@ import type { QueryKey, UseQueryOptions } from '@tanstack/react-query'; export type QueryOptions = Partial< Omit, 'queryKey' | 'queryFn'> >; - -export const emptyFn = () => undefined; export const emptyCacheKey = ['']; export const defaultReadLimits: Limits = { diff --git a/src/shared/parseNumbers/metric.ts b/src/shared/parseNumbers/metric.ts index 9a5d70fd..65d11455 100644 --- a/src/shared/parseNumbers/metric.ts +++ b/src/shared/parseNumbers/metric.ts @@ -128,12 +128,14 @@ export const roundNumber = (value: number | string = 0, round = 6) => { // - 1.2345 -> 1.23 // - 0.012345 -> 0.012 // - 0.00012345 -> 0.00012 -export function roundToSignificantDecimals(big: BigNumber, decimals: number) { +export function roundDownToSignificantDecimals(big: BigNumber, decimals: number) { return big.prec(Math.max(0, big.e + 1) + decimals, 0); } export function multiplyByPowerOfTen(bigDecimal: BigNumber, power: number) { const newBigDecimal = new BigNumber(bigDecimal); + if (newBigDecimal.c[0] === 0) return newBigDecimal; + newBigDecimal.e += power; return newBigDecimal; } diff --git a/src/shared/useAccountBalance.ts b/src/shared/useAccountBalance.ts index 9f533d70..e32eefc0 100644 --- a/src/shared/useAccountBalance.ts +++ b/src/shared/useAccountBalance.ts @@ -2,7 +2,7 @@ import { FrameSystemAccountInfo } from '@polkadot/types/lookup'; import { useQuery, UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; import { cacheKeys } from './constants'; -import { emptyCacheKey, emptyFn, QueryOptions } from './helpers'; +import { emptyCacheKey, QueryOptions } from './helpers'; import { nativeToDecimal, prettyNumbers } from './parseNumbers/metric'; import { useSharedState } from './Provider'; @@ -24,14 +24,13 @@ export const useAccountBalance = ( const enabled = !!api && !!accountAddress && options?.enabled !== false; const query = useQuery( enabled ? [cacheKeys.accountBalance, accountAddress] : emptyCacheKey, - enabled - ? async () => { - const response = await api.query.system.account(accountAddress); - const val = response?.data?.free; - if (!isValid(val)) throw new Error('Error!'); - return response; - } - : emptyFn, + async () => { + if (!enabled) return undefined; + const response = await api.query.system.account(accountAddress); + const val = response?.data?.free; + if (!isValid(val)) throw new Error('Error!'); + return response; + }, { cacheTime: 0, staleTime: 0, From 7be36683bbf1e675e5385f961fd48498f3caa583 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Wed, 8 May 2024 09:10:48 -0300 Subject: [PATCH 41/58] Massively update amount and big number logic --- .../Layout/NavCollapseButtonContent.tsx | 36 ++--- .../Pools/Backstop/AddLiquidity/index.tsx | 23 +-- .../Backstop/WithdrawLiquidity/index.tsx | 10 +- .../WithdrawLiquidity/useSwapPoolWithdraw.ts | 23 +-- src/components/nabla/Pools/Backstop/index.tsx | 9 +- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 9 +- .../nabla/Pools/Swap/Redeem/index.tsx | 7 +- .../Pools/Swap/WithdrawLiquidity/index.tsx | 143 +++++------------- .../Pools/Swap/WithdrawLiquidity/schema.ts | 8 - .../Pools/Swap/WithdrawLiquidity/types.ts | 3 - .../WithdrawLiquidity/useWithdrawLiquidity.ts | 70 ++++++--- src/components/nabla/Pools/Swap/columns.tsx | 8 +- src/components/nabla/Swap/ApprovalSubmit.tsx | 3 +- src/components/nabla/Swap/From.tsx | 8 +- src/components/nabla/Swap/To.tsx | 102 ++++++------- src/components/nabla/Swap/index.tsx | 2 +- src/components/nabla/Swap/schema.ts | 8 +- src/components/nabla/Swap/useSwapComponent.ts | 12 +- .../nabla/common/AmountSelector.tsx | 20 +-- src/components/nabla/common/Erc20Balance.tsx | 2 +- .../nabla/common/NablaTokenPrice.tsx | 9 +- src/components/nabla/common/TokenAmount.tsx | 21 ++- src/components/nabla/common/TokenBalance.tsx | 24 +++ src/constants/cache.ts | 1 + src/helpers/__tests__/calc.test.ts | 12 +- src/helpers/calc.ts | 23 +-- src/helpers/contracts.ts | 47 ++++++ src/hooks/nabla/useContractRead.ts | 53 ++++--- src/hooks/nabla/useErc20ContractBalance.ts | 70 +-------- src/hooks/nabla/useErc20TokenAllowance.ts | 9 +- src/hooks/nabla/useErc20TokenApproval.ts | 21 +-- src/hooks/nabla/useNablaTokenPrice.ts | 7 +- src/hooks/nabla/useQuoteSwapPoolWithdraw.ts | 91 +++++++++++ src/hooks/nabla/useSharesTargetWorth.ts | 9 +- src/hooks/nabla/useTokenOutAmount.ts | 60 ++++++-- src/shared/helpers.ts | 11 +- src/shared/parseNumbers/metric.ts | 16 ++ 37 files changed, 544 insertions(+), 446 deletions(-) delete mode 100644 src/components/nabla/Pools/Swap/WithdrawLiquidity/schema.ts delete mode 100644 src/components/nabla/Pools/Swap/WithdrawLiquidity/types.ts create mode 100644 src/components/nabla/common/TokenBalance.tsx create mode 100644 src/helpers/contracts.ts create mode 100644 src/hooks/nabla/useQuoteSwapPoolWithdraw.ts diff --git a/src/components/Layout/NavCollapseButtonContent.tsx b/src/components/Layout/NavCollapseButtonContent.tsx index f0d493d7..5d7368a8 100644 --- a/src/components/Layout/NavCollapseButtonContent.tsx +++ b/src/components/Layout/NavCollapseButtonContent.tsx @@ -8,20 +8,22 @@ interface NavButtonContentProps { isPlaying: boolean; } -export const NavCollapseButtonContent: React.FC = ({ item, isPlaying }) => ( - <> - {isLottieOptions(item.prefix) ? ( - - ) : ( - item.prefix - )} - {isLottieOptions(item.title) ? ( - - - - ) : ( - {item.title} - )} - {item.suffix} - -); +export const NavCollapseButtonContent: React.FC = ({ item, isPlaying }) => { + return ( + <> + {isLottieOptions(item.prefix) ? ( + + ) : ( + item.prefix + )} + {isLottieOptions(item.title) ? ( + + + + ) : ( + {item.title} + )} + {item.suffix} + + ); +}; diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index d5acfabe..a0277372 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -3,8 +3,7 @@ import { Button } from 'react-daisyui'; import { Big } from 'big.js'; import { PoolProgress } from '../..'; -import { minMax } from '../../../../../helpers/calc'; -import { rawToDecimal } from '../../../../../shared/parseNumbers/metric'; +import { rawToDecimal, stringifyBigWithSignificantDecimals } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; import { NumberLoader } from '../../../../Loader'; import { useAddLiquidity } from './useAddLiquidity'; @@ -13,15 +12,12 @@ import { TransactionProgress } from '../../../common/TransactionProgress'; import { TokenApproval } from '../../../common/TokenApproval'; import { FormProvider } from 'react-hook-form'; import { AmountSelector } from '../../../common/AmountSelector'; +import { calcSharePercentage } from '../../../../../helpers/calc'; interface AddLiquidityProps { data: NablaInstanceBackstopPool; } -function calcSharePercentage(total: Big, share: Big) { - return share.div(total).mul(new Big(100)).toNumber(); -} - const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { const { toggle, onSubmit, mutation, poolTokenBalance, lpTokenBalance, amountString, amountBigDecimal, form } = useAddLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); @@ -30,6 +26,8 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { formState: { errors }, } = form; + const totalSupplyOfLpTokens = rawToDecimal(data.totalSupply, data.token.decimals); + const hideCss = !mutation.isIdle ? 'hidden' : ''; return (
@@ -139,11 +137,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
Total deposit
- {lpTokenBalance === undefined ? ( - - ) : ( - `${lpTokenBalance.approximateStrings.atLeast2Decimals} LP` - )} + {stringifyBigWithSignificantDecimals(totalSupplyOfLpTokens, 2)} {data.symbol}
@@ -152,12 +146,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { {lpTokenBalance === undefined ? ( ) : ( - minMax( - calcSharePercentage( - rawToDecimal(data.totalSupply, data.token.decimals), - lpTokenBalance.preciseBigDecimal, - ), - ) + calcSharePercentage(totalSupplyOfLpTokens, lpTokenBalance.preciseBigDecimal) )} %
diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index 0dd6d9e2..7131f3eb 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -4,7 +4,7 @@ import { ChangeEvent, useEffect, useMemo } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; -import { calcSharePercentage, getPoolSurplusNativeAmount, minMax } from '../../../../../helpers/calc'; +import { calcSharePercentage, getPoolSurplusNativeAmount } from '../../../../../helpers/calc'; import { prettyNumbers, rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; import { NumberLoader } from '../../../../Loader'; @@ -197,11 +197,9 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element
Pool share
- {minMax( - calcSharePercentage( - rawToDecimal(backstopPool.totalSupply || 0, backstopPool.lpTokenDecimals).toNumber(), - depositedBackstopLpTokenDecimalAmount, - ), + {calcSharePercentage( + rawToDecimal(backstopPool.totalSupply || 0, backstopPool.lpTokenDecimals).toNumber(), + depositedBackstopLpTokenDecimalAmount, )} %
diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts index 4ce2411f..c6d579b4 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts @@ -4,7 +4,6 @@ import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { calcAvailablePoolWithdraw, subtractPercentage } from '../../../../../helpers/calc'; import { getValidSlippage } from '../../../../../helpers/transaction'; import { useSharesTargetWorth } from '../../../../../hooks/nabla/useSharesTargetWorth'; -import { getMessageCallValue } from '../../../../../shared/helpers'; import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; import { WithdrawLiquidityValues } from './types'; import { NablaInstanceBackstopPool, NablaInstanceSwapPool } from '../../../../../hooks/nabla/useNablaInstance'; @@ -59,31 +58,35 @@ export const useSwapPoolWithdraw = ({ { address: swapPoolAddress, lpTokenDecimalAmount: depositedBackstopLpTokenDecimalAmount, - abi: backstopPoolAbi, lpTokenDecimals: backstopPool.lpTokenDecimals, + poolTokenDecimals: backstopPool.token.decimals, + abi: backstopPoolAbi, }, enabled, ); - const sharesWorthNativeAmount = getMessageCallValue(sharesQuery.data); const bpPriceQuery = useNablaTokenPrice(backstopPool.token.id, enabled); const spPriceQuery = useNablaTokenPrice(selectedSwapPool?.token.id, enabled); - const bpPrice = getMessageCallValue(bpPriceQuery.data); - const spPrice = getMessageCallValue(spPriceQuery.data); + // TODO Torsen: also check this const withdrawLimitDecimalAmount = useMemo( () => selectedSwapPool ? calcAvailablePoolWithdraw({ selectedSwapPool, backstopLpDecimalAmount: depositedBackstopLpTokenDecimalAmount, - sharesWorthNativeAmount, - bpPrice: bpPrice ? BigInt(bpPrice) : undefined, - spPrice: spPrice ? BigInt(spPrice) : undefined, - backstopPoolTokenDecimals: backstopPool.token.decimals, + sharesValueDecimalAmount: sharesQuery.data?.preciseBigDecimal, + bpPrice: bpPriceQuery.data?.rawBalance, + spPrice: spPriceQuery.data?.rawBalance, swapPoolTokenDecimals: selectedSwapPool.token.decimals, }) : 0, - [selectedSwapPool, backstopPool, depositedBackstopLpTokenDecimalAmount, sharesWorthNativeAmount, bpPrice, spPrice], + [ + selectedSwapPool, + sharesQuery.data?.preciseBigDecimal, + depositedBackstopLpTokenDecimalAmount, + bpPriceQuery.data?.rawBalance, + spPriceQuery.data?.rawBalance, + ], ); return { diff --git a/src/components/nabla/Pools/Backstop/index.tsx b/src/components/nabla/Pools/Backstop/index.tsx index b83462cd..85990427 100644 --- a/src/components/nabla/Pools/Backstop/index.tsx +++ b/src/components/nabla/Pools/Backstop/index.tsx @@ -15,6 +15,7 @@ const BackstopPoolsBody = (): JSX.Element | null => { const pool = nabla?.backstopPool; if (!pool) return

No backstop pools

; + // TODO Torsten: also show the complete share and the percentage here return ( <>
@@ -24,10 +25,12 @@ const BackstopPoolsBody = (): JSX.Element | null => {

My pool balance

diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index 4b5649bd..29c335bf 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -1,7 +1,7 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; import { Button } from 'react-daisyui'; import { PoolProgress } from '../..'; -import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; +import { calcSharePercentage } from '../../../../../helpers/calc'; import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; import { NumberLoader } from '../../../../Loader'; @@ -113,12 +113,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { {depositQuery.isLoading ? ( ) : ( - minMax( - calcSharePercentage( - rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), - deposit, - ), - ) + calcSharePercentage(rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), deposit) )} %
diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index 474d722d..2e890c4d 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -3,7 +3,7 @@ import { ChangeEvent, useEffect } from 'preact/compat'; import { Button, Range } from 'react-daisyui'; import { PoolProgress } from '../..'; import { config } from '../../../../../config'; -import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; +import { calcSharePercentage } from '../../../../../helpers/calc'; import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; import { NumberLoader } from '../../../../Loader'; @@ -131,10 +131,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => {
Pool share
- {minMax( - calcSharePercentage(rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), deposit), - )} - % + {calcSharePercentage(rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), deposit)}%
diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index 93f2992a..c32e440b 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -1,54 +1,44 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; -import { ChangeEvent, useEffect } from 'preact/compat'; -import { Button, Range } from 'react-daisyui'; +import { Button } from 'react-daisyui'; + import { PoolProgress } from '../..'; -import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; -import { calcSharePercentage, minMax } from '../../../../../helpers/calc'; -import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; +import { calcSharePercentage } from '../../../../../helpers/calc'; +import { rawToDecimal, stringifyBigWithSignificantDecimals } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; import { NumberLoader } from '../../../../Loader'; import { SwapPoolColumn } from '../columns'; import { ModalTypes } from '../Modals/types'; import { useSwapPoolWithdrawLiquidity } from './useWithdrawLiquidity'; import { TransactionProgress } from '../../../common/TransactionProgress'; -import { TokenAmount } from '../../../common/TokenAmount'; import { FormProvider } from 'react-hook-form'; -import { NumberInput } from '../../../common/NumberInput'; +import { AmountSelector } from '../../../common/AmountSelector'; +import { TokenBalance } from '../../../common/TokenBalance'; +import Spinner from '../../../../../assets/spinner'; export interface WithdrawLiquidityProps { data: SwapPoolColumn; } const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null => { - const { toggle, mutation, onSubmit, balanceQuery, depositQuery, amount, form } = useSwapPoolWithdrawLiquidity( - data.id, - data.token.id, - data.token.decimals, - data.lpTokenDecimals, - ); + const { toggle, mutation, onSubmit, balanceQuery, depositQuery, amountString, form, withdrawalQuote } = + useSwapPoolWithdrawLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); const { - setError, - clearErrors, - setValue, formState: { errors }, } = form; - useEffect(() => { - if (depositQuery.balance !== undefined && amount > depositQuery.balance) { - setError('amount', { type: 'custom', message: 'Amount exceeds owned LP tokens' }); - } else { - clearErrors('amount'); - } - }, [amount, depositQuery.balance, setError, clearErrors]); + const totalSupplyOfLpTokens = rawToDecimal(data.totalSupply, data.token.decimals); + + const submitEnabled = !withdrawalQuote.isLoading && withdrawalQuote.enabled && Object.keys(errors).length === 0; - const depositedLpTokensDecimalAmount = depositQuery.balance || 0; + const lpTokenBalance = depositQuery.data; + // TODO Torsten: show spinner on withdraw button when loading the share value?? const hideCss = !mutation.isIdle ? 'hidden' : ''; return (
- +
@@ -60,93 +50,33 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null
-

Deposited: {depositQuery.isLoading ? : `${depositQuery.formatted || 0} LP`}

+

+ Deposited: +

- Balance:{' '} - {balanceQuery.isLoading ? : `${balanceQuery.formatted || 0} ${data.token.symbol}`} + Balance:

-
-
- - - + +
+
Share Value
+
- ) => - setValue( - 'amount', - roundNumber((Number(ev.currentTarget.value) / 100) * depositedLpTokensDecimalAmount, 4), - { - shouldDirty: true, - shouldTouch: false, - }, - ) - } - /> -
+
-
Amount
+
Total deposit
- + {stringifyBigWithSignificantDecimals(totalSupplyOfLpTokens, 2)} {data.symbol}
-
Deposit
-
{roundNumber(depositedLpTokensDecimalAmount)}
-
-
-
Pool share
+
Your pool share
- {minMax( - calcSharePercentage( - rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), - depositedLpTokensDecimalAmount, - ), + {lpTokenBalance === undefined ? ( + + ) : ( + calcSharePercentage(totalSupplyOfLpTokens, lpTokenBalance.preciseBigDecimal) )} %
@@ -168,8 +98,15 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null Redeem from backstop pool
- @@ -143,10 +132,10 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps
Your balance:{' '}
@@ -158,8 +147,11 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps >
- {fromToken && toToken && value && fromDecimalAmount && !loading ? ( - <>{`1 ${fromToken.symbol} = ${roundNumber(Number(value) / fromDecimalAmount, 6)} ${toToken.symbol}`} + {fromToken && toToken && tokenOutAmount && debouncedFromDecimalAmount && !loading ? ( + <>{`1 ${fromToken.symbol} = ${stringifyBigWithSignificantDecimals( + tokenOutAmount.amountOut.preciseBigDecimal.div(debouncedFromDecimalAmount), + 6, + )} ${toToken.symbol}`} ) : ( `- ${toToken?.symbol || ''}` )} @@ -177,23 +169,27 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps
Expected Output:
- - {value} {toToken?.symbol || ''} + + {tokenOutAmount?.amountOut.approximateStrings.atLeast2Decimals} {toToken?.symbol || ''}
Minimum received after slippage ({slippage}%)
- - {subtractPercentage(Number(value), slippage)} {toToken?.symbol || ''} + + {tokenOutAmount !== undefined + ? subtractBigDecimalPercentage(tokenOutAmount.amountOut.preciseBigDecimal, slippage) + : ''}{' '} + {toToken?.symbol || ''}
Swap fee:
- {swapFee !== undefined ? prettyNumbers(swapFee) : ''} {toToken?.symbol || ''} + {tokenOutAmount !== undefined ? tokenOutAmount.swapFee.approximateStrings.atLeast2Decimals : ''}{' '} + {toToken?.symbol || ''}
diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index 43260602..06cd9835 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -36,7 +36,7 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { const progressUi = useMemo(() => { if (swapMutation?.isIdle) return null; - const { from: fromV, to: toV, fromAmount = 0, toAmount = 0 } = getValues(); + const { from: fromV, to: toV, fromAmount = '0', toAmount = '0' } = getValues(); const fromAsset = tokensMap[fromV]; const toAsset = tokensMap[toV]; return ( diff --git a/src/components/nabla/Swap/schema.ts b/src/components/nabla/Swap/schema.ts index 5342c5e2..de04f1af 100644 --- a/src/components/nabla/Swap/schema.ts +++ b/src/components/nabla/Swap/schema.ts @@ -3,18 +3,18 @@ import { transformNumber } from '../../../helpers/yup'; export type SwapFormValues = { from: string; - fromAmount: number; + fromAmount: string; to: string; - toAmount: number; + toAmount: string; slippage: number | undefined; deadline: number; }; const schema = Yup.object().shape({ from: Yup.string().min(5).required(), - fromAmount: Yup.number().positive().required().transform(transformNumber), + fromAmount: Yup.string().required(), to: Yup.string().min(5).required(), - toAmount: Yup.number().required(), + toAmount: Yup.string().required(), slippage: Yup.number().nullable().transform(transformNumber), deadline: Yup.number().nullable().transform(transformNumber), }); diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index 42382f25..19ab5892 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -7,7 +7,7 @@ import { cacheKeys } from '../../../constants/cache'; import { storageKeys } from '../../../constants/localStorage'; import { routerAbi } from '../../../contracts/nabla/Router'; import { useGlobalState } from '../../../GlobalStateProvider'; -import { subtractPercentage } from '../../../helpers/calc'; +import { subtractBigDecimalPercentage } from '../../../helpers/calc'; import { debounce } from '../../../helpers/function'; import { getValidDeadline, getValidSlippage } from '../../../helpers/transaction'; import { useGetAppDataByTenant } from '../../../hooks/useGetAppDataByTenant'; @@ -18,6 +18,7 @@ import schema from './schema'; import { SwapFormValues } from './schema'; import { NablaInstanceToken, useNablaInstance } from '../../../hooks/nabla/useNablaInstance'; import { useContractWrite } from '../../../hooks/nabla/useContractWrite'; +import Big from 'big.js'; export interface UseSwapComponentProps { from?: string; @@ -102,8 +103,13 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { const vDeadline = getValidDeadline(variables.deadline || defaultValues.deadline); const vSlippage = getValidSlippage(variables.slippage || defaultValues.slippage); const deadline = calcDeadline(vDeadline).toString(); - const fromAmount = decimalToRaw(variables.fromAmount, fromToken?.decimals).toString(); - const toMinAmount = decimalToRaw(subtractPercentage(variables.toAmount, vSlippage), toToken?.decimals).toString(); + const fromAmount = decimalToRaw(variables.fromAmount, fromToken?.decimals) + .round(0, 0) + .toString(); + const toMinAmount = decimalToRaw( + subtractBigDecimalPercentage(new Big(variables.toAmount), vSlippage ?? 100), + toToken?.decimals, + ).toString(); return swapMutation.mutate([fromAmount, toMinAmount, [variables.from, variables.to], address, deadline]); }); diff --git a/src/components/nabla/common/AmountSelector.tsx b/src/components/nabla/common/AmountSelector.tsx index 31ab1eee..1732eff0 100644 --- a/src/components/nabla/common/AmountSelector.tsx +++ b/src/components/nabla/common/AmountSelector.tsx @@ -3,30 +3,23 @@ import { FieldPath, FieldValues, PathValue, UseFormReturn, useWatch } from 'reac import { useEffect, useMemo } from 'preact/hooks'; import Big from 'big.js'; -import { ContractBalance } from '../../../hooks/nabla/useErc20ContractBalance'; import { NumberInput } from './NumberInput'; import { ChangeEvent } from 'preact/compat'; -import { roundDownToSignificantDecimals } from '../../../shared/parseNumbers/metric'; +import { fractionOfValue } from '../../../shared/parseNumbers/metric'; +import { ContractBalance } from '../../../helpers/contracts'; interface AmountSelectorProps> { maxBalance: ContractBalance | undefined; formFieldName: TFieldName; form: UseFormReturn; -} - -const BIG_100 = new Big('100'); - -function fractionOfValue(maxValue: Big, percentage: number): string { - const preciseResult = new Big(percentage).div(BIG_100).mul(maxValue); - - const roundedNumber = roundDownToSignificantDecimals(preciseResult, 2); - return roundedNumber.toFixed(); + children?: JSX.Element | null; } export function AmountSelector>({ formFieldName, maxBalance, form, + children, }: AmountSelectorProps) { type K = PathValue; @@ -51,11 +44,11 @@ export function AmountSelector + {children}
); } diff --git a/src/components/nabla/common/Erc20Balance.tsx b/src/components/nabla/common/Erc20Balance.tsx index 053747ff..f9cbeae9 100644 --- a/src/components/nabla/common/Erc20Balance.tsx +++ b/src/components/nabla/common/Erc20Balance.tsx @@ -7,7 +7,7 @@ export type Erc20BalanceProps = { }; export function Erc20Balance({ erc20ContractDefinition, abi }: Erc20BalanceProps): JSX.Element | null { - const { isLoading, balance } = useErc20ContractBalance(abi, erc20ContractDefinition); + const { isLoading, data: balance } = useErc20ContractBalance(abi, erc20ContractDefinition); if (balance === undefined || erc20ContractDefinition === undefined || isLoading) return ; const { symbol } = erc20ContractDefinition; diff --git a/src/components/nabla/common/NablaTokenPrice.tsx b/src/components/nabla/common/NablaTokenPrice.tsx index 68ec80c4..6971e320 100644 --- a/src/components/nabla/common/NablaTokenPrice.tsx +++ b/src/components/nabla/common/NablaTokenPrice.tsx @@ -1,5 +1,3 @@ -import { getMessageCallValue } from '../../../shared/helpers'; -import { rawToDecimal, prettyNumbers } from '../../../shared/parseNumbers/metric'; import { NumberLoader } from '../../Loader'; import { useNablaTokenPrice } from '../../../hooks/nabla/useNablaTokenPrice'; @@ -9,18 +7,15 @@ export type TokenPriceProps = { fallback?: ReactNode; }; -const TOKEN_PRICE_DECIMALS = 12; - export function NablaTokenPrice({ address, prefix = null, fallback = null }: TokenPriceProps): JSX.Element | null { const { data, isLoading } = useNablaTokenPrice(address); if (isLoading) return ; - const price = getMessageCallValue(data); - if (price === undefined) return <>{fallback}; + if (data === undefined) return <>{fallback}; return ( - {prefix}${prettyNumbers(rawToDecimal(price, TOKEN_PRICE_DECIMALS).toNumber())} + {prefix}${data.approximateStrings.atLeast2Decimals} ); } diff --git a/src/components/nabla/common/TokenAmount.tsx b/src/components/nabla/common/TokenAmount.tsx index f7f5a695..7da4a1a6 100644 --- a/src/components/nabla/common/TokenAmount.tsx +++ b/src/components/nabla/common/TokenAmount.tsx @@ -1,7 +1,5 @@ import { useSharesTargetWorth } from '../../../hooks/nabla/useSharesTargetWorth'; import { useDebouncedValue } from '../../../hooks/useDebouncedValue'; -import { getMessageCallValue } from '../../../shared/helpers'; -import { rawToDecimal, prettyNumbers } from '../../../shared/parseNumbers/metric'; import { NumberLoader } from '../../Loader'; export interface TokenAmountProps { @@ -13,18 +11,17 @@ export interface TokenAmountProps { poolTokenDecimals: number; lpTokenDecimals: number; debounce?: number; - loader?: boolean; } +// TODO Torsten: remove this component export function TokenAmount({ - symbol, + address, abi, + lpTokenDecimalAmount, + symbol, fallback, - address, poolTokenDecimals, lpTokenDecimals, - lpTokenDecimalAmount, - loader = true, debounce = 800, }: TokenAmountProps): JSX.Element | null { const debouncedAmount = useDebouncedValue(lpTokenDecimalAmount, debounce); @@ -33,17 +30,17 @@ export function TokenAmount({ abi, lpTokenDecimalAmount: debounce ? debouncedAmount : lpTokenDecimalAmount, lpTokenDecimals, + poolTokenDecimals, }); if (lpTokenDecimalAmount && (isLoading || (!!debounce && lpTokenDecimalAmount !== debouncedAmount))) { - return loader ? : null; + return ; } + // TODO Torsten: show explicit error if an error is returned return ( - - {data - ? prettyNumbers(rawToDecimal(getMessageCallValue(data) ?? '0', poolTokenDecimals).toNumber()) - : fallback ?? null} + + {data ? data.approximateStrings.atLeast2Decimals : fallback ?? null} {symbol ? symbol : null} ); diff --git a/src/components/nabla/common/TokenBalance.tsx b/src/components/nabla/common/TokenBalance.tsx new file mode 100644 index 00000000..5df6b8bc --- /dev/null +++ b/src/components/nabla/common/TokenBalance.tsx @@ -0,0 +1,24 @@ +import { UseQueryResult } from '@tanstack/react-query'; +import { NumberLoader } from '../../Loader'; +import { ContractBalance } from '../../../helpers/contracts'; + +export interface TokenBalancProps { + query: Pick, 'error' | 'data' | 'isLoading'>; + symbol: string | undefined; +} + +export function TokenBalance({ query: { data, error, isLoading }, symbol }: TokenBalancProps): JSX.Element | null { + if (isLoading) { + return ; + } + + if (error || !data) { + return N/A; + } + + return ( + + {data.approximateStrings.atLeast2Decimals} {symbol ? symbol : null} + + ); +} diff --git a/src/constants/cache.ts b/src/constants/cache.ts index c94c26a2..0b628164 100644 --- a/src/constants/cache.ts +++ b/src/constants/cache.ts @@ -11,6 +11,7 @@ export const cacheKeys = { walletBalance: 'walletBalance', walletBalances: 'walletBalances', tokenOutAmount: 'tokenOutAmount', + quoteSwapPoolWithdraw: 'quoteSwapPoolWithdraw', sharesTargetWorth: 'sharesTargetWorth', tokenPrice: 'tokenPrice', nablaInstance: 'nablaInstance', diff --git a/src/helpers/__tests__/calc.test.ts b/src/helpers/__tests__/calc.test.ts index e61e3c6a..23898c16 100644 --- a/src/helpers/__tests__/calc.test.ts +++ b/src/helpers/__tests__/calc.test.ts @@ -14,11 +14,10 @@ describe('calc', () => { totalLiabilities: undefined, reserve: native1000, } as unknown as NablaInstanceSwapPool, - sharesWorthNativeAmount: BigInt(native1000), + sharesValueDecimalAmount: new Big(1000), backstopLpDecimalAmount: 1000, bpPrice: BigInt(decimalToNative(1).toString()), spPrice: BigInt(decimalToNative(2).toString()), - backstopPoolTokenDecimals: DEFAULT_DECIMALS, swapPoolTokenDecimals: DEFAULT_DECIMALS, }), ).toBe(undefined); @@ -29,11 +28,10 @@ describe('calc', () => { totalLiabilities: native1000, reserve: native1000, } as unknown as NablaInstanceSwapPool, - sharesWorthNativeAmount: BigInt(native1000), + sharesValueDecimalAmount: new Big(1000), backstopLpDecimalAmount: 1000, bpPrice: BigInt(decimalToNative(1).toString()), spPrice: BigInt(decimalToNative(2).toString()), - backstopPoolTokenDecimals: DEFAULT_DECIMALS, swapPoolTokenDecimals: DEFAULT_DECIMALS, }), ).toEqual(Big(0)); @@ -44,11 +42,10 @@ describe('calc', () => { totalLiabilities: native1000, reserve: decimalToNative(1200).toString(), } as unknown as NablaInstanceSwapPool, - sharesWorthNativeAmount: BigInt(native1000), + sharesValueDecimalAmount: new Big(1000), backstopLpDecimalAmount: 1000, bpPrice: BigInt(decimalToNative(1.1).toString()), spPrice: BigInt(decimalToNative(2.2).toString()), - backstopPoolTokenDecimals: DEFAULT_DECIMALS, swapPoolTokenDecimals: DEFAULT_DECIMALS, }), ).toEqual(decimalToNative(400)); @@ -59,11 +56,10 @@ describe('calc', () => { totalLiabilities: native1000, reserve: decimalToNative(5200).toString(), } as unknown as NablaInstanceSwapPool, - sharesWorthNativeAmount: BigInt(native1000), + sharesValueDecimalAmount: new Big(1000), backstopLpDecimalAmount: 1000, bpPrice: BigInt(decimalToNative(1.1).toString()), spPrice: BigInt(decimalToNative(2.2).toString()), - backstopPoolTokenDecimals: DEFAULT_DECIMALS, swapPoolTokenDecimals: DEFAULT_DECIMALS, }), ).toEqual(decimalToNative(1000)); diff --git a/src/helpers/calc.ts b/src/helpers/calc.ts index 767e6a9f..0ce5ce5e 100644 --- a/src/helpers/calc.ts +++ b/src/helpers/calc.ts @@ -15,16 +15,22 @@ export function calcFiatValuePriceImpact( return Math.floor(ratio * PRECISION); } +// TODO Torsten: abolish /** Calculate percentage */ export const subtractPercentage = (value = 0, percent = 0, round = 2) => roundNumber(value * (1 - percent / 100), round); /** Calculate share percentage */ -export const calcSharePercentage = (total = 0, share = 0, round = 2) => roundNumber((share / total) * 100, round) || 0; +export function calcSharePercentage(total: Big, share: Big) { + const percentage = share.div(total).mul(new Big(100)).toNumber(); + const clampedPercentage = Math.max(Math.min(percentage, 100), 0); + return clampedPercentage.toFixed(2); +} -export const min = (val: number, minNumber = 0) => Math.max(val, minNumber); -export const max = (val: number, maxNumber = 100) => Math.min(val, maxNumber); -export const minMax = (val: number, minNumber = 0, maxNumber = 100) => max(min(val, minNumber), maxNumber); +/** Calculate share percentage */ +export function subtractBigDecimalPercentage(total: Big, percent: number) { + return total.mul(new Big(1 - percent / 100)); +} /** Calculate pool APR (daily fee * 365 / TVL) */ export const calcAPR = (dailyFees: number, tvl: number, round = 2) => @@ -40,10 +46,9 @@ export function getPoolSurplusNativeAmount(pool: NablaInstanceSwapPool) { type CAPWProps = { selectedSwapPool: NablaInstanceSwapPool; backstopLpDecimalAmount: number; - sharesWorthNativeAmount: bigint; + sharesValueDecimalAmount: Big | undefined; bpPrice: bigint | undefined; spPrice: bigint | undefined; - backstopPoolTokenDecimals: number; swapPoolTokenDecimals: number; }; @@ -52,20 +57,18 @@ type CAPWProps = { export const calcAvailablePoolWithdraw = ({ selectedSwapPool, backstopLpDecimalAmount, - sharesWorthNativeAmount, + sharesValueDecimalAmount, bpPrice, spPrice, - backstopPoolTokenDecimals, swapPoolTokenDecimals, }: CAPWProps) => { const surplusNativeAmount = getPoolSurplusNativeAmount(selectedSwapPool); - if (!bpPrice || !spPrice || !sharesWorthNativeAmount || !backstopLpDecimalAmount) { + if (!bpPrice || !spPrice || !sharesValueDecimalAmount || !backstopLpDecimalAmount) { return undefined; } const surplusDecimalAmount = Big(rawToDecimal(surplusNativeAmount.toString(), swapPoolTokenDecimals).toString()); if (surplusDecimalAmount.lte(0)) return Big(0); - const sharesValueDecimalAmount = Big(rawToDecimal(sharesWorthNativeAmount.toString(), backstopPoolTokenDecimals)); const spPriceVal = new Big(spPrice.toString()); const bpPriceVal = new Big(bpPrice.toString()); diff --git a/src/helpers/contracts.ts b/src/helpers/contracts.ts new file mode 100644 index 00000000..58d78b78 --- /dev/null +++ b/src/helpers/contracts.ts @@ -0,0 +1,47 @@ +import { INumber } from '@polkadot/types-codec/types'; +import Big from 'big.js'; +import { multiplyByPowerOfTen, stringifyBigWithSignificantDecimals } from '../shared/parseNumbers/metric'; + +export interface ContractBalance { + rawBalance: bigint; + decimals: number; + preciseBigDecimal: Big; + preciseString: string; + approximateStrings: { + atLeast2Decimals: string; + atLeast4Decimals: string; + }; + approximateNumber: number; +} + +export function parseContractBalanceResponse(decimals: number, balanceResponse: INumber): ContractBalance; +export function parseContractBalanceResponse( + decimals: number | undefined, + balanceResponse: INumber | undefined, +): ContractBalance | undefined; + +export function parseContractBalanceResponse( + decimals: number | undefined, + balanceResponse: INumber | undefined, +): ContractBalance | undefined { + const rawBalanceBigInt = balanceResponse?.toBigInt(); + if (rawBalanceBigInt === undefined || decimals === undefined) return undefined; + + const rawBalanceString = rawBalanceBigInt.toString(); + const preciseBigDecimal = multiplyByPowerOfTen(new Big(rawBalanceString), -decimals); + + const atLeast2Decimals = stringifyBigWithSignificantDecimals(preciseBigDecimal, 2); + const atLeast4Decimals = stringifyBigWithSignificantDecimals(preciseBigDecimal, 4); + + return { + rawBalance: rawBalanceBigInt, + decimals, + preciseBigDecimal, + preciseString: preciseBigDecimal.toFixed(), + approximateStrings: { + atLeast2Decimals, + atLeast4Decimals, + }, + approximateNumber: preciseBigDecimal.toNumber(), + }; +} diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index c9fa4c91..b42812d3 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -9,27 +9,36 @@ import { useSharedState } from '../../shared/Provider'; import { config } from '../../config'; const isDevelopment = config.isDev; +const ALICE = '6mfqoTMHrMeVMyKwjqomUjVomPMJ4AjdCm1VReFtk7Be8wqr'; + +export type MessageCallErrorResult = MessageCallResult & { result: { type: 'error' | 'panic' | 'reverted' } }; -export type UseContractProps = { +export type UseContractReadProps = { abi: Dict; address: string | undefined; method: string; args?: any[]; noWalletAddressRequired?: boolean; - queryOptions: QueryOptions; + parseSuccessOutput: (successResult: any) => ReturnType; + parseError: string | ((errorResult: MessageCallErrorResult) => string); + queryOptions: QueryOptions; }; -export type UseContractResult = Pick< - UseQueryResult, - 'refetch' | 'isLoading' | 'data' | 'fetchStatus' ->; - -const ALICE = '6mfqoTMHrMeVMyKwjqomUjVomPMJ4AjdCm1VReFtk7Be8wqr'; +export type UseContractReadResult = UseQueryResult; -export function useContractRead( +export function useContractRead( key: QueryKey, - { abi, address, method, args, noWalletAddressRequired, queryOptions }: UseContractProps, -): UseContractResult { + { + abi, + address, + method, + args, + noWalletAddressRequired, + queryOptions, + parseSuccessOutput, + parseError, + }: UseContractReadProps, +): UseContractReadResult { const { api, address: walletAddress } = useSharedState(); const contractAbi = useMemo( () => (abi && api?.registry ? new Abi(abi, api.registry.getChainProperties()) : undefined), @@ -39,7 +48,7 @@ export function useContractRead( const actualWalletAddress = noWalletAddressRequired ? ALICE : walletAddress; const enabled = !!contractAbi && queryOptions.enabled !== false && !!address && !!api && !!actualWalletAddress; - const query = useQuery( + const query = useQuery( enabled ? key : emptyCacheKey, async () => { if (!enabled) return; @@ -65,18 +74,24 @@ export function useContractRead( console.log('read', 'Call message result', address, method, args, response); } - return response; + if (response.result.type !== 'success') { + let message; + if (typeof parseError === 'string') { + message = parseError; + } else { + message = parseError(response as MessageCallErrorResult); + } + return Promise.reject(message); + } + + return parseSuccessOutput(response.result.value); }, { ...queryOptions, + retry: false, enabled, }, ); - return { - refetch: query.refetch, - isLoading: query.isLoading, - data: query.data, - fetchStatus: query.fetchStatus, - }; + return query; } diff --git a/src/hooks/nabla/useErc20ContractBalance.ts b/src/hooks/nabla/useErc20ContractBalance.ts index b7d9f4c1..3fb21596 100644 --- a/src/hooks/nabla/useErc20ContractBalance.ts +++ b/src/hooks/nabla/useErc20ContractBalance.ts @@ -1,40 +1,19 @@ -import { Big } from 'big.js'; -import { useMemo } from 'preact/compat'; - +import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; import { cacheKeys } from '../../shared/constants'; -import { getMessageCallValue } from '../../shared/helpers'; -import { multiplyByPowerOfTen, roundDownToSignificantDecimals } from '../../shared/parseNumbers/metric'; import { useSharedState } from '../../shared/Provider'; -import { UseContractResult, useContractRead } from './useContractRead'; - -export interface UseBalanceResponse { - balance: ContractBalance | undefined; - refetch: UseContractResult['refetch']; - isLoading: UseContractResult['isLoading']; -} - -export interface ContractBalance { - rawBalance: bigint; - decimals: number; - preciseBigDecimal: Big; - preciseString: string; - approximateStrings: { - atLeast2Decimals: string; - atLeast4Decimals: string; - }; - approximateNumber: number; -} +import { UseContractReadResult, useContractRead } from './useContractRead'; export const useErc20ContractBalance = ( abi: Dict, erc20ContractDefinition: { contractAddress: string; decimals: number } | undefined, -): UseBalanceResponse => { +): UseContractReadResult => { const { api, address } = useSharedState(); const contractAddress = erc20ContractDefinition?.contractAddress; + const decimals = erc20ContractDefinition?.decimals; const enabled = !!api && !!address; - const query = useContractRead([cacheKeys.balance, contractAddress, address], { + return useContractRead([cacheKeys.balance, contractAddress, address], { abi, address: contractAddress, method: 'balanceOf', @@ -42,44 +21,11 @@ export const useErc20ContractBalance = ( queryOptions: { cacheTime: 10000, staleTime: 10000, - retry: 2, - refetchInterval: 10000, + //refetchInterval: 10000, onError: console.error, enabled, }, + parseSuccessOutput: parseContractBalanceResponse.bind(null, decimals), + parseError: 'Could not load balance', }); - - const decimals = erc20ContractDefinition?.decimals; - - const { data } = query; - const balanceResponse = getMessageCallValue(data); - const rawBalanceBigInt = balanceResponse?.toBigInt(); - - const balance: ContractBalance | undefined = useMemo(() => { - if (rawBalanceBigInt === undefined || decimals === undefined) return undefined; - - const rawBalanceString = rawBalanceBigInt.toString(); - const preciseBigDecimal = multiplyByPowerOfTen(new Big(rawBalanceString), -decimals); - - const roundedTo2SignificantDecimals = roundDownToSignificantDecimals(preciseBigDecimal, 2); - const roundedTo4SignificantDecimals = roundDownToSignificantDecimals(preciseBigDecimal, 4); - - return { - rawBalance: rawBalanceBigInt, - decimals, - preciseBigDecimal, - preciseString: preciseBigDecimal.toFixed(), - approximateStrings: { - atLeast2Decimals: roundedTo2SignificantDecimals.toFixed(), - atLeast4Decimals: roundedTo4SignificantDecimals.toFixed(), - }, - approximateNumber: preciseBigDecimal.toNumber(), - }; - }, [rawBalanceBigInt, decimals]); - - return { - isLoading: query.isLoading, - refetch: query.refetch, - balance, - }; }; diff --git a/src/hooks/nabla/useErc20TokenAllowance.ts b/src/hooks/nabla/useErc20TokenAllowance.ts index bac6daba..86028ba5 100644 --- a/src/hooks/nabla/useErc20TokenAllowance.ts +++ b/src/hooks/nabla/useErc20TokenAllowance.ts @@ -2,6 +2,7 @@ import { erc20WrapperAbi } from '../../contracts/nabla/ERC20Wrapper'; import { cacheKeys } from '../../shared/constants'; import { activeOptions } from '../../constants/cache'; import { useContractRead } from './useContractRead'; +import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; export type UseTokenAllowance = { /** contract/token address */ @@ -10,20 +11,22 @@ export type UseTokenAllowance = { spender: string | undefined; /** owner address */ owner: string | undefined; + decimals: number; }; -export function useErc20TokenAllowance({ token, owner, spender }: UseTokenAllowance, enabled: boolean) { +export function useErc20TokenAllowance({ token, owner, spender, decimals }: UseTokenAllowance, enabled: boolean) { const isEnabled = Boolean(owner && spender && enabled); - return useContractRead([cacheKeys.tokenAllowance, spender, token, owner], { + return useContractRead([cacheKeys.tokenAllowance, spender, token, owner], { abi: erc20WrapperAbi, address: token, method: 'allowance', args: [owner, spender], queryOptions: { ...activeOptions['3m'], - retry: 2, enabled: isEnabled, }, + parseSuccessOutput: parseContractBalanceResponse.bind(null, decimals), + parseError: 'Could not load token allowance', }); } diff --git a/src/hooks/nabla/useErc20TokenApproval.ts b/src/hooks/nabla/useErc20TokenApproval.ts index e426dca8..ff721f15 100644 --- a/src/hooks/nabla/useErc20TokenApproval.ts +++ b/src/hooks/nabla/useErc20TokenApproval.ts @@ -3,11 +3,9 @@ import { useMemo, useState } from 'preact/compat'; import { Big } from 'big.js'; import { erc20WrapperAbi } from '../../contracts/nabla/ERC20Wrapper'; -import { getMessageCallValue } from '../../shared/helpers'; -import { rawToDecimal } from '../../shared/parseNumbers/metric'; import { useSharedState } from '../../shared/Provider'; import { useErc20TokenAllowance } from './useErc20TokenAllowance'; -import { UseContractWriteProps, UseContractWriteResult, useContractWrite } from './useContractWrite'; +import { UseContractWriteProps, UseContractWriteResponse, useContractWrite } from './useContractWrite'; export enum ApprovalState { UNKNOWN, @@ -29,7 +27,7 @@ interface UseErc20TokenApprovalParams { interface UseErc20TokenApprovalResult { state: ApprovalState; - mutate: UseContractWriteResult['mutate']; + mutate: UseContractWriteResponse['mutate']; } export function useErc20TokenApproval({ @@ -49,14 +47,7 @@ export function useErc20TokenApproval({ data: allowanceData, isLoading: isAllowanceLoading, refetch, - } = useErc20TokenAllowance( - { - token, - owner: address, - spender, - }, - isEnabled, - ); + } = useErc20TokenAllowance({ token, owner: address, spender, decimals }, isEnabled); const mutation = useContractWrite({ abi: erc20WrapperAbi, @@ -78,11 +69,7 @@ export function useErc20TokenApproval({ }, }); - const allowanceValue = getMessageCallValue(allowanceData); - const allowanceDecimalAmount = useMemo( - () => (allowanceValue !== undefined ? rawToDecimal(allowanceValue.toString(), decimals) : undefined), - [allowanceValue, decimals], - ); + const allowanceDecimalAmount = allowanceData?.preciseBigDecimal; return useMemo(() => { let state = ApprovalState.UNKNOWN; diff --git a/src/hooks/nabla/useNablaTokenPrice.ts b/src/hooks/nabla/useNablaTokenPrice.ts index c5c9cb69..44214559 100644 --- a/src/hooks/nabla/useNablaTokenPrice.ts +++ b/src/hooks/nabla/useNablaTokenPrice.ts @@ -1,14 +1,17 @@ import { cacheKeys, inactiveOptions } from '../../constants/cache'; import { priceOracleAbi } from '../../contracts/nabla/PriceOracle'; +import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; import { useContractRead } from './useContractRead'; +const TOKEN_PRICE_DECIMALS = 12; + export function useNablaTokenPrice(address: string | undefined, enabled?: boolean) { const { oracle } = useGetAppDataByTenant('nabla').data || {}; enabled = !!address && !!oracle && enabled !== false; - return useContractRead([cacheKeys.tokenPrice, address], { + return useContractRead([cacheKeys.tokenPrice, address], { abi: priceOracleAbi, address: oracle, method: 'getAssetPrice', @@ -18,5 +21,7 @@ export function useNablaTokenPrice(address: string | undefined, enabled?: boolea ...inactiveOptions['1m'], enabled, }, + parseSuccessOutput: parseContractBalanceResponse.bind(null, TOKEN_PRICE_DECIMALS), + parseError: 'Could not retrieve asset price', }); } diff --git a/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts b/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts new file mode 100644 index 00000000..1f1704ad --- /dev/null +++ b/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts @@ -0,0 +1,91 @@ +import { Big } from 'big.js'; + +import { activeOptions, cacheKeys } from '../../constants/cache'; +import { multiplyByPowerOfTen } from '../../shared/parseNumbers/metric'; +import { useContractRead } from './useContractRead'; +import { useDebouncedValue } from '../useDebouncedValue'; +import { swapPoolAbi } from '../../contracts/nabla/SwapPool'; +import { FieldValues, UseFormReturn } from 'react-hook-form'; +import { useEffect } from 'preact/hooks'; +import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; + +export type UseQuoteSwapPoolWithdrawProps = { + lpTokenAmountString: string | undefined; + lpTokenDecimals: number; + maximumLpTokenAmount: Big | undefined; + poolTokenDecimals: number; + swapPoolAddress: string; + form: UseFormReturn; +}; + +// TODO Torsten: check whether the swap quote works the same + +export function useQuoteSwapPoolWithdraw({ + lpTokenAmountString, + lpTokenDecimals, + poolTokenDecimals, + swapPoolAddress, + maximumLpTokenAmount, + form, +}: UseQuoteSwapPoolWithdrawProps) { + const { setError, clearErrors } = form; + + const debouncedAmountString = useDebouncedValue(lpTokenAmountString, 800); + + let debouncedAmountBigDecimal; + try { + debouncedAmountBigDecimal = debouncedAmountString !== undefined ? new Big(debouncedAmountString) : undefined; + } catch { + debouncedAmountBigDecimal = undefined; + } + const enabled = + debouncedAmountBigDecimal !== undefined && + (maximumLpTokenAmount === undefined || + (debouncedAmountBigDecimal.lte(maximumLpTokenAmount) && debouncedAmountBigDecimal?.gt(new Big(0)))); + + // TODO Torsten: check whether the other calls also round like this + const amountIn = + debouncedAmountBigDecimal !== undefined + ? multiplyByPowerOfTen(debouncedAmountBigDecimal, lpTokenDecimals).round(0, 0).toString() + : undefined; + + const { isLoading, fetchStatus, data, error } = useContractRead( + [cacheKeys.quoteSwapPoolWithdraw, swapPoolAddress, amountIn], + { + abi: swapPoolAbi, + address: swapPoolAddress, + method: 'quoteWithdraw', + args: [amountIn], + noWalletAddressRequired: true, + queryOptions: { + ...activeOptions['30s'], + enabled, + }, + parseSuccessOutput: parseContractBalanceResponse.bind(null, poolTokenDecimals), + parseError: (error) => { + switch (error.result.type) { + case 'error': + return 'Cannot determine value of shares'; + case 'panic': + return error.result.errorCode === 0x11 + ? 'The input amount is too large' + : 'Cannot determine value of shares'; + case 'reverted': + return 'Cannot determine value of shares'; + } + }, + }, + ); + + const pending = (isLoading && fetchStatus !== 'idle') || debouncedAmountString !== lpTokenAmountString; + useEffect(() => { + if (pending) return; + if (error === null) { + clearErrors('root'); + } else { + setError('root', { type: 'custom', message: error }); + } + }, [error, pending, clearErrors, setError]); + + return { isLoading: pending, enabled, data, error }; +} diff --git a/src/hooks/nabla/useSharesTargetWorth.ts b/src/hooks/nabla/useSharesTargetWorth.ts index 592c8eb7..fd128a9f 100644 --- a/src/hooks/nabla/useSharesTargetWorth.ts +++ b/src/hooks/nabla/useSharesTargetWorth.ts @@ -1,4 +1,5 @@ import { cacheKeys, inactiveOptions } from '../../constants/cache'; +import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; import { decimalToRaw } from '../../shared/parseNumbers/metric'; import { useContractRead } from './useContractRead'; @@ -6,14 +7,16 @@ export type UseSharesTargetWorthProps = { address: string | undefined; lpTokenDecimalAmount: number; lpTokenDecimals: number; + poolTokenDecimals: number; abi: Dict; }; +// TODO Torsten: where is this still used? Not for swap pool withdrawals anymore export function useSharesTargetWorth( - { address, lpTokenDecimalAmount, abi, lpTokenDecimals }: UseSharesTargetWorthProps, + { address, lpTokenDecimalAmount, abi, lpTokenDecimals, poolTokenDecimals }: UseSharesTargetWorthProps, enabled?: boolean, ) { - return useContractRead([cacheKeys.sharesTargetWorth, lpTokenDecimalAmount], { + return useContractRead([cacheKeys.sharesTargetWorth, lpTokenDecimalAmount], { abi, address, method: 'sharesTargetWorth', @@ -22,5 +25,7 @@ export function useSharesTargetWorth( ...inactiveOptions['1m'], enabled: Boolean(address && lpTokenDecimalAmount && enabled !== false), }, + parseSuccessOutput: parseContractBalanceResponse.bind(null, poolTokenDecimals), + parseError: 'Could not load the share value.', }); } diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index 4f3da949..539f2646 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -1,14 +1,17 @@ +import Big from 'big.js'; import { activeOptions, cacheKeys } from '../../constants/cache'; import { routerAbi } from '../../contracts/nabla/Router'; +import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; import { decimalToRaw } from '../../shared/parseNumbers/metric'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; import { useContractRead } from './useContractRead'; export type UseTokenOutAmountProps = { - fromDecimalAmount: number; + fromDecimalAmount: Big | undefined; from?: string; to?: string; - fromTokenDecimals: number; + fromTokenDecimals: number | undefined; + toTokenDecimals: number | undefined; }; export function useTokenOutAmount({ @@ -16,25 +19,50 @@ export function useTokenOutAmount({ from, to, fromTokenDecimals, + toTokenDecimals, }: UseTokenOutAmountProps) { const { router } = useGetAppDataByTenant('nabla').data || {}; - const enabled = fromTokenDecimals !== undefined && !!decimalAmount && !!from && !!to; + const enabled = fromTokenDecimals !== undefined && decimalAmount && !!from && !!to; const amountIn = - fromTokenDecimals !== undefined ? decimalToRaw(decimalAmount, fromTokenDecimals).toString() : undefined; + fromTokenDecimals !== undefined && decimalAmount !== undefined + ? decimalToRaw(decimalAmount, fromTokenDecimals).round(0, 0).toString() + : undefined; - return useContractRead([cacheKeys.tokenOutAmount, from, to, amountIn], { - abi: routerAbi, - address: router, - method: 'getAmountOut', - args: [amountIn, [from, to]], - noWalletAddressRequired: true, - queryOptions: { - ...activeOptions['30s'], - enabled, - onError: (err) => { - console.error(err); + return useContractRead<{ amountOut: ContractBalance; swapFee: ContractBalance } | undefined>( + [cacheKeys.tokenOutAmount, from, to, amountIn], + { + abi: routerAbi, + address: router, + method: 'getAmountOut', + args: [amountIn, [from, to]], + noWalletAddressRequired: true, + queryOptions: { + ...activeOptions['30s'], + enabled, + onError: (err) => { + console.error(err); + }, + }, + parseSuccessOutput: (data) => + toTokenDecimals === undefined + ? undefined + : { + amountOut: parseContractBalanceResponse(toTokenDecimals, data[0]), + swapFee: parseContractBalanceResponse(toTokenDecimals, data[1]), + }, + parseError: (error) => { + switch (error.result.type) { + case 'error': + return 'Something went wrong'; + case 'panic': + return error.result.errorCode === 0x11 ? 'The input amount is too large' : 'Something went wrong'; + case 'reverted': + return error.result.description === 'SwapPool: EXCEEDS_MAX_COVERAGE_RATIO' + ? 'The input amount is too large' + : 'Something went wrong'; + } }, }, - }); + ); } diff --git a/src/shared/helpers.ts b/src/shared/helpers.ts index 189971ff..4b2e657e 100644 --- a/src/shared/helpers.ts +++ b/src/shared/helpers.ts @@ -1,9 +1,10 @@ -import { Limits, MessageCallResult } from '@pendulum-chain/api-solang'; +import { Limits } from '@pendulum-chain/api-solang'; import type { QueryKey, UseQueryOptions } from '@tanstack/react-query'; // eslint-disable-next-line @typescript-eslint/no-explicit-any -export type QueryOptions = Partial< - Omit, 'queryKey' | 'queryFn'> +export type QueryOptions = Omit< + UseQueryOptions, + 'queryKey' | 'queryFn' >; export const emptyCacheKey = ['']; @@ -22,7 +23,3 @@ export const defaultWriteLimits: Limits = { }, storageDeposit: undefined, }; - -export const getMessageCallValue = (response: MessageCallResult | undefined) => { - return response?.result.type === 'success' ? response.result.value : undefined; -}; diff --git a/src/shared/parseNumbers/metric.ts b/src/shared/parseNumbers/metric.ts index 65d11455..b7cd04cc 100644 --- a/src/shared/parseNumbers/metric.ts +++ b/src/shared/parseNumbers/metric.ts @@ -11,6 +11,8 @@ export const StellarDecimals = 12; // These are the decimals used by the FixedU128 type export const FixedU128Decimals = 18; +const BIG_100 = new BigNumber('100'); + // Change the positive exponent to a high value to prevent toString() returning exponential notation BigNumber.PE = 100; // Change the negative exponent to a low value to show more decimals with toString() @@ -108,6 +110,7 @@ export const nativeToFormatMetric = ( oneCharOnly = false, ) => format(rawToDecimal(value, StellarDecimals).toNumber(), tokenSymbol, oneCharOnly); +// TODO Torsten: abolish for Nabla export const prettyNumbers = (number: number, lang?: string, opts?: Intl.NumberFormatOptions) => number.toLocaleString('en-US', { minimumFractionDigits: 2, @@ -132,6 +135,12 @@ export function roundDownToSignificantDecimals(big: BigNumber, decimals: number) return big.prec(Math.max(0, big.e + 1) + decimals, 0); } +export function stringifyBigWithSignificantDecimals(big: BigNumber, decimals: number) { + const rounded = roundDownToSignificantDecimals(big, decimals); + return rounded.toFixed(); +} + +// TODO Torsten: check whether this can used everywhere to construct cleaner zeros export function multiplyByPowerOfTen(bigDecimal: BigNumber, power: number) { const newBigDecimal = new BigNumber(bigDecimal); if (newBigDecimal.c[0] === 0) return newBigDecimal; @@ -140,5 +149,12 @@ export function multiplyByPowerOfTen(bigDecimal: BigNumber, power: number) { return newBigDecimal; } +export function fractionOfValue(maxValue: BigNumber, percentage: number): string { + const preciseResult = new BigNumber(percentage).div(BIG_100).mul(maxValue); + + const roundedNumber = roundDownToSignificantDecimals(preciseResult, 2); + return roundedNumber.toFixed(); +} + /** Calculate deadline from minutes */ export const calcDeadline = (min: number) => `${Math.floor(Date.now() / 1000) + min * 60}`; From a67b9c35f2e4c6be1f2977f5cd7b65463f9969bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Fri, 10 May 2024 09:44:10 -0300 Subject: [PATCH 42/58] Implement Backstop Pool Redeem --- package.json | 8 +- .../Pools/Backstop/AddLiquidity/index.tsx | 112 +- .../Backstop/AddLiquidity/useAddLiquidity.ts | 31 +- .../Backstop/WithdrawLiquidity/index.tsx | 2 +- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 3 +- .../Swap/AddLiquidity/useAddLiquidity.ts | 6 - .../nabla/Pools/Swap/Modals/types.ts | 11 - .../nabla/Pools/Swap/Redeem/index.tsx | 143 +- .../nabla/Pools/Swap/Redeem/useRedeem.ts | 129 +- .../{Modals/index.tsx => SwapPoolModals.tsx} | 28 +- .../Pools/Swap/WithdrawLiquidity/index.tsx | 52 +- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 24 +- src/components/nabla/Pools/Swap/columns.tsx | 23 +- src/components/nabla/Pools/Swap/index.tsx | 26 +- src/components/nabla/Swap/index.tsx | 2 +- .../nabla/common/AmountSelector.tsx | 4 +- src/components/nabla/common/TokenBalance.tsx | 11 +- .../nabla/common/TransactionProgress.tsx | 5 +- .../common/TransactionSettingsDropdown.tsx} | 47 +- src/config/index.ts | 2 +- src/constants/cache.ts | 7 +- src/constants/localStorage.ts | 2 - src/helpers/calc.ts | 5 + src/hooks/nabla/useContractRead.ts | 30 +- src/hooks/nabla/useContractWrite.ts | 19 +- src/hooks/nabla/useErc20ContractBalance.ts | 2 +- src/hooks/nabla/useErc20TokenAllowance.ts | 3 +- src/hooks/nabla/useQuoteSwapPoolRedeem.ts | 102 ++ src/hooks/nabla/useQuoteSwapPoolWithdraw.ts | 12 +- src/hooks/nabla/useTokenOutAmount.ts | 6 +- src/shared/constants.ts | 6 - src/shared/parseNumbers/metric.ts | 2 +- src/shared/useAccountBalance.ts | 2 +- yarn.lock | 1489 +++++------------ 34 files changed, 844 insertions(+), 1512 deletions(-) delete mode 100644 src/components/nabla/Pools/Swap/Modals/types.ts rename src/components/nabla/Pools/Swap/{Modals/index.tsx => SwapPoolModals.tsx} (59%) rename src/components/{Transaction/Settings/index.tsx => nabla/common/TransactionSettingsDropdown.tsx} (73%) create mode 100644 src/hooks/nabla/useQuoteSwapPoolRedeem.ts diff --git a/package.json b/package.json index 1f865ab0..ebf8d71e 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "@heroicons/react": "^2.1.1", "@hookform/resolvers": "^2.9.11", "@pendulum-chain/api": "^0.3.8", - "@pendulum-chain/api-solang": "^0.2.0", + "@pendulum-chain/api-solang": "0.3.0", "@polkadot/api": "^10.9.1", "@polkadot/api-base": "^10.9.1", "@polkadot/api-contract": "^10.9.1", @@ -35,7 +35,7 @@ "@polkadot/rpc-core": "^10.9.1", "@polkadot/rpc-provider": "^10.9.1", "@polkadot/types": "^10.9.1", - "@polkadot/util": "^10.1.9", + "@polkadot/util": "^12.6.2", "@talismn/connect-components": "^1.1.7", "@talismn/connect-ui": "^1.1.2", "@talismn/connect-wallets": "^1.2.3", @@ -123,5 +123,9 @@ "engines": { "npm": "please-use-yarn", "yarn": ">=1.22.19" + }, + "resolutions": { + "@polkadot/api": "^10.9.1", + "@polkadot/extension-inject": "^0.46.9" } } diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index a0277372..a466b2ed 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -13,13 +13,14 @@ import { TokenApproval } from '../../../common/TokenApproval'; import { FormProvider } from 'react-hook-form'; import { AmountSelector } from '../../../common/AmountSelector'; import { calcSharePercentage } from '../../../../../helpers/calc'; +import { TokenBalance } from '../../../common/TokenBalance'; interface AddLiquidityProps { data: NablaInstanceBackstopPool; } const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { - const { toggle, onSubmit, mutation, poolTokenBalance, lpTokenBalance, amountString, amountBigDecimal, form } = + const { toggle, onSubmit, mutation, depositQuery, balanceQuery, amountString, amountBigDecimal, form } = useAddLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); const { @@ -34,125 +35,44 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { -
- -

Deposit {data.token.symbol}

-
+
+ +

Deposit {data.token.symbol}

+

- Deposited:{' '} - - {lpTokenBalance === undefined ? ( - - ) : ( - `${lpTokenBalance.approximateStrings.atLeast2Decimals} ${data.symbol}` - )} - + Deposited:

- Balance:{' '} - - {poolTokenBalance === undefined ? ( - - ) : ( - `${poolTokenBalance.approximateStrings.atLeast2Decimals} ${data.token.symbol}` - )} - + Balance:

- - {/*
-
-
- - - -
-
- ) => { - if (poolTokenBalance === undefined) return; - setValue( - 'amount', - new Big(ev.currentTarget.value) - .div(new Big('100')) - .mul(poolTokenBalance.preciseBigDecimal) - .toFixed(2, 0), - { - shouldDirty: true, - shouldTouch: false, - }, - ); - }} - /> -
*/} + +
-
Total deposit
+
Total LP tokens
{stringifyBigWithSignificantDecimals(totalSupplyOfLpTokens, 2)} {data.symbol}
-
Pool Share
+
Your pool Share
- {lpTokenBalance === undefined ? ( + {depositQuery.data === undefined ? ( ) : ( - calcSharePercentage(totalSupplyOfLpTokens, lpTokenBalance.preciseBigDecimal) + calcSharePercentage(totalSupplyOfLpTokens, depositQuery.data.preciseBigDecimal) )} %
-
().shape({ }); export const useAddLiquidity = ( - poolAddress: string, + backstopPoolAddress: string, tokenAddress: string, poolTokenDecimals: number, lpTokenDecimals: number, ) => { const queryClient = useQueryClient(); - const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { @@ -38,7 +36,7 @@ export const useAddLiquidity = ( }); const depositQuery = useErc20ContractBalance(backstopPoolAbi, { - contractAddress: poolAddress, + contractAddress: backstopPoolAddress, decimals: lpTokenDecimals, }); @@ -51,7 +49,7 @@ export const useAddLiquidity = ( const mutation = useContractWrite({ abi: backstopPoolAbi, - address: poolAddress, + address: backstopPoolAddress, method: 'deposit', mutateOptions: { onError: () => { @@ -61,21 +59,26 @@ export const useAddLiquidity = ( form.reset(); balanceQuery.refetch(); depositQuery.refetch(); - queryClient.refetchQueries([cacheKeys.backstopPools, indexerUrl]); + queryClient.refetchQueries([cacheKeys.nablaInstance]); }, }, }); - const onSubmit = form.handleSubmit((variables) => - mutation.mutate([decimalToRaw(variables.amount, poolTokenDecimals).toString()]), - ); - const amountString = useWatch({ control: form.control, name: 'amount', defaultValue: '0', }); + const { mutate } = mutation; + const onSubmit = useCallback( + (variables: AddLiquidityValues) => { + if (!variables.amount) return; + return mutate([decimalToRaw(variables.amount, poolTokenDecimals).round(0, 0).toString()]); + }, + [mutate, poolTokenDecimals], + ); + const amountBigDecimal = useMemo(() => { try { return new Big(amountString); @@ -89,9 +92,9 @@ export const useAddLiquidity = ( amountString, amountBigDecimal, mutation, - poolTokenBalance: balanceQuery.balance, - lpTokenBalance: depositQuery.balance, - onSubmit, + balanceQuery, + depositQuery, + onSubmit: form.handleSubmit(onSubmit), toggle, }; }; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index 7131f3eb..ae2ebb6f 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -9,7 +9,6 @@ import { prettyNumbers, rawToDecimal, roundNumber } from '../../../../../shared/ import Validation from '../../../../Form/Validation'; import { NumberLoader } from '../../../../Loader'; import FormLoader from '../../../../Loader/Form'; -import { TransactionSettingsDropdown } from '../../../../Transaction/Settings'; import { useWithdrawLiquidity } from './useWithdrawLiquidity'; import { NablaInstance, NablaInstanceSwapPool, useNablaInstance } from '../../../../../hooks/nabla/useNablaInstance'; import { AssetSelectorModal } from '../../../common/AssetSelectorModal'; @@ -17,6 +16,7 @@ import { TransactionProgress } from '../../../common/TransactionProgress'; import { TokenAmount } from '../../../common/TokenAmount'; import { FormProvider } from 'react-hook-form'; import { NumberInput } from '../../../common/NumberInput'; +import { TransactionSettingsDropdown } from '../../../common/TransactionSettingsDropdown'; const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element | null => { const { diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts index 505979c7..e35cf45c 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -73,8 +73,7 @@ export const useWithdrawLiquidity = (nabla: NablaInstance) => { reset(); balanceRefetch(); depositRefetch(); - queryClient.refetchQueries([cacheKeys.backstopPools, indexerUrl]); - }, [balanceRefetch, depositRefetch, indexerUrl, queryClient, reset]); + }, [balanceRefetch, depositRefetch, reset]); const backstopWithdraw = useBackstopWithdraw({ address: poolAddress, diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index 9f10874c..ec96ddda 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -1,9 +1,6 @@ import { yupResolver } from '@hookform/resolvers/yup'; -import { useQueryClient } from '@tanstack/react-query'; import { useForm, useWatch } from 'react-hook-form'; -import { cacheKeys } from '../../../../../constants/cache'; import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; -import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenant'; import { useModalToggle } from '../../../../../services/modal'; import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; import schema from './schema'; @@ -18,8 +15,6 @@ export const useAddLiquidity = ( poolTokenDecimals: number, lpTokenDecimals: number, ) => { - const queryClient = useQueryClient(); - const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; const toggle = useModalToggle(); const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { @@ -49,7 +44,6 @@ export const useAddLiquidity = ( form.reset(); balanceQuery.refetch(); depositQuery.refetch(); - queryClient.refetchQueries([cacheKeys.swapPools, indexerUrl]); }, }, }); diff --git a/src/components/nabla/Pools/Swap/Modals/types.ts b/src/components/nabla/Pools/Swap/Modals/types.ts deleted file mode 100644 index 3ee869e1..00000000 --- a/src/components/nabla/Pools/Swap/Modals/types.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { SwapPoolColumn } from '../columns'; - -export const ModalTypes = { - AddLiquidity: 2, - WithdrawLiquidity: 3, - Redeem: 4, -}; - -export type LiquidityModalProps = { - data?: SwapPoolColumn; -}; diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index 2e890c4d..c30860a8 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -1,90 +1,76 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; -import { ChangeEvent, useEffect } from 'preact/compat'; -import { Button, Range } from 'react-daisyui'; +import { Button } from 'react-daisyui'; import { PoolProgress } from '../..'; -import { config } from '../../../../../config'; import { calcSharePercentage } from '../../../../../helpers/calc'; -import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; +import { rawToDecimal, stringifyBigWithSignificantDecimals } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; import { NumberLoader } from '../../../../Loader'; -import { TransactionSettingsDropdown } from '../../../../Transaction/Settings'; import { SwapPoolColumn } from '../columns'; import { useRedeem } from './useRedeem'; import { TransactionProgress } from '../../../common/TransactionProgress'; import { NablaTokenPrice } from '../../../common/NablaTokenPrice'; import { FormProvider } from 'react-hook-form'; -import { NumberInput } from '../../../common/NumberInput'; +import { TransactionSettingsDropdown } from '../../../common/TransactionSettingsDropdown'; +import { TokenBalance } from '../../../common/TokenBalance'; +import { AmountSelector } from '../../../common/AmountSelector'; +import Spinner from '../../../../../assets/spinner'; +import { ModalTypes } from '../SwapPoolModals'; + +export type RedeemLiquidityValues = { + amount: number; + slippage?: number | null; +}; export interface RedeemProps { data: SwapPoolColumn; } const Redeem = ({ data }: RedeemProps): JSX.Element | null => { - const { toggle, mutation, onSubmit, balanceQuery, depositQuery, lpTokensDecimalAmount, updateStorage, form } = + const { toggle, mutation, onSubmit, updateStorage, balanceQuery, depositQuery, amountString, form, withdrawalQuote } = useRedeem(data); const { - setError, - clearErrors, register, setValue, formState: { errors }, } = form; - useEffect(() => { - if (depositQuery.balance !== undefined && lpTokensDecimalAmount > depositQuery.balance) { - setError('amount', { type: 'custom', message: 'Amount exceeds owned LP tokens' }); - } else { - clearErrors('amount'); - } - }, [lpTokensDecimalAmount, depositQuery.balance, setError, clearErrors]); - - const deposit = depositQuery.balance || 0; + const totalSupplyOfLpTokens = rawToDecimal(data.totalSupply, data.token.decimals); + const submitEnabled = !withdrawalQuote.isLoading && withdrawalQuote.enabled && Object.keys(errors).length === 0; const hideCss = !mutation.isIdle ? 'hidden' : ''; return (
- +
-

Redeem {data.token?.symbol}

+

Redeem from Backstop Pool

-

Deposited: {depositQuery.isLoading ? : `${depositQuery.formatted || 0} LP`}

+

+ Deposited: +

- Balance:{' '} - {balanceQuery.isLoading ? : `${balanceQuery.formatted || 0} ${data.token.symbol}`} + Balance:

-
-
- - + +
+
+
You will withdraw
+ +
{ setValue('slippage', slippage); @@ -99,46 +85,65 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => { })} />
- ) => - setValue('amount', roundNumber((Number(ev.currentTarget.value) / 100) * deposit, 4), { - shouldDirty: true, - shouldTouch: false, - }) - } - /> -
+ +
Security fee
-
{config.backstop.securityFee * 100}%
+
{(data.insuranceFeeBps / 100).toFixed(2)}%
Price
- +
-
Deposit
-
{roundNumber(deposit)}
+
Total swap pool LP tokens
+
+ {stringifyBigWithSignificantDecimals(totalSupplyOfLpTokens, 2)} {data.symbol} +
-
Pool share
+
Your swap pool share
- {calcSharePercentage(rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), deposit)}% + {depositQuery.data === undefined ? ( + + ) : ( + calcSharePercentage(totalSupplyOfLpTokens, depositQuery.data.preciseBigDecimal) + )} + %
- -
- +
+ -
+
+ {backstopBurnIsPossible && ( +
+ +
+ )}
-
-
Transaction Deadline
- {deadlineProps && ( + {deadlineProps && ( +
+
Transaction Deadline
+
minutes
- )} -
+
+ )}
); }; -export const TransactionSettingsDropdown = (props: TransactionSettingsProps & { button?: ReactNode }) => ( - - {props.button || ( - - )} - - - - -); - -export default TransactionSettings; +export function TransactionSettingsDropdown(props: TransactionSettingsProps & { button?: ReactNode }) { + return ( + + {props.button || ( + + )} + + + + + ); +} diff --git a/src/config/index.ts b/src/config/index.ts index ed69b208..ecafd45a 100644 --- a/src/config/index.ts +++ b/src/config/index.ts @@ -57,7 +57,7 @@ export const config = { defaults: { slippage: 0.1, }, - securityFee: 0.01, // 1% + securityFee: 0.01, // 1% // TODO Torsten: check whether still required }, transaction: { settings: { diff --git a/src/constants/cache.ts b/src/constants/cache.ts index 0b628164..3cc2cd1e 100644 --- a/src/constants/cache.ts +++ b/src/constants/cache.ts @@ -1,16 +1,13 @@ import { UseQueryOptions } from '@tanstack/react-query'; export const cacheKeys = { - assets: 'assets', - backstopPools: 'backstopPools', - swapData: 'swapData', - swapPools: 'swapPools', + accountBalance: 'accountBalance', tokens: 'tokens', tokenAllowance: 'tokenAllowance', balance: 'balance', walletBalance: 'walletBalance', - walletBalances: 'walletBalances', tokenOutAmount: 'tokenOutAmount', + quoteSwapPoolRedeem: 'quoteSwapPoolRedeem', quoteSwapPoolWithdraw: 'quoteSwapPoolWithdraw', sharesTargetWorth: 'sharesTargetWorth', tokenPrice: 'tokenPrice', diff --git a/src/constants/localStorage.ts b/src/constants/localStorage.ts index 74fc749c..5de54126 100644 --- a/src/constants/localStorage.ts +++ b/src/constants/localStorage.ts @@ -2,6 +2,4 @@ export const storageKeys = { ACCOUNT: 'ACCOUNT', SWAP_SETTINGS: 'SWAP_SETTINGS', POOL_SETTINGS: 'POOL_SETTINGS', - GLOBAL: 'GLOBAL', - EXPIRY_DATE: '_EXPIRY_DATE', }; diff --git a/src/helpers/calc.ts b/src/helpers/calc.ts index 0ce5ce5e..95a3ab6c 100644 --- a/src/helpers/calc.ts +++ b/src/helpers/calc.ts @@ -4,6 +4,11 @@ import { NablaInstanceSwapPool } from '../hooks/nabla/useNablaInstance'; export type Percent = number; +// TODO Torsten +// check src/helpers/calc.ts +// - what is needed +// - what is correct + const PRECISION = 10000; /** Calculate fiat value price impact */ export function calcFiatValuePriceImpact( diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index b42812d3..fa930eda 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -1,5 +1,5 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ -import { messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; + import { Abi } from '@polkadot/api-contract'; import { QueryKey, useQuery, UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; @@ -7,17 +7,18 @@ import { useMemo } from 'preact/compat'; import { defaultReadLimits, emptyCacheKey, QueryOptions } from '../../shared/helpers'; import { useSharedState } from '../../shared/Provider'; import { config } from '../../config'; +import { readMessage, ReadMessageResult } from '@pendulum-chain/api-solang'; const isDevelopment = config.isDev; const ALICE = '6mfqoTMHrMeVMyKwjqomUjVomPMJ4AjdCm1VReFtk7Be8wqr'; -export type MessageCallErrorResult = MessageCallResult & { result: { type: 'error' | 'panic' | 'reverted' } }; +export type MessageCallErrorResult = ReadMessageResult & { type: 'error' | 'panic' | 'reverted' }; export type UseContractReadProps = { abi: Dict; address: string | undefined; method: string; - args?: any[]; + args: any[]; noWalletAddressRequired?: boolean; parseSuccessOutput: (successResult: any) => ReturnType; parseError: string | ((errorResult: MessageCallErrorResult) => string); @@ -48,9 +49,23 @@ export function useContractRead( const actualWalletAddress = noWalletAddressRequired ? ALICE : walletAddress; const enabled = !!contractAbi && queryOptions.enabled !== false && !!address && !!api && !!actualWalletAddress; + console.log( + 'Execute contract read', + address, + method, + enabled, + !!contractAbi, + queryOptions.enabled !== false, + !!address, + !!api, + !!actualWalletAddress, + ); const query = useQuery( enabled ? key : emptyCacheKey, async () => { + if (isDevelopment) { + console.log('read', 'Call message enabled', enabled); + } if (!enabled) return; const limits = defaultReadLimits; @@ -59,12 +74,11 @@ export function useContractRead( console.log('read', 'Call message', address, method, args); } - const response = await messageCall({ + const response = await readMessage({ abi: contractAbi, api, - callerAddress: actualWalletAddress, contractDeploymentAddress: address, - getSigner: () => Promise.resolve({} as any), // TODO: cleanup in api-solang lib + callerAddress: actualWalletAddress, messageName: method, messageArguments: args || [], limits, @@ -74,7 +88,7 @@ export function useContractRead( console.log('read', 'Call message result', address, method, args, response); } - if (response.result.type !== 'success') { + if (response.type !== 'success') { let message; if (typeof parseError === 'string') { message = parseError; @@ -84,7 +98,7 @@ export function useContractRead( return Promise.reject(message); } - return parseSuccessOutput(response.result.value); + return parseSuccessOutput(response.value); }, { ...queryOptions, diff --git a/src/hooks/nabla/useContractWrite.ts b/src/hooks/nabla/useContractWrite.ts index 8fb2632f..ecfc7e47 100644 --- a/src/hooks/nabla/useContractWrite.ts +++ b/src/hooks/nabla/useContractWrite.ts @@ -1,7 +1,6 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ -import { messageCall, MessageCallResult } from '@pendulum-chain/api-solang'; +import { executeMessage, ExecuteMessageResult } from '@pendulum-chain/api-solang'; import { Abi } from '@polkadot/api-contract'; -import { ExtrinsicStatus } from '@polkadot/types/interfaces'; import { MutationOptions, useMutation, UseMutationResult } from '@tanstack/react-query'; import { useCallback, useMemo } from 'preact/compat'; @@ -12,21 +11,15 @@ import { config } from '../../config'; const isDevelopment = config.isDev; -// TODO: fix/improve types - parse abi file -export type TransactionsStatus = { - hex?: string; - status?: ExtrinsicStatus['type'] | 'Pending'; -}; - export type UseContractWriteProps> = { abi: TAbi; address?: string; method: string; args?: any[]; - mutateOptions: Partial>; + mutateOptions: Partial>; }; -export type UseContractWriteResponse = UseMutationResult & { +export type UseContractWriteResponse = UseMutationResult & { isReady: boolean; }; @@ -46,7 +39,7 @@ export function useContractWrite>({ const isReady = !!contractAbi && !!address && !!api && !!walletAddress && !!signer; const submit = useCallback( - async (submitArgs?: any[]): Promise => { + async (submitArgs?: any[]): Promise => { if (!isReady) throw 'Missing data'; //setTransaction({ status: 'Pending' }); const fnArgs = submitArgs || args || []; @@ -57,7 +50,7 @@ export function useContractWrite>({ console.log('write', 'limits', { ...defaultWriteLimits, ...contractOptions }); } - const response = await messageCall({ + const response = await executeMessage({ abi: contractAbi, api, callerAddress: walletAddress, @@ -87,5 +80,3 @@ export function useContractWrite>({ const mutation = useMutation(submit, mutateOptions); return { ...mutation, isReady }; } - -// export type UseContractWriteResponse = ReturnType; diff --git a/src/hooks/nabla/useErc20ContractBalance.ts b/src/hooks/nabla/useErc20ContractBalance.ts index 3fb21596..c8aaaa9d 100644 --- a/src/hooks/nabla/useErc20ContractBalance.ts +++ b/src/hooks/nabla/useErc20ContractBalance.ts @@ -1,5 +1,5 @@ +import { cacheKeys } from '../../constants/cache'; import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; -import { cacheKeys } from '../../shared/constants'; import { useSharedState } from '../../shared/Provider'; import { UseContractReadResult, useContractRead } from './useContractRead'; diff --git a/src/hooks/nabla/useErc20TokenAllowance.ts b/src/hooks/nabla/useErc20TokenAllowance.ts index 86028ba5..3d651ace 100644 --- a/src/hooks/nabla/useErc20TokenAllowance.ts +++ b/src/hooks/nabla/useErc20TokenAllowance.ts @@ -1,6 +1,5 @@ import { erc20WrapperAbi } from '../../contracts/nabla/ERC20Wrapper'; -import { cacheKeys } from '../../shared/constants'; -import { activeOptions } from '../../constants/cache'; +import { activeOptions, cacheKeys } from '../../constants/cache'; import { useContractRead } from './useContractRead'; import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; diff --git a/src/hooks/nabla/useQuoteSwapPoolRedeem.ts b/src/hooks/nabla/useQuoteSwapPoolRedeem.ts new file mode 100644 index 00000000..0473c2e8 --- /dev/null +++ b/src/hooks/nabla/useQuoteSwapPoolRedeem.ts @@ -0,0 +1,102 @@ +import { Big } from 'big.js'; + +import { activeOptions, cacheKeys } from '../../constants/cache'; +import { multiplyByPowerOfTen } from '../../shared/parseNumbers/metric'; +import { useContractRead } from './useContractRead'; +import { useDebouncedValue } from '../useDebouncedValue'; +import { FieldValues, UseFormReturn } from 'react-hook-form'; +import { useEffect } from 'preact/hooks'; +import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; +import { backstopPoolAbi } from '../../contracts/nabla/BackstopPool'; + +export type UseQuoteSwapPoolRedeemProps = { + swapPoolLpTokenAmountString: string | undefined; + swapPoolLpTokenDecimals: number; + maximumSwapPoolLpTokenAmount: Big | undefined; + backstopPoolTokenDecimals: number; + backstopPoolAddress: string; + swapPoolAddress: string; + form: UseFormReturn; +}; + +// TODO Torsten: check whether the swap quote works the same + +export function useQuoteSwapPoolRedeem({ + swapPoolLpTokenAmountString, + swapPoolLpTokenDecimals, + maximumSwapPoolLpTokenAmount, + backstopPoolTokenDecimals, + backstopPoolAddress, + swapPoolAddress, + form, +}: UseQuoteSwapPoolRedeemProps) { + const { setError, clearErrors } = form; + + const debouncedAmountString = useDebouncedValue(swapPoolLpTokenAmountString, 800); + + let debouncedAmountBigDecimal; + try { + debouncedAmountBigDecimal = debouncedAmountString !== undefined ? new Big(debouncedAmountString) : undefined; + } catch { + debouncedAmountBigDecimal = undefined; + } + const enabled = + debouncedAmountBigDecimal !== undefined && + debouncedAmountBigDecimal.gt(new Big(0)) && + (maximumSwapPoolLpTokenAmount === undefined || debouncedAmountBigDecimal.lte(maximumSwapPoolLpTokenAmount)); + + // TODO Torsten: check whether the other calls also round like this + const amountIn = + debouncedAmountBigDecimal !== undefined + ? multiplyByPowerOfTen(debouncedAmountBigDecimal, swapPoolLpTokenDecimals).round(0, 0).toString() + : undefined; + + const { isLoading, fetchStatus, data, error } = useContractRead( + [cacheKeys.quoteSwapPoolRedeem, backstopPoolAddress, swapPoolAddress, amountIn], + { + abi: backstopPoolAbi, + address: backstopPoolAddress, + method: 'redeemSwapPoolShares', + args: [swapPoolAddress, amountIn, '0'], + queryOptions: { + ...activeOptions['15s'], + enabled, + }, + parseSuccessOutput: parseContractBalanceResponse.bind(null, backstopPoolTokenDecimals), + parseError: (error) => { + switch (error.type) { + case 'error': + return 'Cannot determine value of shares'; + case 'panic': + return error.errorCode === 0x11 + ? 'The input amount is too large. You cannot redeem all LP tokens right now.' + : 'Cannot determine value of shares'; + case 'reverted': + switch (error.description) { + case 'redeemSwapPoolShares():MIN_AMOUNT': + return 'The returned amount of tokens is below your desired minimum amount.'; + case 'SwapPool#backstopBurn: BALANCE_TOO_LOW': + return "You don't have enough LP tokens to redeem."; + case 'SwapPool#backstopBurn: TIMELOCK': + return 'You cannot redeem tokens from the backstop pool yet.'; + case 'SwapPool#backstopBurn():INSUFFICIENT_COVERAGE': + return 'The input amount is too large.'; + } + return 'Cannot determine value of shares'; + } + }, + }, + ); + + const pending = (isLoading && fetchStatus !== 'idle') || debouncedAmountString !== swapPoolLpTokenAmountString; + useEffect(() => { + if (pending) return; + if (error === null) { + clearErrors('root'); + } else { + setError('root', { type: 'custom', message: error }); + } + }, [error, pending, clearErrors, setError]); + + return { isLoading: pending, enabled, data, error }; +} diff --git a/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts b/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts index 1f1704ad..ea24b41b 100644 --- a/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts +++ b/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts @@ -40,8 +40,8 @@ export function useQuoteSwapPoolWithdraw({ } const enabled = debouncedAmountBigDecimal !== undefined && - (maximumLpTokenAmount === undefined || - (debouncedAmountBigDecimal.lte(maximumLpTokenAmount) && debouncedAmountBigDecimal?.gt(new Big(0)))); + debouncedAmountBigDecimal?.gt(new Big(0)) && + (maximumLpTokenAmount === undefined || debouncedAmountBigDecimal.lte(maximumLpTokenAmount)); // TODO Torsten: check whether the other calls also round like this const amountIn = @@ -58,17 +58,17 @@ export function useQuoteSwapPoolWithdraw({ args: [amountIn], noWalletAddressRequired: true, queryOptions: { - ...activeOptions['30s'], + ...activeOptions['15s'], enabled, }, parseSuccessOutput: parseContractBalanceResponse.bind(null, poolTokenDecimals), parseError: (error) => { - switch (error.result.type) { + switch (error.type) { case 'error': return 'Cannot determine value of shares'; case 'panic': - return error.result.errorCode === 0x11 - ? 'The input amount is too large' + return error.errorCode === 0x11 + ? 'The input amount is too large. You cannot directly redeem all LP tokens right now. Try to redeem from the backstop pool instead.' : 'Cannot determine value of shares'; case 'reverted': return 'Cannot determine value of shares'; diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index 539f2646..da0a9802 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -52,13 +52,13 @@ export function useTokenOutAmount({ swapFee: parseContractBalanceResponse(toTokenDecimals, data[1]), }, parseError: (error) => { - switch (error.result.type) { + switch (error.type) { case 'error': return 'Something went wrong'; case 'panic': - return error.result.errorCode === 0x11 ? 'The input amount is too large' : 'Something went wrong'; + return error.errorCode === 0x11 ? 'The input amount is too large' : 'Something went wrong'; case 'reverted': - return error.result.description === 'SwapPool: EXCEEDS_MAX_COVERAGE_RATIO' + return error.description === 'SwapPool: EXCEEDS_MAX_COVERAGE_RATIO' ? 'The input amount is too large' : 'Something went wrong'; } diff --git a/src/shared/constants.ts b/src/shared/constants.ts index 924c2b3f..7ddfe78d 100644 --- a/src/shared/constants.ts +++ b/src/shared/constants.ts @@ -1,9 +1,3 @@ -export const cacheKeys = { - balance: 'balance', - accountBalance: 'accountBalance', - tokenAllowance: 'tokenAllowance', -}; - export const MINUTE_IN_MILLISECONDS = 60 * 1000; export const SECONDS_IN_A_DAY = 86400; export const BLOCK_TIME_SEC = 12; diff --git a/src/shared/parseNumbers/metric.ts b/src/shared/parseNumbers/metric.ts index b7cd04cc..9e7425ef 100644 --- a/src/shared/parseNumbers/metric.ts +++ b/src/shared/parseNumbers/metric.ts @@ -137,7 +137,7 @@ export function roundDownToSignificantDecimals(big: BigNumber, decimals: number) export function stringifyBigWithSignificantDecimals(big: BigNumber, decimals: number) { const rounded = roundDownToSignificantDecimals(big, decimals); - return rounded.toFixed(); + return rounded.toFixed(decimals + Math.max(0, -(big.e + 1))); } // TODO Torsten: check whether this can used everywhere to construct cleaner zeros diff --git a/src/shared/useAccountBalance.ts b/src/shared/useAccountBalance.ts index e32eefc0..54348d17 100644 --- a/src/shared/useAccountBalance.ts +++ b/src/shared/useAccountBalance.ts @@ -1,10 +1,10 @@ import { FrameSystemAccountInfo } from '@polkadot/types/lookup'; import { useQuery, UseQueryResult } from '@tanstack/react-query'; import { useMemo } from 'preact/compat'; -import { cacheKeys } from './constants'; import { emptyCacheKey, QueryOptions } from './helpers'; import { nativeToDecimal, prettyNumbers } from './parseNumbers/metric'; import { useSharedState } from './Provider'; +import { cacheKeys } from '../constants/cache'; export interface UseAccountBalanceResponse { query: UseQueryResult; diff --git a/yarn.lock b/yarn.lock index 59714960..dac66f10 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1484,7 +1484,7 @@ __metadata: languageName: node linkType: hard -"@babel/runtime@npm:^7.0.0, @babel/runtime@npm:^7.10.2, @babel/runtime@npm:^7.12.5, @babel/runtime@npm:^7.20.13, @babel/runtime@npm:^7.20.6, @babel/runtime@npm:^7.23.8, @babel/runtime@npm:^7.8.4, @babel/runtime@npm:^7.9.2": +"@babel/runtime@npm:^7.0.0, @babel/runtime@npm:^7.10.2, @babel/runtime@npm:^7.12.5, @babel/runtime@npm:^7.23.8, @babel/runtime@npm:^7.8.4, @babel/runtime@npm:^7.9.2": version: 7.24.5 resolution: "@babel/runtime@npm:7.24.5" dependencies: @@ -1966,8 +1966,8 @@ __metadata: linkType: hard "@graphql-tools/delegate@npm:^10.0.4": - version: 10.0.7 - resolution: "@graphql-tools/delegate@npm:10.0.7" + version: 10.0.10 + resolution: "@graphql-tools/delegate@npm:10.0.10" dependencies: "@graphql-tools/batch-execute": "npm:^9.0.4" "@graphql-tools/executor": "npm:^1.2.1" @@ -1977,7 +1977,7 @@ __metadata: tslib: "npm:^2.5.0" peerDependencies: graphql: ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0 - checksum: af0c30e7ee4da547ac6bfc460c74b09756c0bf6cd44ffcf45591c60257e653c9e66b75b7b6d02916d2e9fa6bd87b3132caad2ff1cb9fdbf3c7fdb34e13049247 + checksum: b132f123ac3a9d5d8be8984704674ca09747e7e6308da63e09f8db35fdc210853ad8a2ed5184e27ce18af3324a3739149258b35069c74a927f5a320d551c30cf languageName: node linkType: hard @@ -2789,13 +2789,6 @@ __metadata: languageName: node linkType: hard -"@noble/hashes@npm:1.2.0": - version: 1.2.0 - resolution: "@noble/hashes@npm:1.2.0" - checksum: 8bd3edb7bb6a9068f806a9a5a208cc2144e42940a21c049d8e9a0c23db08bef5cf1cfd844a7e35489b5ab52c6fa6299352075319e7f531e0996d459c38cfe26a - languageName: node - linkType: hard - "@noble/hashes@npm:1.4.0, @noble/hashes@npm:^1.3.1, @noble/hashes@npm:^1.3.3": version: 1.4.0 resolution: "@noble/hashes@npm:1.4.0" @@ -2803,13 +2796,6 @@ __metadata: languageName: node linkType: hard -"@noble/secp256k1@npm:1.7.1": - version: 1.7.1 - resolution: "@noble/secp256k1@npm:1.7.1" - checksum: 48091801d39daba75520012027d0ff0b1719338d96033890cfe0d287ad75af00d82769c0194a06e7e4fbd816ae3f204f4a59c9e26f0ad16b429f7e9b5403ccd5 - languageName: node - linkType: hard - "@nodelib/fs.scandir@npm:2.1.5": version: 2.1.5 resolution: "@nodelib/fs.scandir@npm:2.1.5" @@ -2851,8 +2837,8 @@ __metadata: linkType: hard "@npmcli/arborist@npm:^7.2.1": - version: 7.5.0 - resolution: "@npmcli/arborist@npm:7.5.0" + version: 7.5.1 + resolution: "@npmcli/arborist@npm:7.5.1" dependencies: "@isaacs/string-locale-compare": "npm:^1.1.0" "@npmcli/fs": "npm:^3.1.0" @@ -2863,8 +2849,8 @@ __metadata: "@npmcli/node-gyp": "npm:^3.0.0" "@npmcli/package-json": "npm:^5.1.0" "@npmcli/query": "npm:^3.1.0" - "@npmcli/redact": "npm:^1.1.0" - "@npmcli/run-script": "npm:^8.0.0" + "@npmcli/redact": "npm:^2.0.0" + "@npmcli/run-script": "npm:^8.1.0" bin-links: "npm:^4.0.1" cacache: "npm:^18.0.0" common-ancestor-path: "npm:^1.0.1" @@ -2876,7 +2862,7 @@ __metadata: npm-install-checks: "npm:^6.2.0" npm-package-arg: "npm:^11.0.2" npm-pick-manifest: "npm:^9.0.0" - npm-registry-fetch: "npm:^16.2.1" + npm-registry-fetch: "npm:^17.0.0" pacote: "npm:^18.0.1" parse-conflict-json: "npm:^3.0.0" proc-log: "npm:^4.2.0" @@ -2890,13 +2876,13 @@ __metadata: walk-up-path: "npm:^3.0.1" bin: arborist: bin/index.js - checksum: 5113e81f2c4c98ec9a3c279068a6f9637012878b396505fbb9e21fa8e7507272c15590c77860e17946e6d37b0f5e706b9efff8427ccee87c6053e0bb7151b148 + checksum: aceb8589d82a569e4290148ede7a8e83ee18d13c77d093bfdfd0be687b350d5609f0120b6a96f865594c8df6f6fa0db455234416b94605056f10dafce33b0b63 languageName: node linkType: hard "@npmcli/config@npm:^8.0.2": - version: 8.3.0 - resolution: "@npmcli/config@npm:8.3.0" + version: 8.3.1 + resolution: "@npmcli/config@npm:8.3.1" dependencies: "@npmcli/map-workspaces": "npm:^3.0.2" ci-info: "npm:^4.0.0" @@ -2906,22 +2892,22 @@ __metadata: read-package-json-fast: "npm:^3.0.2" semver: "npm:^7.3.5" walk-up-path: "npm:^3.0.1" - checksum: 257e45f2288d69198c8acb8564a9265a3326e7aa96b76e1aa880a245735bcc9acc53d5498c3d102f42691033e888587763956264846cd9a7bd84c37a53f71735 + checksum: d53e1797ddb29d9171f685761e4354b8bea5b73d414310bbf28cd697e4965ae85758b4ce9e25e4a3ea463a8125ae316ed4a30045aaec29df982447886a845b81 languageName: node linkType: hard "@npmcli/fs@npm:^3.1.0": - version: 3.1.0 - resolution: "@npmcli/fs@npm:3.1.0" + version: 3.1.1 + resolution: "@npmcli/fs@npm:3.1.1" dependencies: semver: "npm:^7.3.5" - checksum: 162b4a0b8705cd6f5c2470b851d1dc6cd228c86d2170e1769d738c1fbb69a87160901411c3c035331e9e99db72f1f1099a8b734bf1637cc32b9a5be1660e4e1e + checksum: c37a5b4842bfdece3d14dfdb054f73fe15ed2d3da61b34ff76629fb5b1731647c49166fd2a8bf8b56fcfa51200382385ea8909a3cbecdad612310c114d3f6c99 languageName: node linkType: hard -"@npmcli/git@npm:^5.0.0, @npmcli/git@npm:^5.0.3": - version: 5.0.6 - resolution: "@npmcli/git@npm:5.0.6" +"@npmcli/git@npm:^5.0.0, @npmcli/git@npm:^5.0.6": + version: 5.0.7 + resolution: "@npmcli/git@npm:5.0.7" dependencies: "@npmcli/promise-spawn": "npm:^7.0.0" lru-cache: "npm:^10.0.1" @@ -2931,7 +2917,7 @@ __metadata: promise-retry: "npm:^2.0.1" semver: "npm:^7.3.5" which: "npm:^4.0.0" - checksum: 5cb92105517c855f640e97cd9eacf874d14b00c1eb5d96d840378793e7892422a440fb0ea09ac3bc327c73103ae93e4a32bc2482c172e0c84df83926d136aedb + checksum: d9895fce3e554e927411ead941d434233585a3edaf8d2ebe3e8d48fdd14e2ce238d227248df30e3300b1c050e982459f4d0b18375bd3c17c4edeb0621da33ade languageName: node linkType: hard @@ -2960,15 +2946,15 @@ __metadata: linkType: hard "@npmcli/metavuln-calculator@npm:^7.1.0": - version: 7.1.0 - resolution: "@npmcli/metavuln-calculator@npm:7.1.0" + version: 7.1.1 + resolution: "@npmcli/metavuln-calculator@npm:7.1.1" dependencies: cacache: "npm:^18.0.0" json-parse-even-better-errors: "npm:^3.0.0" pacote: "npm:^18.0.0" proc-log: "npm:^4.1.0" semver: "npm:^7.3.5" - checksum: ba3fc89843f70b7559f9c03da094bfddd77a020be0339d7b67a7c3f8143eedeac0cf12365ab1ea12ec5f39bfd212285db2bc7c95c78b19204d453af45c03c4ea + checksum: 27402cab124bb1fca56af7549f730c38c0ab40de60cbef6264a4193c26c2d28cefb2adac29ed27f368031795704f9f8fe0c547c4c8cb0c0fa94d72330d56ac80 languageName: node linkType: hard @@ -3002,11 +2988,11 @@ __metadata: linkType: hard "@npmcli/promise-spawn@npm:^7.0.0, @npmcli/promise-spawn@npm:^7.0.1": - version: 7.0.1 - resolution: "@npmcli/promise-spawn@npm:7.0.1" + version: 7.0.2 + resolution: "@npmcli/promise-spawn@npm:7.0.2" dependencies: which: "npm:^4.0.0" - checksum: 441024049170fc9dd0c793fef7366fd1b2a36c06f1036c52ac4a5d0f2d46deced89f2a94fef20f51aa9934edb4d611ff76b060be2b82086d29d2094ee1b46122 + checksum: 8f2af5bc2c1b1ccfb9bcd91da8873ab4723616d8bd5af877c0daa40b1e2cbfa4afb79e052611284179cae918c945a1b99ae1c565d78a355bec1a461011e89f71 languageName: node linkType: hard @@ -3019,13 +3005,6 @@ __metadata: languageName: node linkType: hard -"@npmcli/redact@npm:^1.1.0": - version: 1.1.0 - resolution: "@npmcli/redact@npm:1.1.0" - checksum: 886995220e60ca00405c93c5588aff524d1dbfee0ca8688b9607fefcda42aa464d4a3f7c75fc03a16a582befe4b6c3ac4493d67c4eb07da2fe0794fbe0dfc89b - languageName: node - linkType: hard - "@npmcli/redact@npm:^2.0.0": version: 2.0.0 resolution: "@npmcli/redact@npm:2.0.0" @@ -3033,20 +3012,7 @@ __metadata: languageName: node linkType: hard -"@npmcli/run-script@npm:^7.0.0, @npmcli/run-script@npm:^7.0.2": - version: 7.0.4 - resolution: "@npmcli/run-script@npm:7.0.4" - dependencies: - "@npmcli/node-gyp": "npm:^3.0.0" - "@npmcli/package-json": "npm:^5.0.0" - "@npmcli/promise-spawn": "npm:^7.0.0" - node-gyp: "npm:^10.0.0" - which: "npm:^4.0.0" - checksum: 45159ef7d6b8d9e449e87ed401da69da60514f6e7752e268f29a96f17a543c4a8d4eea6fe2f74b07fd41095e48e0f9859ebec558065d2b01849b382b06fefe35 - languageName: node - linkType: hard - -"@npmcli/run-script@npm:^8.0.0": +"@npmcli/run-script@npm:^8.0.0, @npmcli/run-script@npm:^8.1.0": version: 8.1.0 resolution: "@npmcli/run-script@npm:8.1.0" dependencies: @@ -3428,18 +3394,18 @@ __metadata: languageName: node linkType: hard -"@pendulum-chain/api-solang@npm:^0.2.0": - version: 0.2.0 - resolution: "@pendulum-chain/api-solang@npm:0.2.0" +"@pendulum-chain/api-solang@npm:0.3.0": + version: 0.3.0 + resolution: "@pendulum-chain/api-solang@npm:0.3.0" peerDependencies: - "@polkadot/api": ^10.9.1 - "@polkadot/api-contract": ^10.9.1 - "@polkadot/keyring": ^12.3.2 - "@polkadot/types": ^10.9.1 - "@polkadot/types-codec": ^10.9.1 - "@polkadot/util": ^12.3.2 - "@polkadot/util-crypto": ^12.3.2 - checksum: a118e81af407c15c5dfb94cc3ee52f251bd5dfd57b3f60b10b081854ec5ff5acb1845a62a5fcb509c67c0e6cc9e7c4df3fbe1b53535f6cf9270b148658fac282 + "@polkadot/api": ^10.0 + "@polkadot/api-contract": ^10.12.1 + "@polkadot/keyring": "*" + "@polkadot/types": ^10.0 + "@polkadot/types-codec": ^10.0 + "@polkadot/util": "*" + "@polkadot/util-crypto": "*" + checksum: 4b5912664a270f830a3627a98480853e38df2cfab39d0fc240d2a77c0bcaa509dbd81918089cf7ee5ce70c149829de340585ae802789315b195146b3fb518741 languageName: node linkType: hard @@ -3596,21 +3562,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/api-augment@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/api-augment@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/api-base": "npm:9.14.2" - "@polkadot/rpc-augment": "npm:9.14.2" - "@polkadot/types": "npm:9.14.2" - "@polkadot/types-augment": "npm:9.14.2" - "@polkadot/types-codec": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - checksum: 8d0dd51087913e5fb820e107be3267cc1596e83383d43578cec970421867be9f96bf8e71d7bb053687e864611b65149b7efc65c3c14bd5ba865d170f10492ae3 - languageName: node - linkType: hard - "@polkadot/api-base@npm:10.13.1, @polkadot/api-base@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/api-base@npm:10.13.1" @@ -3624,19 +3575,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/api-base@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/api-base@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/rpc-core": "npm:9.14.2" - "@polkadot/types": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - rxjs: "npm:^7.8.0" - checksum: 320b796a1c30546f979f26f3a01a66ffc15df32582eec24afdc655c62f8fb974885ea651badf26c754fe4f4f27397d0c67fa952c6453b87ba65ddf34a9d709a6 - languageName: node - linkType: hard - "@polkadot/api-contract@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/api-contract@npm:10.13.1" @@ -3672,25 +3610,7 @@ __metadata: languageName: node linkType: hard -"@polkadot/api-derive@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/api-derive@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/api": "npm:9.14.2" - "@polkadot/api-augment": "npm:9.14.2" - "@polkadot/api-base": "npm:9.14.2" - "@polkadot/rpc-core": "npm:9.14.2" - "@polkadot/types": "npm:9.14.2" - "@polkadot/types-codec": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - "@polkadot/util-crypto": "npm:^10.4.2" - rxjs: "npm:^7.8.0" - checksum: 12746625931a8a93be0006ce2a31ccb081d8db5da9e0c18cbbb4250153e7726d54a375d590ebb164c93f70f0bb62de4db0b533cbb6b4d42774c6b7ecbc4751f6 - languageName: node - linkType: hard - -"@polkadot/api@npm:10.13.1, @polkadot/api@npm:^10.12.4, @polkadot/api@npm:^10.6.1, @polkadot/api@npm:^10.9.1": +"@polkadot/api@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/api@npm:10.13.1" dependencies: @@ -3715,31 +3635,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/api@npm:9.14.2, @polkadot/api@npm:^9.3.3": - version: 9.14.2 - resolution: "@polkadot/api@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/api-augment": "npm:9.14.2" - "@polkadot/api-base": "npm:9.14.2" - "@polkadot/api-derive": "npm:9.14.2" - "@polkadot/keyring": "npm:^10.4.2" - "@polkadot/rpc-augment": "npm:9.14.2" - "@polkadot/rpc-core": "npm:9.14.2" - "@polkadot/rpc-provider": "npm:9.14.2" - "@polkadot/types": "npm:9.14.2" - "@polkadot/types-augment": "npm:9.14.2" - "@polkadot/types-codec": "npm:9.14.2" - "@polkadot/types-create": "npm:9.14.2" - "@polkadot/types-known": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - "@polkadot/util-crypto": "npm:^10.4.2" - eventemitter3: "npm:^5.0.0" - rxjs: "npm:^7.8.0" - checksum: 37d037409969685f8362ec7cd829e86a612dedab1e955fb77e9d251585982fa2d10eab951c1776e7b75809144f951dd4dcec848780bd1236d4a21c7b6fd63f79 - languageName: node - linkType: hard - "@polkadot/extension-dapp@npm:^0.46.5": version: 0.46.9 resolution: "@polkadot/extension-dapp@npm:0.46.9" @@ -3756,7 +3651,7 @@ __metadata: languageName: node linkType: hard -"@polkadot/extension-inject@npm:0.46.9, @polkadot/extension-inject@npm:^0.46.5": +"@polkadot/extension-inject@npm:^0.46.9": version: 0.46.9 resolution: "@polkadot/extension-inject@npm:0.46.9" dependencies: @@ -3774,36 +3669,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/extension-inject@npm:^0.44.6": - version: 0.44.9 - resolution: "@polkadot/extension-inject@npm:0.44.9" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/rpc-provider": "npm:^9.14.2" - "@polkadot/types": "npm:^9.14.2" - "@polkadot/util": "npm:^10.4.2" - "@polkadot/util-crypto": "npm:^10.4.2" - "@polkadot/x-global": "npm:^10.4.2" - peerDependencies: - "@polkadot/api": "*" - checksum: 7cfbd2306000f221e50edab84f9a7b9716a0409463ea6471fc14266ff54b4441a8f965fc1b21229756f339642cc7ba7981cf46a3acf5190bad1fd745ea425440 - languageName: node - linkType: hard - -"@polkadot/keyring@npm:^10.4.2": - version: 10.4.2 - resolution: "@polkadot/keyring@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/util": "npm:10.4.2" - "@polkadot/util-crypto": "npm:10.4.2" - peerDependencies: - "@polkadot/util": 10.4.2 - "@polkadot/util-crypto": 10.4.2 - checksum: 3e21a72727e3f77b0a54ae8813f2c28dd25159ec9de8cfdb8ee916b2ce119815a623b721f40b70950868b8754d4c5c55b917d393b8bea92ebcf79b7570a71df2 - languageName: node - linkType: hard - "@polkadot/keyring@npm:^12.3.2, @polkadot/keyring@npm:^12.6.2": version: 12.6.2 resolution: "@polkadot/keyring@npm:12.6.2" @@ -3818,17 +3683,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/networks@npm:10.4.2, @polkadot/networks@npm:^10.4.2": - version: 10.4.2 - resolution: "@polkadot/networks@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/util": "npm:10.4.2" - "@substrate/ss58-registry": "npm:^1.38.0" - checksum: 0afaab8ef911f5d817caa321313c498710d8ee2f5730c084613f4a4b515eaff38769438e47e2a492ada522ce9d1e27b50e829259432c117a9dac5d2594bd11aa - languageName: node - linkType: hard - "@polkadot/networks@npm:12.6.2, @polkadot/networks@npm:^12.6.2": version: 12.6.2 resolution: "@polkadot/networks@npm:12.6.2" @@ -3853,19 +3707,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/rpc-augment@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/rpc-augment@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/rpc-core": "npm:9.14.2" - "@polkadot/types": "npm:9.14.2" - "@polkadot/types-codec": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - checksum: 06dba394a8b682a5af87751bdf40aa20fd0367a47b885580affedc3991c5b3b4dd880916ac7b880635c198a2757ee0e7212abd055149adb1cae9dcd2dde0d814 - languageName: node - linkType: hard - "@polkadot/rpc-core@npm:10.13.1, @polkadot/rpc-core@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/rpc-core@npm:10.13.1" @@ -3880,20 +3721,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/rpc-core@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/rpc-core@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/rpc-augment": "npm:9.14.2" - "@polkadot/rpc-provider": "npm:9.14.2" - "@polkadot/types": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - rxjs: "npm:^7.8.0" - checksum: 4eaea12bbb87cc8fcb1ae1a7fadc8fff8bce4cf452cd53aae2c35d4d5cac35a8baf990b8780a65672720ef7eec24c06fed92b0f7d55e97d3463e8f6d3590104a - languageName: node - linkType: hard - "@polkadot/rpc-provider@npm:10.13.1, @polkadot/rpc-provider@npm:^10.12.4, @polkadot/rpc-provider@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/rpc-provider@npm:10.13.1" @@ -3918,30 +3745,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/rpc-provider@npm:9.14.2, @polkadot/rpc-provider@npm:^9.14.2": - version: 9.14.2 - resolution: "@polkadot/rpc-provider@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/keyring": "npm:^10.4.2" - "@polkadot/types": "npm:9.14.2" - "@polkadot/types-support": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - "@polkadot/util-crypto": "npm:^10.4.2" - "@polkadot/x-fetch": "npm:^10.4.2" - "@polkadot/x-global": "npm:^10.4.2" - "@polkadot/x-ws": "npm:^10.4.2" - "@substrate/connect": "npm:0.7.19" - eventemitter3: "npm:^5.0.0" - mock-socket: "npm:^9.2.1" - nock: "npm:^13.3.0" - dependenciesMeta: - "@substrate/connect": - optional: true - checksum: 3c288103a5c8766b43824891980ecac1ff16d675388424ac316851c2a80ee2928922f2eaee5e504e2f67720653c7f734c9818df6fee3fbb735616f83679179e5 - languageName: node - linkType: hard - "@polkadot/types-augment@npm:10.13.1, @polkadot/types-augment@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/types-augment@npm:10.13.1" @@ -3954,18 +3757,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/types-augment@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/types-augment@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/types": "npm:9.14.2" - "@polkadot/types-codec": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - checksum: ef556ec47cdd06d102acce3e486a0b912656b7faff49833c3cfe09ace4da73a6c2c667122e4ae35bd76a90f078d9bf096ef9d4340bf6e0dd168db0dc36e40de2 - languageName: node - linkType: hard - "@polkadot/types-codec@npm:10.13.1, @polkadot/types-codec@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/types-codec@npm:10.13.1" @@ -3977,17 +3768,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/types-codec@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/types-codec@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/util": "npm:^10.4.2" - "@polkadot/x-bigint": "npm:^10.4.2" - checksum: bd19b5e7ee73e5706f8481d7d5e8d97a5ab3388590a769b2edf38ea28d1ca12a3d7b13189d0df108e9ec0dae475166a109ce3ba5e81cc2b47aa76389e72c17a8 - languageName: node - linkType: hard - "@polkadot/types-create@npm:10.13.1, @polkadot/types-create@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/types-create@npm:10.13.1" @@ -3999,17 +3779,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/types-create@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/types-create@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/types-codec": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - checksum: 5eb636d24e98f0b5003bab5bd9bddb773da999f7d37d7941868db9244535bbfed8eb867fedb2390f73191fa86bfbda46fe4c349f361943d9a9cd5e5c6de88041 - languageName: node - linkType: hard - "@polkadot/types-known@npm:10.13.1, @polkadot/types-known@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/types-known@npm:10.13.1" @@ -4024,20 +3793,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/types-known@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/types-known@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/networks": "npm:^10.4.2" - "@polkadot/types": "npm:9.14.2" - "@polkadot/types-codec": "npm:9.14.2" - "@polkadot/types-create": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - checksum: 16a6d79b8828d4eb7714dad99cc00678d1fac62dfc94fcbce12b798714f8b351a40b55a0a7c9967d5025cffda60d99e3178763be8a81fad24d28768d1a90605f - languageName: node - linkType: hard - "@polkadot/types-support@npm:10.13.1": version: 10.13.1 resolution: "@polkadot/types-support@npm:10.13.1" @@ -4048,16 +3803,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/types-support@npm:9.14.2": - version: 9.14.2 - resolution: "@polkadot/types-support@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/util": "npm:^10.4.2" - checksum: 91671d5f54940b6577eec79b985818f3def241de53de5f57b2324b15a6232dc47f971d872e52ee4ee7d379f11331ae0e13c996487ca82e14f131d346f5b71f88 - languageName: node - linkType: hard - "@polkadot/types@npm:10.13.1, @polkadot/types@npm:^10.12.4, @polkadot/types@npm:^10.9.1": version: 10.13.1 resolution: "@polkadot/types@npm:10.13.1" @@ -4074,43 +3819,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/types@npm:9.14.2, @polkadot/types@npm:^9.14.2": - version: 9.14.2 - resolution: "@polkadot/types@npm:9.14.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/keyring": "npm:^10.4.2" - "@polkadot/types-augment": "npm:9.14.2" - "@polkadot/types-codec": "npm:9.14.2" - "@polkadot/types-create": "npm:9.14.2" - "@polkadot/util": "npm:^10.4.2" - "@polkadot/util-crypto": "npm:^10.4.2" - rxjs: "npm:^7.8.0" - checksum: af1285f696a16d984ef4754d21d6a028b97ddb852c9aa462e23c5f58dfc692421ef56f6e7f64555532eddeb3442815f36cd13ecfd7dc00b1fc20879402065366 - languageName: node - linkType: hard - -"@polkadot/util-crypto@npm:10.4.2, @polkadot/util-crypto@npm:^10.4.2": - version: 10.4.2 - resolution: "@polkadot/util-crypto@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@noble/hashes": "npm:1.2.0" - "@noble/secp256k1": "npm:1.7.1" - "@polkadot/networks": "npm:10.4.2" - "@polkadot/util": "npm:10.4.2" - "@polkadot/wasm-crypto": "npm:^6.4.1" - "@polkadot/x-bigint": "npm:10.4.2" - "@polkadot/x-randomvalues": "npm:10.4.2" - "@scure/base": "npm:1.1.1" - ed2curve: "npm:^0.3.0" - tweetnacl: "npm:^1.0.3" - peerDependencies: - "@polkadot/util": 10.4.2 - checksum: 1651146a2a70d632459ee891eb3af0e3c19a52a9e80abf7ff15a99cc3d7732e3cf7c8f0e86415502113b7dd1eeb801d6b70d7db1994fe8159af9c0d37e2c9af3 - languageName: node - linkType: hard - "@polkadot/util-crypto@npm:12.6.2, @polkadot/util-crypto@npm:^12.6.2": version: 12.6.2 resolution: "@polkadot/util-crypto@npm:12.6.2" @@ -4131,21 +3839,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/util@npm:10.4.2, @polkadot/util@npm:^10.1.9, @polkadot/util@npm:^10.4.2": - version: 10.4.2 - resolution: "@polkadot/util@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/x-bigint": "npm:10.4.2" - "@polkadot/x-global": "npm:10.4.2" - "@polkadot/x-textdecoder": "npm:10.4.2" - "@polkadot/x-textencoder": "npm:10.4.2" - "@types/bn.js": "npm:^5.1.1" - bn.js: "npm:^5.2.1" - checksum: b1b8fefa9482ef6f6cbbb2aa7f7cac873bc2cf8552170d3d4bca388675cd3b707d3eb965e1df93bc1c2ff49c9dc4dfbb0690f1212a201148b6d37652d6bd9e3f - languageName: node - linkType: hard - "@polkadot/util@npm:12.6.2, @polkadot/util@npm:^12.6.2": version: 12.6.2 resolution: "@polkadot/util@npm:12.6.2" @@ -4161,18 +3854,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/wasm-bridge@npm:6.4.1": - version: 6.4.1 - resolution: "@polkadot/wasm-bridge@npm:6.4.1" - dependencies: - "@babel/runtime": "npm:^7.20.6" - peerDependencies: - "@polkadot/util": "*" - "@polkadot/x-randomvalues": "*" - checksum: 37bb682ff71afc9faa3526093743a88d1baa96e1065a135281394e2f6ecb9de4539d329f54a3475c0ca89dfb08788d71bc7d7483c9e71552a1635b836518f893 - languageName: node - linkType: hard - "@polkadot/wasm-bridge@npm:7.3.2": version: 7.3.2 resolution: "@polkadot/wasm-bridge@npm:7.3.2" @@ -4186,17 +3867,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/wasm-crypto-asmjs@npm:6.4.1": - version: 6.4.1 - resolution: "@polkadot/wasm-crypto-asmjs@npm:6.4.1" - dependencies: - "@babel/runtime": "npm:^7.20.6" - peerDependencies: - "@polkadot/util": "*" - checksum: dbdc9c82b5dbed5295c7724e5ecfae97b5a7500a6cac1c893a58d1a9ce44a93fb4fb6268efd401d399e3d2d47ce0c6c13b80a0ce55ba506eba8f99bb493fd0e9 - languageName: node - linkType: hard - "@polkadot/wasm-crypto-asmjs@npm:7.3.2": version: 7.3.2 resolution: "@polkadot/wasm-crypto-asmjs@npm:7.3.2" @@ -4208,21 +3878,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/wasm-crypto-init@npm:6.4.1": - version: 6.4.1 - resolution: "@polkadot/wasm-crypto-init@npm:6.4.1" - dependencies: - "@babel/runtime": "npm:^7.20.6" - "@polkadot/wasm-bridge": "npm:6.4.1" - "@polkadot/wasm-crypto-asmjs": "npm:6.4.1" - "@polkadot/wasm-crypto-wasm": "npm:6.4.1" - peerDependencies: - "@polkadot/util": "*" - "@polkadot/x-randomvalues": "*" - checksum: c37f0254371cdb72be0258ee9d0f46d6ab5b9642e0693938b87c35b1ff10496a5c7d7b76fdda77837cfc8f3bd35a5aa3a78cc26b1d97eaf91429a92b368810bb - languageName: node - linkType: hard - "@polkadot/wasm-crypto-init@npm:7.3.2": version: 7.3.2 resolution: "@polkadot/wasm-crypto-init@npm:7.3.2" @@ -4239,18 +3894,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/wasm-crypto-wasm@npm:6.4.1": - version: 6.4.1 - resolution: "@polkadot/wasm-crypto-wasm@npm:6.4.1" - dependencies: - "@babel/runtime": "npm:^7.20.6" - "@polkadot/wasm-util": "npm:6.4.1" - peerDependencies: - "@polkadot/util": "*" - checksum: 90a4e958f463451fe76bc30eb856bdeb61a590709a80479f3326c099fb3f14a4c4ec8ad1c3880e9e33fd6dca5922f71b6c04a46297da007e82b2292ed0e3bc27 - languageName: node - linkType: hard - "@polkadot/wasm-crypto-wasm@npm:7.3.2": version: 7.3.2 resolution: "@polkadot/wasm-crypto-wasm@npm:7.3.2" @@ -4263,23 +3906,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/wasm-crypto@npm:^6.4.1": - version: 6.4.1 - resolution: "@polkadot/wasm-crypto@npm:6.4.1" - dependencies: - "@babel/runtime": "npm:^7.20.6" - "@polkadot/wasm-bridge": "npm:6.4.1" - "@polkadot/wasm-crypto-asmjs": "npm:6.4.1" - "@polkadot/wasm-crypto-init": "npm:6.4.1" - "@polkadot/wasm-crypto-wasm": "npm:6.4.1" - "@polkadot/wasm-util": "npm:6.4.1" - peerDependencies: - "@polkadot/util": "*" - "@polkadot/x-randomvalues": "*" - checksum: b2c286878c3902b5b80ada3e90ae549b6fd3aa504e324bfda3996969263a418537737d02683f823d8b887e7b4476acfec2af2808c67eee35b02c2d7946a6b10a - languageName: node - linkType: hard - "@polkadot/wasm-crypto@npm:^7.3.2": version: 7.3.2 resolution: "@polkadot/wasm-crypto@npm:7.3.2" @@ -4297,17 +3923,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/wasm-util@npm:6.4.1": - version: 6.4.1 - resolution: "@polkadot/wasm-util@npm:6.4.1" - dependencies: - "@babel/runtime": "npm:^7.20.6" - peerDependencies: - "@polkadot/util": "*" - checksum: edcfe04956ff32d774510c021192b79482d59e983d2a9956cddf9e8cef1f96956537bbc9e928ac5d98fd9ff0eecdb81822030b57b803e42bb4253ee4e87fd801 - languageName: node - linkType: hard - "@polkadot/wasm-util@npm:7.3.2, @polkadot/wasm-util@npm:^7.3.2": version: 7.3.2 resolution: "@polkadot/wasm-util@npm:7.3.2" @@ -4319,16 +3934,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/x-bigint@npm:10.4.2, @polkadot/x-bigint@npm:^10.4.2": - version: 10.4.2 - resolution: "@polkadot/x-bigint@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/x-global": "npm:10.4.2" - checksum: 7fe685e943bcb591d465c8775fa2249a07ae3ec0ffe1cc74cf3205f0096e6ad0d81d37145fb64dee200b272187390467eeb7830e65ab368f06dbcc9fd43d272d - languageName: node - linkType: hard - "@polkadot/x-bigint@npm:12.6.2, @polkadot/x-bigint@npm:^12.6.2": version: 12.6.2 resolution: "@polkadot/x-bigint@npm:12.6.2" @@ -4339,18 +3944,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/x-fetch@npm:^10.4.2": - version: 10.4.2 - resolution: "@polkadot/x-fetch@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/x-global": "npm:10.4.2" - "@types/node-fetch": "npm:^2.6.2" - node-fetch: "npm:^3.3.0" - checksum: b4d50d0845a9bd0e984b3d674dd13eca82ea2c5ec18dc1dcb976292202ac28d69933f73cb1cadf767393bbd85b13e877414f83eb7a0fc27fcc064a4a98ba7e55 - languageName: node - linkType: hard - "@polkadot/x-fetch@npm:^12.6.2": version: 12.6.2 resolution: "@polkadot/x-fetch@npm:12.6.2" @@ -4362,15 +3955,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/x-global@npm:10.4.2, @polkadot/x-global@npm:^10.4.2": - version: 10.4.2 - resolution: "@polkadot/x-global@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - checksum: 33c40bd23dfdb94979b2e0ef78b0647eab62513a9256158952dab14d0eb57b10e7aa5cd78db0fa49922a6c0ee73dcc2853f0382e19d0540cd276f141ce72778a - languageName: node - linkType: hard - "@polkadot/x-global@npm:12.6.2, @polkadot/x-global@npm:^12.6.2": version: 12.6.2 resolution: "@polkadot/x-global@npm:12.6.2" @@ -4380,16 +3964,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/x-randomvalues@npm:10.4.2": - version: 10.4.2 - resolution: "@polkadot/x-randomvalues@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/x-global": "npm:10.4.2" - checksum: bcb5f944a574fd5b8ef5014294fe07a9e17af7474338b7b0adbb31dc73961db5936e5b27d8abc54584e564ea4fdca6ca1241af0d1939b570ee0ca390d7bbc663 - languageName: node - linkType: hard - "@polkadot/x-randomvalues@npm:12.6.2": version: 12.6.2 resolution: "@polkadot/x-randomvalues@npm:12.6.2" @@ -4403,16 +3977,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/x-textdecoder@npm:10.4.2": - version: 10.4.2 - resolution: "@polkadot/x-textdecoder@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/x-global": "npm:10.4.2" - checksum: 0a6fe7110990a10f68eaf6d7d90b00ef4d7526734defbd248c0b0ad92d0663d51e109fe6fbc162f0ed251dd67a0edc86aef79d25df58768754fb4055d2a93d48 - languageName: node - linkType: hard - "@polkadot/x-textdecoder@npm:12.6.2": version: 12.6.2 resolution: "@polkadot/x-textdecoder@npm:12.6.2" @@ -4423,16 +3987,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/x-textencoder@npm:10.4.2": - version: 10.4.2 - resolution: "@polkadot/x-textencoder@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/x-global": "npm:10.4.2" - checksum: 704f3de2476cd9e7a87b1245feb3f760d0a1695d28a97ab997817869b4f035f4ddcda3d02cdfdbdf2ad6908a86db3774e584025b593c4270b38905ca7da5f58c - languageName: node - linkType: hard - "@polkadot/x-textencoder@npm:12.6.2": version: 12.6.2 resolution: "@polkadot/x-textencoder@npm:12.6.2" @@ -4443,18 +3997,6 @@ __metadata: languageName: node linkType: hard -"@polkadot/x-ws@npm:^10.4.2": - version: 10.4.2 - resolution: "@polkadot/x-ws@npm:10.4.2" - dependencies: - "@babel/runtime": "npm:^7.20.13" - "@polkadot/x-global": "npm:10.4.2" - "@types/websocket": "npm:^1.0.5" - websocket: "npm:^1.0.34" - checksum: 932512458a68126b2ccb97d5d775b283e0ac0fa0eaf908a191bca7813b7d0fc3be6fdc8bd394a33f8873e7e7ee59648db0d53695b820aa74cdeb616e7903c9d4 - languageName: node - linkType: hard - "@polkadot/x-ws@npm:^12.6.2": version: 12.6.2 resolution: "@polkadot/x-ws@npm:12.6.2" @@ -4536,9 +4078,9 @@ __metadata: linkType: hard "@repeaterjs/repeater@npm:^3.0.4": - version: 3.0.5 - resolution: "@repeaterjs/repeater@npm:3.0.5" - checksum: e6e1aca2bbfe0b8e974bc5185a6839f9e78ec8acb96b6d6911a9dfc958443689f9bc38bcc6d554e6c8598f597f0151841aafbd1ee3ef16262ee93d18b2c1d4b5 + version: 3.0.6 + resolution: "@repeaterjs/repeater@npm:3.0.6" + checksum: c3915e2603927c7d6a9eb09673bc28fc49ab3a86947ec191a74663b33deebee2fcc4b03c31cc663ff27bd6db9e6c9487639b6935e265d601ce71b8c497f5f4a8 languageName: node linkType: hard @@ -4552,13 +4094,6 @@ __metadata: languageName: node linkType: hard -"@scure/base@npm:1.1.1": - version: 1.1.1 - resolution: "@scure/base@npm:1.1.1" - checksum: 97d200da8915ca18a4eceb73c23dda7fc3a4b8509f620c9b7756ee451d7c9ebbc828c6662f9ffa047806fbe41f37bf236c6ef75692690688b7659196cb2dc804 - languageName: node - linkType: hard - "@scure/base@npm:^1.1.1, @scure/base@npm:^1.1.5": version: 1.1.6 resolution: "@scure/base@npm:1.1.6" @@ -4722,24 +4257,26 @@ __metadata: linkType: hard "@sigstore/sign@npm:^2.3.0": - version: 2.3.0 - resolution: "@sigstore/sign@npm:2.3.0" + version: 2.3.1 + resolution: "@sigstore/sign@npm:2.3.1" dependencies: "@sigstore/bundle": "npm:^2.3.0" "@sigstore/core": "npm:^1.0.0" "@sigstore/protobuf-specs": "npm:^0.3.1" - make-fetch-happen: "npm:^13.0.0" - checksum: e11b9318c283604747e0ff6084e17f9da210dd999e8c5c32a229db6b9a9faf54698994458c2a09dec0a1a43ac99eb0d278ca6d5d86045145a96c941aad969e1d + make-fetch-happen: "npm:^13.0.1" + proc-log: "npm:^4.2.0" + promise-retry: "npm:^2.0.1" + checksum: e511125de9a7f846ce0df8a9d4f1b0fb6995c71f32369ea9cc21c483e7a283099fb588b94ba97e850ada4cf5d828a23b421772011d260a1cb3e7c21ac1ef9b8c languageName: node linkType: hard "@sigstore/tuf@npm:^2.3.1, @sigstore/tuf@npm:^2.3.2": - version: 2.3.2 - resolution: "@sigstore/tuf@npm:2.3.2" + version: 2.3.3 + resolution: "@sigstore/tuf@npm:2.3.3" dependencies: "@sigstore/protobuf-specs": "npm:^0.3.0" - tuf-js: "npm:^2.2.0" - checksum: c05008fa46efec1546cc2cdb46e54d6a4773cbd05efa3ad7272339b4f935d58634b9f8494b109197b506116fb894206bf1cdb1fc09351a00297c23ef3c2a1a01 + tuf-js: "npm:^2.2.1" + checksum: ecc479cc9b77324f481dcb93e7979f80893a79ede98e242247f533fe94cd60c82e8d9f22dbb8d46695685c321037061614f001c44b9a92fadc8fd8fc396bcc3c languageName: node linkType: hard @@ -4913,7 +4450,7 @@ __metadata: languageName: node linkType: hard -"@stablelib/random@npm:^1.0.1, @stablelib/random@npm:^1.0.2": +"@stablelib/random@npm:1.0.2, @stablelib/random@npm:^1.0.1, @stablelib/random@npm:^1.0.2": version: 1.0.2 resolution: "@stablelib/random@npm:1.0.2" dependencies: @@ -4952,7 +4489,7 @@ __metadata: languageName: node linkType: hard -"@stablelib/x25519@npm:^1.0.3": +"@stablelib/x25519@npm:1.0.3": version: 1.0.3 resolution: "@stablelib/x25519@npm:1.0.3" dependencies: @@ -4963,13 +4500,6 @@ __metadata: languageName: node linkType: hard -"@substrate/connect-extension-protocol@npm:^1.0.1": - version: 1.0.1 - resolution: "@substrate/connect-extension-protocol@npm:1.0.1" - checksum: 83257dba6d421c8e1d1e2976391e467cebf760b4bab5cf09f266414a82c906e97544c1e25767f826abfd30e5e5518c7ecc4010661c87c47eae3bba8dbd00a6fa - languageName: node - linkType: hard - "@substrate/connect-extension-protocol@npm:^2.0.0": version: 2.0.0 resolution: "@substrate/connect-extension-protocol@npm:2.0.0" @@ -4984,17 +4514,6 @@ __metadata: languageName: node linkType: hard -"@substrate/connect@npm:0.7.19": - version: 0.7.19 - resolution: "@substrate/connect@npm:0.7.19" - dependencies: - "@substrate/connect-extension-protocol": "npm:^1.0.1" - "@substrate/smoldot-light": "npm:0.7.9" - eventemitter3: "npm:^4.0.7" - checksum: 44d4b4bb9c48b7472b996eb1f09f47b93c356d0fe2e08c10f47a3e4f959af47edcc333275a871fc155d2918543e56a787af5465451054e0fe1937c6ab3195a73 - languageName: node - linkType: hard - "@substrate/connect@npm:0.8.8": version: 0.8.8 resolution: "@substrate/connect@npm:0.8.8" @@ -5024,17 +4543,7 @@ __metadata: languageName: node linkType: hard -"@substrate/smoldot-light@npm:0.7.9": - version: 0.7.9 - resolution: "@substrate/smoldot-light@npm:0.7.9" - dependencies: - pako: "npm:^2.0.4" - ws: "npm:^8.8.1" - checksum: 95d567f019238dfcec9d0685a9e168ccf8ab2cc4c9d6454985097ae10a9350619c66690eda3dfa4fca02b0259a4852e241154b903cc14b5c2bf1ba486e1fecc8 - languageName: node - linkType: hard - -"@substrate/ss58-registry@npm:^1.38.0, @substrate/ss58-registry@npm:^1.44.0": +"@substrate/ss58-registry@npm:^1.44.0": version: 1.47.0 resolution: "@substrate/ss58-registry@npm:1.47.0" checksum: 256b692d2331cf171664b0bf0e0185d56f6a5952f9162d618f5725e0989686fcaced99608ac56240f8cc1e2e037440430bf2b4d7e410ee39123ac96bb27f2742 @@ -5208,8 +4717,8 @@ __metadata: linkType: hard "@testing-library/jest-dom@npm:*, @testing-library/jest-dom@npm:^6.1.6": - version: 6.4.2 - resolution: "@testing-library/jest-dom@npm:6.4.2" + version: 6.4.5 + resolution: "@testing-library/jest-dom@npm:6.4.5" dependencies: "@adobe/css-tools": "npm:^4.3.2" "@babel/runtime": "npm:^7.9.2" @@ -5217,7 +4726,7 @@ __metadata: chalk: "npm:^3.0.0" css.escape: "npm:^1.5.1" dom-accessibility-api: "npm:^0.6.3" - lodash: "npm:^4.17.15" + lodash: "npm:^4.17.21" redent: "npm:^3.0.0" peerDependencies: "@jest/globals": ">= 28" @@ -5236,7 +4745,7 @@ __metadata: optional: true vitest: optional: true - checksum: e7eba527b34ce30cde94424d2ec685bdfed51daaafb7df9b68b51aec6052e99a50c8bfe654612dacdf857a1eb81d68cf294fc89de558ee3a992bf7a6019fffcc + checksum: 4cfdd44e2abab2b9d399c47cbfe686729bb65160d7df0f9e2329aaaea7702f6e852a9eefb29b468f00c1e5a5274b684f8cac76959d33299dfa909ba007ea191d languageName: node linkType: hard @@ -5324,13 +4833,13 @@ __metadata: languageName: node linkType: hard -"@tufjs/models@npm:2.0.0": - version: 2.0.0 - resolution: "@tufjs/models@npm:2.0.0" +"@tufjs/models@npm:2.0.1": + version: 2.0.1 + resolution: "@tufjs/models@npm:2.0.1" dependencies: "@tufjs/canonical-json": "npm:2.0.0" - minimatch: "npm:^9.0.3" - checksum: 252f525b05526077430920b30b125e197a3d711f4c6d1ceeee9cea5044035e4d94e57db481d96bd8e9d1ce5ee23fcc9fe989e7e0c9c2aec7e1edc27326ee16e6 + minimatch: "npm:^9.0.4" + checksum: ad9e82fd921954501fd90ed34ae062254637595577ad13fdc1e076405c0ea5ee7d8aebad09e63032972fd92b07f1786c15b24a195a171fc8ac470ca8e2ffbcc4 languageName: node linkType: hard @@ -5389,7 +4898,7 @@ __metadata: languageName: node linkType: hard -"@types/bn.js@npm:^5.1.1, @types/bn.js@npm:^5.1.5": +"@types/bn.js@npm:^5.1.5": version: 5.1.5 resolution: "@types/bn.js@npm:5.1.5" dependencies: @@ -5484,9 +4993,9 @@ __metadata: linkType: hard "@types/lodash@npm:^4.14.202": - version: 4.17.0 - resolution: "@types/lodash@npm:4.17.0" - checksum: 4c5b41c9a6c41e2c05d08499e96f7940bcf194dcfa84356235b630da920c2a5e05f193618cea76006719bec61c76617dff02defa9d29934f9f6a76a49291bd8f + version: 4.17.1 + resolution: "@types/lodash@npm:4.17.1" + checksum: af2ad8a3c8d7deb170a7ec6e18afc5ae8980576e5f7fe798d8a95a1df7222c15bdf967a25a35879f575a3b64743de00145710ee461a0051e055e94e4fe253f45 languageName: node linkType: hard @@ -5497,31 +5006,21 @@ __metadata: languageName: node linkType: hard -"@types/node-fetch@npm:^2.6.2": - version: 2.6.11 - resolution: "@types/node-fetch@npm:2.6.11" - dependencies: - "@types/node": "npm:*" - form-data: "npm:^4.0.0" - checksum: 5283d4e0bcc37a5b6d8e629aee880a4ffcfb33e089f4b903b2981b19c623972d1e64af7c3f9540ab990f0f5c89b9b5dda19c5bcb37a8e177079e93683bfd2f49 - languageName: node - linkType: hard - "@types/node@npm:*, @types/node@npm:>= 8": - version: 20.12.7 - resolution: "@types/node@npm:20.12.7" + version: 20.12.11 + resolution: "@types/node@npm:20.12.11" dependencies: undici-types: "npm:~5.26.4" - checksum: dce80d63a3b91892b321af823d624995c61e39c6a223cc0ac481a44d337640cc46931d33efb3beeed75f5c85c3bda1d97cef4c5cd4ec333caf5dee59cff6eca0 + checksum: efaa7b08c50ba6e6982ac7d531ba08d5935539ba76e954807df1ff9382a319ead7e003ccaca5ad7cf33ecf53f212507f7c1f2794bd2ff52df6365fef21f6e1fb languageName: node linkType: hard "@types/node@npm:^18.19.4": - version: 18.19.31 - resolution: "@types/node@npm:18.19.31" + version: 18.19.33 + resolution: "@types/node@npm:18.19.33" dependencies: undici-types: "npm:~5.26.4" - checksum: bfebae8389220c0188492c82eaf328f4ba15e6e9b4abee33d6bf36d3b13f188c2f53eb695d427feb882fff09834f467405e2ed9be6aeb6ad4705509822d2ea08 + checksum: 0a17cf55c4e6ec90fdb47e73fde44a613ec0f6cd02619b156b1e8fd3f81f8b3346b06ca0757024ddff304d44c8ce5b99570eac8fa2d6baa0fc12e4b2146ac7c6 languageName: node linkType: hard @@ -5636,15 +5135,6 @@ __metadata: languageName: node linkType: hard -"@types/websocket@npm:^1.0.5": - version: 1.0.10 - resolution: "@types/websocket@npm:1.0.10" - dependencies: - "@types/node": "npm:*" - checksum: 5950b8d01d1178c67c049f482fcab182085c59c2f98edda5980721f6eb512439ff91534e50ca7262720d75fc42ea6c8f8e5e7739442feea8f3cc0e320ebe2c74 - languageName: node - linkType: hard - "@types/ws@npm:^8.0.0": version: 8.5.10 resolution: "@types/ws@npm:8.5.10" @@ -5863,28 +5353,28 @@ __metadata: languageName: node linkType: hard -"@walletconnect/core@npm:2.12.2": - version: 2.12.2 - resolution: "@walletconnect/core@npm:2.12.2" +"@walletconnect/core@npm:2.13.0": + version: 2.13.0 + resolution: "@walletconnect/core@npm:2.13.0" dependencies: - "@walletconnect/heartbeat": "npm:1.2.1" - "@walletconnect/jsonrpc-provider": "npm:1.0.13" - "@walletconnect/jsonrpc-types": "npm:1.0.3" + "@walletconnect/heartbeat": "npm:1.2.2" + "@walletconnect/jsonrpc-provider": "npm:1.0.14" + "@walletconnect/jsonrpc-types": "npm:1.0.4" "@walletconnect/jsonrpc-utils": "npm:1.0.8" "@walletconnect/jsonrpc-ws-connection": "npm:1.0.14" - "@walletconnect/keyvaluestorage": "npm:^1.1.1" - "@walletconnect/logger": "npm:^2.1.2" - "@walletconnect/relay-api": "npm:^1.0.9" - "@walletconnect/relay-auth": "npm:^1.0.4" - "@walletconnect/safe-json": "npm:^1.0.2" - "@walletconnect/time": "npm:^1.0.2" - "@walletconnect/types": "npm:2.12.2" - "@walletconnect/utils": "npm:2.12.2" - events: "npm:^3.3.0" + "@walletconnect/keyvaluestorage": "npm:1.1.1" + "@walletconnect/logger": "npm:2.1.2" + "@walletconnect/relay-api": "npm:1.0.10" + "@walletconnect/relay-auth": "npm:1.0.4" + "@walletconnect/safe-json": "npm:1.0.2" + "@walletconnect/time": "npm:1.0.2" + "@walletconnect/types": "npm:2.13.0" + "@walletconnect/utils": "npm:2.13.0" + events: "npm:3.3.0" isomorphic-unfetch: "npm:3.1.0" lodash.isequal: "npm:4.5.0" - uint8arrays: "npm:^3.1.0" - checksum: 62feecfeb8c5557c9b2cbf28501df6403f02d87483a097df84fd1e1c9b42a5fc99b964a4d0ff4b3b48640bb7e57a8aabb43d23b104568d532f33b18ceb963302 + uint8arrays: "npm:3.1.0" + checksum: e1356eb8ac94f8f6743814337607244557280d43a6e2ec14591beb21dca0e73cc79b16f0a2ace60ef447149778c5383a1fd4eac67788372d249c8c5f6d8c7dc2 languageName: node linkType: hard @@ -5897,7 +5387,7 @@ __metadata: languageName: node linkType: hard -"@walletconnect/events@npm:^1.0.1": +"@walletconnect/events@npm:1.0.1, @walletconnect/events@npm:^1.0.1": version: 1.0.1 resolution: "@walletconnect/events@npm:1.0.1" dependencies: @@ -5907,51 +5397,51 @@ __metadata: languageName: node linkType: hard -"@walletconnect/heartbeat@npm:1.2.1": - version: 1.2.1 - resolution: "@walletconnect/heartbeat@npm:1.2.1" +"@walletconnect/heartbeat@npm:1.2.2": + version: 1.2.2 + resolution: "@walletconnect/heartbeat@npm:1.2.2" dependencies: "@walletconnect/events": "npm:^1.0.1" "@walletconnect/time": "npm:^1.0.2" - tslib: "npm:1.14.1" - checksum: 5ad46f26dcb7b9b3227f004cd74b18741d4cd32c21825a036eb03985c67a0cf859c285bc5635401966a99129e854d72de3458ff592370575ef7e52f5dd12ebbc + events: "npm:^3.3.0" + checksum: a97b07764c397fe3cd26e8ea4233ecc8a26049624df7edc05290d286266bc5ba1de740d12c50dc1b7e8605198c5974e34e2d5318087bd4e9db246e7b273f4592 languageName: node linkType: hard -"@walletconnect/jsonrpc-http-connection@npm:^1.0.7": - version: 1.0.7 - resolution: "@walletconnect/jsonrpc-http-connection@npm:1.0.7" +"@walletconnect/jsonrpc-http-connection@npm:1.0.8": + version: 1.0.8 + resolution: "@walletconnect/jsonrpc-http-connection@npm:1.0.8" dependencies: "@walletconnect/jsonrpc-utils": "npm:^1.0.6" "@walletconnect/safe-json": "npm:^1.0.1" cross-fetch: "npm:^3.1.4" - tslib: "npm:1.14.1" - checksum: 24272eca0d2b20397b2c83ecaac324cbc857fab4a4c2699332ea5c8b81096b1cf4a3c60f51c82ca9e98ab87a213c04bf047037478b089effabe0139005c71867 + events: "npm:^3.3.0" + checksum: cfac9ae74085d383ebc6edf075aeff01312818ac95e706cb8538ef4d4e6d82e75fb51529b3a9b65fa56a3f0f32a1738defad61713ed8a5f67cee25a79b6b4614 languageName: node linkType: hard -"@walletconnect/jsonrpc-provider@npm:1.0.13": - version: 1.0.13 - resolution: "@walletconnect/jsonrpc-provider@npm:1.0.13" +"@walletconnect/jsonrpc-provider@npm:1.0.14": + version: 1.0.14 + resolution: "@walletconnect/jsonrpc-provider@npm:1.0.14" dependencies: "@walletconnect/jsonrpc-utils": "npm:^1.0.8" "@walletconnect/safe-json": "npm:^1.0.2" - tslib: "npm:1.14.1" - checksum: 9b5b2f0ce516d2ddebe2cd1a2c8ea18a6b765b0d068162caf39745c18534e264a0cc6198adb869ba8684d0efa563be30956a3b9a7cc82b80b9e263f6211e30ab + events: "npm:^3.3.0" + checksum: 9801bd516d81e92977b6add213da91e0e4a7a5915ad22685a4d2a733bab6199e9053485b76340cd724c7faa17a1b0eb842696247944fd57fb581488a2e1bed75 languageName: node linkType: hard -"@walletconnect/jsonrpc-types@npm:1.0.3, @walletconnect/jsonrpc-types@npm:^1.0.2, @walletconnect/jsonrpc-types@npm:^1.0.3": - version: 1.0.3 - resolution: "@walletconnect/jsonrpc-types@npm:1.0.3" +"@walletconnect/jsonrpc-types@npm:1.0.4, @walletconnect/jsonrpc-types@npm:^1.0.2, @walletconnect/jsonrpc-types@npm:^1.0.3": + version: 1.0.4 + resolution: "@walletconnect/jsonrpc-types@npm:1.0.4" dependencies: + events: "npm:^3.3.0" keyvaluestorage-interface: "npm:^1.0.0" - tslib: "npm:1.14.1" - checksum: a0fc8a88c62795bf4bf83d4e98a4e2cdd659ef70c73642582089fdf0994c54fd8050aa6cca85cfdcca6b77994e71334895e7a19649c325a8c822b059c2003884 + checksum: 752978685b0596a4ba02e1b689d23873e464460e4f376c97ef63e6b3ab273658ca062de2bfcaa8a498d31db0c98be98c8bbfbe5142b256a4b3ef425e1707f353 languageName: node linkType: hard -"@walletconnect/jsonrpc-utils@npm:1.0.8, @walletconnect/jsonrpc-utils@npm:^1.0.6, @walletconnect/jsonrpc-utils@npm:^1.0.7, @walletconnect/jsonrpc-utils@npm:^1.0.8": +"@walletconnect/jsonrpc-utils@npm:1.0.8, @walletconnect/jsonrpc-utils@npm:^1.0.6, @walletconnect/jsonrpc-utils@npm:^1.0.8": version: 1.0.8 resolution: "@walletconnect/jsonrpc-utils@npm:1.0.8" dependencies: @@ -5974,7 +5464,7 @@ __metadata: languageName: node linkType: hard -"@walletconnect/keyvaluestorage@npm:^1.1.1": +"@walletconnect/keyvaluestorage@npm:1.1.1": version: 1.1.1 resolution: "@walletconnect/keyvaluestorage@npm:1.1.1" dependencies: @@ -5990,7 +5480,7 @@ __metadata: languageName: node linkType: hard -"@walletconnect/logger@npm:^2.0.1, @walletconnect/logger@npm:^2.1.2": +"@walletconnect/logger@npm:2.1.2": version: 2.1.2 resolution: "@walletconnect/logger@npm:2.1.2" dependencies: @@ -6031,7 +5521,7 @@ __metadata: languageName: node linkType: hard -"@walletconnect/relay-api@npm:^1.0.9": +"@walletconnect/relay-api@npm:1.0.10": version: 1.0.10 resolution: "@walletconnect/relay-api@npm:1.0.10" dependencies: @@ -6040,7 +5530,7 @@ __metadata: languageName: node linkType: hard -"@walletconnect/relay-auth@npm:^1.0.4": +"@walletconnect/relay-auth@npm:1.0.4": version: 1.0.4 resolution: "@walletconnect/relay-auth@npm:1.0.4" dependencies: @@ -6054,7 +5544,7 @@ __metadata: languageName: node linkType: hard -"@walletconnect/safe-json@npm:^1.0.1, @walletconnect/safe-json@npm:^1.0.2": +"@walletconnect/safe-json@npm:1.0.2, @walletconnect/safe-json@npm:^1.0.1, @walletconnect/safe-json@npm:^1.0.2": version: 1.0.2 resolution: "@walletconnect/safe-json@npm:1.0.2" dependencies: @@ -6063,24 +5553,24 @@ __metadata: languageName: node linkType: hard -"@walletconnect/sign-client@npm:2.12.2": - version: 2.12.2 - resolution: "@walletconnect/sign-client@npm:2.12.2" +"@walletconnect/sign-client@npm:2.13.0": + version: 2.13.0 + resolution: "@walletconnect/sign-client@npm:2.13.0" dependencies: - "@walletconnect/core": "npm:2.12.2" - "@walletconnect/events": "npm:^1.0.1" - "@walletconnect/heartbeat": "npm:1.2.1" + "@walletconnect/core": "npm:2.13.0" + "@walletconnect/events": "npm:1.0.1" + "@walletconnect/heartbeat": "npm:1.2.2" "@walletconnect/jsonrpc-utils": "npm:1.0.8" - "@walletconnect/logger": "npm:^2.1.2" - "@walletconnect/time": "npm:^1.0.2" - "@walletconnect/types": "npm:2.12.2" - "@walletconnect/utils": "npm:2.12.2" - events: "npm:^3.3.0" - checksum: 183f16eb4405086475c21e11b5b20ec3c00ba57dfe55cf1a489863ef850973916a42fb354c4f307557cd1b75d772e58de077bedddd0766f5254bc659df4aefbe + "@walletconnect/logger": "npm:2.1.2" + "@walletconnect/time": "npm:1.0.2" + "@walletconnect/types": "npm:2.13.0" + "@walletconnect/utils": "npm:2.13.0" + events: "npm:3.3.0" + checksum: 58c702997f719cab9b183d23c53efee561a3a407de24e464e339e350124a71eeccb1bd651f0893ad0f39343ce42a7ff3666bbd28cb8dfc6a0e8d12c94eacc288 languageName: node linkType: hard -"@walletconnect/time@npm:^1.0.2": +"@walletconnect/time@npm:1.0.2, @walletconnect/time@npm:^1.0.2": version: 1.0.2 resolution: "@walletconnect/time@npm:1.0.2" dependencies: @@ -6089,60 +5579,60 @@ __metadata: languageName: node linkType: hard -"@walletconnect/types@npm:2.12.2": - version: 2.12.2 - resolution: "@walletconnect/types@npm:2.12.2" +"@walletconnect/types@npm:2.13.0": + version: 2.13.0 + resolution: "@walletconnect/types@npm:2.13.0" dependencies: - "@walletconnect/events": "npm:^1.0.1" - "@walletconnect/heartbeat": "npm:1.2.1" - "@walletconnect/jsonrpc-types": "npm:1.0.3" - "@walletconnect/keyvaluestorage": "npm:^1.1.1" - "@walletconnect/logger": "npm:^2.0.1" - events: "npm:^3.3.0" - checksum: 9bc834aa41b59a5d9f19fdc2db15345568867635114b72b6dc23d93ba7040d3ad2ef742e6c7e5233d9fb747995d69103a9f1c75d368c8d3bce22c916e4dde748 + "@walletconnect/events": "npm:1.0.1" + "@walletconnect/heartbeat": "npm:1.2.2" + "@walletconnect/jsonrpc-types": "npm:1.0.4" + "@walletconnect/keyvaluestorage": "npm:1.1.1" + "@walletconnect/logger": "npm:2.1.2" + events: "npm:3.3.0" + checksum: 9962284daf92d6b27a009b90b908518b3f028f10f2168ddbc37ad2cb2b20cb0e65d170aa4343e2ea445c519cf79e78264480e2b2c4ab9f974f2c15962db5b012 languageName: node linkType: hard "@walletconnect/universal-provider@npm:^2.11.1": - version: 2.12.2 - resolution: "@walletconnect/universal-provider@npm:2.12.2" + version: 2.13.0 + resolution: "@walletconnect/universal-provider@npm:2.13.0" dependencies: - "@walletconnect/jsonrpc-http-connection": "npm:^1.0.7" - "@walletconnect/jsonrpc-provider": "npm:1.0.13" - "@walletconnect/jsonrpc-types": "npm:^1.0.2" - "@walletconnect/jsonrpc-utils": "npm:^1.0.7" - "@walletconnect/logger": "npm:^2.1.2" - "@walletconnect/sign-client": "npm:2.12.2" - "@walletconnect/types": "npm:2.12.2" - "@walletconnect/utils": "npm:2.12.2" - events: "npm:^3.3.0" - checksum: d77a9ecbd0f5ec5f17fb1aa2909d657755faa28a01eb46adab5a23cadc267519ee550fc823146792c6701cd25d62eb3b5a1fd38ef7f42e444642320b4a0e31ba + "@walletconnect/jsonrpc-http-connection": "npm:1.0.8" + "@walletconnect/jsonrpc-provider": "npm:1.0.14" + "@walletconnect/jsonrpc-types": "npm:1.0.4" + "@walletconnect/jsonrpc-utils": "npm:1.0.8" + "@walletconnect/logger": "npm:2.1.2" + "@walletconnect/sign-client": "npm:2.13.0" + "@walletconnect/types": "npm:2.13.0" + "@walletconnect/utils": "npm:2.13.0" + events: "npm:3.3.0" + checksum: 79d14cdce74054859f26f69a17215c59367d961d0f36e7868601ed98030bd0636b3806dd68b76cc66ec4a70d5f6ec107fbe18bb6a1022a5161ea6d71810a0ed9 languageName: node linkType: hard -"@walletconnect/utils@npm:2.12.2": - version: 2.12.2 - resolution: "@walletconnect/utils@npm:2.12.2" +"@walletconnect/utils@npm:2.13.0": + version: 2.13.0 + resolution: "@walletconnect/utils@npm:2.13.0" dependencies: "@stablelib/chacha20poly1305": "npm:1.0.1" "@stablelib/hkdf": "npm:1.0.1" - "@stablelib/random": "npm:^1.0.2" + "@stablelib/random": "npm:1.0.2" "@stablelib/sha256": "npm:1.0.1" - "@stablelib/x25519": "npm:^1.0.3" - "@walletconnect/relay-api": "npm:^1.0.9" - "@walletconnect/safe-json": "npm:^1.0.2" - "@walletconnect/time": "npm:^1.0.2" - "@walletconnect/types": "npm:2.12.2" - "@walletconnect/window-getters": "npm:^1.0.1" - "@walletconnect/window-metadata": "npm:^1.0.1" + "@stablelib/x25519": "npm:1.0.3" + "@walletconnect/relay-api": "npm:1.0.10" + "@walletconnect/safe-json": "npm:1.0.2" + "@walletconnect/time": "npm:1.0.2" + "@walletconnect/types": "npm:2.13.0" + "@walletconnect/window-getters": "npm:1.0.1" + "@walletconnect/window-metadata": "npm:1.0.1" detect-browser: "npm:5.3.0" query-string: "npm:7.1.3" - uint8arrays: "npm:^3.1.0" - checksum: fbfb67ff6092a6c14dd517ce9053882620c5c18a743adc52039d9fa06646f62edacc8c602c8a0f69d7ade3a43d86a6dac25fd43103962bc7d41d19eb2f937da7 + uint8arrays: "npm:3.1.0" + checksum: 2dbdb9ed790492411eb5c4e6b06aa511f6c0204c4ff283ecb5a4d339bb1bf3da033ef3a0c0af66b94df0553676f408222c2feca8c601b0554be2bbfbef43d6ec languageName: node linkType: hard -"@walletconnect/window-getters@npm:^1.0.1": +"@walletconnect/window-getters@npm:1.0.1, @walletconnect/window-getters@npm:^1.0.1": version: 1.0.1 resolution: "@walletconnect/window-getters@npm:1.0.1" dependencies: @@ -6151,7 +5641,7 @@ __metadata: languageName: node linkType: hard -"@walletconnect/window-metadata@npm:^1.0.1": +"@walletconnect/window-metadata@npm:1.0.1": version: 1.0.1 resolution: "@walletconnect/window-metadata@npm:1.0.1" dependencies: @@ -6421,7 +5911,7 @@ __metadata: languageName: node linkType: hard -"aproba@npm:^1.0.3 || ^2.0.0, aproba@npm:^2.0.0": +"aproba@npm:^2.0.0": version: 2.0.0 resolution: "aproba@npm:2.0.0" checksum: d06e26384a8f6245d8c8896e138c0388824e259a329e0c9f196b4fa533c82502a6fd449586e3604950a0c42921832a458bb3aa0aa9f0ba449cfd4f50fd0d09b5 @@ -6435,13 +5925,6 @@ __metadata: languageName: node linkType: hard -"are-we-there-yet@npm:^4.0.0": - version: 4.0.2 - resolution: "are-we-there-yet@npm:4.0.2" - checksum: 376204f6f07ee7a5f081f5043c92c4c39fd9984278486e0c7c60e74cfc61dc206d2363a2086610f6b95399d9dc3c193cec1832d0ce10666d567f64571c2dedf5 - languageName: node - linkType: hard - "arg@npm:^4.1.0": version: 4.1.3 resolution: "arg@npm:4.1.3" @@ -6921,14 +6404,14 @@ __metadata: linkType: hard "bin-links@npm:^4.0.1": - version: 4.0.3 - resolution: "bin-links@npm:4.0.3" + version: 4.0.4 + resolution: "bin-links@npm:4.0.4" dependencies: cmd-shim: "npm:^6.0.0" npm-normalize-package-bin: "npm:^3.0.0" read-cmd-shim: "npm:^4.0.0" write-file-atomic: "npm:^5.0.0" - checksum: 66668e005743e7e8df2ecf3018c0f06c5a87043647280e334abb4577bdef124df2893cd0c61eb7261d24ed9a6a1dc35fd8c4f930c89200251974840b3286236f + checksum: feb664e786429289d189c19c193b28d855c2898bc53b8391306cbad2273b59ccecb91fd31a433020019552c3bad3a1e0eeecca1c12e739a12ce2ca94f7553a17 languageName: node linkType: hard @@ -7048,25 +6531,6 @@ __metadata: languageName: node linkType: hard -"bufferutil@npm:^4.0.1": - version: 4.0.8 - resolution: "bufferutil@npm:4.0.8" - dependencies: - node-gyp: "npm:latest" - node-gyp-build: "npm:^4.3.0" - checksum: 36cdc5b53a38d9f61f89fdbe62029a2ebcd020599862253fefebe31566155726df9ff961f41b8c97b02b4c12b391ef97faf94e2383392654cf8f0ed68f76e47c - languageName: node - linkType: hard - -"builtins@npm:^5.0.0": - version: 5.1.0 - resolution: "builtins@npm:5.1.0" - dependencies: - semver: "npm:^7.0.0" - checksum: 3c32fe5bd7ed4ff7dbd6fb14bcb9d7eaa7e967327f1899cd336f8625d3f46fceead0a53528f1e332aeaee757034ebb307cb2f1a37af2b86a3c5ad4845d01c0c8 - languageName: node - linkType: hard - "busboy@npm:^1.6.0": version: 1.6.0 resolution: "busboy@npm:1.6.0" @@ -7077,8 +6541,8 @@ __metadata: linkType: hard "cacache@npm:^18.0.0, cacache@npm:^18.0.2": - version: 18.0.2 - resolution: "cacache@npm:18.0.2" + version: 18.0.3 + resolution: "cacache@npm:18.0.3" dependencies: "@npmcli/fs": "npm:^3.1.0" fs-minipass: "npm:^3.0.0" @@ -7092,7 +6556,7 @@ __metadata: ssri: "npm:^10.0.0" tar: "npm:^6.1.11" unique-filename: "npm:^3.0.0" - checksum: 7992665305cc251a984f4fdbab1449d50e88c635bc43bf2785530c61d239c61b349e5734461baa461caaee65f040ab14e2d58e694f479c0810cffd181ba5eabc + checksum: dfda92840bb371fb66b88c087c61a74544363b37a265023223a99965b16a16bbb87661fe4948718d79df6e0cc04e85e62784fbcf1832b2a5e54ff4c46fbb45b7 languageName: node linkType: hard @@ -7167,9 +6631,9 @@ __metadata: linkType: hard "caniuse-lite@npm:^1.0.0, caniuse-lite@npm:^1.0.30001587, caniuse-lite@npm:^1.0.30001599": - version: 1.0.30001614 - resolution: "caniuse-lite@npm:1.0.30001614" - checksum: 54873ef47f5f04448f1dafe371dece0129f1f2e4644c377956e66ebfa4bfa16dd3529062b7b4d95d9e3a80129907558c19200532669c6dcd5733eff724fdf2b6 + version: 1.0.30001617 + resolution: "caniuse-lite@npm:1.0.30001617" + checksum: 711702501063968b2807d1a8f40981e66f45eb8962968b4b84c70392dc804cee62845e8e391e9749f78ff41ca48be2a4a7a38620c44af526b5e03bc3c7a1bc0a languageName: node linkType: hard @@ -7471,9 +6935,9 @@ __metadata: linkType: hard "cmd-shim@npm:^6.0.0": - version: 6.0.2 - resolution: "cmd-shim@npm:6.0.2" - checksum: c34cadcfa32ee923fd055fc6edbd933e56432228b7d8078ea0120e24949343fbc1b24066f817eb4f58a66141443463591c545c0d08cf461203bf20d0f8c55ff2 + version: 6.0.3 + resolution: "cmd-shim@npm:6.0.3" + checksum: dc09fe0bf39e86250529456d9a87dd6d5208d053e449101a600e96dc956c100e0bc312cdb413a91266201f3bd8057d4abf63875cafb99039553a1937d8f3da36 languageName: node linkType: hard @@ -7533,15 +6997,6 @@ __metadata: languageName: node linkType: hard -"color-support@npm:^1.1.3": - version: 1.1.3 - resolution: "color-support@npm:1.1.3" - bin: - color-support: bin.js - checksum: 8ffeaa270a784dc382f62d9be0a98581db43e11eee301af14734a6d089bd456478b1a8b3e7db7ca7dc5b18a75f828f775c44074020b51c05fc00e6d0992b1cc6 - languageName: node - linkType: hard - "color@npm:^4.2": version: 4.2.3 resolution: "color@npm:4.2.3" @@ -7653,13 +7108,6 @@ __metadata: languageName: node linkType: hard -"console-control-strings@npm:^1.1.0": - version: 1.1.0 - resolution: "console-control-strings@npm:1.1.0" - checksum: 7ab51d30b52d461412cd467721bb82afe695da78fff8f29fe6f6b9cbaac9a2328e27a22a966014df9532100f6dd85370460be8130b9c677891ba36d96a343f50 - languageName: node - linkType: hard - "constant-case@npm:^3.0.4": version: 3.0.4 resolution: "constant-case@npm:3.0.4" @@ -8156,15 +7604,6 @@ __metadata: languageName: node linkType: hard -"debug@npm:^2.2.0": - version: 2.6.9 - resolution: "debug@npm:2.6.9" - dependencies: - ms: "npm:2.0.0" - checksum: 121908fb839f7801180b69a7e218a40b5a0b718813b886b7d6bdb82001b931c938e2941d1e4450f33a1b1df1da653f5f7a0440c197f29fbf8a6e9d45ff6ef589 - languageName: node - linkType: hard - "decamelize@npm:^1.2.0": version: 1.2.0 resolution: "decamelize@npm:1.2.0" @@ -8577,19 +8016,10 @@ __metadata: languageName: node linkType: hard -"ed2curve@npm:^0.3.0": - version: 0.3.0 - resolution: "ed2curve@npm:0.3.0" - dependencies: - tweetnacl: "npm:1.x.x" - checksum: 016afa38b2d9ed52129b38211f7c746bea17261c82e548912b81b6a6b884d6b1b0f1513ea16def1b056ca4e0d72365a331453a67537f8a4494a74074ff8bcf5b - languageName: node - linkType: hard - "electron-to-chromium@npm:^1.4.668": - version: 1.4.752 - resolution: "electron-to-chromium@npm:1.4.752" - checksum: c3d577dc1d76ddf97a593f7c7c80b5be68d306064c1f81a791ce2803da6fef24e27a152e53066f36818160c04aa8018308ab12ebf71f67400ae67c2b3d044645 + version: 1.4.762 + resolution: "electron-to-chromium@npm:1.4.762" + checksum: b4f9e7472b0f25bac24454a6450c43257ef931a12f4f18d0f430997b383db228b73caf268010cec0441646d6842875503c25fca7125f0bf2805fb2ee8c2e2aea languageName: node linkType: hard @@ -8842,7 +8272,7 @@ __metadata: languageName: node linkType: hard -"es5-ext@npm:^0.10.35, es5-ext@npm:^0.10.46, es5-ext@npm:^0.10.50, es5-ext@npm:^0.10.53, es5-ext@npm:^0.10.62, es5-ext@npm:^0.10.64, es5-ext@npm:~0.10.14, es5-ext@npm:~0.10.2, es5-ext@npm:~0.10.46": +"es5-ext@npm:^0.10.35, es5-ext@npm:^0.10.46, es5-ext@npm:^0.10.53, es5-ext@npm:^0.10.62, es5-ext@npm:^0.10.64, es5-ext@npm:~0.10.14, es5-ext@npm:~0.10.2, es5-ext@npm:~0.10.46": version: 0.10.64 resolution: "es5-ext@npm:0.10.64" dependencies: @@ -9123,7 +8553,7 @@ __metadata: languageName: node linkType: hard -"escalade@npm:^3.1.1": +"escalade@npm:^3.1.1, escalade@npm:^3.1.2": version: 3.1.2 resolution: "escalade@npm:3.1.2" checksum: 6b4adafecd0682f3aa1cd1106b8fff30e492c7015b178bc81b2d2f75106dabea6c6d6e8508fc491bd58e597c74abb0e8e2368f943ecb9393d4162e3c2f3cf287 @@ -9402,21 +8832,21 @@ __metadata: languageName: node linkType: hard -"eventemitter3@npm:^4.0.4, eventemitter3@npm:^4.0.7": +"eventemitter3@npm:^4.0.4": version: 4.0.7 resolution: "eventemitter3@npm:4.0.7" checksum: 5f6d97cbcbac47be798e6355e3a7639a84ee1f7d9b199a07017f1d2f1e2fe236004d14fa5dfaeba661f94ea57805385e326236a6debbc7145c8877fbc0297c6b languageName: node linkType: hard -"eventemitter3@npm:^5.0.0, eventemitter3@npm:^5.0.1": +"eventemitter3@npm:^5.0.1": version: 5.0.1 resolution: "eventemitter3@npm:5.0.1" checksum: 4ba5c00c506e6c786b4d6262cfbce90ddc14c10d4667e5c83ae993c9de88aa856033994dd2b35b83e8dc1170e224e66a319fa80adc4c32adcd2379bbc75da814 languageName: node linkType: hard -"events@npm:^3.3.0": +"events@npm:3.3.0, events@npm:^3.3.0": version: 3.3.0 resolution: "events@npm:3.3.0" checksum: d6b6f2adbccbcda74ddbab52ed07db727ef52e31a61ed26db9feb7dc62af7fc8e060defa65e5f8af9449b86b52cc1a1f6a79f2eafcf4e62add2b7a1fa4a432f6 @@ -9921,22 +9351,6 @@ __metadata: languageName: node linkType: hard -"gauge@npm:^5.0.0": - version: 5.0.1 - resolution: "gauge@npm:5.0.1" - dependencies: - aproba: "npm:^1.0.3 || ^2.0.0" - color-support: "npm:^1.1.3" - console-control-strings: "npm:^1.1.0" - has-unicode: "npm:^2.0.1" - signal-exit: "npm:^4.0.1" - string-width: "npm:^4.2.3" - strip-ansi: "npm:^6.0.1" - wide-align: "npm:^1.1.5" - checksum: 845f9a2534356cd0e9c1ae590ed471bbe8d74c318915b92a34e8813b8d3441ca8e0eb0fa87a48081e70b63b84d398c5e66a13b8e8040181c10b9d77e9fe3287f - languageName: node - linkType: hard - "generic-names@npm:^4.0.0": version: 4.0.0 resolution: "generic-names@npm:4.0.0" @@ -10052,17 +9466,17 @@ __metadata: linkType: hard "glob@npm:^10.2.2, glob@npm:^10.3.10, glob@npm:^10.3.12": - version: 10.3.12 - resolution: "glob@npm:10.3.12" + version: 10.3.14 + resolution: "glob@npm:10.3.14" dependencies: foreground-child: "npm:^3.1.0" jackspeak: "npm:^2.3.6" minimatch: "npm:^9.0.1" minipass: "npm:^7.0.4" - path-scurry: "npm:^1.10.2" + path-scurry: "npm:^1.11.0" bin: glob: dist/esm/bin.mjs - checksum: f60cefdc1cf3f958b2bb5823e1b233727f04916d489dc4641d76914f016e6704421e06a83cbb68b0cb1cb9382298b7a88075b844ad2127fc9727ea22b18b0711 + checksum: 19126e53b99c94dea9b3509500e22b325e24d2674523fc95b9fe710f1549ad7e091fbb0704c325c53d3a172fc21a8251acce5395c4f3efd872a2e65a376c82a1 languageName: node linkType: hard @@ -10317,13 +9731,6 @@ __metadata: languageName: node linkType: hard -"has-unicode@npm:^2.0.1": - version: 2.0.1 - resolution: "has-unicode@npm:2.0.1" - checksum: ebdb2f4895c26bb08a8a100b62d362e49b2190bcfd84b76bc4be1a3bd4d254ec52d0dd9f2fbcc093fc5eb878b20c52146f9dfd33e2686ed28982187be593b47c - languageName: node - linkType: hard - "hasown@npm:^2.0.0, hasown@npm:^2.0.1, hasown@npm:^2.0.2": version: 2.0.2 resolution: "hasown@npm:2.0.2" @@ -10367,11 +9774,11 @@ __metadata: linkType: hard "hosted-git-info@npm:^7.0.0, hosted-git-info@npm:^7.0.1": - version: 7.0.1 - resolution: "hosted-git-info@npm:7.0.1" + version: 7.0.2 + resolution: "hosted-git-info@npm:7.0.2" dependencies: lru-cache: "npm:^10.0.1" - checksum: 361c4254f717f06d581a5a90aa0156a945e662e05ebbb533c1fa9935f10886d8247db48cbbcf9667f02e519e6479bf16dcdcf3124c3030e76c4c3ca2c88ee9d3 + checksum: b19dbd92d3c0b4b0f1513cf79b0fc189f54d6af2129eeb201de2e9baaa711f1936929c848b866d9c8667a0f956f34bf4f07418c12be1ee9ca74fd9246335ca1f languageName: node linkType: hard @@ -10509,11 +9916,11 @@ __metadata: linkType: hard "ignore-walk@npm:^6.0.4": - version: 6.0.4 - resolution: "ignore-walk@npm:6.0.4" + version: 6.0.5 + resolution: "ignore-walk@npm:6.0.5" dependencies: minimatch: "npm:^9.0.0" - checksum: 6dd2ea369f3d32d90cb26ca6647bc6e112ed483433270ed89b8055dd708d00777c2cbc85b93b43f53e2100851277fd1539796a758ae4c64b84445d4f1da5fd8f + checksum: 8bd6d37c82400016c7b6538b03422dde8c9d7d3e99051c8357dd205d499d42828522fb4fbce219c9c21b4b069079445bacdc42bbd3e2e073b52856c2646d8a39 languageName: node linkType: hard @@ -10669,8 +10076,8 @@ __metadata: linkType: hard "init-package-json@npm:^6.0.2": - version: 6.0.2 - resolution: "init-package-json@npm:6.0.2" + version: 6.0.3 + resolution: "init-package-json@npm:6.0.3" dependencies: "@npmcli/package-json": "npm:^5.0.0" npm-package-arg: "npm:^11.0.0" @@ -10679,7 +10086,7 @@ __metadata: semver: "npm:^7.3.5" validate-npm-package-license: "npm:^3.0.4" validate-npm-package-name: "npm:^5.0.0" - checksum: b2e6331afda7228782c4db24f000d9131bc77a691a0845c911bfbb4ed775073ec0d0ecfacacbe74636fa2ed53122221846dc0409e5773ebf8477c31d22522428 + checksum: a80f024ee041a2cf4d3062ba936abf015cbc32bda625cabe994d1fa4bd942bb9af37a481afd6880d340d3e94d90bf97bed1a0a877cc8c7c9b48e723c2524ae74 languageName: node linkType: hard @@ -10754,9 +10161,9 @@ __metadata: linkType: hard "iron-webcrypto@npm:^1.0.0": - version: 1.1.1 - resolution: "iron-webcrypto@npm:1.1.1" - checksum: a1b3a45044f36c4b1d191164c3395de86396ed316b7a69569efd1e72fc695143dc667f38f048595b8d59a2034b98de727c04ef0b049a4caab8077cfc440c38aa + version: 1.2.1 + resolution: "iron-webcrypto@npm:1.2.1" + checksum: 5cf27c6e2bd3ef3b4970e486235fd82491ab8229e2ed0ac23307c28d6c80d721772a86ed4e9fe2a5cabadd710c2f024b706843b40561fb83f15afee58f809f66 languageName: node linkType: hard @@ -11118,13 +10525,6 @@ __metadata: languageName: node linkType: hard -"is-typedarray@npm:^1.0.0": - version: 1.0.0 - resolution: "is-typedarray@npm:1.0.0" - checksum: 4c096275ba041a17a13cca33ac21c16bc4fd2d7d7eb94525e7cd2c2f2c1a3ab956e37622290642501ff4310601e413b675cf399ad6db49855527d2163b3eeeec - languageName: node - linkType: hard - "is-unc-path@npm:^1.0.0": version: 1.0.0 resolution: "is-unc-path@npm:1.0.0" @@ -11975,9 +11375,9 @@ __metadata: linkType: hard "json-parse-even-better-errors@npm:^3.0.0, json-parse-even-better-errors@npm:^3.0.1": - version: 3.0.1 - resolution: "json-parse-even-better-errors@npm:3.0.1" - checksum: bc40600b14231dff1ff911d269c7ed89fbf3dbedf25cad3f47c10ff9cbb998ce03921372a17f27f3c7cfed76e679bc6c02a7b4cb2604b0ba68cd51ed16899492 + version: 3.0.2 + resolution: "json-parse-even-better-errors@npm:3.0.2" + checksum: 147f12b005768abe9fab78d2521ce2b7e1381a118413d634a40e6d907d7d10f5e9a05e47141e96d6853af7cc36d2c834d0a014251be48791e037ff2f13d2b94b languageName: node linkType: hard @@ -12122,18 +11522,18 @@ __metadata: linkType: hard "libnpmaccess@npm:^8.0.1": - version: 8.0.4 - resolution: "libnpmaccess@npm:8.0.4" + version: 8.0.5 + resolution: "libnpmaccess@npm:8.0.5" dependencies: npm-package-arg: "npm:^11.0.2" - npm-registry-fetch: "npm:^16.2.1" - checksum: e78fa13b623e70c1a754b986cd14d6dd98bde49beb44726601a77644eb411af039662007f60420321e3eb75c7d1af881e39cc510ba20f1a858627ca918265401 + npm-registry-fetch: "npm:^17.0.0" + checksum: 85753f135442b7b7df1bc015cb6bc2c0dc0284921d488107ffc21cfd7aa28e9d278a29b3819d32401a44cbd640da2c1d8716376cf863879e238947304ed22956 languageName: node linkType: hard "libnpmdiff@npm:^6.0.3": - version: 6.1.0 - resolution: "libnpmdiff@npm:6.1.0" + version: 6.1.1 + resolution: "libnpmdiff@npm:6.1.1" dependencies: "@npmcli/arborist": "npm:^7.2.1" "@npmcli/installed-package-contents": "npm:^2.1.0" @@ -12143,115 +11543,114 @@ __metadata: npm-package-arg: "npm:^11.0.2" pacote: "npm:^18.0.1" tar: "npm:^6.2.1" - checksum: 1ac5fa69c3c75a3bb8592ede5a40dd999ec8f58d6fd7a50462b9f8846f395054a30f14bada8e933adde0ff219f3cc1cf5c2f98c2f8f132462a6da2d61c6a7631 + checksum: 11fdb7249009101e80ec89f88b3294a52b4bf35b74484c5d25bbaab930c1ac49b1cd47c944c69879a824f4e464aff6a85dcf663871132113b6153c7418ba4e82 languageName: node linkType: hard -"libnpmexec@npm:^7.0.4": - version: 7.0.10 - resolution: "libnpmexec@npm:7.0.10" +"libnpmexec@npm:^8.0.0": + version: 8.1.0 + resolution: "libnpmexec@npm:8.1.0" dependencies: "@npmcli/arborist": "npm:^7.2.1" - "@npmcli/run-script": "npm:^7.0.2" + "@npmcli/run-script": "npm:^8.1.0" ci-info: "npm:^4.0.0" - npm-package-arg: "npm:^11.0.1" - npmlog: "npm:^7.0.1" - pacote: "npm:^17.0.4" - proc-log: "npm:^3.0.0" + npm-package-arg: "npm:^11.0.2" + pacote: "npm:^18.0.1" + proc-log: "npm:^4.2.0" read: "npm:^3.0.1" read-package-json-fast: "npm:^3.0.2" semver: "npm:^7.3.7" walk-up-path: "npm:^3.0.1" - checksum: e2d117d386c93be71a10ef369c106b5e00fd7449d42a314f018c0767504e45a15a9ceb7be3bf50c8b98e7d1d3083a665695d6da2c7fc921b06850a5d5f5cb121 + checksum: c27bdeb10f78895e48c3e188ece437a1fea415cd58be323b89dc798a02adeec8752e583b0f4a72e89413073dd5a37140b391c1252a1cb70b62b679836de0adca languageName: node linkType: hard "libnpmfund@npm:^5.0.1": - version: 5.0.8 - resolution: "libnpmfund@npm:5.0.8" + version: 5.0.9 + resolution: "libnpmfund@npm:5.0.9" dependencies: "@npmcli/arborist": "npm:^7.2.1" - checksum: 1920b7eb19d65ce8c5915f33a17803a541a964b474b67e05dce37e8d2e554fc7025bb14003f23c5008655e1c126e44a0ddc70d1399529e92d9aa88c98e16efc9 + checksum: fe491b4dd08f678f9bc857f389a75ac8ee8427842da305f6516d8e907422cb088118b6f29fb8fcd85668ea8ad853c9b77884b75dbf52ea844dc68f22ac4532cb languageName: node linkType: hard "libnpmhook@npm:^10.0.0": - version: 10.0.3 - resolution: "libnpmhook@npm:10.0.3" + version: 10.0.4 + resolution: "libnpmhook@npm:10.0.4" dependencies: aproba: "npm:^2.0.0" - npm-registry-fetch: "npm:^16.2.1" - checksum: e4cd4c4b508806d6d40c1dea68018440babb49d6604c31ff12e2d24ce579cc928510144f6cf084920a04da26ad1ad7c339b0e23db98c455b1c62d4ed099dabd7 + npm-registry-fetch: "npm:^17.0.0" + checksum: 234f19dd4ddea0ca57abb606c5994b423538c6bf9a53ad0f4917ac5395bb3e33f488b75cf988e75eae72d7d552f9e65e8a12b6012d43bd24bd34da241c532a7d languageName: node linkType: hard "libnpmorg@npm:^6.0.1": - version: 6.0.4 - resolution: "libnpmorg@npm:6.0.4" + version: 6.0.5 + resolution: "libnpmorg@npm:6.0.5" dependencies: aproba: "npm:^2.0.0" - npm-registry-fetch: "npm:^16.2.1" - checksum: 4935969a3db13482033f9aba8b6c63781e44e7fa51164adbbc7af1e41786af508b4401c52c812f58455b754c8fa7afe66a6ea9fe1eb5ccd6249c1a2a0829ea4f + npm-registry-fetch: "npm:^17.0.0" + checksum: 30014600506abf9f0dd7ad7fb8792b32e068a6f73e9b1d90bc2bedbafeb93b2cf364a556dae6dd374fa92850a2a9c4a411d042e5955e1f362d1443250c150ab8 languageName: node linkType: hard -"libnpmpack@npm:^6.0.3": - version: 6.0.9 - resolution: "libnpmpack@npm:6.0.9" +"libnpmpack@npm:^7.0.0": + version: 7.0.1 + resolution: "libnpmpack@npm:7.0.1" dependencies: "@npmcli/arborist": "npm:^7.2.1" - "@npmcli/run-script": "npm:^7.0.2" - npm-package-arg: "npm:^11.0.1" - pacote: "npm:^17.0.4" - checksum: b2209c9c97361865f622f2d0dea5272dbdf4d10d1b4157af7b74fae507d4669237027a63968db0bc6cc0016abc7aca0d61de0bb1d32ab2f54ccb09a1fd74d803 + "@npmcli/run-script": "npm:^8.1.0" + npm-package-arg: "npm:^11.0.2" + pacote: "npm:^18.0.1" + checksum: edf8e744e32aa472cb5e3aa7bc083238102ca8e8412d91d392439cacae004ad6050dabdd9320da91c36d8686fc2e486f278ebf9a6a3d74d8e5606f9081a573a9 languageName: node linkType: hard "libnpmpublish@npm:^9.0.2": - version: 9.0.6 - resolution: "libnpmpublish@npm:9.0.6" + version: 9.0.7 + resolution: "libnpmpublish@npm:9.0.7" dependencies: ci-info: "npm:^4.0.0" normalize-package-data: "npm:^6.0.0" npm-package-arg: "npm:^11.0.2" - npm-registry-fetch: "npm:^16.2.1" + npm-registry-fetch: "npm:^17.0.0" proc-log: "npm:^4.2.0" semver: "npm:^7.3.7" sigstore: "npm:^2.2.0" ssri: "npm:^10.0.5" - checksum: 3f5f528a6e765d51f070269baf0084381cda2a08c14d9f0026537ca9c9b408b5297ee9c386a35677d3a78399c8c8409c67a73ae4ad3f91b251109f124c70d4cf + checksum: ecfa0629b4adadb7fe5eb6c7286840ebcc5384fbda0be875fa8308230f3814ee08e7f2175cab8263d3bef1121331ae6c8d92ed47561afb69cb1cbf160e50153e languageName: node linkType: hard "libnpmsearch@npm:^7.0.0": - version: 7.0.3 - resolution: "libnpmsearch@npm:7.0.3" + version: 7.0.4 + resolution: "libnpmsearch@npm:7.0.4" dependencies: - npm-registry-fetch: "npm:^16.2.1" - checksum: 84a7d750193f0545b2d565088970e22d3afaa1c40cfdcdf61037c658111b6d7cb58e270d2305a64dee125fec03ef9d331bb7e72616802ab05ed78b21cb03584b + npm-registry-fetch: "npm:^17.0.0" + checksum: 3d16fcd0273405eac0fd3dffc0b032226c6c6ba76a7fad70a07b9f60f32392705be15ec399fd0fd527fc9297a46479d47045f431f1ae74fffe2a3d82155e7ada languageName: node linkType: hard "libnpmteam@npm:^6.0.0": - version: 6.0.3 - resolution: "libnpmteam@npm:6.0.3" + version: 6.0.4 + resolution: "libnpmteam@npm:6.0.4" dependencies: aproba: "npm:^2.0.0" - npm-registry-fetch: "npm:^16.2.1" - checksum: 48f04b3709400ad98ea795d328ef55c6a4d1e832a17b79321c91a89406963eddde3d7227d7e132d2c57d3f4201fea4e79b88978c6f862e46479b4c2e3ecb31c4 + npm-registry-fetch: "npm:^17.0.0" + checksum: 2d7f2bf6831eecc62a711e4e47f3ccd0dee306380ff1a90828156fff480a09f90b294e97b21f2e15d74d57b75fe37f1889132ce1b839603d62ff5f5be35aaea8 languageName: node linkType: hard -"libnpmversion@npm:^5.0.1": - version: 5.0.2 - resolution: "libnpmversion@npm:5.0.2" +"libnpmversion@npm:^6.0.0": + version: 6.0.1 + resolution: "libnpmversion@npm:6.0.1" dependencies: - "@npmcli/git": "npm:^5.0.3" - "@npmcli/run-script": "npm:^7.0.2" + "@npmcli/git": "npm:^5.0.6" + "@npmcli/run-script": "npm:^8.1.0" json-parse-even-better-errors: "npm:^3.0.0" - proc-log: "npm:^3.0.0" + proc-log: "npm:^4.2.0" semver: "npm:^7.3.7" - checksum: 0abfa0589530233593953b43bf0f36c96b2448838c77abad054b3c4cea20b5128b1ee30e1e383645fbb9cf31587136ddee33fc854f8b5b01766a5fee2f9e2b6b + checksum: c4a12167920fadfae9919c9b0145a432743f15813c674af4a7e9a7117dc457e98da67014b688ba37c00fffc4547b99ed63478123a1e193c27e42c398bbc6c4e3 languageName: node linkType: hard @@ -12495,7 +11894,7 @@ __metadata: languageName: node linkType: hard -"lodash@npm:^4.17.15, lodash@npm:^4.17.20, lodash@npm:^4.17.21, lodash@npm:^4.17.4, lodash@npm:^4.17.5, lodash@npm:~4.17.0": +"lodash@npm:^4.17.20, lodash@npm:^4.17.21, lodash@npm:^4.17.4, lodash@npm:^4.17.5, lodash@npm:~4.17.0": version: 4.17.21 resolution: "lodash@npm:4.17.21" checksum: d8cbea072bb08655bb4c989da418994b073a608dffa608b09ac04b43a791b12aeae7cd7ad919aa4c925f33b48490b5cfe6c1f71d827956071dae2e7bb3a6b74c @@ -12583,15 +11982,6 @@ __metadata: languageName: node linkType: hard -"lru-cache@npm:^6.0.0": - version: 6.0.0 - resolution: "lru-cache@npm:6.0.0" - dependencies: - yallist: "npm:^4.0.0" - checksum: cb53e582785c48187d7a188d3379c181b5ca2a9c78d2bce3e7dee36f32761d1c42983da3fe12b55cb74e1779fa94cdc2e5367c028a9b35317184ede0c07a30a9 - languageName: node - linkType: hard - "lru-queue@npm:^0.1.0": version: 0.1.0 resolution: "lru-queue@npm:0.1.0" @@ -12642,7 +12032,7 @@ __metadata: languageName: node linkType: hard -"make-fetch-happen@npm:^13.0.0": +"make-fetch-happen@npm:^13.0.0, make-fetch-happen@npm:^13.0.1": version: 13.0.1 resolution: "make-fetch-happen@npm:13.0.1" dependencies: @@ -12861,7 +12251,7 @@ __metadata: languageName: node linkType: hard -"minimatch@npm:^9.0.0, minimatch@npm:^9.0.1, minimatch@npm:^9.0.3, minimatch@npm:^9.0.4": +"minimatch@npm:^9.0.0, minimatch@npm:^9.0.1, minimatch@npm:^9.0.4": version: 9.0.4 resolution: "minimatch@npm:9.0.4" dependencies: @@ -12887,8 +12277,8 @@ __metadata: linkType: hard "minipass-fetch@npm:^3.0.0": - version: 3.0.4 - resolution: "minipass-fetch@npm:3.0.4" + version: 3.0.5 + resolution: "minipass-fetch@npm:3.0.5" dependencies: encoding: "npm:^0.1.13" minipass: "npm:^7.0.3" @@ -12897,7 +12287,7 @@ __metadata: dependenciesMeta: encoding: optional: true - checksum: 1b63c1f3313e88eeac4689f1b71c9f086598db9a189400e3ee960c32ed89e06737fa23976c9305c2d57464fb3fcdc12749d3378805c9d6176f5569b0d0ee8a75 + checksum: 9d702d57f556274286fdd97e406fc38a2f5c8d15e158b498d7393b1105974b21249289ec571fa2b51e038a4872bfc82710111cf75fae98c662f3d6f95e72152b languageName: node linkType: hard @@ -12955,9 +12345,9 @@ __metadata: linkType: hard "minipass@npm:^5.0.0 || ^6.0.2 || ^7.0.0, minipass@npm:^7.0.2, minipass@npm:^7.0.3, minipass@npm:^7.0.4": - version: 7.0.4 - resolution: "minipass@npm:7.0.4" - checksum: 6c7370a6dfd257bf18222da581ba89a5eaedca10e158781232a8b5542a90547540b4b9b7e7f490e4cda43acfbd12e086f0453728ecf8c19e0ef6921bc5958ac5 + version: 7.1.1 + resolution: "minipass@npm:7.1.1" + checksum: fdccc2f99c31083f45f881fd1e6971d798e333e078ab3c8988fb818c470fbd5e935388ad9adb286397eba50baebf46ef8ff487c8d3f455a69c6f3efc327bdff9 languageName: node linkType: hard @@ -12980,15 +12370,15 @@ __metadata: languageName: node linkType: hard -"mlly@npm:^1.6.1": - version: 1.6.1 - resolution: "mlly@npm:1.6.1" +"mlly@npm:^1.6.1, mlly@npm:^1.7.0": + version: 1.7.0 + resolution: "mlly@npm:1.7.0" dependencies: acorn: "npm:^8.11.3" pathe: "npm:^1.1.2" - pkg-types: "npm:^1.0.3" - ufo: "npm:^1.3.2" - checksum: a7bf26b3d4f83b0f5a5232caa3af44be08b464f562f31c11d885d1bc2d43b7d717137d47b0c06fdc69e1b33ffc09f902b6d2b18de02c577849d40914e8785092 + pkg-types: "npm:^1.1.0" + ufo: "npm:^1.5.3" + checksum: 0b90e5b86e35897fd830624635b30052d0dfeb01b62a021fff4c0a5f46fbc617db685acfbc8c1c7cdcf687d9ffb8d54f3c1b0087ab953232cb3c158a2fb2d770 languageName: node linkType: hard @@ -13008,7 +12398,7 @@ __metadata: languageName: node linkType: hard -"mock-socket@npm:^9.2.1, mock-socket@npm:^9.3.1": +"mock-socket@npm:^9.3.1": version: 9.3.1 resolution: "mock-socket@npm:9.3.1" checksum: 0c53baa4acca12ed1ff9bddfdd4bc0cabe0fc96a3ed25a42a00d23b7a111eb6edfc2b44d93aef9a0c93a4a000b4d2d8dcff028488cd2a1e9cc416477ee341ce0 @@ -13036,13 +12426,6 @@ __metadata: languageName: node linkType: hard -"ms@npm:2.0.0": - version: 2.0.0 - resolution: "ms@npm:2.0.0" - checksum: f8fda810b39fd7255bbdc451c46286e549794fcc700dc9cd1d25658bbc4dc2563a5de6fe7c60f798a16a60c6ceb53f033cb353f493f0cf63e5199b702943159d - languageName: node - linkType: hard - "ms@npm:2.1.2": version: 2.1.2 resolution: "ms@npm:2.1.2" @@ -13150,7 +12533,7 @@ __metadata: languageName: node linkType: hard -"nock@npm:^13.3.0, nock@npm:^13.5.0": +"nock@npm:^13.5.0": version: 13.5.4 resolution: "nock@npm:13.5.4" dependencies: @@ -13210,7 +12593,7 @@ __metadata: languageName: node linkType: hard -"node-fetch@npm:^3.3.0, node-fetch@npm:^3.3.2": +"node-fetch@npm:^3.3.2": version: 3.3.2 resolution: "node-fetch@npm:3.3.2" dependencies: @@ -13229,13 +12612,13 @@ __metadata: linkType: hard "node-gyp-build@npm:^4.3.0": - version: 4.8.0 - resolution: "node-gyp-build@npm:4.8.0" + version: 4.8.1 + resolution: "node-gyp-build@npm:4.8.1" bin: node-gyp-build: bin.js node-gyp-build-optional: optional.js node-gyp-build-test: build-test.js - checksum: 85324be16f81f0235cbbc42e3eceaeb1b5ab94c8d8f5236755e1435b4908338c65a4e75f66ee343cbcb44ddf9b52a428755bec16dcd983295be4458d95c8e1ad + checksum: e36ca3d2adf2b9cca316695d7687207c19ac6ed326d6d7c68d7112cebe0de4f82d6733dff139132539fcc01cf5761f6c9082a21864ab9172edf84282bc849ce7 languageName: node linkType: hard @@ -13284,25 +12667,25 @@ __metadata: linkType: hard "nopt@npm:^7.0.0, nopt@npm:^7.2.0": - version: 7.2.0 - resolution: "nopt@npm:7.2.0" + version: 7.2.1 + resolution: "nopt@npm:7.2.1" dependencies: abbrev: "npm:^2.0.0" bin: nopt: bin/nopt.js - checksum: 9bd7198df6f16eb29ff16892c77bcf7f0cc41f9fb5c26280ac0def2cf8cf319f3b821b3af83eba0e74c85807cc430a16efe0db58fe6ae1f41e69519f585b6aff + checksum: a069c7c736767121242037a22a788863accfa932ab285a1eb569eb8cd534b09d17206f68c37f096ae785647435e0c5a5a0a67b42ec743e481a455e5ae6a6df81 languageName: node linkType: hard "normalize-package-data@npm:^6.0.0": - version: 6.0.0 - resolution: "normalize-package-data@npm:6.0.0" + version: 6.0.1 + resolution: "normalize-package-data@npm:6.0.1" dependencies: hosted-git-info: "npm:^7.0.0" is-core-module: "npm:^2.8.1" semver: "npm:^7.3.5" validate-npm-package-license: "npm:^3.0.4" - checksum: dbd7c712c1e016a4b682640a53b44e9290c9db7b94355c71234bafee1534bef4c5dc3970c30c7ee2c4990a3c07e963e15e211b61624d58eb857d867ec71d3bb6 + checksum: a44ef2312e6372b70fa48eb84081bdff509476abcd7e9ea3fe2f890a20aeb02068f6739230d2fa40f6a4494450a0a51dbfe00444ea83df3411451278ec94a911 languageName: node linkType: hard @@ -13351,11 +12734,11 @@ __metadata: linkType: hard "npm-bundled@npm:^3.0.0": - version: 3.0.0 - resolution: "npm-bundled@npm:3.0.0" + version: 3.0.1 + resolution: "npm-bundled@npm:3.0.1" dependencies: npm-normalize-package-bin: "npm:^3.0.0" - checksum: 65fcc621ba6e183be2715e3bbbf29d85e65e986965f06ee5e96a293d62dfad59ee57a9dcdd1c591eab156e03d58b3c35926b4211ce792d683458e15bb9f642c7 + checksum: 7975590a50b7ce80dd9f3eddc87f7e990c758f2f2c4d9313dd67a9aca38f1a5ac0abe20d514b850902c441e89d2346adfc3c6f1e9cbab3ea28ebb653c4442440 languageName: node linkType: hard @@ -13375,7 +12758,7 @@ __metadata: languageName: node linkType: hard -"npm-package-arg@npm:^11.0.0, npm-package-arg@npm:^11.0.1, npm-package-arg@npm:^11.0.2": +"npm-package-arg@npm:^11.0.0, npm-package-arg@npm:^11.0.2": version: 11.0.2 resolution: "npm-package-arg@npm:11.0.2" dependencies: @@ -13397,18 +12780,18 @@ __metadata: linkType: hard "npm-pick-manifest@npm:^9.0.0": - version: 9.0.0 - resolution: "npm-pick-manifest@npm:9.0.0" + version: 9.0.1 + resolution: "npm-pick-manifest@npm:9.0.1" dependencies: npm-install-checks: "npm:^6.0.0" npm-normalize-package-bin: "npm:^3.0.0" npm-package-arg: "npm:^11.0.0" semver: "npm:^7.3.5" - checksum: 930859b70fb7b8cd8aee1c9819c2fbe95db5ae246398fbd6eaa819793675e36be97da2b4d19e1b56a913a016f7a0a33070cd3ed363ad522d5dbced9c0d94d037 + checksum: c9b93a533b599bccba4f5d7ba313725d83a0058d981e8318176bfbb3a6c9435acd1a995847eaa3ffb45162161947db9b0674ceee13cfe716b345573ca1073d8e languageName: node linkType: hard -"npm-profile@npm:^9.0.1": +"npm-profile@npm:^9.0.2": version: 9.0.2 resolution: "npm-profile@npm:9.0.2" dependencies: @@ -13418,25 +12801,9 @@ __metadata: languageName: node linkType: hard -"npm-registry-fetch@npm:^16.0.0, npm-registry-fetch@npm:^16.2.1": - version: 16.2.1 - resolution: "npm-registry-fetch@npm:16.2.1" - dependencies: - "@npmcli/redact": "npm:^1.1.0" - make-fetch-happen: "npm:^13.0.0" - minipass: "npm:^7.0.2" - minipass-fetch: "npm:^3.0.0" - minipass-json-stream: "npm:^1.0.1" - minizlib: "npm:^2.1.2" - npm-package-arg: "npm:^11.0.0" - proc-log: "npm:^4.0.0" - checksum: bccffc291771d55056a6ebedb7aaf431cecc663286e060dc2936e8e0deee454a4a71654f772afcaa44f0d74a2c02403d8b45486a0aa2dd6d2bd8c09c9134eeb9 - languageName: node - linkType: hard - "npm-registry-fetch@npm:^17.0.0": - version: 17.0.0 - resolution: "npm-registry-fetch@npm:17.0.0" + version: 17.0.1 + resolution: "npm-registry-fetch@npm:17.0.1" dependencies: "@npmcli/redact": "npm:^2.0.0" make-fetch-happen: "npm:^13.0.0" @@ -13446,7 +12813,7 @@ __metadata: minizlib: "npm:^2.1.2" npm-package-arg: "npm:^11.0.0" proc-log: "npm:^4.0.0" - checksum: 873fd9e4a11178badcf9f749310f364244307912f45b2ca0ec6913f0bc01186899674378dacddc6c0a15013236dc604d406754e65cce42477b9819a61f33f597 + checksum: c5235928fe31fdb8dc28982f8b20109c5f630adaaf21f69bfece609d3851d670d31e1ea2b70d38c2e573fb88145c6ba270c1c9efc0893860ae89d9e6789ab0fb languageName: node linkType: hard @@ -13469,15 +12836,15 @@ __metadata: linkType: hard "npm-user-validate@npm:^2.0.0": - version: 2.0.0 - resolution: "npm-user-validate@npm:2.0.0" - checksum: 18bb65b746e0e052371db68f260693ee4db82828494b09c16f9ecd686ecf06bb217c605886d4c31b5c42350abc2162244be60e5eccd6133326522f36abf58c9f + version: 2.0.1 + resolution: "npm-user-validate@npm:2.0.1" + checksum: 56cd19b1acbf4c4cd3f7b071b71172a56f756097768b3a940353dcb7cf022525a4b8574015b0ad2bdec69d2bf0ea16dacb33817290a261e011e39f4e01480fcf languageName: node linkType: hard "npm@npm:^10.5.0": - version: 10.6.0 - resolution: "npm@npm:10.6.0" + version: 10.7.0 + resolution: "npm@npm:10.7.0" dependencies: "@isaacs/string-locale-compare": "npm:^1.1.0" "@npmcli/arborist": "npm:^7.2.1" @@ -13486,8 +12853,8 @@ __metadata: "@npmcli/map-workspaces": "npm:^3.0.6" "@npmcli/package-json": "npm:^5.1.0" "@npmcli/promise-spawn": "npm:^7.0.1" - "@npmcli/redact": "npm:^1.1.0" - "@npmcli/run-script": "npm:^8.0.0" + "@npmcli/redact": "npm:^2.0.0" + "@npmcli/run-script": "npm:^8.1.0" "@sigstore/tuf": "npm:^2.3.2" abbrev: "npm:^2.0.0" archy: "npm:~1.0.0" @@ -13506,16 +12873,16 @@ __metadata: json-parse-even-better-errors: "npm:^3.0.1" libnpmaccess: "npm:^8.0.1" libnpmdiff: "npm:^6.0.3" - libnpmexec: "npm:^7.0.4" + libnpmexec: "npm:^8.0.0" libnpmfund: "npm:^5.0.1" libnpmhook: "npm:^10.0.0" libnpmorg: "npm:^6.0.1" - libnpmpack: "npm:^6.0.3" + libnpmpack: "npm:^7.0.0" libnpmpublish: "npm:^9.0.2" libnpmsearch: "npm:^7.0.0" libnpmteam: "npm:^6.0.0" - libnpmversion: "npm:^5.0.1" - make-fetch-happen: "npm:^13.0.0" + libnpmversion: "npm:^6.0.0" + make-fetch-happen: "npm:^13.0.1" minimatch: "npm:^9.0.4" minipass: "npm:^7.0.4" minipass-pipeline: "npm:^1.2.4" @@ -13527,14 +12894,13 @@ __metadata: npm-install-checks: "npm:^6.3.0" npm-package-arg: "npm:^11.0.2" npm-pick-manifest: "npm:^9.0.0" - npm-profile: "npm:^9.0.1" - npm-registry-fetch: "npm:^16.2.1" + npm-profile: "npm:^9.0.2" + npm-registry-fetch: "npm:^17.0.0" npm-user-validate: "npm:^2.0.0" p-map: "npm:^4.0.0" - pacote: "npm:^18.0.2" + pacote: "npm:^18.0.3" parse-conflict-json: "npm:^3.0.1" proc-log: "npm:^4.2.0" - proggy: "npm:^2.0.0" qrcode-terminal: "npm:^0.12.0" read: "npm:^3.0.1" semver: "npm:^7.6.0" @@ -13551,19 +12917,7 @@ __metadata: bin: npm: bin/npm-cli.js npx: bin/npx-cli.js - checksum: f4c98ebafb3c9dbf16899570c6900fa0d9c29898527af72ae6396e6a67c3930cbc524f5967fe4814464e29d866cccc114a1f33b248a94919b77cc3e5f178c6a6 - languageName: node - linkType: hard - -"npmlog@npm:^7.0.1": - version: 7.0.1 - resolution: "npmlog@npm:7.0.1" - dependencies: - are-we-there-yet: "npm:^4.0.0" - console-control-strings: "npm:^1.1.0" - gauge: "npm:^5.0.0" - set-blocking: "npm:^2.0.0" - checksum: d4e6a2aaa7b5b5d2e2ed8f8ac3770789ca0691a49f3576b6a8c97d560a4c3305d2c233a9173d62be737e6e4506bf9e89debd6120a3843c1d37315c34f90fef71 + checksum: cebd2e4cff956403f2cc132bbc184d1955f3849ac33d192375979cf82f4e2c5dd6a1eafa50865f2c6ab5ddda1561581a782684dd206adb5d1208f5220cf5a49a languageName: node linkType: hard @@ -13922,37 +13276,9 @@ __metadata: languageName: node linkType: hard -"pacote@npm:^17.0.4": - version: 17.0.7 - resolution: "pacote@npm:17.0.7" - dependencies: - "@npmcli/git": "npm:^5.0.0" - "@npmcli/installed-package-contents": "npm:^2.0.1" - "@npmcli/promise-spawn": "npm:^7.0.0" - "@npmcli/run-script": "npm:^7.0.0" - cacache: "npm:^18.0.0" - fs-minipass: "npm:^3.0.0" - minipass: "npm:^7.0.2" - npm-package-arg: "npm:^11.0.0" - npm-packlist: "npm:^8.0.0" - npm-pick-manifest: "npm:^9.0.0" - npm-registry-fetch: "npm:^16.0.0" - proc-log: "npm:^4.0.0" - promise-retry: "npm:^2.0.1" - read-package-json: "npm:^7.0.0" - read-package-json-fast: "npm:^3.0.0" - sigstore: "npm:^2.2.0" - ssri: "npm:^10.0.0" - tar: "npm:^6.1.11" - bin: - pacote: lib/bin.js - checksum: 05730d3233918e4d89a4b9f8b436cddbe5081a4922c26c8af7d8f7db3adc79b211edd0e1ef2fd1c5b280811fd93a4486d76188fe75f3172a09d864f099d61066 - languageName: node - linkType: hard - -"pacote@npm:^18.0.0, pacote@npm:^18.0.1, pacote@npm:^18.0.2": - version: 18.0.3 - resolution: "pacote@npm:18.0.3" +"pacote@npm:^18.0.0, pacote@npm:^18.0.1, pacote@npm:^18.0.3": + version: 18.0.6 + resolution: "pacote@npm:18.0.6" dependencies: "@npmcli/git": "npm:^5.0.0" "@npmcli/installed-package-contents": "npm:^2.0.1" @@ -13972,15 +13298,8 @@ __metadata: ssri: "npm:^10.0.0" tar: "npm:^6.1.11" bin: - pacote: lib/bin.js - checksum: 73984dab9b0f6631138772bf72f33ed9dedc17a1b3411feadd8d4e4aecd2a713ba564f5a1f16b6400c74a76f47325719df6ba11cd0d65defaec50cdc0f0d43b8 - languageName: node - linkType: hard - -"pako@npm:^2.0.4": - version: 2.1.0 - resolution: "pako@npm:2.1.0" - checksum: 8e8646581410654b50eb22a5dfd71159cae98145bd5086c9a7a816ec0370b5f72b4648d08674624b3870a521e6a3daffd6c2f7bc00fdefc7063c9d8232ff5116 + pacote: bin/index.js + checksum: d80907375dd52a521255e0debca1ba9089ad8fd7acdf16c5a5db2ea2a5bb23045e2bcf08d1648b1ebc40fcc889657db86ff6187ff5f8d2fc312cd6ad1ec4c6ac languageName: node linkType: hard @@ -14145,13 +13464,13 @@ __metadata: languageName: node linkType: hard -"path-scurry@npm:^1.10.2": - version: 1.10.2 - resolution: "path-scurry@npm:1.10.2" +"path-scurry@npm:^1.11.0": + version: 1.11.0 + resolution: "path-scurry@npm:1.11.0" dependencies: lru-cache: "npm:^10.2.0" minipass: "npm:^5.0.0 || ^6.0.2 || ^7.0.0" - checksum: d723777fbf9627f201e64656680f66ebd940957eebacf780e6cce1c2919c29c116678b2d7dbf8821b3a2caa758d125f4444005ccec886a25c8f324504e48e601 + checksum: a5cd5dfbc6d5bb01d06bc2eb16ccdf303d617865438a21fe15431b8ad334f23351f73259abeb7e4be56f9c68d237b26b4dba51c78b508586035dfc2b55085493 languageName: node linkType: hard @@ -14191,7 +13510,7 @@ __metadata: "@heroicons/react": "npm:^2.1.1" "@hookform/resolvers": "npm:^2.9.11" "@pendulum-chain/api": "npm:^0.3.8" - "@pendulum-chain/api-solang": "npm:^0.2.0" + "@pendulum-chain/api-solang": "npm:0.3.0" "@pendulum-chain/types": "npm:^0.3.8" "@polkadot/api": "npm:^10.9.1" "@polkadot/api-base": "npm:^10.9.1" @@ -14207,7 +13526,7 @@ __metadata: "@polkadot/types-codec": "npm:^10.9.1" "@polkadot/types-create": "npm:^10.9.1" "@polkadot/types-known": "npm:^10.9.1" - "@polkadot/util": "npm:^10.1.9" + "@polkadot/util": "npm:^12.6.2" "@preact/preset-vite": "npm:^2.5.0" "@semantic-release/changelog": "npm:^6.0.3" "@semantic-release/commit-analyzer": "npm:^11.1.0" @@ -14379,14 +13698,14 @@ __metadata: languageName: node linkType: hard -"pkg-types@npm:^1.0.3": - version: 1.1.0 - resolution: "pkg-types@npm:1.1.0" +"pkg-types@npm:^1.1.0": + version: 1.1.1 + resolution: "pkg-types@npm:1.1.1" dependencies: confbox: "npm:^0.1.7" - mlly: "npm:^1.6.1" + mlly: "npm:^1.7.0" pathe: "npm:^1.1.2" - checksum: b350da13d2dab7dc2fa9d65a08a2038d841d8d8c94bf3878dd911a522e20da50d6662bab510fa329e363e403892374b3b847ebf7b3e10011805cdefb00f228fd + checksum: c7d167935de7207479e5829086040d70bea289f31fc1331f17c83e996a4440115c9deba2aa96de839ea66e1676d083c9ca44b33886f87bffa6b49740b67b6fcb languageName: node linkType: hard @@ -15026,11 +14345,11 @@ __metadata: linkType: hard "promzard@npm:^1.0.0": - version: 1.0.1 - resolution: "promzard@npm:1.0.1" + version: 1.0.2 + resolution: "promzard@npm:1.0.2" dependencies: read: "npm:^3.0.1" - checksum: 8445442ff1ff71a2ac2d91ca6a0908631cf6573745298afe52283af23ec00c2dc6276ac4e75cd9bb521c126d33d268c5e5682c93eda492a5dcca8a76e0f671b3 + checksum: d53c4ecb8b606b7e4bdeab14ac22c5f81a57463d29de1b8fe43bbc661106d9e4a79d07044bd3f69bde82c7ebacba7307db90a9699bc20482ce637bdea5fb8e4b languageName: node linkType: hard @@ -15247,11 +14566,11 @@ __metadata: linkType: hard "react-hook-form@npm:^7.43.2": - version: 7.51.3 - resolution: "react-hook-form@npm:7.51.3" + version: 7.51.4 + resolution: "react-hook-form@npm:7.51.4" peerDependencies: react: ^16.8.0 || ^17 || ^18 - checksum: dd7dfc8514df19a13b7647b3faebdcb1329723afb52454626496eeaa657323d42bab12dc85e6b77d758a166c6427fa87f13c5bd9f5f78666c682e8263117e297 + checksum: 73b585adb80bd99ae1fc21208e389fd9830f82c8c8bab4b6c4d5853f858a3259b8dc8fd4aa4608a0bd95bc69883c9332f2fa5e8c80dc17dbb2866de9744dbdb6 languageName: node linkType: hard @@ -15368,18 +14687,6 @@ __metadata: languageName: node linkType: hard -"read-package-json@npm:^7.0.0": - version: 7.0.0 - resolution: "read-package-json@npm:7.0.0" - dependencies: - glob: "npm:^10.2.2" - json-parse-even-better-errors: "npm:^3.0.0" - normalize-package-data: "npm:^6.0.0" - npm-normalize-package-bin: "npm:^3.0.0" - checksum: a2d373d0f87613fe86ec49c7e4bcdaf2a14967c258c6ccfd9585dec8b21e3d5bfe422c460648fb30e8c93fc13579da0d9c9c65adc5ec4e95ec888d99e4bccc79 - languageName: node - linkType: hard - "read-pkg-up@npm:^11.0.0": version: 11.0.0 resolution: "read-pkg-up@npm:11.0.0" @@ -15869,7 +15176,7 @@ __metadata: languageName: node linkType: hard -"rxjs@npm:^7.2.0, rxjs@npm:^7.5.5, rxjs@npm:^7.8.0, rxjs@npm:^7.8.1": +"rxjs@npm:^7.2.0, rxjs@npm:^7.5.5, rxjs@npm:^7.8.1": version: 7.8.1 resolution: "rxjs@npm:7.8.1" dependencies: @@ -15937,15 +15244,15 @@ __metadata: linkType: hard "sass@npm:^1.58.3": - version: 1.75.0 - resolution: "sass@npm:1.75.0" + version: 1.77.0 + resolution: "sass@npm:1.77.0" dependencies: chokidar: "npm:>=3.0.0 <4.0.0" immutable: "npm:^4.0.0" source-map-js: "npm:>=0.6.2 <2.0.0" bin: sass: sass.js - checksum: 1564ab2c8041c99a330cec93127fe8abcf65ac63eecb471610ed7f3126a2599a58b788a3a98eb8719f7f40b9b04e00c92bc9e11a9c2180ad582b8cba9fb030b0 + checksum: bce0e5f5b535491e4e775045a79f19cbe10d800ef53b5f7698958d2992505d7b124c968169b05a0190842d8e0a24c2aa6d75dfbdd7c213820d9d59e227009c19 languageName: node linkType: hard @@ -16045,14 +15352,12 @@ __metadata: languageName: node linkType: hard -"semver@npm:^7.0.0, semver@npm:^7.1.1, semver@npm:^7.1.2, semver@npm:^7.3.2, semver@npm:^7.3.5, semver@npm:^7.3.7, semver@npm:^7.5.2, semver@npm:^7.5.3, semver@npm:^7.5.4, semver@npm:^7.6.0": - version: 7.6.0 - resolution: "semver@npm:7.6.0" - dependencies: - lru-cache: "npm:^6.0.0" +"semver@npm:^7.1.1, semver@npm:^7.1.2, semver@npm:^7.3.2, semver@npm:^7.3.5, semver@npm:^7.3.7, semver@npm:^7.5.2, semver@npm:^7.5.3, semver@npm:^7.5.4, semver@npm:^7.6.0": + version: 7.6.2 + resolution: "semver@npm:7.6.2" bin: semver: bin/semver.js - checksum: fbfe717094ace0aa8d6332d7ef5ce727259815bd8d8815700853f4faf23aacbd7192522f0dc5af6df52ef4fa85a355ebd2f5d39f554bd028200d6cf481ab9b53 + checksum: 97d3441e97ace8be4b1976433d1c32658f6afaff09f143e52c593bae7eef33de19e3e369c88bd985ce1042c6f441c80c6803078d1de2a9988080b66684cbb30c languageName: node linkType: hard @@ -16456,11 +15761,11 @@ __metadata: linkType: hard "ssri@npm:^10.0.0, ssri@npm:^10.0.5": - version: 10.0.5 - resolution: "ssri@npm:10.0.5" + version: 10.0.6 + resolution: "ssri@npm:10.0.6" dependencies: minipass: "npm:^7.0.3" - checksum: b091f2ae92474183c7ac5ed3f9811457e1df23df7a7e70c9476eaa9a0c4a0c8fc190fb45acefbf023ca9ee864dd6754237a697dc52a0fb182afe65d8e77443d8 + checksum: e5a1e23a4057a86a97971465418f22ea89bd439ac36ade88812dd920e4e61873e8abd6a9b72a03a67ef50faa00a2daf1ab745c5a15b46d03e0544a0296354227 languageName: node linkType: hard @@ -16601,7 +15906,7 @@ __metadata: languageName: node linkType: hard -"string-width-cjs@npm:string-width@^4.2.0, string-width@npm:^1.0.2 || 2 || 3 || 4, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": +"string-width-cjs@npm:string-width@^4.2.0, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": version: 4.2.3 resolution: "string-width@npm:4.2.3" dependencies: @@ -17254,18 +16559,18 @@ __metadata: languageName: node linkType: hard -"tuf-js@npm:^2.2.0": - version: 2.2.0 - resolution: "tuf-js@npm:2.2.0" +"tuf-js@npm:^2.2.1": + version: 2.2.1 + resolution: "tuf-js@npm:2.2.1" dependencies: - "@tufjs/models": "npm:2.0.0" + "@tufjs/models": "npm:2.0.1" debug: "npm:^4.3.4" - make-fetch-happen: "npm:^13.0.0" - checksum: 9a11793feed2aa798c1a50107a0f031034b4a670016684e0d0b7d97be3fff7f98f53783c30120bce795c16d58f1b951410bb673aae92cc2437d641cc7457e215 + make-fetch-happen: "npm:^13.0.1" + checksum: 7c17b097571f001730d7be0aeaec6bec46ed2f25bf73990b1133c383d511a1ce65f831e5d6d78770940a85b67664576ff0e4c98e5421bab6d33ff36e4be500c8 languageName: node linkType: hard -"tweetnacl@npm:1.x.x, tweetnacl@npm:^1.0.3": +"tweetnacl@npm:^1.0.3": version: 1.0.3 resolution: "tweetnacl@npm:1.0.3" checksum: 069d9df51e8ad4a89fbe6f9806c68e06c65be3c7d42f0701cc43dba5f0d6064686b238bbff206c5addef8854e3ce00c643bff59432ea2f2c639feab0ee1a93f9 @@ -17317,9 +16622,9 @@ __metadata: linkType: hard "type-fest@npm:^4.6.0, type-fest@npm:^4.7.1": - version: 4.18.0 - resolution: "type-fest@npm:4.18.0" - checksum: d16d9be71ceeb5341cfa7e21d9081e843e74791fb60b5e2555caa26c259c9bcbffd965e1a1c8e571856efddb317b4b1802f73938723f399f1070e9db5b182f4e + version: 4.18.2 + resolution: "type-fest@npm:4.18.2" + checksum: 5e669128bf7cbc9f9cea4e4862c974517a1d9f77652589c2ac0908a8be5d852d4e52593ed14f4d8a44a604fb5e8a8ec1b658e461acd8bb7592f5e5265a04cbab languageName: node linkType: hard @@ -17382,15 +16687,6 @@ __metadata: languageName: node linkType: hard -"typedarray-to-buffer@npm:^3.1.5": - version: 3.1.5 - resolution: "typedarray-to-buffer@npm:3.1.5" - dependencies: - is-typedarray: "npm:^1.0.0" - checksum: 4ac5b7a93d604edabf3ac58d3a2f7e07487e9f6e98195a080e81dbffdc4127817f470f219d794a843b87052cedef102b53ac9b539855380b8c2172054b7d5027 - languageName: node - linkType: hard - "typedarray.prototype.slice@npm:^1.0.3": version: 1.0.3 resolution: "typedarray.prototype.slice@npm:1.0.3" @@ -17432,7 +16728,7 @@ __metadata: languageName: node linkType: hard -"ufo@npm:^1.3.2, ufo@npm:^1.4.0, ufo@npm:^1.5.3": +"ufo@npm:^1.4.0, ufo@npm:^1.5.3": version: 1.5.3 resolution: "ufo@npm:1.5.3" checksum: 1df10702582aa74f4deac4486ecdfd660e74be057355f1afb6adfa14243476cf3d3acff734ccc3d0b74e9bfdefe91d578f3edbbb0a5b2430fe93cd672370e024 @@ -17448,7 +16744,16 @@ __metadata: languageName: node linkType: hard -"uint8arrays@npm:^3.0.0, uint8arrays@npm:^3.1.0": +"uint8arrays@npm:3.1.0": + version: 3.1.0 + resolution: "uint8arrays@npm:3.1.0" + dependencies: + multiformats: "npm:^9.4.2" + checksum: e54e64593a76541330f0fea97b1b5dea6becbbec3572b9bb88863d064f2630bede4d42eafd457f19c6ef9125f50bfc61053d519c4d71b59c3b7566a0691e3ba2 + languageName: node + linkType: hard + +"uint8arrays@npm:^3.0.0": version: 3.1.1 resolution: "uint8arrays@npm:3.1.1" dependencies: @@ -17685,16 +16990,16 @@ __metadata: linkType: hard "update-browserslist-db@npm:^1.0.13": - version: 1.0.13 - resolution: "update-browserslist-db@npm:1.0.13" + version: 1.0.15 + resolution: "update-browserslist-db@npm:1.0.15" dependencies: - escalade: "npm:^3.1.1" + escalade: "npm:^3.1.2" picocolors: "npm:^1.0.0" peerDependencies: browserslist: ">= 4.21.0" bin: update-browserslist-db: cli.js - checksum: e52b8b521c78ce1e0c775f356cd16a9c22c70d25f3e01180839c407a5dc787fb05a13f67560cbaf316770d26fa99f78f1acd711b1b54a4f35d4820d4ea7136e6 + checksum: c5f67dc68aba9a37701a14199e57e22f20c579411d386f47b4d81f6e3f06fd3ec256310594f4f9d6b01bc1cfb93cb1ebb1a1da70c4fa28720bc1d030f55bb8a1 languageName: node linkType: hard @@ -17788,16 +17093,6 @@ __metadata: languageName: node linkType: hard -"utf-8-validate@npm:^5.0.2": - version: 5.0.10 - resolution: "utf-8-validate@npm:5.0.10" - dependencies: - node-gyp: "npm:latest" - node-gyp-build: "npm:^4.3.0" - checksum: 23cd6adc29e6901aa37ff97ce4b81be9238d0023c5e217515b34792f3c3edb01470c3bd6b264096dd73d0b01a1690b57468de3a24167dd83004ff71c51cc025f - languageName: node - linkType: hard - "util-deprecate@npm:^1.0.1, util-deprecate@npm:^1.0.2, util-deprecate@npm:~1.0.1": version: 1.0.2 resolution: "util-deprecate@npm:1.0.2" @@ -17841,11 +17136,9 @@ __metadata: linkType: hard "validate-npm-package-name@npm:^5.0.0": - version: 5.0.0 - resolution: "validate-npm-package-name@npm:5.0.0" - dependencies: - builtins: "npm:^5.0.0" - checksum: 36a9067650f5b90c573a0d394b89ddffb08fe58a60507d7938ad7c38f25055cc5c6bf4a10fbd604abe1f4a31062cbe0dfa8e7ccad37b249da32e7b71889c079e + version: 5.0.1 + resolution: "validate-npm-package-name@npm:5.0.1" + checksum: 903e738f7387404bb72f7ac34e45d7010c877abd2803dc2d614612527927a40a6d024420033132e667b1bade94544b8a1f65c9431a4eb30d0ce0d80093cd1f74 languageName: node linkType: hard @@ -17980,20 +17273,6 @@ __metadata: languageName: node linkType: hard -"websocket@npm:^1.0.34": - version: 1.0.34 - resolution: "websocket@npm:1.0.34" - dependencies: - bufferutil: "npm:^4.0.1" - debug: "npm:^2.2.0" - es5-ext: "npm:^0.10.50" - typedarray-to-buffer: "npm:^3.1.5" - utf-8-validate: "npm:^5.0.2" - yaeti: "npm:^0.0.6" - checksum: a7e17d24edec685fdf055940ff9c6a15e726df5bb5e537382390bd1ab978fc8c0d71cd2842bb628e361d823aafd43934cc56aa5b979d08e52461be7da8d01eee - languageName: node - linkType: hard - "whatwg-encoding@npm:^2.0.0": version: 2.0.0 resolution: "whatwg-encoding@npm:2.0.0" @@ -18117,15 +17396,6 @@ __metadata: languageName: node linkType: hard -"wide-align@npm:^1.1.5": - version: 1.1.5 - resolution: "wide-align@npm:1.1.5" - dependencies: - string-width: "npm:^1.0.2 || 2 || 3 || 4" - checksum: 1d9c2a3e36dfb09832f38e2e699c367ef190f96b82c71f809bc0822c306f5379df87bab47bed27ea99106d86447e50eb972d3c516c2f95782807a9d082fbea95 - languageName: node - linkType: hard - "word-wrap@npm:^1.2.5": version: 1.2.5 resolution: "word-wrap@npm:1.2.5" @@ -18265,13 +17535,6 @@ __metadata: languageName: node linkType: hard -"yaeti@npm:^0.0.6": - version: 0.0.6 - resolution: "yaeti@npm:0.0.6" - checksum: 4e88702d8b34d7b61c1c4ec674422b835d453b8f8a6232be41e59fc98bc4d9ab6d5abd2da55bab75dfc07ae897fdc0c541f856ce3ab3b17de1630db6161aa3f6 - languageName: node - linkType: hard - "yallist@npm:^3.0.2": version: 3.1.1 resolution: "yallist@npm:3.1.1" From c654567c583c9daec73a535e070823732e6eea54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Sat, 11 May 2024 15:57:20 -0300 Subject: [PATCH 43/58] Fix code for backstop withdrawals --- .../Pools/Backstop/AddLiquidity/index.tsx | 10 +- .../Backstop/AddLiquidity/useAddLiquidity.ts | 6 +- .../index.tsx => BackstopPoolModals.tsx} | 25 +- .../nabla/Pools/Backstop/Modals/types.ts | 10 - .../Backstop/WithdrawLiquidity/index.tsx | 242 +++++++----------- .../Backstop/WithdrawLiquidity/schema.ts | 11 - .../Pools/Backstop/WithdrawLiquidity/types.ts | 5 - .../WithdrawLiquidity/useBackstopDrain.ts | 78 ++++++ .../WithdrawLiquidity/useBackstopWithdraw.ts | 42 +-- .../WithdrawLiquidity/useSwapPoolWithdraw.ts | 98 ------- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 165 ++++++++---- src/components/nabla/Pools/Backstop/index.tsx | 5 +- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 125 +++------ .../nabla/Pools/Swap/AddLiquidity/schema.ts | 8 - .../nabla/Pools/Swap/AddLiquidity/types.ts | 3 - .../Swap/AddLiquidity/useAddLiquidity.ts | 65 ++++- .../nabla/Pools/Swap/Redeem/index.tsx | 17 +- .../nabla/Pools/Swap/Redeem/schema.ts | 10 - .../nabla/Pools/Swap/Redeem/types.ts | 4 - .../nabla/Pools/Swap/Redeem/useRedeem.ts | 68 +++-- .../Pools/Swap/WithdrawLiquidity/index.tsx | 17 +- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 39 ++- src/components/nabla/Pools/Swap/columns.tsx | 1 - src/components/nabla/Swap/index.tsx | 15 +- src/components/nabla/Swap/useSwapComponent.ts | 29 ++- .../nabla/common/AssetSelectorModal.tsx | 108 -------- .../nabla/common/PoolSelectorModal.tsx | 150 +++++++++++ src/config/index.ts | 3 +- src/constants/cache.ts | 2 + src/helpers/calc.ts | 46 ---- src/helpers/transaction.ts | 12 +- src/hooks/nabla/useContractRead.ts | 2 +- src/hooks/nabla/useQuote.ts | 110 ++++++++ ...eem.ts => useQuoteBackstopPoolWithdraw.ts} | 41 ++- src/shared/parseNumbers/metric.ts | 3 +- 35 files changed, 826 insertions(+), 749 deletions(-) rename src/components/nabla/Pools/Backstop/{Modals/index.tsx => BackstopPoolModals.tsx} (58%) delete mode 100644 src/components/nabla/Pools/Backstop/Modals/types.ts delete mode 100644 src/components/nabla/Pools/Backstop/WithdrawLiquidity/schema.ts delete mode 100644 src/components/nabla/Pools/Backstop/WithdrawLiquidity/types.ts create mode 100644 src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts delete mode 100644 src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts delete mode 100644 src/components/nabla/Pools/Swap/AddLiquidity/schema.ts delete mode 100644 src/components/nabla/Pools/Swap/AddLiquidity/types.ts delete mode 100644 src/components/nabla/Pools/Swap/Redeem/schema.ts delete mode 100644 src/components/nabla/Pools/Swap/Redeem/types.ts delete mode 100644 src/components/nabla/common/AssetSelectorModal.tsx create mode 100644 src/components/nabla/common/PoolSelectorModal.tsx create mode 100644 src/hooks/nabla/useQuote.ts rename src/hooks/nabla/{useQuoteSwapPoolRedeem.ts => useQuoteBackstopPoolWithdraw.ts} (72%) diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index a466b2ed..6e8555fc 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -28,6 +28,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { } = form; const totalSupplyOfLpTokens = rawToDecimal(data.totalSupply, data.token.decimals); + const submitEnabled = amountBigDecimal?.gt(new Big(0)) && Object.keys(errors).length === 0; const hideCss = !mutation.isIdle ? 'hidden' : ''; return ( @@ -80,14 +81,9 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { token={data.token.id} decimals={data.token.decimals} decimalAmount={amountBigDecimal} - enabled={amountBigDecimal?.gt(new Big(0)) && Object.keys(errors).length === 0} + enabled={submitEnabled} > - diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts index 2db8849b..67a4070a 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts @@ -1,3 +1,4 @@ +import { useCallback, useMemo } from 'preact/hooks'; import { yupResolver } from '@hookform/resolvers/yup'; import * as Yup from 'yup'; import { useQueryClient } from '@tanstack/react-query'; @@ -11,7 +12,6 @@ import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; -import { useCallback, useMemo } from 'preact/hooks'; interface AddLiquidityValues { amount: string; @@ -59,7 +59,9 @@ export const useAddLiquidity = ( form.reset(); balanceQuery.refetch(); depositQuery.refetch(); - queryClient.refetchQueries([cacheKeys.nablaInstance]); + setTimeout(() => { + queryClient.refetchQueries([cacheKeys.nablaInstance]); + }, 2000); }, }, }); diff --git a/src/components/nabla/Pools/Backstop/Modals/index.tsx b/src/components/nabla/Pools/Backstop/BackstopPoolModals.tsx similarity index 58% rename from src/components/nabla/Pools/Backstop/Modals/index.tsx rename to src/components/nabla/Pools/Backstop/BackstopPoolModals.tsx index f1abf638..ad7db7fb 100644 --- a/src/components/nabla/Pools/Backstop/Modals/index.tsx +++ b/src/components/nabla/Pools/Backstop/BackstopPoolModals.tsx @@ -1,10 +1,20 @@ import { FunctionalComponent } from 'preact'; import { Modal } from 'react-daisyui'; -import { useModal } from '../../../../../services/modal'; -import ModalCloseButton from '../../../../Button/ModalClose'; -import AddLiquidity from '../AddLiquidity'; -import WithdrawLiquidity from '../WithdrawLiquidity'; -import { LiquidityModalProps } from './types'; + +import { NablaInstanceBackstopPool } from '../../../../hooks/nabla/useNablaInstance'; +import { useModal } from '../../../../services/modal'; +import ModalCloseButton from '../../../Button/ModalClose'; +import AddLiquidity from './AddLiquidity'; +import WithdrawLiquidity from './WithdrawLiquidity'; + +export const ModalTypes = { + AddLiquidity: 2, + WithdrawLiquidity: 3, +}; + +export type LiquidityModalProps = { + data?: NablaInstanceBackstopPool; +}; // eslint-disable-next-line @typescript-eslint/no-explicit-any const modalsUi: Record> = { @@ -12,7 +22,7 @@ const modalsUi: Record> = { 3: WithdrawLiquidity, }; -const Modals = () => { +export function BackstopPoolModals() { const [{ type, props }, setModal] = useModal(); const Component = type ? modalsUi[type] : undefined; @@ -26,5 +36,4 @@ const Modals = () => { ); -}; -export default Modals; +} diff --git a/src/components/nabla/Pools/Backstop/Modals/types.ts b/src/components/nabla/Pools/Backstop/Modals/types.ts deleted file mode 100644 index 98f931e2..00000000 --- a/src/components/nabla/Pools/Backstop/Modals/types.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { NablaInstanceBackstopPool } from '../../../../../hooks/nabla/useNablaInstance'; - -export const ModalTypes = { - AddLiquidity: 2, - WithdrawLiquidity: 3, -}; - -export type LiquidityModalProps = { - data?: NablaInstanceBackstopPool; -}; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index ae2ebb6f..1cb16616 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -1,218 +1,147 @@ import { ChevronDownIcon } from '@heroicons/react/20/solid'; import { ArrowLeftIcon } from '@heroicons/react/24/outline'; -import { ChangeEvent, useEffect, useMemo } from 'preact/compat'; -import { Button, Range } from 'react-daisyui'; +import { useMemo, useState } from 'preact/compat'; +import { Button } from 'react-daisyui'; import { PoolProgress } from '../..'; -import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { calcSharePercentage, getPoolSurplusNativeAmount } from '../../../../../helpers/calc'; -import { prettyNumbers, rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; +import { rawToDecimal, stringifyBigWithSignificantDecimals } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; import { NumberLoader } from '../../../../Loader'; import FormLoader from '../../../../Loader/Form'; import { useWithdrawLiquidity } from './useWithdrawLiquidity'; import { NablaInstance, NablaInstanceSwapPool, useNablaInstance } from '../../../../../hooks/nabla/useNablaInstance'; -import { AssetSelectorModal } from '../../../common/AssetSelectorModal'; import { TransactionProgress } from '../../../common/TransactionProgress'; -import { TokenAmount } from '../../../common/TokenAmount'; import { FormProvider } from 'react-hook-form'; -import { NumberInput } from '../../../common/NumberInput'; import { TransactionSettingsDropdown } from '../../../common/TransactionSettingsDropdown'; +import { PoolSelectorModal } from '../../../common/PoolSelectorModal'; +import { TokenBalance } from '../../../common/TokenBalance'; +import { AmountSelector } from '../../../common/AmountSelector'; const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element | null => { + const [showTokenModal, setShowTokenModal] = useState(false); const { - toggle, + form, + amountString, + backstopWithdraw, + backstopDrain, balanceQuery, depositQuery, - form, - backstopLpTokenDecimalAmountToRedeem, - pools, selectedPool, - tokenModal, - backstopWithdraw: bpw, - swapPoolWithdraw: spw, - isSwapPoolWithdraw, - updateStorage, + tokenToReceive, + withdrawalQuote, + toggle, onSubmit, + updateStorage, } = useWithdrawLiquidity(nabla); const { - setError, - clearErrors, register, setValue, formState: { errors }, } = form; - useEffect(() => { - if (depositQuery.balance !== undefined && backstopLpTokenDecimalAmountToRedeem > depositQuery.balance) { - setError('amount', { type: 'custom', message: 'Amount exceeds owned LP tokens' }); - } else { - clearErrors('amount'); - } - }, [backstopLpTokenDecimalAmountToRedeem, depositQuery.balance, setError, clearErrors]); - - const isIdle = bpw.mutation.isIdle && spw.mutation.isIdle; - const isLoading = bpw.mutation.isLoading || spw.mutation.isLoading; - const depositedBackstopLpTokenDecimalAmount = depositQuery.balance || 0; - - const withdrawLimit = rawToDecimal( - spw.withdrawLimitDecimalAmount?.toString() || 0, - nabla.backstopPool.lpTokenDecimals, - ).toNumber(); - - const poolTokens = useMemo(() => pools.map((pool) => pool.token), [pools]); + const isIdle = backstopWithdraw.mutation.isIdle && backstopDrain.mutation.isIdle; const hideCss = !isIdle ? 'hidden' : ''; const backstopPool = nabla.backstopPool; + const totalSupplyOfLpTokens = rawToDecimal(backstopPool.totalSupply, backstopPool.token.decimals); + const poolToWithdraw = selectedPool ?? backstopPool; + + const submitEnabled = !withdrawalQuote.isLoading && withdrawalQuote.enabled && Object.keys(errors).length > 0; return (
{ - bpw.mutation.reset(); - spw.mutation.reset(); + backstopWithdraw.mutation.reset(); + backstopDrain.mutation.reset(); }} > - + -
+

-

Withdraw {backstopPool.token.symbol}

-
+ Withdraw from + +

- Deposited:{' '} - {depositQuery.isLoading ? ( - - ) : ( - - setValue('amount', depositedBackstopLpTokenDecimalAmount, { - shouldDirty: true, - shouldTouch: true, - }) - } - >{`${depositQuery.formatted || 0} LP`} - )} + Deposited:

- Balance:{' '} - {balanceQuery.isLoading ? ( - - ) : ( - `${balanceQuery.formatted || 0} ${backstopPool.token.symbol}` - )} + Balance:

-
- {isSwapPoolWithdraw && ( -
-
- Withdraw limit: - {spw.isLoading ? : <>{prettyNumbers(withdrawLimit)} LP} + +
+
+
+
You will withdraw
+ +
+
+
Your current balance
+
- )} -
-
- - - { - setValue('slippage', slippage); - updateStorage({ slippage }); - }} - slippageProps={register('slippage', { - valueAsNumber: true, - onChange: (ev) => - updateStorage({ - slippage: Number(ev.currentTarget.value), - }), - })} - /> -
+ { + setValue('slippage', slippage); + updateStorage({ slippage }); + }} + slippageProps={register('slippage', { + valueAsNumber: true, + onChange: (ev) => + updateStorage({ + slippage: Number(ev.currentTarget.value), + }), + })} + />
- ) => - setValue( - 'amount', - roundNumber((Number(ev.currentTarget.value) / 100) * depositedBackstopLpTokenDecimalAmount, 4), - { - shouldDirty: true, - shouldTouch: false, - }, - ) - } - /> -
+
+
-
Amount
+
Total backstop pool LP tokens
- + {stringifyBigWithSignificantDecimals(totalSupplyOfLpTokens, 2)} {backstopPool.symbol}
-
Deposit
-
{roundNumber(depositedBackstopLpTokenDecimalAmount || 0)} LP
-
-
-
Pool share
+
Your backstop pool share
- {calcSharePercentage( - rawToDecimal(backstopPool.totalSupply || 0, backstopPool.lpTokenDecimals).toNumber(), - depositedBackstopLpTokenDecimalAmount, + {depositQuery.data === undefined ? ( + + ) : ( + calcSharePercentage(totalSupplyOfLpTokens, depositQuery.data.preciseBigDecimal) )} %
-
-
- { - setValue('address', pools.find((pool) => pool.token.id === value.id)?.id); - tokenModal[1].setFalse(); + { + setValue('address', type === 'backstopPool' ? undefined : pool.id); + setShowTokenModal(false); }} excludedToken={undefined} - selected={selectedPool?.token.id} - onClose={tokenModal[1].setFalse} + selected={selectedPool ? { type: 'swapPool', poolAddress: selectedPool.id } : { type: 'backstopPool' }} + onClose={() => setShowTokenModal(false)} />
); diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/schema.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/schema.ts deleted file mode 100644 index b3f8c325..00000000 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/schema.ts +++ /dev/null @@ -1,11 +0,0 @@ -import * as Yup from 'yup'; -import { transformNumber } from '../../../../../helpers/yup'; -import { WithdrawLiquidityValues } from './types'; - -const schema = Yup.object().shape({ - address: Yup.string().nullable().min(5), - slippage: Yup.number().nullable().transform(transformNumber), - amount: Yup.number().positive().required().transform(transformNumber), -}); - -export default schema; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/types.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/types.ts deleted file mode 100644 index 0e1297a3..00000000 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/types.ts +++ /dev/null @@ -1,5 +0,0 @@ -export type WithdrawLiquidityValues = { - amount: number; - address?: string | null; - slippage?: number | null; -}; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts new file mode 100644 index 00000000..b2bfeb22 --- /dev/null +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts @@ -0,0 +1,78 @@ +import { useCallback } from 'react'; +import { config } from '../../../../../config'; +import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; +import { subtractBigDecimalPercentage } from '../../../../../helpers/calc'; +import { getValidSlippage } from '../../../../../helpers/transaction'; +import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; +import { NablaInstanceBackstopPool, NablaInstanceSwapPool } from '../../../../../hooks/nabla/useNablaInstance'; +import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; +import { WithdrawLiquidityValues } from './useWithdrawLiquidity'; +import { UseQuoteResult } from '../../../../../hooks/nabla/useQuote'; + +export type UseBackstopDrainProps = { + backstopPool: NablaInstanceBackstopPool; + selectedSwapPool: NablaInstanceSwapPool | undefined; + onSuccess: () => void; + withdrawalQuote: UseQuoteResult; +}; + +export const useBackstopDrain = ({ + backstopPool, + selectedSwapPool, + onSuccess, + withdrawalQuote, +}: UseBackstopDrainProps) => { + const swapPoolAddress = selectedSwapPool?.id; + + const mutation = useContractWrite({ + abi: backstopPoolAbi, + address: backstopPool.id, + method: 'withdrawExcessSwapLiquidity', + mutateOptions: { + onSuccess, + }, + }); + const { mutate } = mutation; + + const lpTokenDecimals = backstopPool.lpTokenDecimals; + const poolTokenDecimals = selectedSwapPool?.token.decimals; + + const onSubmit = useCallback( + async (variables: WithdrawLiquidityValues) => { + if ( + !variables.amount || + swapPoolAddress === undefined || + poolTokenDecimals === undefined || + withdrawalQuote.data === undefined + ) + return; + const vSlippage = getValidSlippage(variables.slippage ?? config.pools.defaults.slippage); + const minimumAmount = subtractBigDecimalPercentage(withdrawalQuote.data.preciseBigDecimal, vSlippage); + + mutate([ + swapPoolAddress, + decimalToRaw(variables.amount, lpTokenDecimals).toString(), + decimalToRaw(minimumAmount, poolTokenDecimals).toString(), + ]); + }, + [poolTokenDecimals, withdrawalQuote.data, mutate, swapPoolAddress, lpTokenDecimals], + ); + + // TODO Torsten: check whether this calculation makes any sense + /*const sharesQuery = useSharesTargetWorth( + { + address: swapPoolAddress, + lpTokenDecimalAmount: depositedBackstopLpTokenDecimalAmount, + lpTokenDecimals: backstopPool.lpTokenDecimals, + poolTokenDecimals: backstopPool.token.decimals, + abi: backstopPoolAbi, + }, + enabled, + );*/ + + return { + onSubmit, + mutation, + //isLoading: sharesQuery.isLoading, + }; +}; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts index 06e80f3e..81893562 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts @@ -1,28 +1,25 @@ import { useCallback } from 'react'; + import { config } from '../../../../../config'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; -import { subtractPercentage } from '../../../../../helpers/calc'; +import { subtractBigDecimalPercentage } from '../../../../../helpers/calc'; import { getValidSlippage } from '../../../../../helpers/transaction'; import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; -import { WithdrawLiquidityValues } from './types'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; +import { WithdrawLiquidityValues } from './useWithdrawLiquidity'; +import { UseQuoteResult } from '../../../../../hooks/nabla/useQuote'; +import { NablaInstanceBackstopPool } from '../../../../../hooks/nabla/useNablaInstance'; -export type UseBackstopWithdrawProps = { - address: string; - poolTokenDecimals: number; - lpTokenDecimals: number; +interface UseBackstopWithdrawProps { + backstopPool: NablaInstanceBackstopPool; onSuccess: () => void; -}; + withdrawalQuote: UseQuoteResult; +} -export const useBackstopWithdraw = ({ - address, - poolTokenDecimals, - lpTokenDecimals, - onSuccess, -}: UseBackstopWithdrawProps) => { +export function useBackstopWithdraw({ backstopPool, onSuccess, withdrawalQuote }: UseBackstopWithdrawProps) { const mutation = useContractWrite({ abi: backstopPoolAbi, - address, + address: backstopPool.id, method: 'withdraw', mutateOptions: { onSuccess, @@ -30,20 +27,25 @@ export const useBackstopWithdraw = ({ }); const { mutate } = mutation; + const lpTokenDecimals = backstopPool.lpTokenDecimals; + const poolTokenDecimals = backstopPool.token.decimals; + const onSubmit = useCallback( async (variables: WithdrawLiquidityValues) => { - if (!variables.amount) return; - const vSlippage = getValidSlippage(variables.slippage || config.backstop.defaults.slippage); + if (!variables.amount || withdrawalQuote.data === undefined) return; + const vSlippage = getValidSlippage(variables.slippage ?? config.pools.defaults.slippage); + const minimumAmount = subtractBigDecimalPercentage(withdrawalQuote.data.preciseBigDecimal, vSlippage); + mutate([ - decimalToRaw(variables.amount, lpTokenDecimals).toString(), - decimalToRaw(subtractPercentage(variables.amount, vSlippage), poolTokenDecimals).toString(), + decimalToRaw(variables.amount, lpTokenDecimals).round(0, 0).toString(), + decimalToRaw(minimumAmount, poolTokenDecimals).round(0, 0).toString(), ]); }, - [mutate, poolTokenDecimals, lpTokenDecimals], + [withdrawalQuote.data, mutate, lpTokenDecimals, poolTokenDecimals], ); return { onSubmit, mutation, }; -}; +} diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts deleted file mode 100644 index c6d579b4..00000000 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useSwapPoolWithdraw.ts +++ /dev/null @@ -1,98 +0,0 @@ -import { useCallback, useMemo } from 'react'; -import { config } from '../../../../../config'; -import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; -import { calcAvailablePoolWithdraw, subtractPercentage } from '../../../../../helpers/calc'; -import { getValidSlippage } from '../../../../../helpers/transaction'; -import { useSharesTargetWorth } from '../../../../../hooks/nabla/useSharesTargetWorth'; -import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; -import { WithdrawLiquidityValues } from './types'; -import { NablaInstanceBackstopPool, NablaInstanceSwapPool } from '../../../../../hooks/nabla/useNablaInstance'; -import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; -import { useNablaTokenPrice } from '../../../../../hooks/nabla/useNablaTokenPrice'; - -export type UseSwapPoolWithdrawProps = { - backstopPool: NablaInstanceBackstopPool; - selectedSwapPool: NablaInstanceSwapPool; - depositedBackstopLpTokenDecimalAmount: number; - onSuccess: () => void; - enabled: boolean; -}; - -export const useSwapPoolWithdraw = ({ - backstopPool, - selectedSwapPool, - depositedBackstopLpTokenDecimalAmount, - onSuccess, - enabled, -}: UseSwapPoolWithdrawProps) => { - const swapPoolAddress = selectedSwapPool?.id; - - const mutation = useContractWrite({ - abi: backstopPoolAbi, - address: backstopPool.id, - method: 'withdrawExcessSwapLiquidity', - mutateOptions: { - onSuccess, - }, - }); - const { mutate } = mutation; - - const onSubmit = useCallback( - async (variables: WithdrawLiquidityValues) => { - if (!variables.amount || !swapPoolAddress) return; - const vSlippage = getValidSlippage(variables.slippage || config.backstop.defaults.slippage); - - mutate([ - swapPoolAddress, - decimalToRaw(variables.amount, backstopPool.token.decimals).toString(), - // TODO (Torsten): this next line does not make sense, there is no proper way to convert - // backstop pool shares to swap pool tokens - decimalToRaw(subtractPercentage(variables.amount, vSlippage), selectedSwapPool?.token.decimals).toString(), - ]); - }, - [mutate, swapPoolAddress, backstopPool.token.decimals, selectedSwapPool?.token.decimals], - ); - - // TODO Torsten: check whether this calculation makes any sense - const sharesQuery = useSharesTargetWorth( - { - address: swapPoolAddress, - lpTokenDecimalAmount: depositedBackstopLpTokenDecimalAmount, - lpTokenDecimals: backstopPool.lpTokenDecimals, - poolTokenDecimals: backstopPool.token.decimals, - abi: backstopPoolAbi, - }, - enabled, - ); - const bpPriceQuery = useNablaTokenPrice(backstopPool.token.id, enabled); - const spPriceQuery = useNablaTokenPrice(selectedSwapPool?.token.id, enabled); - - // TODO Torsen: also check this - const withdrawLimitDecimalAmount = useMemo( - () => - selectedSwapPool - ? calcAvailablePoolWithdraw({ - selectedSwapPool, - backstopLpDecimalAmount: depositedBackstopLpTokenDecimalAmount, - sharesValueDecimalAmount: sharesQuery.data?.preciseBigDecimal, - bpPrice: bpPriceQuery.data?.rawBalance, - spPrice: spPriceQuery.data?.rawBalance, - swapPoolTokenDecimals: selectedSwapPool.token.decimals, - }) - : 0, - [ - selectedSwapPool, - sharesQuery.data?.preciseBigDecimal, - depositedBackstopLpTokenDecimalAmount, - bpPriceQuery.data?.rawBalance, - spPriceQuery.data?.rawBalance, - ], - ); - - return { - onSubmit, - mutation, - isLoading: bpPriceQuery.isLoading || spPriceQuery.isLoading || sharesQuery.isLoading, - withdrawLimitDecimalAmount, - }; -}; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts index e35cf45c..db6e4e92 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -2,93 +2,159 @@ import { yupResolver } from '@hookform/resolvers/yup'; import { useQueryClient } from '@tanstack/react-query'; import { useCallback, useMemo } from 'preact/compat'; import { useForm, useWatch } from 'react-hook-form'; +import * as Yup from 'yup'; + import { cacheKeys } from '../../../../../constants/cache'; import { storageKeys } from '../../../../../constants/localStorage'; import { debounce } from '../../../../../helpers/function'; -import useBoolean from '../../../../../hooks/useBoolean'; -import { useGetAppDataByTenant } from '../../../../../hooks/useGetAppDataByTenant'; import { TransactionSettings } from '../../../../../models/Transaction'; import { useModalToggle } from '../../../../../services/modal'; import { storageService } from '../../../../../services/storage/local'; -import { defaultValues } from '../../../Swap/useSwapComponent'; -import schema from './schema'; -import { WithdrawLiquidityValues } from './types'; import { useBackstopWithdraw } from './useBackstopWithdraw'; -import { useSwapPoolWithdraw } from './useSwapPoolWithdraw'; +import { useBackstopDrain } from './useBackstopDrain'; import { NablaInstance, NablaInstanceSwapPool } from '../../../../../hooks/nabla/useNablaInstance'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; +import { transformNumber } from '../../../../../helpers/yup'; +import { config } from '../../../../../config'; +import { getValidSlippage } from '../../../../../helpers/transaction'; +import { useQuote } from '../../../../../hooks/nabla/useQuote'; +import { MessageCallErrorResult } from '../../../../../hooks/nabla/useContractRead'; + +export type WithdrawLiquidityValues = { + amount: string; + address?: string | null; + slippage?: number | null; +}; + +const schema = Yup.object().shape({ + amount: Yup.string().required(), + address: Yup.string().nullable().min(5), + slippage: Yup.number().nullable().transform(transformNumber), +}); + +const defaultValues = config.pools.defaults; +const getInitialValues = (): Partial => { + const storageValues = storageService.getParsed(storageKeys.POOL_SETTINGS); + return { + ...defaultValues, + amount: undefined, + address: null, + slippage: getValidSlippage(storageValues?.slippage), + }; +}; + +function parseError(error: MessageCallErrorResult): string { + switch (error.type) { + case 'error': + return 'Cannot determine value of shares'; + case 'panic': + return 'Cannot determine value of shares'; + case 'reverted': + switch (error.description) { + case 'withdraw():MINIMUM_AMOUNT': + case 'withdrawExcessSwapLiquidity():MIN_AMOUNT': + return 'The returned amount of tokens is below your desired minimum amount.'; + case 'sharesTargetWorth():POOLWORTH_NEGATIVE': + return 'It is not possible to withdraw from the backstop pool at the moment.'; + case 'withdraw: INSUFFICIENT_BALANCE': + case 'withdrawExcessSwapLiquidity():BALANCE': + return "You don't have enough LP tokens to redeem."; + case 'SwapPool#backstopDrain():INSUFFICIENT_COVERAGE': + return 'The input amount is too large.'; + } + return 'Cannot determine value of shares'; + } +} const storageSet = debounce(storageService.set, 1000); -export const useWithdrawLiquidity = (nabla: NablaInstance) => { - const poolAddress = nabla.backstopPool.id; - const token = nabla.backstopPool.token; - const tokenAddress = token.id; - const swapPools = nabla.swapPools; - const { indexerUrl } = useGetAppDataByTenant('nabla').data || {}; +export const useWithdrawLiquidity = (nabla: NablaInstance) => { const queryClient = useQueryClient(); const toggle = useModalToggle(); - const tokenModal = useBoolean(); - const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { - contractAddress: tokenAddress, - decimals: nabla.backstopPool.token.decimals, - }); - - const depositQuery = useErc20ContractBalance(backstopPoolAbi, { - contractAddress: poolAddress, - decimals: nabla.backstopPool.lpTokenDecimals, - }); + const backstopPoolAddress = nabla.backstopPool.id; - const { refetch: balanceRefetch } = balanceQuery; - const { refetch: depositRefetch } = depositQuery; + const swapPools = nabla.swapPools; const form = useForm({ resolver: yupResolver(schema), - defaultValues: {}, + defaultValues: getInitialValues(), }); - const { reset, getValues, handleSubmit } = form; - const backstopLpTokenDecimalAmountToRedeem = - Number( - useWatch({ - control: form.control, - name: 'amount', - defaultValue: 0, - }), - ) || 0; const address = useWatch({ control: form.control, name: 'address', }); - const selectedPool: NablaInstanceSwapPool | undefined = useMemo( + const selectedPool = useMemo( () => swapPools.find((t) => t.id === address)!, [address, swapPools], ); + const tokenToReceive = selectedPool?.token ?? nabla.backstopPool.token; + + const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { + contractAddress: tokenToReceive.id, + decimals: tokenToReceive.decimals, + }); + + const depositQuery = useErc20ContractBalance(backstopPoolAbi, { + contractAddress: backstopPoolAddress, + decimals: nabla.backstopPool.lpTokenDecimals, + }); + + const { reset, getValues } = form; + const amountString = useWatch({ + control: form.control, + name: 'amount', + defaultValue: '0', + }); + + const { refetch: balanceRefetch } = balanceQuery; + const { refetch: depositRefetch } = depositQuery; + const { refetchQueries } = queryClient; const onWithdrawSuccess = useCallback(() => { reset(); balanceRefetch(); depositRefetch(); - }, [balanceRefetch, depositRefetch, reset]); + setTimeout(() => { + refetchQueries([cacheKeys.nablaInstance]); + }, 2000); + }, [refetchQueries, balanceRefetch, depositRefetch, reset]); - const backstopWithdraw = useBackstopWithdraw({ - address: poolAddress, - poolTokenDecimals: nabla.backstopPool.token.decimals, + const withdrawalQuote = useQuote({ + lpTokenAmountString: amountString, lpTokenDecimals: nabla.backstopPool.lpTokenDecimals, + maximumLpTokenAmount: depositQuery.data?.preciseBigDecimal, + poolTokenDecimals: tokenToReceive.decimals, + contractAddress: backstopPoolAddress, + contractAbi: backstopPoolAbi, + messageName: selectedPool !== undefined ? 'withdrawExcessSwapLiquidity' : 'withdraw', + primaryCacheKey: + selectedPool !== undefined ? cacheKeys.quoteBackstopPoolDrain : cacheKeys.quoteBackstopPoolWithdraw, + constructArgs: useCallback( + (amountIn: string | undefined) => + amountIn === undefined ? [] : selectedPool !== undefined ? [selectedPool.id, amountIn, '0'] : [amountIn, '0'], + [selectedPool], + ), + parseError, + form, + pickFromReturnArray: selectedPool !== undefined ? undefined : 0, + }); + + const backstopWithdraw = useBackstopWithdraw({ + backstopPool: nabla.backstopPool, onSuccess: onWithdrawSuccess, + withdrawalQuote, }); - const isSwapPoolWithdraw = !!address && address.length > 5; - const swapPoolWithdraw = useSwapPoolWithdraw({ + const backstopDrain = useBackstopDrain({ backstopPool: nabla.backstopPool, - depositedBackstopLpTokenDecimalAmount: depositQuery.balance?.approximateNumber ?? 0, selectedSwapPool: selectedPool, - enabled: isSwapPoolWithdraw, onSuccess: onWithdrawSuccess, + withdrawalQuote, }); const updateStorage = useCallback( @@ -105,18 +171,17 @@ export const useWithdrawLiquidity = (nabla: NablaInstance) => { ); return { - backstopLpTokenDecimalAmountToRedeem, + form, + amountString, backstopWithdraw, + backstopDrain, balanceQuery, depositQuery, - form, - isSwapPoolWithdraw, - pools: swapPools, selectedPool, - swapPoolWithdraw, - tokenModal, + tokenToReceive, + withdrawalQuote, toggle, + onSubmit: form.handleSubmit(selectedPool !== undefined ? backstopDrain.onSubmit : backstopWithdraw.onSubmit), updateStorage, - onSubmit: handleSubmit(isSwapPoolWithdraw ? swapPoolWithdraw.onSubmit : backstopWithdraw.onSubmit), }; }; diff --git a/src/components/nabla/Pools/Backstop/index.tsx b/src/components/nabla/Pools/Backstop/index.tsx index 85990427..aba105cb 100644 --- a/src/components/nabla/Pools/Backstop/index.tsx +++ b/src/components/nabla/Pools/Backstop/index.tsx @@ -1,11 +1,10 @@ import { Button, Card } from 'react-daisyui'; import ModalProvider, { useModalToggle } from '../../../../services/modal'; import { Skeleton } from '../../../Skeleton'; -import Modals from './Modals'; -import { LiquidityModalProps, ModalTypes } from './Modals/types'; import { useNablaInstance } from '../../../../hooks/nabla/useNablaInstance'; import { backstopPoolAbi } from '../../../../contracts/nabla/BackstopPool'; import { Erc20Balance } from '../../common/Erc20Balance'; +import { BackstopPoolModals, LiquidityModalProps, ModalTypes } from './BackstopPoolModals'; const BackstopPoolsBody = (): JSX.Element | null => { const toggle = useModalToggle(); @@ -62,7 +61,7 @@ const BackstopPoolsBody = (): JSX.Element | null => {
- + ); }; diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index 29c335bf..0d69e87f 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -1,140 +1,89 @@ import { ArrowLeftIcon } from '@heroicons/react/24/outline'; import { Button } from 'react-daisyui'; +import { FormProvider } from 'react-hook-form'; +import Big from 'big.js'; + import { PoolProgress } from '../..'; import { calcSharePercentage } from '../../../../../helpers/calc'; -import { rawToDecimal, roundNumber } from '../../../../../shared/parseNumbers/metric'; +import { rawToDecimal, stringifyBigWithSignificantDecimals } from '../../../../../shared/parseNumbers/metric'; import Validation from '../../../../Form/Validation'; import { NumberLoader } from '../../../../Loader'; import { SwapPoolColumn } from '../columns'; import { useAddLiquidity } from './useAddLiquidity'; import { TransactionProgress } from '../../../common/TransactionProgress'; import { TokenApproval } from '../../../common/TokenApproval'; -import { useEffect } from 'preact/hooks'; -import { NumberInput } from '../../../common/NumberInput'; -import { FormProvider } from 'react-hook-form'; +import { TokenBalance } from '../../../common/TokenBalance'; +import { AmountSelector } from '../../../common/AmountSelector'; export interface AddLiquidityProps { data: SwapPoolColumn; } const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => { - const { toggle, mutation, onSubmit, balanceQuery, depositQuery, decimalAmount, form } = useAddLiquidity( - data.id, - data.token.id, - data.token.decimals, - data.lpTokenDecimals, - ); - const balance = balanceQuery.balance || 0; - const deposit = depositQuery.balance || 0; + const { toggle, onSubmit, mutation, depositQuery, balanceQuery, amountString, amountBigDecimal, form } = + useAddLiquidity(data.id, data.token.id, data.token.decimals, data.lpTokenDecimals); const { - setError, - clearErrors, - setValue, formState: { errors }, } = form; - useEffect(() => { - if (balanceQuery.balance !== undefined && decimalAmount > balanceQuery.balance) { - setError('amount', { type: 'custom', message: 'Amount exceeds balance' }); - } else { - clearErrors('amount'); - } - }, [decimalAmount, balanceQuery.balance, setError, clearErrors]); - - console.log(errors, Object.keys(errors)); + const totalSupplyOfLpTokens = rawToDecimal(data.totalSupply, data.token.decimals); + const submitEnabled = amountBigDecimal?.gt(new Big(0)) && Object.keys(errors).length === 0; const hideCss = !mutation.isIdle ? 'hidden' : ''; return (
- + -
- -

Confirm deposit

-
+
+ +

Confirm deposit

+
-
-
-

Deposited: {depositQuery.isLoading ? : `${depositQuery.formatted || 0} LP`}

-

- Balance:{' '} - {balanceQuery.isLoading ? : `${balanceQuery.formatted || 0} ${data.token.symbol}`} -

-
-
- - - -
+
+

+ Deposited: +

+

+ Balance: +

+ +
-
Total deposit
-
{depositQuery.isLoading ? : `${roundNumber(deposit)} ${data.token.symbol}`}
+
Total LP Tokens
+
+ {stringifyBigWithSignificantDecimals(totalSupplyOfLpTokens, 2)} {data.symbol} +
-
Pool Share
+
Your pool Share
- {depositQuery.isLoading ? ( + {depositQuery.data === undefined ? ( ) : ( - calcSharePercentage(rawToDecimal(data.totalSupply || 0, data.lpTokenDecimals).toNumber(), deposit) + calcSharePercentage(totalSupplyOfLpTokens, depositQuery.data.preciseBigDecimal) )} %
- -
+
0 && Object.keys(errors).length === 0} + decimalAmount={amountBigDecimal} + enabled={submitEnabled} > - diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/schema.ts b/src/components/nabla/Pools/Swap/AddLiquidity/schema.ts deleted file mode 100644 index 88b2b38a..00000000 --- a/src/components/nabla/Pools/Swap/AddLiquidity/schema.ts +++ /dev/null @@ -1,8 +0,0 @@ -import * as Yup from 'yup'; -import { AddLiquidityValues } from './types'; - -const schema = Yup.object().shape({ - amount: Yup.number().positive().required(), -}); - -export default schema; diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/types.ts b/src/components/nabla/Pools/Swap/AddLiquidity/types.ts deleted file mode 100644 index 79046f40..00000000 --- a/src/components/nabla/Pools/Swap/AddLiquidity/types.ts +++ /dev/null @@ -1,3 +0,0 @@ -export type AddLiquidityValues = { - amount: number; -}; diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index ec96ddda..eae3e737 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -1,13 +1,25 @@ import { yupResolver } from '@hookform/resolvers/yup'; +import * as Yup from 'yup'; import { useForm, useWatch } from 'react-hook-form'; +import { useCallback, useMemo } from 'preact/hooks'; +import Big from 'big.js'; +import { useQueryClient } from '@tanstack/react-query'; + import { swapPoolAbi } from '../../../../../contracts/nabla/SwapPool'; import { useModalToggle } from '../../../../../services/modal'; import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; -import schema from './schema'; -import { AddLiquidityValues } from './types'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; +import { cacheKeys } from '../../../../../constants/cache'; + +export type AddLiquidityValues = { + amount: string; +}; + +const schema = Yup.object().shape({ + amount: Yup.number().positive().required(), +}); export const useAddLiquidity = ( poolAddress: string, @@ -15,6 +27,7 @@ export const useAddLiquidity = ( poolTokenDecimals: number, lpTokenDecimals: number, ) => { + const queryClient = useQueryClient(); const toggle = useModalToggle(); const balanceQuery = useErc20ContractBalance(erc20WrapperAbi, { @@ -29,7 +42,9 @@ export const useAddLiquidity = ( const form = useForm({ resolver: yupResolver(schema), - defaultValues: {}, + defaultValues: { + amount: undefined, + }, }); const mutation = useContractWrite({ @@ -44,22 +59,44 @@ export const useAddLiquidity = ( form.reset(); balanceQuery.refetch(); depositQuery.refetch(); + setTimeout(() => { + queryClient.refetchQueries([cacheKeys.nablaInstance]); + }, 2000); }, }, }); - const onSubmit = form.handleSubmit((variables) => { - return mutation.mutate([decimalToRaw(variables.amount, poolTokenDecimals).toString()]); + const amountString = useWatch({ + control: form.control, + name: 'amount', + defaultValue: '0', }); - const decimalAmount = - Number( - useWatch({ - control: form.control, - name: 'amount', - defaultValue: 0, - }), - ) || 0; + const { mutate } = mutation; + const onSubmit = useCallback( + (variables: AddLiquidityValues) => { + if (!variables.amount) return; + return mutate([decimalToRaw(variables.amount, poolTokenDecimals).round(0, 0).toString()]); + }, + [mutate, poolTokenDecimals], + ); + + const amountBigDecimal = useMemo(() => { + try { + return new Big(amountString); + } catch { + return undefined; + } + }, [amountString]); - return { form, decimalAmount, mutation, onSubmit, toggle, balanceQuery, depositQuery }; + return { + form, + amountString, + amountBigDecimal, + mutation, + balanceQuery, + depositQuery, + onSubmit: form.handleSubmit(onSubmit), + toggle, + }; }; diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index c30860a8..2d6f2ac9 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -13,7 +13,6 @@ import { FormProvider } from 'react-hook-form'; import { TransactionSettingsDropdown } from '../../../common/TransactionSettingsDropdown'; import { TokenBalance } from '../../../common/TokenBalance'; import { AmountSelector } from '../../../common/AmountSelector'; -import Spinner from '../../../../../assets/spinner'; import { ModalTypes } from '../SwapPoolModals'; export type RedeemLiquidityValues = { @@ -135,15 +134,13 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => { Withdraw from swap pool
-
)} - - ); - })} -
-
- ); -} - -type AssetSelectorModalProps = { - isLoading?: boolean; - onClose: () => void; -} & AssetListProps & - Omit; - -export function AssetSelectorModal({ - assets, - selected, - excludedToken, - isLoading, - onSelect, - onClose, - ...rest -}: AssetSelectorModalProps) { - return ( - - - -

Select a token

-
- -
- {isLoading ? ( - repeat() - ) : ( - - )} -
-
-
- ); -} diff --git a/src/components/nabla/common/PoolSelectorModal.tsx b/src/components/nabla/common/PoolSelectorModal.tsx new file mode 100644 index 00000000..682ff54d --- /dev/null +++ b/src/components/nabla/common/PoolSelectorModal.tsx @@ -0,0 +1,150 @@ +import { CheckIcon } from '@heroicons/react/20/solid'; +import { matchSorter } from 'match-sorter'; +import { ChangeEvent, useMemo, useState } from 'preact/compat'; +import { Avatar, AvatarProps, Button, Input, Modal } from 'react-daisyui'; +import { repeat } from '../../../helpers/general'; +import ModalCloseButton from '../../Button/ModalClose'; +import { Skeleton } from '../../Skeleton'; +import { NablaInstanceBackstopPool, NablaInstanceSwapPool } from '../../../hooks/nabla/useNablaInstance'; + +export type PoolEntry = + | { type: 'swapPool'; pool: NablaInstanceSwapPool } + | { type: 'backstopPool'; pool: NablaInstanceBackstopPool }; + +interface PoolListProps { + swapPools: NablaInstanceSwapPool[]; + backstopPool?: NablaInstanceBackstopPool; + onSelect: (pool: PoolEntry) => void; + excludedToken: string | undefined; + selected: + | { type: 'token'; tokenAddress: string | undefined } + | { type: 'backstopPool' } + | { type: 'swapPool'; poolAddress: string }; +} + +function PoolList({ swapPools, backstopPool, onSelect, selected, excludedToken }: PoolListProps) { + const [filter, setFilter] = useState(); + + const poolList = useMemo(() => { + const poolList: PoolEntry[] = swapPools + .filter((pool) => pool.token.id !== excludedToken) + .map((pool) => ({ type: 'swapPool', pool })); + poolList.sort((a, b) => (a.pool.token.symbol < b.pool.token.symbol ? -1 : 1)); + + if (backstopPool !== undefined) { + poolList.unshift({ type: 'backstopPool', pool: backstopPool }); + } + + if (filter) { + return matchSorter(poolList, filter, { + keys: ['pool.token.name', 'pool.token.address', 'pool.token.symbol'], + }); + } + + return poolList; + }, [swapPools, backstopPool, filter, excludedToken]); + + const showPoolType = backstopPool !== undefined; + + return ( +
+ ) => setFilter(ev.currentTarget.value)} + placeholder="Find by name or address" + /> +
+ {poolList?.map((poolEntry) => { + const { pool, type } = poolEntry; + let isSelected; + switch (selected.type) { + case 'token': + isSelected = selected.tokenAddress === pool.token.id; + break; + case 'backstopPool': + isSelected = type === 'backstopPool'; + break; + case 'swapPool': + isSelected = type === 'swapPool' && selected.poolAddress === pool.id; + break; + } + + return ( + + ); + })} +
+
+ ); +} + +interface PoolSelectorModalProps extends PoolListProps { + isLoading?: boolean; + onClose: () => void; + open: boolean; +} + +export function PoolSelectorModal({ + swapPools, + backstopPool, + selected, + excludedToken, + isLoading, + onSelect, + onClose, + open, +}: PoolSelectorModalProps) { + return ( + + + +

{backstopPool !== undefined ? 'Select a pool' : 'Select a token'}

+
+ +
+ {isLoading ? ( + repeat() + ) : ( + + )} +
+
+
+ ); +} diff --git a/src/config/index.ts b/src/config/index.ts index ecafd45a..74663e2f 100644 --- a/src/config/index.ts +++ b/src/config/index.ts @@ -53,11 +53,10 @@ export const config = { deadline: 30, }, }, - backstop: { + pools: { defaults: { slippage: 0.1, }, - securityFee: 0.01, // 1% // TODO Torsten: check whether still required }, transaction: { settings: { diff --git a/src/constants/cache.ts b/src/constants/cache.ts index 3cc2cd1e..162dd5b4 100644 --- a/src/constants/cache.ts +++ b/src/constants/cache.ts @@ -9,6 +9,8 @@ export const cacheKeys = { tokenOutAmount: 'tokenOutAmount', quoteSwapPoolRedeem: 'quoteSwapPoolRedeem', quoteSwapPoolWithdraw: 'quoteSwapPoolWithdraw', + quoteBackstopPoolWithdraw: 'quoteBackstopPoolWithdraw', + quoteBackstopPoolDrain: 'quoteBackstopPoolDrain', sharesTargetWorth: 'sharesTargetWorth', tokenPrice: 'tokenPrice', nablaInstance: 'nablaInstance', diff --git a/src/helpers/calc.ts b/src/helpers/calc.ts index 95a3ab6c..763e2ed5 100644 --- a/src/helpers/calc.ts +++ b/src/helpers/calc.ts @@ -46,49 +46,3 @@ export function getPoolSurplusNativeAmount(pool: NablaInstanceSwapPool) { const surplus = BigInt(pool.reserve) - BigInt(pool.totalLiabilities); return surplus > 0n ? surplus : 0n; } - -/** Calculate max withdraw value based on deposit and pool surplus */ -type CAPWProps = { - selectedSwapPool: NablaInstanceSwapPool; - backstopLpDecimalAmount: number; - sharesValueDecimalAmount: Big | undefined; - bpPrice: bigint | undefined; - spPrice: bigint | undefined; - swapPoolTokenDecimals: number; -}; - -// TODO (Torsten) I don't understand whether this calculation really makes sense -// also check decimals, this has a lot of occurrences of the word "native" -export const calcAvailablePoolWithdraw = ({ - selectedSwapPool, - backstopLpDecimalAmount, - sharesValueDecimalAmount, - bpPrice, - spPrice, - swapPoolTokenDecimals, -}: CAPWProps) => { - const surplusNativeAmount = getPoolSurplusNativeAmount(selectedSwapPool); - if (!bpPrice || !spPrice || !sharesValueDecimalAmount || !backstopLpDecimalAmount) { - return undefined; - } - const surplusDecimalAmount = Big(rawToDecimal(surplusNativeAmount.toString(), swapPoolTokenDecimals).toString()); - if (surplusDecimalAmount.lte(0)) return Big(0); - - const spPriceVal = new Big(spPrice.toString()); - const bpPriceVal = new Big(bpPrice.toString()); - - const spMax = surplusDecimalAmount.mul(spPriceVal); - const bpMax = sharesValueDecimalAmount.mul(bpPriceVal); - - const maxValue = bpMax.gt(spMax) ? spMax : bpMax; - const maxBackstopPoolTokensDecimalAmount = maxValue.div(bpPriceVal); - - const depositedBackstopLpTokenDecimalAmount = Big(backstopLpDecimalAmount); - const redeemableBackstopLpTokensDecimalAmount = maxBackstopPoolTokensDecimalAmount.gt( - depositedBackstopLpTokenDecimalAmount, - ) - ? depositedBackstopLpTokenDecimalAmount - : maxBackstopPoolTokensDecimalAmount; - - return redeemableBackstopLpTokensDecimalAmount; -}; diff --git a/src/helpers/transaction.ts b/src/helpers/transaction.ts index a6d943e3..fdc86c2c 100644 --- a/src/helpers/transaction.ts +++ b/src/helpers/transaction.ts @@ -2,7 +2,13 @@ import { config } from '../config'; const { slippage, deadline } = config.transaction.settings; -export const getValidSlippage = (val?: number): number | undefined => - val !== undefined ? Math.min(Math.max(val, slippage.min), slippage.max) : val; +export function getValidSlippage(val: number): number; +export function getValidSlippage(val: number | undefined): number | undefined; -export const getValidDeadline = (val: number): number => Math.min(Math.max(val, deadline.min), deadline.max); +export function getValidSlippage(val: number | undefined): number | undefined { + return val !== undefined ? Math.min(Math.max(val, slippage.min), slippage.max) : val; +} + +export function getValidDeadline(val: number): number { + return Math.min(Math.max(val, deadline.min), deadline.max); +} diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index fa930eda..d8737ffe 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -46,7 +46,7 @@ export function useContractRead( [abi, api?.registry], ); - const actualWalletAddress = noWalletAddressRequired ? ALICE : walletAddress; + const actualWalletAddress = noWalletAddressRequired === true ? ALICE : walletAddress; const enabled = !!contractAbi && queryOptions.enabled !== false && !!address && !!api && !!actualWalletAddress; console.log( diff --git a/src/hooks/nabla/useQuote.ts b/src/hooks/nabla/useQuote.ts new file mode 100644 index 00000000..2f0aa2ad --- /dev/null +++ b/src/hooks/nabla/useQuote.ts @@ -0,0 +1,110 @@ +import { Big } from 'big.js'; + +import { activeOptions } from '../../constants/cache'; +import { multiplyByPowerOfTen } from '../../shared/parseNumbers/metric'; +import { MessageCallErrorResult, useContractRead } from './useContractRead'; +import { useDebouncedValue } from '../useDebouncedValue'; +import { FieldValues, UseFormReturn } from 'react-hook-form'; +import { useEffect, useMemo } from 'preact/hooks'; +import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; +import { useCallback } from 'react'; + +interface UseQuoteProps { + lpTokenAmountString: string | undefined; + lpTokenDecimals: number; + maximumLpTokenAmount: Big | undefined; + poolTokenDecimals: number; + contractAddress: string; + contractAbi: Dict; + messageName: string; + primaryCacheKey: string; + constructArgs: (amountIn: string | undefined) => string[]; + parseError: string | ((errorResult: MessageCallErrorResult) => string); + form: UseFormReturn; + pickFromReturnArray?: number; +} + +export interface UseQuoteResult { + isLoading: boolean; + enabled: boolean; + data: ContractBalance | undefined; + error: string | null; +} + +// TODO Torsten: check whether the swap quote works the same + +export function useQuote({ + lpTokenAmountString, + lpTokenDecimals, + maximumLpTokenAmount, + poolTokenDecimals, + contractAddress, + contractAbi, + messageName, + primaryCacheKey, + constructArgs, + parseError, + form, + pickFromReturnArray, +}: UseQuoteProps): UseQuoteResult { + const { setError, clearErrors } = form; + + const debouncedAmountString = useDebouncedValue(lpTokenAmountString, 800); + + let debouncedAmountBigDecimal; + try { + debouncedAmountBigDecimal = debouncedAmountString !== undefined ? new Big(debouncedAmountString) : undefined; + } catch { + debouncedAmountBigDecimal = undefined; + } + + const enabled = + debouncedAmountBigDecimal !== undefined && + debouncedAmountBigDecimal?.gt(new Big(0)) && + (maximumLpTokenAmount === undefined || debouncedAmountBigDecimal.lte(maximumLpTokenAmount)); + + // TODO Torsten: check whether the other calls also round like this + const amountIn = + debouncedAmountBigDecimal !== undefined + ? multiplyByPowerOfTen(debouncedAmountBigDecimal, lpTokenDecimals).round(0, 0).toString() + : undefined; + + const { cacheKey, args } = useMemo(() => { + const args = constructArgs(amountIn); + return { cacheKey: [primaryCacheKey, contractAddress, ...args], args }; + }, [primaryCacheKey, contractAddress, constructArgs, amountIn]); + + const parseSuccessOutput = useCallback( + // eslint-disable-next-line @typescript-eslint/no-explicit-any + (result: any): ContractBalance | undefined => { + if (pickFromReturnArray !== undefined) result = result[pickFromReturnArray]; + return parseContractBalanceResponse(poolTokenDecimals, result); + }, + [poolTokenDecimals, pickFromReturnArray], + ); + + const { isLoading, fetchStatus, data, error } = useContractRead(cacheKey, { + abi: contractAbi, + address: contractAddress, + method: messageName, + args, + queryOptions: { + ...activeOptions['15s'], + enabled, + }, + parseSuccessOutput, + parseError, + }); + + const pending = (isLoading && fetchStatus !== 'idle') || debouncedAmountString !== lpTokenAmountString; + useEffect(() => { + if (pending) return; + if (error === null) { + clearErrors('root'); + } else { + setError('root', { type: 'custom', message: error }); + } + }, [error, pending, clearErrors, setError]); + + return { isLoading: pending, enabled, data, error }; +} diff --git a/src/hooks/nabla/useQuoteSwapPoolRedeem.ts b/src/hooks/nabla/useQuoteBackstopPoolWithdraw.ts similarity index 72% rename from src/hooks/nabla/useQuoteSwapPoolRedeem.ts rename to src/hooks/nabla/useQuoteBackstopPoolWithdraw.ts index 0473c2e8..bd2b7303 100644 --- a/src/hooks/nabla/useQuoteSwapPoolRedeem.ts +++ b/src/hooks/nabla/useQuoteBackstopPoolWithdraw.ts @@ -9,30 +9,28 @@ import { useEffect } from 'preact/hooks'; import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; import { backstopPoolAbi } from '../../contracts/nabla/BackstopPool'; -export type UseQuoteSwapPoolRedeemProps = { - swapPoolLpTokenAmountString: string | undefined; - swapPoolLpTokenDecimals: number; - maximumSwapPoolLpTokenAmount: Big | undefined; - backstopPoolTokenDecimals: number; +export type UseQuoteBackstopPoolWithdrawProps = { + lpTokenAmountString: string | undefined; + lpTokenDecimals: number; + maximumLpTokenAmount: Big | undefined; + poolTokenDecimals: number; backstopPoolAddress: string; - swapPoolAddress: string; form: UseFormReturn; }; // TODO Torsten: check whether the swap quote works the same -export function useQuoteSwapPoolRedeem({ - swapPoolLpTokenAmountString, - swapPoolLpTokenDecimals, - maximumSwapPoolLpTokenAmount, - backstopPoolTokenDecimals, +export function useQuoteBackstopPoolWithdraw({ + lpTokenAmountString, + lpTokenDecimals, + maximumLpTokenAmount, + poolTokenDecimals, backstopPoolAddress, - swapPoolAddress, form, -}: UseQuoteSwapPoolRedeemProps) { +}: UseQuoteBackstopPoolWithdrawProps) { const { setError, clearErrors } = form; - const debouncedAmountString = useDebouncedValue(swapPoolLpTokenAmountString, 800); + const debouncedAmountString = useDebouncedValue(lpTokenAmountString, 800); let debouncedAmountBigDecimal; try { @@ -40,29 +38,30 @@ export function useQuoteSwapPoolRedeem({ } catch { debouncedAmountBigDecimal = undefined; } + const enabled = debouncedAmountBigDecimal !== undefined && debouncedAmountBigDecimal.gt(new Big(0)) && - (maximumSwapPoolLpTokenAmount === undefined || debouncedAmountBigDecimal.lte(maximumSwapPoolLpTokenAmount)); + (maximumLpTokenAmount === undefined || debouncedAmountBigDecimal.lte(maximumLpTokenAmount)); // TODO Torsten: check whether the other calls also round like this const amountIn = debouncedAmountBigDecimal !== undefined - ? multiplyByPowerOfTen(debouncedAmountBigDecimal, swapPoolLpTokenDecimals).round(0, 0).toString() + ? multiplyByPowerOfTen(debouncedAmountBigDecimal, lpTokenDecimals).round(0, 0).toString() : undefined; const { isLoading, fetchStatus, data, error } = useContractRead( - [cacheKeys.quoteSwapPoolRedeem, backstopPoolAddress, swapPoolAddress, amountIn], + [cacheKeys.quoteBackstopPoolWithdraw, backstopPoolAddress, amountIn], { abi: backstopPoolAbi, address: backstopPoolAddress, - method: 'redeemSwapPoolShares', - args: [swapPoolAddress, amountIn, '0'], + method: 'withdraw', + args: [amountIn, '0'], queryOptions: { ...activeOptions['15s'], enabled, }, - parseSuccessOutput: parseContractBalanceResponse.bind(null, backstopPoolTokenDecimals), + parseSuccessOutput: parseContractBalanceResponse.bind(null, poolTokenDecimals), parseError: (error) => { switch (error.type) { case 'error': @@ -88,7 +87,7 @@ export function useQuoteSwapPoolRedeem({ }, ); - const pending = (isLoading && fetchStatus !== 'idle') || debouncedAmountString !== swapPoolLpTokenAmountString; + const pending = (isLoading && fetchStatus !== 'idle') || debouncedAmountString !== lpTokenAmountString; useEffect(() => { if (pending) return; if (error === null) { diff --git a/src/shared/parseNumbers/metric.ts b/src/shared/parseNumbers/metric.ts index 9e7425ef..8eeb51eb 100644 --- a/src/shared/parseNumbers/metric.ts +++ b/src/shared/parseNumbers/metric.ts @@ -152,8 +152,7 @@ export function multiplyByPowerOfTen(bigDecimal: BigNumber, power: number) { export function fractionOfValue(maxValue: BigNumber, percentage: number): string { const preciseResult = new BigNumber(percentage).div(BIG_100).mul(maxValue); - const roundedNumber = roundDownToSignificantDecimals(preciseResult, 2); - return roundedNumber.toFixed(); + return stringifyBigWithSignificantDecimals(preciseResult, 2); } /** Calculate deadline from minutes */ From ecc4a936756db18c4dce416441024177e2af71ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Mon, 13 May 2024 06:32:50 -0300 Subject: [PATCH 44/58] Fix swaps --- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 1 - src/components/nabla/Swap/ApprovalSubmit.tsx | 26 +++-- src/components/nabla/Swap/To.tsx | 23 ++-- src/components/nabla/Swap/useSwapComponent.ts | 1 + src/helpers/__tests__/calc.test.ts | 67 ------------ src/hooks/nabla/useContractRead.ts | 2 +- .../nabla/useQuoteBackstopPoolWithdraw.ts | 101 ------------------ src/hooks/nabla/useQuoteSwapPoolWithdraw.ts | 91 ---------------- src/hooks/nabla/useTokenOutAmount.ts | 1 + 9 files changed, 35 insertions(+), 278 deletions(-) delete mode 100644 src/helpers/__tests__/calc.test.ts delete mode 100644 src/hooks/nabla/useQuoteBackstopPoolWithdraw.ts delete mode 100644 src/hooks/nabla/useQuoteSwapPoolWithdraw.ts diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts index 98f0e9bb..2d3d1cda 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -10,7 +10,6 @@ import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; -import { useQuoteSwapPoolWithdraw } from '../../../../../hooks/nabla/useQuoteSwapPoolWithdraw'; import { useQueryClient } from '@tanstack/react-query'; import { cacheKeys } from '../../../../../constants/cache'; import { useQuote } from '../../../../../hooks/nabla/useQuote'; diff --git a/src/components/nabla/Swap/ApprovalSubmit.tsx b/src/components/nabla/Swap/ApprovalSubmit.tsx index 3b5bd589..ca1d9e55 100644 --- a/src/components/nabla/Swap/ApprovalSubmit.tsx +++ b/src/components/nabla/Swap/ApprovalSubmit.tsx @@ -14,25 +14,33 @@ export interface ApprovalProps { const ApprovalSubmit = ({ token, disabled }: ApprovalProps): JSX.Element | null => { const { router } = useGetAppDataByTenant('nabla').data || {}; const { control } = useFormContext(); - const decimalAmount = new Big( - useWatch({ - control, - name: 'fromAmount', - defaultValue: 0, - }), - ); + + const amountString = useWatch({ + control: control, + name: 'fromAmount', + defaultValue: '0', + }); + + let amountBigDecimal; + try { + amountBigDecimal = amountString !== undefined ? new Big(amountString) : undefined; + } catch { + amountBigDecimal = undefined; + } if (!router || !token) return null; + const amountPositive = amountBigDecimal?.gt(new Big(0)); + return ( - diff --git a/src/components/nabla/Swap/To.tsx b/src/components/nabla/Swap/To.tsx index 04d364de..51813fac 100644 --- a/src/components/nabla/Swap/To.tsx +++ b/src/components/nabla/Swap/To.tsx @@ -17,6 +17,7 @@ import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; import { NablaTokenPrice } from '../common/NablaTokenPrice'; import { Erc20Balance } from '../common/Erc20Balance'; import Big from 'big.js'; +import { getValidSlippage } from '../../../helpers/transaction'; export interface ToProps { tokensMap: Record; @@ -52,13 +53,16 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps } }, [fromDecimalAmountString]); - const slippage = Number( - useWatch({ - control, - name: 'slippage', - defaultValue: config.swap.defaults.slippage, - }), + const slippage = getValidSlippage( + Number( + useWatch({ + control, + name: 'slippage', + defaultValue: config.swap.defaults.slippage, + }), + ), ); + const fromToken: NablaInstanceToken | undefined = tokensMap?.[from]; const toToken: NablaInstanceToken | undefined = tokensMap?.[to]; @@ -170,7 +174,7 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps
Expected Output:
- {tokenOutAmount?.amountOut.approximateStrings.atLeast2Decimals} {toToken?.symbol || ''} + {tokenOutAmount?.amountOut.approximateStrings.atLeast4Decimals} {toToken?.symbol || ''}
@@ -179,7 +183,10 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps
{tokenOutAmount !== undefined - ? subtractBigDecimalPercentage(tokenOutAmount.amountOut.preciseBigDecimal, slippage) + ? stringifyBigWithSignificantDecimals( + subtractBigDecimalPercentage(tokenOutAmount.amountOut.preciseBigDecimal, slippage), + 2, + ) : ''}{' '} {toToken?.symbol || ''} diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index 142a3c15..4164533a 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -150,6 +150,7 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { // when props change (url updated) useEffect(() => { + console.log('useEffect'); if (hadMountedRef) { onFromChange(initFrom ?? '', false); onToChange(initTo ?? '', false); diff --git a/src/helpers/__tests__/calc.test.ts b/src/helpers/__tests__/calc.test.ts deleted file mode 100644 index 23898c16..00000000 --- a/src/helpers/__tests__/calc.test.ts +++ /dev/null @@ -1,67 +0,0 @@ -import Big from 'big.js'; -import { decimalToNative } from '../../shared/parseNumbers/metric'; -import * as helpers from '../calc'; -import { NablaInstanceSwapPool } from '../../hooks/nabla/useNablaInstance'; - -const DEFAULT_DECIMALS = 12; -const native1000 = decimalToNative(1000).toString(); - -describe('calc', () => { - it('should return correct withdraw amount from calcAvailablePoolWithdraw', () => { - expect( - helpers.calcAvailablePoolWithdraw({ - selectedSwapPool: { - totalLiabilities: undefined, - reserve: native1000, - } as unknown as NablaInstanceSwapPool, - sharesValueDecimalAmount: new Big(1000), - backstopLpDecimalAmount: 1000, - bpPrice: BigInt(decimalToNative(1).toString()), - spPrice: BigInt(decimalToNative(2).toString()), - swapPoolTokenDecimals: DEFAULT_DECIMALS, - }), - ).toBe(undefined); - - expect( - helpers.calcAvailablePoolWithdraw({ - selectedSwapPool: { - totalLiabilities: native1000, - reserve: native1000, - } as unknown as NablaInstanceSwapPool, - sharesValueDecimalAmount: new Big(1000), - backstopLpDecimalAmount: 1000, - bpPrice: BigInt(decimalToNative(1).toString()), - spPrice: BigInt(decimalToNative(2).toString()), - swapPoolTokenDecimals: DEFAULT_DECIMALS, - }), - ).toEqual(Big(0)); - - expect( - helpers.calcAvailablePoolWithdraw({ - selectedSwapPool: { - totalLiabilities: native1000, - reserve: decimalToNative(1200).toString(), - } as unknown as NablaInstanceSwapPool, - sharesValueDecimalAmount: new Big(1000), - backstopLpDecimalAmount: 1000, - bpPrice: BigInt(decimalToNative(1.1).toString()), - spPrice: BigInt(decimalToNative(2.2).toString()), - swapPoolTokenDecimals: DEFAULT_DECIMALS, - }), - ).toEqual(decimalToNative(400)); - - expect( - helpers.calcAvailablePoolWithdraw({ - selectedSwapPool: { - totalLiabilities: native1000, - reserve: decimalToNative(5200).toString(), - } as unknown as NablaInstanceSwapPool, - sharesValueDecimalAmount: new Big(1000), - backstopLpDecimalAmount: 1000, - bpPrice: BigInt(decimalToNative(1.1).toString()), - spPrice: BigInt(decimalToNative(2.2).toString()), - swapPoolTokenDecimals: DEFAULT_DECIMALS, - }), - ).toEqual(decimalToNative(1000)); - }); -}); diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index d8737ffe..563d4f89 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -48,7 +48,7 @@ export function useContractRead( const actualWalletAddress = noWalletAddressRequired === true ? ALICE : walletAddress; - const enabled = !!contractAbi && queryOptions.enabled !== false && !!address && !!api && !!actualWalletAddress; + const enabled = !!contractAbi && queryOptions.enabled === true && !!address && !!api && !!actualWalletAddress; console.log( 'Execute contract read', address, diff --git a/src/hooks/nabla/useQuoteBackstopPoolWithdraw.ts b/src/hooks/nabla/useQuoteBackstopPoolWithdraw.ts deleted file mode 100644 index bd2b7303..00000000 --- a/src/hooks/nabla/useQuoteBackstopPoolWithdraw.ts +++ /dev/null @@ -1,101 +0,0 @@ -import { Big } from 'big.js'; - -import { activeOptions, cacheKeys } from '../../constants/cache'; -import { multiplyByPowerOfTen } from '../../shared/parseNumbers/metric'; -import { useContractRead } from './useContractRead'; -import { useDebouncedValue } from '../useDebouncedValue'; -import { FieldValues, UseFormReturn } from 'react-hook-form'; -import { useEffect } from 'preact/hooks'; -import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; -import { backstopPoolAbi } from '../../contracts/nabla/BackstopPool'; - -export type UseQuoteBackstopPoolWithdrawProps = { - lpTokenAmountString: string | undefined; - lpTokenDecimals: number; - maximumLpTokenAmount: Big | undefined; - poolTokenDecimals: number; - backstopPoolAddress: string; - form: UseFormReturn; -}; - -// TODO Torsten: check whether the swap quote works the same - -export function useQuoteBackstopPoolWithdraw({ - lpTokenAmountString, - lpTokenDecimals, - maximumLpTokenAmount, - poolTokenDecimals, - backstopPoolAddress, - form, -}: UseQuoteBackstopPoolWithdrawProps) { - const { setError, clearErrors } = form; - - const debouncedAmountString = useDebouncedValue(lpTokenAmountString, 800); - - let debouncedAmountBigDecimal; - try { - debouncedAmountBigDecimal = debouncedAmountString !== undefined ? new Big(debouncedAmountString) : undefined; - } catch { - debouncedAmountBigDecimal = undefined; - } - - const enabled = - debouncedAmountBigDecimal !== undefined && - debouncedAmountBigDecimal.gt(new Big(0)) && - (maximumLpTokenAmount === undefined || debouncedAmountBigDecimal.lte(maximumLpTokenAmount)); - - // TODO Torsten: check whether the other calls also round like this - const amountIn = - debouncedAmountBigDecimal !== undefined - ? multiplyByPowerOfTen(debouncedAmountBigDecimal, lpTokenDecimals).round(0, 0).toString() - : undefined; - - const { isLoading, fetchStatus, data, error } = useContractRead( - [cacheKeys.quoteBackstopPoolWithdraw, backstopPoolAddress, amountIn], - { - abi: backstopPoolAbi, - address: backstopPoolAddress, - method: 'withdraw', - args: [amountIn, '0'], - queryOptions: { - ...activeOptions['15s'], - enabled, - }, - parseSuccessOutput: parseContractBalanceResponse.bind(null, poolTokenDecimals), - parseError: (error) => { - switch (error.type) { - case 'error': - return 'Cannot determine value of shares'; - case 'panic': - return error.errorCode === 0x11 - ? 'The input amount is too large. You cannot redeem all LP tokens right now.' - : 'Cannot determine value of shares'; - case 'reverted': - switch (error.description) { - case 'redeemSwapPoolShares():MIN_AMOUNT': - return 'The returned amount of tokens is below your desired minimum amount.'; - case 'SwapPool#backstopBurn: BALANCE_TOO_LOW': - return "You don't have enough LP tokens to redeem."; - case 'SwapPool#backstopBurn: TIMELOCK': - return 'You cannot redeem tokens from the backstop pool yet.'; - case 'SwapPool#backstopBurn():INSUFFICIENT_COVERAGE': - return 'The input amount is too large.'; - } - return 'Cannot determine value of shares'; - } - }, - }, - ); - - const pending = (isLoading && fetchStatus !== 'idle') || debouncedAmountString !== lpTokenAmountString; - useEffect(() => { - if (pending) return; - if (error === null) { - clearErrors('root'); - } else { - setError('root', { type: 'custom', message: error }); - } - }, [error, pending, clearErrors, setError]); - - return { isLoading: pending, enabled, data, error }; -} diff --git a/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts b/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts deleted file mode 100644 index ea24b41b..00000000 --- a/src/hooks/nabla/useQuoteSwapPoolWithdraw.ts +++ /dev/null @@ -1,91 +0,0 @@ -import { Big } from 'big.js'; - -import { activeOptions, cacheKeys } from '../../constants/cache'; -import { multiplyByPowerOfTen } from '../../shared/parseNumbers/metric'; -import { useContractRead } from './useContractRead'; -import { useDebouncedValue } from '../useDebouncedValue'; -import { swapPoolAbi } from '../../contracts/nabla/SwapPool'; -import { FieldValues, UseFormReturn } from 'react-hook-form'; -import { useEffect } from 'preact/hooks'; -import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; - -export type UseQuoteSwapPoolWithdrawProps = { - lpTokenAmountString: string | undefined; - lpTokenDecimals: number; - maximumLpTokenAmount: Big | undefined; - poolTokenDecimals: number; - swapPoolAddress: string; - form: UseFormReturn; -}; - -// TODO Torsten: check whether the swap quote works the same - -export function useQuoteSwapPoolWithdraw({ - lpTokenAmountString, - lpTokenDecimals, - poolTokenDecimals, - swapPoolAddress, - maximumLpTokenAmount, - form, -}: UseQuoteSwapPoolWithdrawProps) { - const { setError, clearErrors } = form; - - const debouncedAmountString = useDebouncedValue(lpTokenAmountString, 800); - - let debouncedAmountBigDecimal; - try { - debouncedAmountBigDecimal = debouncedAmountString !== undefined ? new Big(debouncedAmountString) : undefined; - } catch { - debouncedAmountBigDecimal = undefined; - } - const enabled = - debouncedAmountBigDecimal !== undefined && - debouncedAmountBigDecimal?.gt(new Big(0)) && - (maximumLpTokenAmount === undefined || debouncedAmountBigDecimal.lte(maximumLpTokenAmount)); - - // TODO Torsten: check whether the other calls also round like this - const amountIn = - debouncedAmountBigDecimal !== undefined - ? multiplyByPowerOfTen(debouncedAmountBigDecimal, lpTokenDecimals).round(0, 0).toString() - : undefined; - - const { isLoading, fetchStatus, data, error } = useContractRead( - [cacheKeys.quoteSwapPoolWithdraw, swapPoolAddress, amountIn], - { - abi: swapPoolAbi, - address: swapPoolAddress, - method: 'quoteWithdraw', - args: [amountIn], - noWalletAddressRequired: true, - queryOptions: { - ...activeOptions['15s'], - enabled, - }, - parseSuccessOutput: parseContractBalanceResponse.bind(null, poolTokenDecimals), - parseError: (error) => { - switch (error.type) { - case 'error': - return 'Cannot determine value of shares'; - case 'panic': - return error.errorCode === 0x11 - ? 'The input amount is too large. You cannot directly redeem all LP tokens right now. Try to redeem from the backstop pool instead.' - : 'Cannot determine value of shares'; - case 'reverted': - return 'Cannot determine value of shares'; - } - }, - }, - ); - - const pending = (isLoading && fetchStatus !== 'idle') || debouncedAmountString !== lpTokenAmountString; - useEffect(() => { - if (pending) return; - if (error === null) { - clearErrors('root'); - } else { - setError('root', { type: 'custom', message: error }); - } - }, [error, pending, clearErrors, setError]); - - return { isLoading: pending, enabled, data, error }; -} diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index da0a9802..cc4dcd23 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -29,6 +29,7 @@ export function useTokenOutAmount({ ? decimalToRaw(decimalAmount, fromTokenDecimals).round(0, 0).toString() : undefined; + console.log('useTokenOutAmount', enabled, fromTokenDecimals, decimalAmount, from, to); return useContractRead<{ amountOut: ContractBalance; swapFee: ContractBalance } | undefined>( [cacheKeys.tokenOutAmount, from, to, amountIn], { From 350ced32340151e5e3910fd1c5f8149581242f96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Mon, 13 May 2024 06:36:17 -0300 Subject: [PATCH 45/58] Git ignore vite timestamp files --- .gitignore | 4 +- vite.config.ts.timestamp-1714462483331.mjs | 71 ---------------------- 2 files changed, 3 insertions(+), 72 deletions(-) delete mode 100644 vite.config.ts.timestamp-1714462483331.mjs diff --git a/.gitignore b/.gitignore index a380285e..7584be77 100644 --- a/.gitignore +++ b/.gitignore @@ -32,4 +32,6 @@ dist-ssr !.yarn/plugins !.yarn/releases !.yarn/sdks -!.yarn/versions \ No newline at end of file +!.yarn/versions + +vite.config.ts.timestamp-* diff --git a/vite.config.ts.timestamp-1714462483331.mjs b/vite.config.ts.timestamp-1714462483331.mjs deleted file mode 100644 index 69dc7960..00000000 --- a/vite.config.ts.timestamp-1714462483331.mjs +++ /dev/null @@ -1,71 +0,0 @@ -// vite.config.ts -import preact from "file:///Users/torsten/Development/pendulum/portal/node_modules/@preact/preset-vite/dist/esm/index.mjs"; -import { defineConfig } from "file:///Users/torsten/Development/pendulum/portal/node_modules/vite/dist/node/index.js"; -import { NodeGlobalsPolyfillPlugin } from "file:///Users/torsten/Development/pendulum/portal/node_modules/@esbuild-plugins/node-globals-polyfill/dist/index.js"; -import { NodeModulesPolyfillPlugin } from "file:///Users/torsten/Development/pendulum/portal/node_modules/@esbuild-plugins/node-modules-polyfill/dist/index.js"; -import rollupNodePolyFill from "file:///Users/torsten/Development/pendulum/portal/node_modules/rollup-plugin-node-polyfills/dist/index.js"; -var vite_config_default = defineConfig({ - plugins: [preact()], - esbuild: { - logOverride: { "this-is-undefined-in-esm": "silent" } - }, - resolve: { - alias: { - assert: "rollup-plugin-node-polyfills/polyfills/assert", - buffer: "rollup-plugin-node-polyfills/polyfills/buffer-es6", - console: "rollup-plugin-node-polyfills/polyfills/console", - constants: "rollup-plugin-node-polyfills/polyfills/constants", - domain: "rollup-plugin-node-polyfills/polyfills/domain", - events: "rollup-plugin-node-polyfills/polyfills/events", - http: "rollup-plugin-node-polyfills/polyfills/http", - https: "rollup-plugin-node-polyfills/polyfills/http", - os: "rollup-plugin-node-polyfills/polyfills/os", - path: "rollup-plugin-node-polyfills/polyfills/path", - process: "rollup-plugin-node-polyfills/polyfills/process-es6", - punycode: "rollup-plugin-node-polyfills/polyfills/punycode", - querystring: "rollup-plugin-node-polyfills/polyfills/qs", - stream: "rollup-plugin-node-polyfills/polyfills/stream", - string_decoder: "rollup-plugin-node-polyfills/polyfills/string-decoder", - sys: "util", - timers: "rollup-plugin-node-polyfills/polyfills/timers", - tty: "rollup-plugin-node-polyfills/polyfills/tty", - url: "rollup-plugin-node-polyfills/polyfills/url", - util: "rollup-plugin-node-polyfills/polyfills/util", - vm: "rollup-plugin-node-polyfills/polyfills/vm", - zlib: "rollup-plugin-node-polyfills/polyfills/zlib", - _stream_duplex: "rollup-plugin-node-polyfills/polyfills/readable-stream/duplex", - _stream_passthrough: "rollup-plugin-node-polyfills/polyfills/readable-stream/passthrough", - _stream_readable: "rollup-plugin-node-polyfills/polyfills/readable-stream/readable", - _stream_writable: "rollup-plugin-node-polyfills/polyfills/readable-stream/writable", - _stream_transform: "rollup-plugin-node-polyfills/polyfills/readable-stream/transform" - } - }, - optimizeDeps: { - exclude: [], - esbuildOptions: { - target: "esnext", - define: { - global: "globalThis" - }, - plugins: [ - NodeGlobalsPolyfillPlugin({ - process: true, - buffer: true - }), - NodeModulesPolyfillPlugin() - ] - } - }, - build: { - target: ["esnext"], - rollupOptions: { - plugins: [ - rollupNodePolyFill() - ] - } - } -}); -export { - vite_config_default as default -}; -//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsidml0ZS5jb25maWcudHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbImNvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9kaXJuYW1lID0gXCIvVXNlcnMvdG9yc3Rlbi9EZXZlbG9wbWVudC9wZW5kdWx1bS9wb3J0YWxcIjtjb25zdCBfX3ZpdGVfaW5qZWN0ZWRfb3JpZ2luYWxfZmlsZW5hbWUgPSBcIi9Vc2Vycy90b3JzdGVuL0RldmVsb3BtZW50L3BlbmR1bHVtL3BvcnRhbC92aXRlLmNvbmZpZy50c1wiO2NvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9pbXBvcnRfbWV0YV91cmwgPSBcImZpbGU6Ly8vVXNlcnMvdG9yc3Rlbi9EZXZlbG9wbWVudC9wZW5kdWx1bS9wb3J0YWwvdml0ZS5jb25maWcudHNcIjtpbXBvcnQgcHJlYWN0IGZyb20gJ0BwcmVhY3QvcHJlc2V0LXZpdGUnO1xuaW1wb3J0IHsgZGVmaW5lQ29uZmlnIH0gZnJvbSAndml0ZSc7XG5cbmltcG9ydCB7IE5vZGVHbG9iYWxzUG9seWZpbGxQbHVnaW4gfSBmcm9tICdAZXNidWlsZC1wbHVnaW5zL25vZGUtZ2xvYmFscy1wb2x5ZmlsbCc7XG5pbXBvcnQgeyBOb2RlTW9kdWxlc1BvbHlmaWxsUGx1Z2luIH0gZnJvbSAnQGVzYnVpbGQtcGx1Z2lucy9ub2RlLW1vZHVsZXMtcG9seWZpbGwnO1xuaW1wb3J0IHJvbGx1cE5vZGVQb2x5RmlsbCBmcm9tICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzJztcblxuLy8gaHR0cHM6Ly92aXRlanMuZGV2L2NvbmZpZy9cbmV4cG9ydCBkZWZhdWx0IGRlZmluZUNvbmZpZyh7XG4gIHBsdWdpbnM6IFtwcmVhY3QoKV0sXG4gIGVzYnVpbGQ6IHtcbiAgICBsb2dPdmVycmlkZTogeyAndGhpcy1pcy11bmRlZmluZWQtaW4tZXNtJzogJ3NpbGVudCcgfSxcbiAgfSxcbiAgcmVzb2x2ZToge1xuICAgIGFsaWFzOiB7XG4gICAgICAvLyBUaGlzIFJvbGx1cCBhbGlhc2VzIGFyZSBleHRyYWN0ZWQgZnJvbSBAZXNidWlsZC1wbHVnaW5zL25vZGUtbW9kdWxlcy1wb2x5ZmlsbCxcbiAgICAgIC8vIHNlZSBodHRwczovL2dpdGh1Yi5jb20vcmVtb3JzZXMvZXNidWlsZC1wbHVnaW5zL2Jsb2IvbWFzdGVyL25vZGUtbW9kdWxlcy1wb2x5ZmlsbC9zcmMvcG9seWZpbGxzLnRzXG4gICAgICBhc3NlcnQ6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9hc3NlcnQnLFxuICAgICAgYnVmZmVyOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvYnVmZmVyLWVzNicsXG4gICAgICBjb25zb2xlOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvY29uc29sZScsXG4gICAgICBjb25zdGFudHM6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9jb25zdGFudHMnLFxuICAgICAgZG9tYWluOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvZG9tYWluJyxcbiAgICAgIGV2ZW50czogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL2V2ZW50cycsXG4gICAgICBodHRwOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvaHR0cCcsXG4gICAgICBodHRwczogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL2h0dHAnLFxuICAgICAgb3M6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9vcycsXG4gICAgICBwYXRoOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvcGF0aCcsXG4gICAgICBwcm9jZXNzOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvcHJvY2Vzcy1lczYnLFxuICAgICAgcHVueWNvZGU6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9wdW55Y29kZScsXG4gICAgICBxdWVyeXN0cmluZzogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3FzJyxcbiAgICAgIHN0cmVhbTogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3N0cmVhbScsXG4gICAgICBzdHJpbmdfZGVjb2RlcjogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3N0cmluZy1kZWNvZGVyJyxcbiAgICAgIHN5czogJ3V0aWwnLFxuICAgICAgdGltZXJzOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvdGltZXJzJyxcbiAgICAgIHR0eTogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3R0eScsXG4gICAgICB1cmw6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy91cmwnLFxuICAgICAgdXRpbDogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3V0aWwnLFxuICAgICAgdm06ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy92bScsXG4gICAgICB6bGliOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvemxpYicsXG4gICAgICBfc3RyZWFtX2R1cGxleDogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3JlYWRhYmxlLXN0cmVhbS9kdXBsZXgnLFxuICAgICAgX3N0cmVhbV9wYXNzdGhyb3VnaDogJ3JvbGx1cC1wbHVnaW4tbm9kZS1wb2x5ZmlsbHMvcG9seWZpbGxzL3JlYWRhYmxlLXN0cmVhbS9wYXNzdGhyb3VnaCcsXG4gICAgICBfc3RyZWFtX3JlYWRhYmxlOiAncm9sbHVwLXBsdWdpbi1ub2RlLXBvbHlmaWxscy9wb2x5ZmlsbHMvcmVhZGFibGUtc3RyZWFtL3JlYWRhYmxlJyxcbiAgICAgIF9zdHJlYW1fd3JpdGFibGU6ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9yZWFkYWJsZS1zdHJlYW0vd3JpdGFibGUnLFxuICAgICAgX3N0cmVhbV90cmFuc2Zvcm06ICdyb2xsdXAtcGx1Z2luLW5vZGUtcG9seWZpbGxzL3BvbHlmaWxscy9yZWFkYWJsZS1zdHJlYW0vdHJhbnNmb3JtJyxcbiAgICB9LFxuICB9LFxuICBvcHRpbWl6ZURlcHM6IHtcbiAgICBleGNsdWRlOiBbXSxcbiAgICBlc2J1aWxkT3B0aW9uczoge1xuICAgICAgdGFyZ2V0OiAnZXNuZXh0JyxcbiAgICAgIC8vIE5vZGUuanMgZ2xvYmFsIHRvIGJyb3dzZXIgZ2xvYmFsVGhpc1xuICAgICAgZGVmaW5lOiB7XG4gICAgICAgIGdsb2JhbDogJ2dsb2JhbFRoaXMnLFxuICAgICAgfSxcbiAgICAgIC8vIEVuYWJsZSBlc2J1aWxkIHBvbHlmaWxsIHBsdWdpbnNcbiAgICAgIHBsdWdpbnM6IFtcbiAgICAgICAgTm9kZUdsb2JhbHNQb2x5ZmlsbFBsdWdpbih7XG4gICAgICAgICAgcHJvY2VzczogdHJ1ZSxcbiAgICAgICAgICBidWZmZXI6IHRydWUsXG4gICAgICAgIH0pLFxuICAgICAgICBOb2RlTW9kdWxlc1BvbHlmaWxsUGx1Z2luKCksXG4gICAgICBdLFxuICAgIH0sXG4gIH0sXG4gIGJ1aWxkOiB7XG4gICAgdGFyZ2V0OiBbJ2VzbmV4dCddLFxuICAgIHJvbGx1cE9wdGlvbnM6IHtcbiAgICAgIHBsdWdpbnM6IFtcbiAgICAgICAgLy8gRW5hYmxlIHJvbGx1cCBwb2x5ZmlsbHMgcGx1Z2luXG4gICAgICAgIC8vIHVzZWQgZHVyaW5nIHByb2R1Y3Rpb24gYnVuZGxpbmdcbiAgICAgICAgcm9sbHVwTm9kZVBvbHlGaWxsKCksXG4gICAgICBdLFxuICAgIH0sXG4gIH0sXG59KTtcbiJdLAogICJtYXBwaW5ncyI6ICI7QUFBZ1QsT0FBTyxZQUFZO0FBQ25VLFNBQVMsb0JBQW9CO0FBRTdCLFNBQVMsaUNBQWlDO0FBQzFDLFNBQVMsaUNBQWlDO0FBQzFDLE9BQU8sd0JBQXdCO0FBRy9CLElBQU8sc0JBQVEsYUFBYTtBQUFBLEVBQzFCLFNBQVMsQ0FBQyxPQUFPLENBQUM7QUFBQSxFQUNsQixTQUFTO0FBQUEsSUFDUCxhQUFhLEVBQUUsNEJBQTRCLFNBQVM7QUFBQSxFQUN0RDtBQUFBLEVBQ0EsU0FBUztBQUFBLElBQ1AsT0FBTztBQUFBLE1BR0wsUUFBUTtBQUFBLE1BQ1IsUUFBUTtBQUFBLE1BQ1IsU0FBUztBQUFBLE1BQ1QsV0FBVztBQUFBLE1BQ1gsUUFBUTtBQUFBLE1BQ1IsUUFBUTtBQUFBLE1BQ1IsTUFBTTtBQUFBLE1BQ04sT0FBTztBQUFBLE1BQ1AsSUFBSTtBQUFBLE1BQ0osTUFBTTtBQUFBLE1BQ04sU0FBUztBQUFBLE1BQ1QsVUFBVTtBQUFBLE1BQ1YsYUFBYTtBQUFBLE1BQ2IsUUFBUTtBQUFBLE1BQ1IsZ0JBQWdCO0FBQUEsTUFDaEIsS0FBSztBQUFBLE1BQ0wsUUFBUTtBQUFBLE1BQ1IsS0FBSztBQUFBLE1BQ0wsS0FBSztBQUFBLE1BQ0wsTUFBTTtBQUFBLE1BQ04sSUFBSTtBQUFBLE1BQ0osTUFBTTtBQUFBLE1BQ04sZ0JBQWdCO0FBQUEsTUFDaEIscUJBQXFCO0FBQUEsTUFDckIsa0JBQWtCO0FBQUEsTUFDbEIsa0JBQWtCO0FBQUEsTUFDbEIsbUJBQW1CO0FBQUEsSUFDckI7QUFBQSxFQUNGO0FBQUEsRUFDQSxjQUFjO0FBQUEsSUFDWixTQUFTLENBQUM7QUFBQSxJQUNWLGdCQUFnQjtBQUFBLE1BQ2QsUUFBUTtBQUFBLE1BRVIsUUFBUTtBQUFBLFFBQ04sUUFBUTtBQUFBLE1BQ1Y7QUFBQSxNQUVBLFNBQVM7QUFBQSxRQUNQLDBCQUEwQjtBQUFBLFVBQ3hCLFNBQVM7QUFBQSxVQUNULFFBQVE7QUFBQSxRQUNWLENBQUM7QUFBQSxRQUNELDBCQUEwQjtBQUFBLE1BQzVCO0FBQUEsSUFDRjtBQUFBLEVBQ0Y7QUFBQSxFQUNBLE9BQU87QUFBQSxJQUNMLFFBQVEsQ0FBQyxRQUFRO0FBQUEsSUFDakIsZUFBZTtBQUFBLE1BQ2IsU0FBUztBQUFBLFFBR1AsbUJBQW1CO0FBQUEsTUFDckI7QUFBQSxJQUNGO0FBQUEsRUFDRjtBQUNGLENBQUM7IiwKICAibmFtZXMiOiBbXQp9Cg== From a276221e596a10a2b745a24fbf0eeb27c34390df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 14 May 2024 05:02:03 -0300 Subject: [PATCH 46/58] Remove unnecessary code and resolve TODOs --- src/NodeInfoProvider.tsx | 4 + .../Backstop/WithdrawLiquidity/index.tsx | 1 - .../WithdrawLiquidity/useBackstopDrain.ts | 13 -- src/components/nabla/Pools/Backstop/index.tsx | 1 - .../WithdrawLiquidity/useWithdrawLiquidity.ts | 3 +- src/components/nabla/Swap/ApprovalSubmit.tsx | 26 +-- src/components/nabla/Swap/From.tsx | 86 ++++----- src/components/nabla/Swap/To.tsx | 168 ++++++------------ src/components/nabla/Swap/index.tsx | 65 +++---- src/components/nabla/Swap/useSwapComponent.ts | 152 ++++++++++------ .../nabla/common/AmountSelector.tsx | 13 ++ .../nabla/common/PoolSelectorModal.tsx | 18 +- .../Progress.tsx => common/SwapProgress.tsx} | 5 +- src/components/nabla/common/TokenAmount.tsx | 47 ----- src/components/nabla/common/TokenApproval.tsx | 2 +- src/helpers/calc.ts | 26 --- src/hooks/nabla/useErc20TokenApproval.ts | 8 + src/hooks/nabla/useNablaInstance.ts | 2 +- src/hooks/nabla/useQuote.ts | 3 - src/hooks/nabla/useSharesTargetWorth.ts | 31 ---- src/hooks/nabla/useTokenOutAmount.ts | 121 ++++++++++--- src/pages/nabla/swap/index.tsx | 2 + src/shared/parseNumbers/metric.ts | 29 ++- 23 files changed, 393 insertions(+), 433 deletions(-) rename src/components/nabla/{Swap/Progress.tsx => common/SwapProgress.tsx} (85%) delete mode 100644 src/components/nabla/common/TokenAmount.tsx delete mode 100644 src/hooks/nabla/useSharesTargetWorth.ts diff --git a/src/NodeInfoProvider.tsx b/src/NodeInfoProvider.tsx index f5755984..2946ef00 100644 --- a/src/NodeInfoProvider.tsx +++ b/src/NodeInfoProvider.tsx @@ -85,6 +85,7 @@ const NodeInfoProvider = ({ children, tenantRPC }: { children: ReactNode; tenant } useEffect(() => { + console.log('Connection use effect', currentTenantRPC, tenantRPC, pendingInitiationPromise); let disconnect: () => void = () => undefined; // If the tenantRPC is the same as the currentTenantRPC, we don't need to do anything. @@ -96,11 +97,14 @@ const NodeInfoProvider = ({ children, tenantRPC }: { children: ReactNode; tenant const provider = new WsProvider(tenantRPC, false); await provider.connect(); + console.log('Start connecting'); const api = await createApiPromise(provider); + console.log('Have API, update now'); await updateStateWithChainProperties(api); await updateStateWithSystemInfo(api); disconnect = () => { + console.log('Disconnect'); api.disconnect(); }; }; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index 1cb16616..f21e17ec 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -159,7 +159,6 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element setValue('address', type === 'backstopPool' ? undefined : pool.id); setShowTokenModal(false); }} - excludedToken={undefined} selected={selectedPool ? { type: 'swapPool', poolAddress: selectedPool.id } : { type: 'backstopPool' }} onClose={() => setShowTokenModal(false)} /> diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts index b2bfeb22..17a8ba73 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts @@ -58,21 +58,8 @@ export const useBackstopDrain = ({ [poolTokenDecimals, withdrawalQuote.data, mutate, swapPoolAddress, lpTokenDecimals], ); - // TODO Torsten: check whether this calculation makes any sense - /*const sharesQuery = useSharesTargetWorth( - { - address: swapPoolAddress, - lpTokenDecimalAmount: depositedBackstopLpTokenDecimalAmount, - lpTokenDecimals: backstopPool.lpTokenDecimals, - poolTokenDecimals: backstopPool.token.decimals, - abi: backstopPoolAbi, - }, - enabled, - );*/ - return { onSubmit, mutation, - //isLoading: sharesQuery.isLoading, }; }; diff --git a/src/components/nabla/Pools/Backstop/index.tsx b/src/components/nabla/Pools/Backstop/index.tsx index aba105cb..44e90ba8 100644 --- a/src/components/nabla/Pools/Backstop/index.tsx +++ b/src/components/nabla/Pools/Backstop/index.tsx @@ -14,7 +14,6 @@ const BackstopPoolsBody = (): JSX.Element | null => { const pool = nabla?.backstopPool; if (!pool) return

No backstop pools

; - // TODO Torsten: also show the complete share and the percentage here return ( <>
diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts index 2d3d1cda..92b90c69 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -101,8 +101,7 @@ export const useSwapPoolWithdrawLiquidity = ( form, }); - // TODO Torsten: check how values are determined in the other mutation functions - // TODO Torsten: also make slippage here configurable + // TODO also make slippage here configurable const { mutate } = mutation; const onSubmit = useCallback( (variables: WithdrawLiquidityValues) => { diff --git a/src/components/nabla/Swap/ApprovalSubmit.tsx b/src/components/nabla/Swap/ApprovalSubmit.tsx index ca1d9e55..982371ba 100644 --- a/src/components/nabla/Swap/ApprovalSubmit.tsx +++ b/src/components/nabla/Swap/ApprovalSubmit.tsx @@ -1,43 +1,29 @@ import { Button } from 'react-daisyui'; -import { useFormContext, useWatch } from 'react-hook-form'; +import Big from 'big.js'; + import { useGetAppDataByTenant } from '../../../hooks/useGetAppDataByTenant'; -import { SwapFormValues } from './schema'; import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; import { TokenApproval } from '../common/TokenApproval'; -import Big from 'big.js'; export interface ApprovalProps { token: NablaInstanceToken | undefined; disabled: boolean; + fromAmount: Big | undefined; } -const ApprovalSubmit = ({ token, disabled }: ApprovalProps): JSX.Element | null => { +const ApprovalSubmit = ({ token, disabled, fromAmount }: ApprovalProps): JSX.Element | null => { const { router } = useGetAppDataByTenant('nabla').data || {}; - const { control } = useFormContext(); - - const amountString = useWatch({ - control: control, - name: 'fromAmount', - defaultValue: '0', - }); - - let amountBigDecimal; - try { - amountBigDecimal = amountString !== undefined ? new Big(amountString) : undefined; - } catch { - amountBigDecimal = undefined; - } if (!router || !token) return null; - const amountPositive = amountBigDecimal?.gt(new Big(0)); + const amountPositive = fromAmount?.gt(new Big(0)); return (
-
{token ? : '$ -'}
+
+ {fromToken ? : '$ -'} +
- {balance !== undefined && ( + {fromTokenBalance !== undefined && ( - - Your Balance:{' '} - {`${balance.approximateStrings.atLeast2Decimals}${token?.symbol ? ` ${token?.symbol}` : ''}`} + + Your Balance:
); -}; -export default From; +} diff --git a/src/components/nabla/Swap/To.tsx b/src/components/nabla/Swap/To.tsx index 51813fac..4c6c9b65 100644 --- a/src/components/nabla/Swap/To.tsx +++ b/src/components/nabla/Swap/To.tsx @@ -1,14 +1,12 @@ import { ArrowPathRoundedSquareIcon, ChevronDownIcon } from '@heroicons/react/20/solid'; -import { useEffect, useMemo } from 'preact/compat'; +import { useEffect } from 'preact/compat'; import { Button } from 'react-daisyui'; -import { useFormContext, useWatch } from 'react-hook-form'; +import { useFormContext } from 'react-hook-form'; +import Big from 'big.js'; + import pendulumIcon from '../../../assets/pendulum-icon.svg'; -import { config } from '../../../config'; -import { subtractBigDecimalPercentage } from '../../../helpers/calc'; -import { useTokenOutAmount } from '../../../hooks/nabla/useTokenOutAmount'; +import { UseTokenOutAmountResult } from '../../../hooks/nabla/useTokenOutAmount'; import useBoolean from '../../../hooks/useBoolean'; -import { useDebouncedValue } from '../../../hooks/useDebouncedValue'; -import { stringifyBigWithSignificantDecimals } from '../../../shared/parseNumbers/metric'; import { NumberLoader } from '../../Loader'; import { Skeleton } from '../../Skeleton'; import { SwapFormValues } from './schema'; @@ -16,102 +14,50 @@ import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; import { NablaTokenPrice } from '../common/NablaTokenPrice'; import { Erc20Balance } from '../common/Erc20Balance'; -import Big from 'big.js'; -import { getValidSlippage } from '../../../helpers/transaction'; export interface ToProps { - tokensMap: Record; onOpenSelector: () => void; - inputHasError: boolean; + fromToken: NablaInstanceToken | undefined; + toToken: NablaInstanceToken | undefined; + toAmountQuote: UseTokenOutAmountResult; + fromAmount: Big | undefined; + slippage: number; } -export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps): JSX.Element | null { +export function To({ + fromToken, + toToken, + onOpenSelector, + toAmountQuote, + fromAmount, + slippage, +}: ToProps): JSX.Element | null { const [isOpen, { toggle }] = useBoolean(true); - const { setValue, setError, clearErrors, control } = useFormContext(); - - const from = useWatch({ - control, - name: 'from', - }); - - const to = useWatch({ - control, - name: 'to', - }); - - const fromDecimalAmountString = useWatch({ - control, - name: 'fromAmount', - defaultValue: '0', - }); - - const fromDecimalAmount = useMemo(() => { - try { - return new Big(fromDecimalAmountString); - } catch { - return undefined; - } - }, [fromDecimalAmountString]); - - const slippage = getValidSlippage( - Number( - useWatch({ - control, - name: 'slippage', - defaultValue: config.swap.defaults.slippage, - }), - ), - ); - - const fromToken: NablaInstanceToken | undefined = tokensMap?.[from]; - const toToken: NablaInstanceToken | undefined = tokensMap?.[to]; - - const debouncedFromDecimalAmount = useDebouncedValue(fromDecimalAmount, 800); - - const { - isLoading, - fetchStatus, - data: tokenOutAmount, - error, - refetch, - } = useTokenOutAmount({ - fromDecimalAmount: debouncedFromDecimalAmount, - from, - to, - fromTokenDecimals: fromToken?.decimals, - toTokenDecimals: toToken?.decimals, - }); + const { setValue } = useFormContext(); useEffect(() => { - if (error !== null) { - setError('fromAmount', { type: 'manual', message: error }); - } else { - clearErrors('fromAmount'); - } - }, [error, setError, clearErrors]); - - const loading = (isLoading && fetchStatus !== 'idle') || fromDecimalAmount !== debouncedFromDecimalAmount; - - useEffect(() => { - setValue('toAmount', tokenOutAmount?.amountOut.preciseString ?? '0', { + setValue('toAmount', toAmountQuote.data?.amountOut.preciseString ?? '0', { shouldDirty: true, shouldTouch: true, shouldValidate: true, }); - }, [tokenOutAmount?.amountOut.preciseString, setValue]); + }, [toAmountQuote.data?.amountOut.preciseString, setValue]); return ( -
+
-
- {loading ? ( +
+ {toAmountQuote.isLoading ? ( - ) : tokenOutAmount ? ( - `${tokenOutAmount.amountOut.approximateStrings.atLeast4Decimals}` - ) : fromDecimalAmount !== undefined && fromDecimalAmount.gt(new Big(0)) ? ( - ) : ( @@ -151,13 +97,13 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps >
- {fromToken && toToken && tokenOutAmount && debouncedFromDecimalAmount && !loading ? ( - <>{`1 ${fromToken.symbol} = ${stringifyBigWithSignificantDecimals( - tokenOutAmount.amountOut.preciseBigDecimal.div(debouncedFromDecimalAmount), - 6, - )} ${toToken.symbol}`} + {fromToken !== undefined && + toToken !== undefined && + !toAmountQuote.isLoading && + toAmountQuote.data !== undefined ? ( + <>{`1 ${fromToken.symbol} = ${toAmountQuote.data.effectiveExchangeRate} ${toToken.symbol}`} ) : ( - `- ${toToken?.symbol || ''}` + `-` )}
@@ -172,30 +118,32 @@ export default function To({ tokensMap, onOpenSelector, inputHasError }: ToProps
Expected Output:
-
- - {tokenOutAmount?.amountOut.approximateStrings.atLeast4Decimals} {toToken?.symbol || ''} - -
+ {toAmountQuote.data !== undefined ? ( +
+ + {toAmountQuote.data?.amountOut.approximateStrings.atLeast4Decimals} {toToken?.symbol || ''} + +
+ ) : ( +
N/A
+ )}
Minimum received after slippage ({slippage}%)
-
- - {tokenOutAmount !== undefined - ? stringifyBigWithSignificantDecimals( - subtractBigDecimalPercentage(tokenOutAmount.amountOut.preciseBigDecimal, slippage), - 2, - ) - : ''}{' '} - {toToken?.symbol || ''} - -
+ {toAmountQuote.data !== undefined ? ( +
+ + {toAmountQuote.data !== undefined ? toAmountQuote.data.minAmountOut : ''} {toToken?.symbol || ''} + +
+ ) : ( +
N/A
+ )}
Swap fee:
- {tokenOutAmount !== undefined ? tokenOutAmount.swapFee.approximateStrings.atLeast2Decimals : ''}{' '} + {toAmountQuote.data !== undefined ? toAmountQuote.data.swapFee.approximateStrings.atLeast2Decimals : ''}{' '} {toToken?.symbol || ''}
diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index 183aa090..ad123317 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -1,15 +1,14 @@ import { Cog8ToothIcon } from '@heroicons/react/24/outline'; -import { useMemo } from 'preact/compat'; import { Button, Card } from 'react-daisyui'; import { FormProvider } from 'react-hook-form'; import ApprovalSubmit from './ApprovalSubmit'; -import From from './From'; -import SwapProgress from './Progress'; -import To from './To'; +import { From } from './From'; +import { To } from './To'; import { useSwapComponent, UseSwapComponentProps } from './useSwapComponent'; import { PoolSelectorModal } from '../common/PoolSelectorModal'; import Validation from '../../Form/Validation'; import { TransactionSettingsDropdown } from '../common/TransactionSettingsDropdown'; +import { SwapProgress } from '../common/SwapProgress'; const Swap = (props: UseSwapComponentProps): JSX.Element | null => { const { @@ -19,30 +18,28 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { swapMutation, onSubmit, form, - from, updateStorage, progressClose, - tokensMap, swapPools, - isLoading, + nablaInstanceIsLoading, + fromTokenBalance, + fromAmountString, + fromAmount, + toAmountQuote, + fromToken, + toToken, + slippage, } = useSwapComponent(props); const { setValue, register, - getValues, formState: { errors }, } = form; - const progressUi = useMemo(() => { - if (swapMutation?.isIdle) return null; - const { from: fromV, to: toV, fromAmount = '0', toAmount = '0' } = getValues(); - const fromAsset = tokensMap[fromV]; - const toAsset = tokensMap[toV]; - return ( -

{`Swapping ${fromAmount} ${fromAsset?.symbol} for ${toAmount} ${toAsset?.symbol}`}

- ); - }, [getValues, swapMutation?.isIdle, tokensMap]); + const submitEnabled = !toAmountQuote.isLoading && toAmountQuote.enabled && Object.keys(errors).length === 0; + const inputHasErrors = errors.fromAmount?.message !== undefined || errors.root?.message !== undefined; + console.log('submitEnabled', toAmountQuote, errors); return ( <> @@ -79,22 +76,27 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { />
setModalType('from')} - errorMessage={errors.fromAmount?.message} + inputHasError={inputHasErrors} + form={form} + fromFormFieldName="fromAmount" + fromTokenBalance={fromTokenBalance} /> setModalType('to')} - inputHasError={errors.to !== undefined} + fromAmount={fromAmount} + slippage={slippage} />
{/* */} - +
@@ -105,14 +107,17 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { onSelect={modalType === 'from' ? onFromChange : onToChange} selected={{ type: 'token', - tokenAddress: modalType ? (modalType === 'from' ? getValues('from') : getValues('to')) : undefined, + tokenAddress: modalType ? (modalType === 'from' ? fromToken?.id : toToken?.id) : undefined, }} - excludedToken={modalType === 'from' ? getValues('to') : getValues('from')} onClose={() => setModalType(undefined)} - isLoading={isLoading} + isLoading={nablaInstanceIsLoading} /> - - {progressUi} + +

{`Swapping ${fromAmountString} ${fromToken?.symbol} for ${toAmountQuote.data?.amountOut.approximateStrings.atLeast4Decimals} ${toToken?.symbol}`}

); diff --git a/src/components/nabla/Swap/useSwapComponent.ts b/src/components/nabla/Swap/useSwapComponent.ts index 4164533a..1abf8654 100644 --- a/src/components/nabla/Swap/useSwapComponent.ts +++ b/src/components/nabla/Swap/useSwapComponent.ts @@ -1,15 +1,12 @@ import { yupResolver } from '@hookform/resolvers/yup'; -import { useQueryClient } from '@tanstack/react-query'; -import { useCallback, useEffect, useRef, useState } from 'preact/compat'; +import { useCallback, useEffect, useMemo, useRef, useState } from 'preact/compat'; import { Resolver, useForm, useWatch } from 'react-hook-form'; import Big from 'big.js'; import { config } from '../../../config'; -import { cacheKeys } from '../../../constants/cache'; import { storageKeys } from '../../../constants/localStorage'; import { routerAbi } from '../../../contracts/nabla/Router'; import { useGlobalState } from '../../../GlobalStateProvider'; -import { subtractBigDecimalPercentage } from '../../../helpers/calc'; import { debounce } from '../../../helpers/function'; import { getValidDeadline, getValidSlippage } from '../../../helpers/transaction'; import { useGetAppDataByTenant } from '../../../hooks/useGetAppDataByTenant'; @@ -18,9 +15,12 @@ import { storageService } from '../../../services/storage/local'; import { calcDeadline, decimalToRaw } from '../../../shared/parseNumbers/metric'; import schema from './schema'; import { SwapFormValues } from './schema'; -import { NablaInstanceToken, useNablaInstance } from '../../../hooks/nabla/useNablaInstance'; +import { useNablaInstance } from '../../../hooks/nabla/useNablaInstance'; import { useContractWrite } from '../../../hooks/nabla/useContractWrite'; import { PoolEntry } from '../common/PoolSelectorModal'; +import { useErc20ContractBalance } from '../../../hooks/nabla/useErc20ContractBalance'; +import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; +import { useTokenOutAmount } from '../../../hooks/nabla/useTokenOutAmount'; export interface UseSwapComponentProps { from?: string; @@ -28,61 +28,84 @@ export interface UseSwapComponentProps { onChange?: (from: string, to: string) => void; } -export const defaultValues = config.swap.defaults; -const storageValues = storageService.getParsed(storageKeys.SWAP_SETTINGS); -const getInitialValues = () => ({ - ...defaultValues, - ...storageValues, - slippage: getValidSlippage(storageValues?.slippage), - deadline: getValidDeadline(storageValues?.deadline || defaultValues.deadline), -}); +const defaultValues = config.swap.defaults; const storageSet = debounce(storageService.set, 1000); export const useSwapComponent = (props: UseSwapComponentProps) => { const { onChange } = props; - const { nabla, isLoading } = useNablaInstance(); + const { nabla, isLoading: nablaInstanceIsLoading } = useNablaInstance(); const tokens = nabla?.swapPools.map((p) => p.token) ?? []; const tokensMap = nabla?.tokens ?? {}; const { address } = useGlobalState().walletAccount || {}; const hadMountedRef = useRef(false); - const queryClient = useQueryClient(); const { router } = useGetAppDataByTenant('nabla').data || {}; const tokensModal = useState(); const setTokenModal = tokensModal[1]; - const storageState = useRef(getInitialValues()); - - const initFrom = props.from || storageState.current.from; - const initTo = props.to || storageState.current.to; - const defaultFormValues = { - ...storageState.current, - from: initFrom || '', - to: initTo || '', - }; + + const initialState = useMemo(() => { + const storageValues = storageService.getParsed(storageKeys.SWAP_SETTINGS); + return { + from: props.from ?? storageValues?.from ?? '', + to: props.to ?? storageValues?.to ?? '', + slippage: getValidSlippage(storageValues?.slippage), + deadline: getValidDeadline(storageValues?.deadline ?? defaultValues.deadline), + }; + }, [props.from, props.to]); + const form = useForm({ resolver: yupResolver(schema) as Resolver, - defaultValues: defaultFormValues, + defaultValues: initialState, }); - const { setValue, reset, getValues, control } = form; - const from = useWatch({ + + const { setValue, getValues, control } = form; + const from = useWatch({ control, name: 'from' }); + const to = useWatch({ control, name: 'to' }); + + const fromToken = tokensMap[from]; + const toToken = tokensMap[to]; + + const fromTokenBalance = useErc20ContractBalance( + erc20WrapperAbi, + fromToken !== undefined ? { contractAddress: fromToken.id, decimals: fromToken.decimals } : undefined, + ); + const toTokenBalance = useErc20ContractBalance( + erc20WrapperAbi, + toToken !== undefined ? { contractAddress: toToken.id, decimals: toToken.decimals } : undefined, + ); + + const fromAmountString = useWatch({ control, - name: 'from', + name: 'fromAmount', + defaultValue: '0', }); - const updateStorage = useCallback( - (newValues: Partial) => { - const prev = getValues(); - const updated = { - slippage: prev.slippage || defaultValues.slippage, - deadline: prev.deadline || defaultValues.deadline, - ...newValues, - }; - storageSet(storageKeys.SWAP_SETTINGS, updated); - return updated; - }, - [getValues], + let fromAmount: Big | undefined; + try { + fromAmount = new Big(fromAmountString); + } catch { + fromAmount = undefined; + } + + const slippage = getValidSlippage( + Number( + useWatch({ + control, + name: 'slippage', + defaultValue: config.swap.defaults.slippage, + }), + ), ); + const toAmountQuote = useTokenOutAmount({ + fromAmountString, + fromToken, + toToken, + maximumFromAmount: fromTokenBalance.data?.preciseBigDecimal, + form, + slippage, + }); + const swapMutation = useContractWrite({ abi: routerAbi, address: router, @@ -90,30 +113,41 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { mutateOptions: { onSuccess: () => { // update token balances - queryClient.refetchQueries({ queryKey: [cacheKeys.walletBalance, getValues('from')], type: 'active' }); - queryClient.refetchQueries({ queryKey: [cacheKeys.walletBalance, getValues('to')], type: 'active' }); - // reset form - reset(); + fromTokenBalance.refetch(); + toTokenBalance.refetch(); + setValue('fromAmount', '0'); + setValue('toAmount', '0'); }, }, }); const onSubmit = form.handleSubmit((variables: SwapFormValues) => { + if (toAmountQuote.data === undefined) return; const fromToken = tokens.find((token) => token.id === variables.from)!; const toToken = tokens.find((token) => token.id === variables.to)!; const vDeadline = getValidDeadline(variables.deadline ?? defaultValues.deadline); - const vSlippage = getValidSlippage(variables.slippage ?? defaultValues.slippage); const deadline = calcDeadline(vDeadline).toString(); const fromAmount = decimalToRaw(variables.fromAmount, fromToken?.decimals).round(0, 0).toString(); - const toMinAmount = decimalToRaw( - subtractBigDecimalPercentage(new Big(variables.toAmount), vSlippage), - toToken?.decimals, - ).toString(); + const toMinAmount = decimalToRaw(toAmountQuote.data.minAmountOut, toToken.decimals).round(0, 0).toString(); return swapMutation.mutate([fromAmount, toMinAmount, [variables.from, variables.to], address, deadline]); }); + const updateStorage = useCallback( + (newValues: Partial) => { + const prev = getValues(); + const updated = { + slippage: prev.slippage || defaultValues.slippage, + deadline: prev.deadline || defaultValues.deadline, + ...newValues, + }; + storageSet(storageKeys.SWAP_SETTINGS, updated); + return updated; + }, + [getValues], + ); + const onFromChange = useCallback( (a: string | PoolEntry, event = true) => { const f = typeof a === 'string' ? a : a.pool.token.id; @@ -150,17 +184,15 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { // when props change (url updated) useEffect(() => { - console.log('useEffect'); - if (hadMountedRef) { - onFromChange(initFrom ?? '', false); - onToChange(initTo ?? '', false); + if (hadMountedRef.current) { + if (props.from !== undefined) onFromChange(props.from, false); + if (props.to !== undefined) onToChange(props.to, false); } hadMountedRef.current = true; - }, [initFrom, initTo, onFromChange, onToChange]); + }, [props.from, props.to, onFromChange, onToChange]); return { form, - tokensMap, swapPools: nabla?.swapPools ?? [], swapMutation, onSubmit, @@ -168,10 +200,16 @@ export const useSwapComponent = (props: UseSwapComponentProps) => { onFromChange, onToChange, updateStorage, - from, - isLoading, + nablaInstanceIsLoading, progressClose: () => { swapMutation.reset(); }, + fromTokenBalance, + fromAmountString, + fromAmount, + toAmountQuote, + fromToken, + toToken, + slippage, }; }; diff --git a/src/components/nabla/common/AmountSelector.tsx b/src/components/nabla/common/AmountSelector.tsx index 781795b9..638ab694 100644 --- a/src/components/nabla/common/AmountSelector.tsx +++ b/src/components/nabla/common/AmountSelector.tsx @@ -13,6 +13,7 @@ interface AmountSelectorProps; children?: ReactNode; + onlyShowNumberInput?: boolean; } export function AmountSelector>({ @@ -20,6 +21,7 @@ export function AmountSelector) { type K = PathValue; @@ -60,6 +62,17 @@ export function AmountSelector + ); + } + return (
diff --git a/src/components/nabla/common/PoolSelectorModal.tsx b/src/components/nabla/common/PoolSelectorModal.tsx index 682ff54d..c496bc11 100644 --- a/src/components/nabla/common/PoolSelectorModal.tsx +++ b/src/components/nabla/common/PoolSelectorModal.tsx @@ -15,20 +15,17 @@ interface PoolListProps { swapPools: NablaInstanceSwapPool[]; backstopPool?: NablaInstanceBackstopPool; onSelect: (pool: PoolEntry) => void; - excludedToken: string | undefined; selected: | { type: 'token'; tokenAddress: string | undefined } | { type: 'backstopPool' } | { type: 'swapPool'; poolAddress: string }; } -function PoolList({ swapPools, backstopPool, onSelect, selected, excludedToken }: PoolListProps) { +function PoolList({ swapPools, backstopPool, onSelect, selected }: PoolListProps) { const [filter, setFilter] = useState(); const poolList = useMemo(() => { - const poolList: PoolEntry[] = swapPools - .filter((pool) => pool.token.id !== excludedToken) - .map((pool) => ({ type: 'swapPool', pool })); + const poolList: PoolEntry[] = swapPools.map((pool) => ({ type: 'swapPool', pool })); poolList.sort((a, b) => (a.pool.token.symbol < b.pool.token.symbol ? -1 : 1)); if (backstopPool !== undefined) { @@ -42,7 +39,7 @@ function PoolList({ swapPools, backstopPool, onSelect, selected, excludedToken } } return poolList; - }, [swapPools, backstopPool, filter, excludedToken]); + }, [swapPools, backstopPool, filter]); const showPoolType = backstopPool !== undefined; @@ -118,7 +115,6 @@ export function PoolSelectorModal({ swapPools, backstopPool, selected, - excludedToken, isLoading, onSelect, onClose, @@ -135,13 +131,7 @@ export function PoolSelectorModal({ {isLoading ? ( repeat() ) : ( - + )}
diff --git a/src/components/nabla/Swap/Progress.tsx b/src/components/nabla/common/SwapProgress.tsx similarity index 85% rename from src/components/nabla/Swap/Progress.tsx rename to src/components/nabla/common/SwapProgress.tsx index fcf489a1..30a0a1e4 100644 --- a/src/components/nabla/Swap/Progress.tsx +++ b/src/components/nabla/common/SwapProgress.tsx @@ -10,7 +10,7 @@ export type SwapProgressProps = { mutation?: TransactionProgressProps['mutation']; }; -const SwapProgress = ({ mutation, children, ...rest }: SwapProgressProps): JSX.Element | null => { +export function SwapProgress({ mutation, children, ...rest }: SwapProgressProps) { return ( @@ -25,5 +25,4 @@ const SwapProgress = ({ mutation, children, ...rest }: SwapProgressProps): JSX.E ); -}; -export default SwapProgress; +} diff --git a/src/components/nabla/common/TokenAmount.tsx b/src/components/nabla/common/TokenAmount.tsx deleted file mode 100644 index 7da4a1a6..00000000 --- a/src/components/nabla/common/TokenAmount.tsx +++ /dev/null @@ -1,47 +0,0 @@ -import { useSharesTargetWorth } from '../../../hooks/nabla/useSharesTargetWorth'; -import { useDebouncedValue } from '../../../hooks/useDebouncedValue'; -import { NumberLoader } from '../../Loader'; - -export interface TokenAmountProps { - address: string; - abi: Dict; - lpTokenDecimalAmount: number; - symbol: ReactNode; - fallback: number; - poolTokenDecimals: number; - lpTokenDecimals: number; - debounce?: number; -} - -// TODO Torsten: remove this component -export function TokenAmount({ - address, - abi, - lpTokenDecimalAmount, - symbol, - fallback, - poolTokenDecimals, - lpTokenDecimals, - debounce = 800, -}: TokenAmountProps): JSX.Element | null { - const debouncedAmount = useDebouncedValue(lpTokenDecimalAmount, debounce); - const { isLoading, data } = useSharesTargetWorth({ - address, - abi, - lpTokenDecimalAmount: debounce ? debouncedAmount : lpTokenDecimalAmount, - lpTokenDecimals, - poolTokenDecimals, - }); - - if (lpTokenDecimalAmount && (isLoading || (!!debounce && lpTokenDecimalAmount !== debouncedAmount))) { - return ; - } - - // TODO Torsten: show explicit error if an error is returned - return ( - - {data ? data.approximateStrings.atLeast2Decimals : fallback ?? null} - {symbol ? symbol : null} - - ); -} diff --git a/src/components/nabla/common/TokenApproval.tsx b/src/components/nabla/common/TokenApproval.tsx index 66bdeb08..908241ea 100644 --- a/src/components/nabla/common/TokenApproval.tsx +++ b/src/components/nabla/common/TokenApproval.tsx @@ -38,7 +38,7 @@ export function TokenApproval({ if (state === ApprovalState.PENDING || decimalAmount === undefined) return; const nativeAmount = multiplyByPowerOfTen(decimalAmount, decimals); - mutate([spender, nativeAmount.toFixed()]); + mutate([spender, nativeAmount.round(0, 0).toFixed()]); }, [state, mutate, decimalAmount, decimals, spender]); if (state === ApprovalState.APPROVED || !enabled) return <>{children}; diff --git a/src/helpers/calc.ts b/src/helpers/calc.ts index 763e2ed5..27b9633c 100644 --- a/src/helpers/calc.ts +++ b/src/helpers/calc.ts @@ -1,30 +1,8 @@ import Big from 'big.js'; -import { rawToDecimal, roundNumber } from '../shared/parseNumbers/metric'; import { NablaInstanceSwapPool } from '../hooks/nabla/useNablaInstance'; export type Percent = number; -// TODO Torsten -// check src/helpers/calc.ts -// - what is needed -// - what is correct - -const PRECISION = 10000; -/** Calculate fiat value price impact */ -export function calcFiatValuePriceImpact( - fiatInput: number | undefined | null, - fiatOutput: number | undefined | null, -): number | undefined { - if (!fiatOutput || !fiatInput) return undefined; - const ratio = 1 - fiatOutput / fiatInput; - return Math.floor(ratio * PRECISION); -} - -// TODO Torsten: abolish -/** Calculate percentage */ -export const subtractPercentage = (value = 0, percent = 0, round = 2) => - roundNumber(value * (1 - percent / 100), round); - /** Calculate share percentage */ export function calcSharePercentage(total: Big, share: Big) { const percentage = share.div(total).mul(new Big(100)).toNumber(); @@ -37,10 +15,6 @@ export function subtractBigDecimalPercentage(total: Big, percent: number) { return total.mul(new Big(1 - percent / 100)); } -/** Calculate pool APR (daily fee * 365 / TVL) */ -export const calcAPR = (dailyFees: number, tvl: number, round = 2) => - roundNumber(((dailyFees * 365) / tvl) * 100, round); - /** Calculate pool surplus from reserves and liabilities */ export function getPoolSurplusNativeAmount(pool: NablaInstanceSwapPool) { const surplus = BigInt(pool.reserve) - BigInt(pool.totalLiabilities); diff --git a/src/hooks/nabla/useErc20TokenApproval.ts b/src/hooks/nabla/useErc20TokenApproval.ts index ff721f15..3a4709df 100644 --- a/src/hooks/nabla/useErc20TokenApproval.ts +++ b/src/hooks/nabla/useErc20TokenApproval.ts @@ -49,6 +49,8 @@ export function useErc20TokenApproval({ refetch, } = useErc20TokenAllowance({ token, owner: address, spender, decimals }, isEnabled); + console.log('Allowance', allowanceData?.preciseString); + const mutation = useContractWrite({ abi: erc20WrapperAbi, address: token, @@ -59,9 +61,15 @@ export function useErc20TokenApproval({ if (onError) onError(err); }, onSuccess: (...args) => { + console.log('Has success'); setPending(true); if (onSuccess) onSuccess(...args); + + console.log('Refetch now'); + refetch(); + setTimeout(() => { + console.log('Refetch after 2 seconds'); refetch(); setPending(false); }, 2000); // delay refetch as sometimes the allowance takes some time to reflect diff --git a/src/hooks/nabla/useNablaInstance.ts b/src/hooks/nabla/useNablaInstance.ts index 0c45839e..7211f94b 100644 --- a/src/hooks/nabla/useNablaInstance.ts +++ b/src/hooks/nabla/useNablaInstance.ts @@ -15,7 +15,7 @@ export interface NablaInstance { router: NablaInstanceRouter; backstopPool: NablaInstanceBackstopPool; swapPools: NablaInstanceSwapPool[]; - tokens: Record; + tokens: Partial>; } export function useNablaInstance(): { nabla: NablaInstance | undefined; isLoading: boolean } { diff --git a/src/hooks/nabla/useQuote.ts b/src/hooks/nabla/useQuote.ts index 2f0aa2ad..69c9cee9 100644 --- a/src/hooks/nabla/useQuote.ts +++ b/src/hooks/nabla/useQuote.ts @@ -31,8 +31,6 @@ export interface UseQuoteResult { error: string | null; } -// TODO Torsten: check whether the swap quote works the same - export function useQuote({ lpTokenAmountString, lpTokenDecimals, @@ -63,7 +61,6 @@ export function useQuote({ debouncedAmountBigDecimal?.gt(new Big(0)) && (maximumLpTokenAmount === undefined || debouncedAmountBigDecimal.lte(maximumLpTokenAmount)); - // TODO Torsten: check whether the other calls also round like this const amountIn = debouncedAmountBigDecimal !== undefined ? multiplyByPowerOfTen(debouncedAmountBigDecimal, lpTokenDecimals).round(0, 0).toString() diff --git a/src/hooks/nabla/useSharesTargetWorth.ts b/src/hooks/nabla/useSharesTargetWorth.ts deleted file mode 100644 index fd128a9f..00000000 --- a/src/hooks/nabla/useSharesTargetWorth.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { cacheKeys, inactiveOptions } from '../../constants/cache'; -import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; -import { decimalToRaw } from '../../shared/parseNumbers/metric'; -import { useContractRead } from './useContractRead'; - -export type UseSharesTargetWorthProps = { - address: string | undefined; - lpTokenDecimalAmount: number; - lpTokenDecimals: number; - poolTokenDecimals: number; - abi: Dict; -}; - -// TODO Torsten: where is this still used? Not for swap pool withdrawals anymore -export function useSharesTargetWorth( - { address, lpTokenDecimalAmount, abi, lpTokenDecimals, poolTokenDecimals }: UseSharesTargetWorthProps, - enabled?: boolean, -) { - return useContractRead([cacheKeys.sharesTargetWorth, lpTokenDecimalAmount], { - abi, - address, - method: 'sharesTargetWorth', - args: [decimalToRaw(lpTokenDecimalAmount, lpTokenDecimals).toString()], - queryOptions: { - ...inactiveOptions['1m'], - enabled: Boolean(address && lpTokenDecimalAmount && enabled !== false), - }, - parseSuccessOutput: parseContractBalanceResponse.bind(null, poolTokenDecimals), - parseError: 'Could not load the share value.', - }); -} diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index cc4dcd23..0f26e5b6 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -1,42 +1,85 @@ import Big from 'big.js'; +import { FieldValues, UseFormReturn } from 'react-hook-form'; + import { activeOptions, cacheKeys } from '../../constants/cache'; import { routerAbi } from '../../contracts/nabla/Router'; import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; -import { decimalToRaw } from '../../shared/parseNumbers/metric'; +import { multiplyByPowerOfTen, stringifyBigWithSignificantDecimals } from '../../shared/parseNumbers/metric'; import { useGetAppDataByTenant } from '../useGetAppDataByTenant'; import { useContractRead } from './useContractRead'; +import { NablaInstanceToken } from './useNablaInstance'; +import { useDebouncedValue } from '../useDebouncedValue'; +import { useEffect } from 'preact/hooks'; +import { UseQueryResult } from '@tanstack/react-query'; +import { subtractBigDecimalPercentage } from '../../helpers/calc'; -export type UseTokenOutAmountProps = { - fromDecimalAmount: Big | undefined; - from?: string; - to?: string; - fromTokenDecimals: number | undefined; - toTokenDecimals: number | undefined; +export type UseTokenOutAmountProps = { + fromAmountString: string | undefined; + fromToken: NablaInstanceToken | undefined; + toToken: NablaInstanceToken | undefined; + maximumFromAmount: Big | undefined; + form: UseFormReturn; + slippage: number; }; -export function useTokenOutAmount({ - fromDecimalAmount: decimalAmount, - from, - to, - fromTokenDecimals, - toTokenDecimals, -}: UseTokenOutAmountProps) { +export interface TokenOutData { + amountOut: ContractBalance; + swapFee: ContractBalance; + effectiveExchangeRate: string; + minAmountOut: string; +} + +export interface UseTokenOutAmountResult { + isLoading: boolean; + enabled: boolean; + data: TokenOutData | undefined; + error: string | null; + refetch?: UseQueryResult['refetch']; +} + +export function useTokenOutAmount({ + fromAmountString, + fromToken, + toToken, + maximumFromAmount, + form, + slippage, +}: UseTokenOutAmountProps): UseTokenOutAmountResult { const { router } = useGetAppDataByTenant('nabla').data || {}; + const { setError, clearErrors } = form; + + const debouncedAmountString = useDebouncedValue(fromAmountString, 800); + + let debouncedAmountBigDecimal: Big | undefined; + try { + debouncedAmountBigDecimal = debouncedAmountString !== undefined ? new Big(debouncedAmountString) : undefined; + } catch { + debouncedAmountBigDecimal = undefined; + } - const enabled = fromTokenDecimals !== undefined && decimalAmount && !!from && !!to; + const enabled = + router !== undefined && + fromToken !== undefined && + toToken !== undefined && + debouncedAmountBigDecimal !== undefined && + debouncedAmountBigDecimal?.gt(new Big(0)) && + (maximumFromAmount === undefined || debouncedAmountBigDecimal.lte(maximumFromAmount)); + + console.log('useTokenOutAmount', enabled); + + const fromTokenDecimals = fromToken?.decimals; const amountIn = - fromTokenDecimals !== undefined && decimalAmount !== undefined - ? decimalToRaw(decimalAmount, fromTokenDecimals).round(0, 0).toString() + fromTokenDecimals !== undefined && debouncedAmountBigDecimal !== undefined + ? multiplyByPowerOfTen(debouncedAmountBigDecimal, fromTokenDecimals).round(0, 0).toString() : undefined; - console.log('useTokenOutAmount', enabled, fromTokenDecimals, decimalAmount, from, to); - return useContractRead<{ amountOut: ContractBalance; swapFee: ContractBalance } | undefined>( - [cacheKeys.tokenOutAmount, from, to, amountIn], + const { isLoading, fetchStatus, data, error, refetch } = useContractRead( + [cacheKeys.tokenOutAmount, fromToken?.id, toToken?.id, amountIn], { abi: routerAbi, address: router, method: 'getAmountOut', - args: [amountIn, [from, to]], + args: [amountIn, [fromToken?.id, toToken?.id]], noWalletAddressRequired: true, queryOptions: { ...activeOptions['30s'], @@ -45,13 +88,23 @@ export function useTokenOutAmount({ console.error(err); }, }, - parseSuccessOutput: (data) => - toTokenDecimals === undefined - ? undefined - : { - amountOut: parseContractBalanceResponse(toTokenDecimals, data[0]), - swapFee: parseContractBalanceResponse(toTokenDecimals, data[1]), - }, + parseSuccessOutput: (data) => { + if (toToken === undefined || fromToken === undefined || debouncedAmountBigDecimal === undefined) + return undefined; + const amountOut = parseContractBalanceResponse(toToken.decimals, data[0]); + const effectiveExchangeRate = stringifyBigWithSignificantDecimals( + amountOut.preciseBigDecimal.div(debouncedAmountBigDecimal), + 6, + ); + const minAmountOut = subtractBigDecimalPercentage(amountOut.preciseBigDecimal, slippage); + + return { + amountOut, + effectiveExchangeRate, + swapFee: parseContractBalanceResponse(toToken.decimals, data[1]), + minAmountOut: stringifyBigWithSignificantDecimals(minAmountOut, 2), + }; + }, parseError: (error) => { switch (error.type) { case 'error': @@ -66,4 +119,16 @@ export function useTokenOutAmount({ }, }, ); + + const pending = (isLoading && fetchStatus !== 'idle') || debouncedAmountString !== fromAmountString; + useEffect(() => { + if (pending) return; + if (error === null) { + clearErrors('root'); + } else { + setError('root', { type: 'custom', message: error }); + } + }, [error, pending, clearErrors, setError]); + + return { isLoading: pending, enabled, data, error, refetch }; } diff --git a/src/pages/nabla/swap/index.tsx b/src/pages/nabla/swap/index.tsx index 483b2a26..ec6e3ef7 100644 --- a/src/pages/nabla/swap/index.tsx +++ b/src/pages/nabla/swap/index.tsx @@ -14,6 +14,8 @@ const SwapPage = (): JSX.Element | null => { [navigate], ); + console.log('Swap Master', params.get('from')); + return (
diff --git a/src/shared/parseNumbers/metric.ts b/src/shared/parseNumbers/metric.ts index 8eeb51eb..3627b397 100644 --- a/src/shared/parseNumbers/metric.ts +++ b/src/shared/parseNumbers/metric.ts @@ -12,6 +12,7 @@ export const StellarDecimals = 12; export const FixedU128Decimals = 18; const BIG_100 = new BigNumber('100'); +const BIG_0 = new BigNumber('0'); // Change the positive exponent to a high value to prevent toString() returning exponential notation BigNumber.PE = 100; @@ -110,7 +111,6 @@ export const nativeToFormatMetric = ( oneCharOnly = false, ) => format(rawToDecimal(value, StellarDecimals).toNumber(), tokenSymbol, oneCharOnly); -// TODO Torsten: abolish for Nabla export const prettyNumbers = (number: number, lang?: string, opts?: Intl.NumberFormatOptions) => number.toLocaleString('en-US', { minimumFractionDigits: 2, @@ -135,12 +135,35 @@ export function roundDownToSignificantDecimals(big: BigNumber, decimals: number) return big.prec(Math.max(0, big.e + 1) + decimals, 0); } +// toString method where the resulting string will have at least the number of +// decimals or more if the number is very small +// e.g., if decimals = 4, then +// - 12345678 -> 12345678.0000 +// - 1234.5678 -> 1234.5678 +// - 123.45678 -> 123.4567 +// - 1.2345678 -> 1.2345 +// - 0.12345678 -> 0.1234 +// - 0.012345678 -> 0.01234 +// - 0.00012345678 -> 0.0001234 +// - 12 -> 12.0000 +// - 0.12 -> 0.1200 +// - 0.012 -> 0.0120 +// - 0.0012 -> 0.0012 +// - 0.00012 -> 0.00012 +// - 0.000012 -> 0.000012 export function stringifyBigWithSignificantDecimals(big: BigNumber, decimals: number) { const rounded = roundDownToSignificantDecimals(big, decimals); - return rounded.toFixed(decimals + Math.max(0, -(big.e + 1))); + + let significantDecimals; + if (rounded.eq(BIG_0)) { + significantDecimals = decimals; + } else { + significantDecimals = Math.max(decimals, Math.min(decimals, rounded.c.length) - 1 - rounded.e); + } + + return rounded.toFixed(significantDecimals, 0); } -// TODO Torsten: check whether this can used everywhere to construct cleaner zeros export function multiplyByPowerOfTen(bigDecimal: BigNumber, power: number) { const newBigDecimal = new BigNumber(bigDecimal); if (newBigDecimal.c[0] === 0) return newBigDecimal; From 3c7f0d81832b78eaad5d6d2c84b44a1b10fde0cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Tue, 14 May 2024 05:05:26 -0300 Subject: [PATCH 47/58] Remove console.log statements --- src/NodeInfoProvider.tsx | 4 ---- src/components/nabla/Swap/index.tsx | 1 - src/hooks/nabla/useContractRead.ts | 14 -------------- src/hooks/nabla/useContractWrite.ts | 1 - src/hooks/nabla/useErc20ContractBalance.ts | 2 +- src/hooks/nabla/useErc20TokenApproval.ts | 5 ----- src/hooks/nabla/useTokenOutAmount.ts | 2 -- src/pages/nabla/swap/index.tsx | 2 -- 8 files changed, 1 insertion(+), 30 deletions(-) diff --git a/src/NodeInfoProvider.tsx b/src/NodeInfoProvider.tsx index 2946ef00..f5755984 100644 --- a/src/NodeInfoProvider.tsx +++ b/src/NodeInfoProvider.tsx @@ -85,7 +85,6 @@ const NodeInfoProvider = ({ children, tenantRPC }: { children: ReactNode; tenant } useEffect(() => { - console.log('Connection use effect', currentTenantRPC, tenantRPC, pendingInitiationPromise); let disconnect: () => void = () => undefined; // If the tenantRPC is the same as the currentTenantRPC, we don't need to do anything. @@ -97,14 +96,11 @@ const NodeInfoProvider = ({ children, tenantRPC }: { children: ReactNode; tenant const provider = new WsProvider(tenantRPC, false); await provider.connect(); - console.log('Start connecting'); const api = await createApiPromise(provider); - console.log('Have API, update now'); await updateStateWithChainProperties(api); await updateStateWithSystemInfo(api); disconnect = () => { - console.log('Disconnect'); api.disconnect(); }; }; diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index ad123317..4a211472 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -39,7 +39,6 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { const submitEnabled = !toAmountQuote.isLoading && toAmountQuote.enabled && Object.keys(errors).length === 0; const inputHasErrors = errors.fromAmount?.message !== undefined || errors.root?.message !== undefined; - console.log('submitEnabled', toAmountQuote, errors); return ( <> diff --git a/src/hooks/nabla/useContractRead.ts b/src/hooks/nabla/useContractRead.ts index 563d4f89..63ae99c4 100644 --- a/src/hooks/nabla/useContractRead.ts +++ b/src/hooks/nabla/useContractRead.ts @@ -49,23 +49,9 @@ export function useContractRead( const actualWalletAddress = noWalletAddressRequired === true ? ALICE : walletAddress; const enabled = !!contractAbi && queryOptions.enabled === true && !!address && !!api && !!actualWalletAddress; - console.log( - 'Execute contract read', - address, - method, - enabled, - !!contractAbi, - queryOptions.enabled !== false, - !!address, - !!api, - !!actualWalletAddress, - ); const query = useQuery( enabled ? key : emptyCacheKey, async () => { - if (isDevelopment) { - console.log('read', 'Call message enabled', enabled); - } if (!enabled) return; const limits = defaultReadLimits; diff --git a/src/hooks/nabla/useContractWrite.ts b/src/hooks/nabla/useContractWrite.ts index ecfc7e47..ac497c99 100644 --- a/src/hooks/nabla/useContractWrite.ts +++ b/src/hooks/nabla/useContractWrite.ts @@ -47,7 +47,6 @@ export function useContractWrite>({ if (isDevelopment) { console.log('write', 'call message write', address, method, args, submitArgs); - console.log('write', 'limits', { ...defaultWriteLimits, ...contractOptions }); } const response = await executeMessage({ diff --git a/src/hooks/nabla/useErc20ContractBalance.ts b/src/hooks/nabla/useErc20ContractBalance.ts index c8aaaa9d..005992ca 100644 --- a/src/hooks/nabla/useErc20ContractBalance.ts +++ b/src/hooks/nabla/useErc20ContractBalance.ts @@ -21,7 +21,7 @@ export const useErc20ContractBalance = ( queryOptions: { cacheTime: 10000, staleTime: 10000, - //refetchInterval: 10000, + refetchInterval: 10000, onError: console.error, enabled, }, diff --git a/src/hooks/nabla/useErc20TokenApproval.ts b/src/hooks/nabla/useErc20TokenApproval.ts index 3a4709df..c5ffa869 100644 --- a/src/hooks/nabla/useErc20TokenApproval.ts +++ b/src/hooks/nabla/useErc20TokenApproval.ts @@ -49,8 +49,6 @@ export function useErc20TokenApproval({ refetch, } = useErc20TokenAllowance({ token, owner: address, spender, decimals }, isEnabled); - console.log('Allowance', allowanceData?.preciseString); - const mutation = useContractWrite({ abi: erc20WrapperAbi, address: token, @@ -61,15 +59,12 @@ export function useErc20TokenApproval({ if (onError) onError(err); }, onSuccess: (...args) => { - console.log('Has success'); setPending(true); if (onSuccess) onSuccess(...args); - console.log('Refetch now'); refetch(); setTimeout(() => { - console.log('Refetch after 2 seconds'); refetch(); setPending(false); }, 2000); // delay refetch as sometimes the allowance takes some time to reflect diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index 0f26e5b6..a5d6f1d1 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -65,8 +65,6 @@ export function useTokenOutAmount({ debouncedAmountBigDecimal?.gt(new Big(0)) && (maximumFromAmount === undefined || debouncedAmountBigDecimal.lte(maximumFromAmount)); - console.log('useTokenOutAmount', enabled); - const fromTokenDecimals = fromToken?.decimals; const amountIn = fromTokenDecimals !== undefined && debouncedAmountBigDecimal !== undefined diff --git a/src/pages/nabla/swap/index.tsx b/src/pages/nabla/swap/index.tsx index ec6e3ef7..483b2a26 100644 --- a/src/pages/nabla/swap/index.tsx +++ b/src/pages/nabla/swap/index.tsx @@ -14,8 +14,6 @@ const SwapPage = (): JSX.Element | null => { [navigate], ); - console.log('Swap Master', params.get('from')); - return (
From 0dc153326da9ffa1904ef11d9269705b99dcd98e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Wed, 15 May 2024 14:13:18 -0300 Subject: [PATCH 48/58] Add debug output to execute message calls --- src/hooks/nabla/useContractWrite.ts | 38 +++++++++++++++++------------ 1 file changed, 22 insertions(+), 16 deletions(-) diff --git a/src/hooks/nabla/useContractWrite.ts b/src/hooks/nabla/useContractWrite.ts index ac497c99..eb29374f 100644 --- a/src/hooks/nabla/useContractWrite.ts +++ b/src/hooks/nabla/useContractWrite.ts @@ -49,22 +49,28 @@ export function useContractWrite>({ console.log('write', 'call message write', address, method, args, submitArgs); } - const response = await executeMessage({ - abi: contractAbi, - api, - callerAddress: walletAddress, - contractDeploymentAddress: address, - getSigner: () => - Promise.resolve({ - type: 'signer', - address: walletAddress, - signer, - }), - messageName: method, - messageArguments: fnArgs, - limits: { ...defaultWriteLimits, ...contractOptions }, - gasLimitTolerancePercentage: 10, // Allow 3 fold gas tolerance - }); + let response; + try { + response = await executeMessage({ + abi: contractAbi, + api, + callerAddress: walletAddress, + contractDeploymentAddress: address, + getSigner: () => + Promise.resolve({ + type: 'signer', + address: walletAddress, + signer, + }), + messageName: method, + messageArguments: fnArgs, + limits: { ...defaultWriteLimits, ...contractOptions }, + gasLimitTolerancePercentage: 10, // Allow 3 fold gas tolerance + }); + } catch (error) { + console.error('An error occurred', error); + throw error; + } if (isDevelopment) { console.log('write', 'call message write response', address, method, fnArgs, response); From 4778d07d9fde6b09450525d87941a56570ffcb82 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Wed, 15 May 2024 15:10:33 -0300 Subject: [PATCH 49/58] Upgrade api-solang version --- package.json | 2 +- src/hooks/nabla/useContractWrite.ts | 38 ++++++++++++----------------- yarn.lock | 10 ++++---- 3 files changed, 22 insertions(+), 28 deletions(-) diff --git a/package.json b/package.json index ebf8d71e..3fc0730d 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "@heroicons/react": "^2.1.1", "@hookform/resolvers": "^2.9.11", "@pendulum-chain/api": "^0.3.8", - "@pendulum-chain/api-solang": "0.3.0", + "@pendulum-chain/api-solang": "^0.4.0", "@polkadot/api": "^10.9.1", "@polkadot/api-base": "^10.9.1", "@polkadot/api-contract": "^10.9.1", diff --git a/src/hooks/nabla/useContractWrite.ts b/src/hooks/nabla/useContractWrite.ts index eb29374f..ac497c99 100644 --- a/src/hooks/nabla/useContractWrite.ts +++ b/src/hooks/nabla/useContractWrite.ts @@ -49,28 +49,22 @@ export function useContractWrite>({ console.log('write', 'call message write', address, method, args, submitArgs); } - let response; - try { - response = await executeMessage({ - abi: contractAbi, - api, - callerAddress: walletAddress, - contractDeploymentAddress: address, - getSigner: () => - Promise.resolve({ - type: 'signer', - address: walletAddress, - signer, - }), - messageName: method, - messageArguments: fnArgs, - limits: { ...defaultWriteLimits, ...contractOptions }, - gasLimitTolerancePercentage: 10, // Allow 3 fold gas tolerance - }); - } catch (error) { - console.error('An error occurred', error); - throw error; - } + const response = await executeMessage({ + abi: contractAbi, + api, + callerAddress: walletAddress, + contractDeploymentAddress: address, + getSigner: () => + Promise.resolve({ + type: 'signer', + address: walletAddress, + signer, + }), + messageName: method, + messageArguments: fnArgs, + limits: { ...defaultWriteLimits, ...contractOptions }, + gasLimitTolerancePercentage: 10, // Allow 3 fold gas tolerance + }); if (isDevelopment) { console.log('write', 'call message write response', address, method, fnArgs, response); diff --git a/yarn.lock b/yarn.lock index dac66f10..5210111f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3394,9 +3394,9 @@ __metadata: languageName: node linkType: hard -"@pendulum-chain/api-solang@npm:0.3.0": - version: 0.3.0 - resolution: "@pendulum-chain/api-solang@npm:0.3.0" +"@pendulum-chain/api-solang@npm:^0.4.0": + version: 0.4.0 + resolution: "@pendulum-chain/api-solang@npm:0.4.0" peerDependencies: "@polkadot/api": ^10.0 "@polkadot/api-contract": ^10.12.1 @@ -3405,7 +3405,7 @@ __metadata: "@polkadot/types-codec": ^10.0 "@polkadot/util": "*" "@polkadot/util-crypto": "*" - checksum: 4b5912664a270f830a3627a98480853e38df2cfab39d0fc240d2a77c0bcaa509dbd81918089cf7ee5ce70c149829de340585ae802789315b195146b3fb518741 + checksum: 37f0b225b1529dd46b38e050a4fac89acb706bc62b10855db83f4e8658423aeb921f8ad16fadcd21e9aef68aa5ac66274dbdd829247005a3e207a94411ab1cd0 languageName: node linkType: hard @@ -13510,7 +13510,7 @@ __metadata: "@heroicons/react": "npm:^2.1.1" "@hookform/resolvers": "npm:^2.9.11" "@pendulum-chain/api": "npm:^0.3.8" - "@pendulum-chain/api-solang": "npm:0.3.0" + "@pendulum-chain/api-solang": "npm:^0.4.0" "@pendulum-chain/types": "npm:^0.3.8" "@polkadot/api": "npm:^10.9.1" "@polkadot/api-base": "npm:^10.9.1" From c164e5b083e751e4c748edecc8560746e80a5be0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Thu, 16 May 2024 10:34:54 -0300 Subject: [PATCH 50/58] Implement PR comments --- src/SharedProvider.tsx | 2 - .../Layout/NavCollapseButtonContent.tsx | 37 +++++++++---------- .../Pools/Backstop/AddLiquidity/index.tsx | 2 +- .../Backstop/AddLiquidity/useAddLiquidity.ts | 5 +-- .../Pools/Backstop/BackstopPoolModals.tsx | 13 ++----- .../Backstop/WithdrawLiquidity/index.tsx | 2 +- .../WithdrawLiquidity/useBackstopDrain.ts | 3 +- .../WithdrawLiquidity/useBackstopWithdraw.ts | 2 +- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 2 +- src/components/nabla/Pools/Backstop/index.tsx | 6 +-- .../nabla/Pools/Swap/AddLiquidity/index.tsx | 2 +- .../Swap/AddLiquidity/useAddLiquidity.ts | 5 +-- .../nabla/Pools/Swap/Redeem/index.tsx | 5 +-- .../nabla/Pools/Swap/Redeem/useRedeem.ts | 5 +-- .../nabla/Pools/Swap/SwapPoolModals.tsx | 16 +++----- .../Pools/Swap/WithdrawLiquidity/index.tsx | 5 +-- .../WithdrawLiquidity/useWithdrawLiquidity.ts | 5 +-- src/components/nabla/Pools/Swap/columns.tsx | 6 +-- src/components/nabla/Swap/From.tsx | 5 +-- .../nabla/common/NablaTokenPrice.tsx | 2 +- src/components/nabla/common/NumberInput.tsx | 2 +- src/components/nabla/common/TokenApproval.tsx | 2 +- .../common/TransactionSettingsDropdown.tsx | 3 +- src/helpers/query.ts | 7 ++++ src/hooks/nabla/useQuote.ts | 5 +-- .../dialogs/ConfirmDelegateDialog.tsx | 3 +- src/services/modal/index.tsx | 15 +++++--- 27 files changed, 78 insertions(+), 89 deletions(-) create mode 100644 src/helpers/query.ts diff --git a/src/SharedProvider.tsx b/src/SharedProvider.tsx index a7201af3..4e4a7aa4 100644 --- a/src/SharedProvider.tsx +++ b/src/SharedProvider.tsx @@ -7,8 +7,6 @@ const SharedProvider = ({ children }: { children: ComponentChildren }) => { const { api } = useNodeInfoState().state; const { signer, address } = useGlobalState().walletAccount || {}; - console.log('Provider', api, signer, address); - return ( {children} diff --git a/src/components/Layout/NavCollapseButtonContent.tsx b/src/components/Layout/NavCollapseButtonContent.tsx index 5d7368a8..1dcaf3a9 100644 --- a/src/components/Layout/NavCollapseButtonContent.tsx +++ b/src/components/Layout/NavCollapseButtonContent.tsx @@ -1,4 +1,3 @@ -import React from 'react'; import Lottie from 'react-lottie'; import { LinkItem, isLottieOptions } from './links'; @@ -8,22 +7,20 @@ interface NavButtonContentProps { isPlaying: boolean; } -export const NavCollapseButtonContent: React.FC = ({ item, isPlaying }) => { - return ( - <> - {isLottieOptions(item.prefix) ? ( - - ) : ( - item.prefix - )} - {isLottieOptions(item.title) ? ( - - - - ) : ( - {item.title} - )} - {item.suffix} - - ); -}; +export const NavCollapseButtonContent: React.FC = ({ item, isPlaying }) => ( + <> + {isLottieOptions(item.prefix) ? ( + + ) : ( + item.prefix + )} + {isLottieOptions(item.title) ? ( + + + + ) : ( + {item.title} + )} + {item.suffix} + +); diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index 6e8555fc..2948351d 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -38,7 +38,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
-

Deposit {data.token.symbol}

diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts index 67a4070a..18d35eef 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/useAddLiquidity.ts @@ -12,6 +12,7 @@ import { decimalToRaw } from '../../../../../shared/parseNumbers/metric'; import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; +import { refetchDelayed } from '../../../../../helpers/query'; interface AddLiquidityValues { amount: string; @@ -59,9 +60,7 @@ export const useAddLiquidity = ( form.reset(); balanceQuery.refetch(); depositQuery.refetch(); - setTimeout(() => { - queryClient.refetchQueries([cacheKeys.nablaInstance]); - }, 2000); + refetchDelayed(queryClient, [cacheKeys.nablaInstance]); }, }, }); diff --git a/src/components/nabla/Pools/Backstop/BackstopPoolModals.tsx b/src/components/nabla/Pools/Backstop/BackstopPoolModals.tsx index ad7db7fb..8ce1f93a 100644 --- a/src/components/nabla/Pools/Backstop/BackstopPoolModals.tsx +++ b/src/components/nabla/Pools/Backstop/BackstopPoolModals.tsx @@ -2,24 +2,19 @@ import { FunctionalComponent } from 'preact'; import { Modal } from 'react-daisyui'; import { NablaInstanceBackstopPool } from '../../../../hooks/nabla/useNablaInstance'; -import { useModal } from '../../../../services/modal'; +import { ModalTypes, useModal } from '../../../../services/modal'; import ModalCloseButton from '../../../Button/ModalClose'; import AddLiquidity from './AddLiquidity'; import WithdrawLiquidity from './WithdrawLiquidity'; -export const ModalTypes = { - AddLiquidity: 2, - WithdrawLiquidity: 3, -}; - export type LiquidityModalProps = { data?: NablaInstanceBackstopPool; }; // eslint-disable-next-line @typescript-eslint/no-explicit-any -const modalsUi: Record> = { - 2: AddLiquidity, - 3: WithdrawLiquidity, +const modalsUi: Partial>> = { + AddLiquidity: AddLiquidity, + WithdrawLiquidity: WithdrawLiquidity, }; export function BackstopPoolModals() { diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index f21e17ec..92034e20 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -62,7 +62,7 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element

- Withdraw from diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts index 17a8ba73..2f2bd65d 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopDrain.ts @@ -1,4 +1,5 @@ -import { useCallback } from 'react'; +import { useCallback } from 'preact/hooks'; + import { config } from '../../../../../config'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; import { subtractBigDecimalPercentage } from '../../../../../helpers/calc'; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts index 81893562..a265b346 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useBackstopWithdraw.ts @@ -1,4 +1,4 @@ -import { useCallback } from 'react'; +import { useCallback } from 'preact/hooks'; import { config } from '../../../../../config'; import { backstopPoolAbi } from '../../../../../contracts/nabla/BackstopPool'; diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts index db6e4e92..5a1b4728 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -89,7 +89,7 @@ export const useWithdrawLiquidity = (nabla: NablaInstance) => { }); const selectedPool = useMemo( - () => swapPools.find((t) => t.id === address)!, + () => swapPools.find((t) => t.id === address), [address, swapPools], ); diff --git a/src/components/nabla/Pools/Backstop/index.tsx b/src/components/nabla/Pools/Backstop/index.tsx index 44e90ba8..802de7b6 100644 --- a/src/components/nabla/Pools/Backstop/index.tsx +++ b/src/components/nabla/Pools/Backstop/index.tsx @@ -4,7 +4,7 @@ import { Skeleton } from '../../../Skeleton'; import { useNablaInstance } from '../../../../hooks/nabla/useNablaInstance'; import { backstopPoolAbi } from '../../../../contracts/nabla/BackstopPool'; import { Erc20Balance } from '../../common/Erc20Balance'; -import { BackstopPoolModals, LiquidityModalProps, ModalTypes } from './BackstopPoolModals'; +import { BackstopPoolModals, LiquidityModalProps } from './BackstopPoolModals'; const BackstopPoolsBody = (): JSX.Element | null => { const toggle = useModalToggle(); @@ -38,7 +38,7 @@ const BackstopPoolsBody = (): JSX.Element | null => { color="primary" onClick={() => toggle({ - type: ModalTypes.AddLiquidity, + type: 'AddLiquidity', props: { data: pool }, }) } @@ -50,7 +50,7 @@ const BackstopPoolsBody = (): JSX.Element | null => { color="secondary" onClick={() => toggle({ - type: ModalTypes.WithdrawLiquidity, + type: 'WithdrawLiquidity', }) } > diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx index 0d69e87f..d2aaee5a 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/AddLiquidity/index.tsx @@ -38,7 +38,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
-

Confirm deposit

diff --git a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts index eae3e737..92fcc7cf 100644 --- a/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts +++ b/src/components/nabla/Pools/Swap/AddLiquidity/useAddLiquidity.ts @@ -12,6 +12,7 @@ import { erc20WrapperAbi } from '../../../../../contracts/nabla/ERC20Wrapper'; import { useErc20ContractBalance } from '../../../../../hooks/nabla/useErc20ContractBalance'; import { useContractWrite } from '../../../../../hooks/nabla/useContractWrite'; import { cacheKeys } from '../../../../../constants/cache'; +import { refetchDelayed } from '../../../../../helpers/query'; export type AddLiquidityValues = { amount: string; @@ -59,9 +60,7 @@ export const useAddLiquidity = ( form.reset(); balanceQuery.refetch(); depositQuery.refetch(); - setTimeout(() => { - queryClient.refetchQueries([cacheKeys.nablaInstance]); - }, 2000); + refetchDelayed(queryClient, [cacheKeys.nablaInstance]); }, }, }); diff --git a/src/components/nabla/Pools/Swap/Redeem/index.tsx b/src/components/nabla/Pools/Swap/Redeem/index.tsx index 2d6f2ac9..d1728756 100644 --- a/src/components/nabla/Pools/Swap/Redeem/index.tsx +++ b/src/components/nabla/Pools/Swap/Redeem/index.tsx @@ -13,7 +13,6 @@ import { FormProvider } from 'react-hook-form'; import { TransactionSettingsDropdown } from '../../../common/TransactionSettingsDropdown'; import { TokenBalance } from '../../../common/TokenBalance'; import { AmountSelector } from '../../../common/AmountSelector'; -import { ModalTypes } from '../SwapPoolModals'; export type RedeemLiquidityValues = { amount: number; @@ -45,7 +44,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => {
-

Redeem from Backstop Pool

@@ -125,7 +124,7 @@ const Redeem = ({ data }: RedeemProps): JSX.Element | null => { type="button" onClick={() => toggle({ - type: ModalTypes.WithdrawLiquidity, + type: 'WithdrawLiquidity', props: { data }, }) } diff --git a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts index b94b1c47..150f6d1e 100644 --- a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts +++ b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts @@ -23,6 +23,7 @@ import { useQueryClient } from '@tanstack/react-query'; import { cacheKeys } from '../../../../../constants/cache'; import { useQuote } from '../../../../../hooks/nabla/useQuote'; import { MessageCallErrorResult } from '../../../../../hooks/nabla/useContractRead'; +import { refetchDelayed } from '../../../../../helpers/query'; interface RedeemLiquidityValues { amount: string; @@ -103,9 +104,7 @@ export const useRedeem = (swapPoolData: SwapPoolColumn) => { form.reset(); backstopBalanceQuery.refetch(); swapPoolDepositQuery.refetch(); - setTimeout(() => { - queryClient.refetchQueries([cacheKeys.nablaInstance]); - }, 2000); + refetchDelayed(queryClient, [cacheKeys.nablaInstance]); }, }, }); diff --git a/src/components/nabla/Pools/Swap/SwapPoolModals.tsx b/src/components/nabla/Pools/Swap/SwapPoolModals.tsx index 3faa4e3c..c0dccd6f 100644 --- a/src/components/nabla/Pools/Swap/SwapPoolModals.tsx +++ b/src/components/nabla/Pools/Swap/SwapPoolModals.tsx @@ -1,6 +1,6 @@ import { FunctionalComponent } from 'preact'; import { Modal } from 'react-daisyui'; -import { useModal } from '../../../../services/modal'; +import { ModalTypes, useModal } from '../../../../services/modal'; import ModalCloseButton from '../../../Button/ModalClose'; import AddLiquidity from './AddLiquidity'; import Redeem from './Redeem'; @@ -8,21 +8,15 @@ import WithdrawLiquidity from './WithdrawLiquidity'; import { SwapPoolColumn } from './columns'; -export const ModalTypes = { - AddLiquidity: 2, - WithdrawLiquidity: 3, - Redeem: 4, -}; - export type LiquidityModalProps = { data?: SwapPoolColumn; }; // eslint-disable-next-line @typescript-eslint/no-explicit-any -const modalsUi: Record> = { - 2: AddLiquidity, - 3: WithdrawLiquidity, - 4: Redeem, +const modalsUi: Partial>> = { + AddLiquidity: AddLiquidity, + WithdrawLiquidity: WithdrawLiquidity, + Redeem: Redeem, }; export function SwapPoolModals() { diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx index 251c71d4..e7c4fb70 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/index.tsx @@ -12,7 +12,6 @@ import { TransactionProgress } from '../../../common/TransactionProgress'; import { FormProvider } from 'react-hook-form'; import { AmountSelector } from '../../../common/AmountSelector'; import { TokenBalance } from '../../../common/TokenBalance'; -import { ModalTypes } from '../SwapPoolModals'; export interface WithdrawLiquidityProps { data: SwapPoolColumn; @@ -39,7 +38,7 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null
-

Withdraw {data.token?.symbol}

@@ -87,7 +86,7 @@ const WithdrawLiquidity = ({ data }: WithdrawLiquidityProps): JSX.Element | null type="button" onClick={() => toggle({ - type: ModalTypes.Redeem, + type: 'Redeem', props: { data }, }) } diff --git a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts index 92b90c69..6a81f557 100644 --- a/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Swap/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -14,6 +14,7 @@ import { useQueryClient } from '@tanstack/react-query'; import { cacheKeys } from '../../../../../constants/cache'; import { useQuote } from '../../../../../hooks/nabla/useQuote'; import { MessageCallErrorResult } from '../../../../../hooks/nabla/useContractRead'; +import { refetchDelayed } from '../../../../../helpers/query'; interface WithdrawLiquidityValues { amount: string; @@ -74,9 +75,7 @@ export const useSwapPoolWithdrawLiquidity = ( form.reset(); balanceQuery.refetch(); depositQuery.refetch(); - setTimeout(() => { - queryClient.refetchQueries([cacheKeys.nablaInstance]); - }, 2000); + refetchDelayed(queryClient, [cacheKeys.nablaInstance]); }, }, }); diff --git a/src/components/nabla/Pools/Swap/columns.tsx b/src/components/nabla/Pools/Swap/columns.tsx index 0ead3e58..df63adcc 100644 --- a/src/components/nabla/Pools/Swap/columns.tsx +++ b/src/components/nabla/Pools/Swap/columns.tsx @@ -5,7 +5,7 @@ import { rawToDecimal } from '../../../../shared/parseNumbers/metric'; import { NablaInstanceBackstopPool, NablaInstanceSwapPool } from '../../../../hooks/nabla/useNablaInstance'; import { swapPoolAbi } from '../../../../contracts/nabla/SwapPool'; import { Erc20Balance } from '../../common/Erc20Balance'; -import { LiquidityModalProps, ModalTypes } from './SwapPoolModals'; +import { LiquidityModalProps } from './SwapPoolModals'; import Big from 'big.js'; export type SwapPoolColumn = NablaInstanceSwapPool & { @@ -80,7 +80,7 @@ const ActionsColumn = ({ row: { original } }: CellContext - + )}
diff --git a/src/components/nabla/common/NablaTokenPrice.tsx b/src/components/nabla/common/NablaTokenPrice.tsx index 6971e320..45944ae8 100644 --- a/src/components/nabla/common/NablaTokenPrice.tsx +++ b/src/components/nabla/common/NablaTokenPrice.tsx @@ -11,7 +11,7 @@ export function NablaTokenPrice({ address, prefix = null, fallback = null }: Tok const { data, isLoading } = useNablaTokenPrice(address); if (isLoading) return ; - if (data === undefined) return <>{fallback}; + if (data === undefined) return fallback; return ( diff --git a/src/components/nabla/common/NumberInput.tsx b/src/components/nabla/common/NumberInput.tsx index 9ad14da3..82728097 100644 --- a/src/components/nabla/common/NumberInput.tsx +++ b/src/components/nabla/common/NumberInput.tsx @@ -1,4 +1,4 @@ -import { HTMLAttributes, useCallback } from 'react'; +import { HTMLAttributes, useCallback } from 'preact/compat'; import { FieldPath, FieldValues, useFormContext } from 'react-hook-form'; export interface NumberInputProps extends HTMLAttributes { diff --git a/src/components/nabla/common/TokenApproval.tsx b/src/components/nabla/common/TokenApproval.tsx index 908241ea..27e72104 100644 --- a/src/components/nabla/common/TokenApproval.tsx +++ b/src/components/nabla/common/TokenApproval.tsx @@ -41,7 +41,7 @@ export function TokenApproval({ mutate([spender, nativeAmount.round(0, 0).toFixed()]); }, [state, mutate, decimalAmount, decimals, spender]); - if (state === ApprovalState.APPROVED || !enabled) return <>{children}; + if (state === ApprovalState.APPROVED || !enabled) return children; const noAccount = state === ApprovalState.NO_ACCOUNT; const isPending = state === ApprovalState.PENDING; diff --git a/src/components/nabla/common/TransactionSettingsDropdown.tsx b/src/components/nabla/common/TransactionSettingsDropdown.tsx index b730316b..3346dcb8 100644 --- a/src/components/nabla/common/TransactionSettingsDropdown.tsx +++ b/src/components/nabla/common/TransactionSettingsDropdown.tsx @@ -1,6 +1,5 @@ import { Cog8ToothIcon } from '@heroicons/react/24/outline'; -import { Button, Dropdown, Input } from 'react-daisyui'; -import { InputProps } from 'react-daisyui/dist/Input/Input'; +import { Button, Dropdown, Input, InputProps } from 'react-daisyui'; import { config } from '../../../config'; export interface TransactionSettingsProps { diff --git a/src/helpers/query.ts b/src/helpers/query.ts new file mode 100644 index 00000000..052e82b2 --- /dev/null +++ b/src/helpers/query.ts @@ -0,0 +1,7 @@ +import { QueryClient, QueryKey } from '@tanstack/react-query'; + +export function refetchDelayed(queryClient: QueryClient, queryKey: QueryKey, delayMilliseconds = 2000) { + setTimeout(() => { + queryClient.refetchQueries(queryKey); + }, delayMilliseconds); +} diff --git a/src/hooks/nabla/useQuote.ts b/src/hooks/nabla/useQuote.ts index 69c9cee9..78b792b1 100644 --- a/src/hooks/nabla/useQuote.ts +++ b/src/hooks/nabla/useQuote.ts @@ -1,13 +1,12 @@ import { Big } from 'big.js'; +import { useCallback, useEffect, useMemo } from 'preact/hooks'; +import { FieldValues, UseFormReturn } from 'react-hook-form'; import { activeOptions } from '../../constants/cache'; import { multiplyByPowerOfTen } from '../../shared/parseNumbers/metric'; import { MessageCallErrorResult, useContractRead } from './useContractRead'; import { useDebouncedValue } from '../useDebouncedValue'; -import { FieldValues, UseFormReturn } from 'react-hook-form'; -import { useEffect, useMemo } from 'preact/hooks'; import { ContractBalance, parseContractBalanceResponse } from '../../helpers/contracts'; -import { useCallback } from 'react'; interface UseQuoteProps { lpTokenAmountString: string | undefined; diff --git a/src/pages/collators/dialogs/ConfirmDelegateDialog.tsx b/src/pages/collators/dialogs/ConfirmDelegateDialog.tsx index c188d30f..d90b541f 100644 --- a/src/pages/collators/dialogs/ConfirmDelegateDialog.tsx +++ b/src/pages/collators/dialogs/ConfirmDelegateDialog.tsx @@ -1,6 +1,7 @@ import Big from 'big.js'; -import { useCallback, useMemo, useState } from 'react'; +import { useCallback, useMemo, useState } from 'preact/hooks'; import { Button } from 'react-daisyui'; + import { nativeToDecimal, nativeToFormatMetric } from '../../../shared/parseNumbers/metric'; import { DelegationMode } from './ExecuteDelegationDialogs'; import { Dialog } from './Dialog'; diff --git a/src/services/modal/index.tsx b/src/services/modal/index.tsx index 2df00abb..8dc56226 100644 --- a/src/services/modal/index.tsx +++ b/src/services/modal/index.tsx @@ -2,11 +2,13 @@ import { ComponentChildren } from 'preact'; import { createContext, useCallback, useContext, useState } from 'preact/compat'; +export type ModalTypes = 'AddLiquidity' | 'WithdrawLiquidity' | 'Redeem'; + export type ModalState = Dict> = { - type?: number; + type?: ModalTypes; props?: T; }; -export type ToggleModal = Dict> = (type?: number | ModalState) => void; +export type ToggleModal = Dict> = (type?: ModalTypes | ModalState) => void; const ModalStateContext = createContext(undefined); const ModalToggleContext = createContext(undefined); @@ -25,9 +27,12 @@ export interface ModalProviderProps { const ModalProvider = ({ children }: ModalProviderProps): JSX.Element | null => { const [state, setModalState] = useState({}); - const toggleModal: ToggleModal = useCallback((type = {}) => { - if (typeof type === 'number') setModalState({ type }); - else setModalState(type); + const toggleModal: ToggleModal = useCallback((type) => { + if (type === undefined) { + setModalState({}); + } else if (typeof type === 'string') { + setModalState({ type }); + } else setModalState(type); }, []); return ( From a763e0ab8db6a94c007d139a039a85f3bce9b6fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Thu, 16 May 2024 15:32:19 -0300 Subject: [PATCH 51/58] Improve error messages --- .../Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts | 2 +- src/components/nabla/Pools/Swap/Redeem/useRedeem.ts | 2 +- src/hooks/nabla/useTokenOutAmount.ts | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts index 5a1b4728..5ad2ec08 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/useWithdrawLiquidity.ts @@ -62,7 +62,7 @@ function parseError(error: MessageCallErrorResult): string { case 'withdrawExcessSwapLiquidity():BALANCE': return "You don't have enough LP tokens to redeem."; case 'SwapPool#backstopDrain():INSUFFICIENT_COVERAGE': - return 'The input amount is too large.'; + return 'The input amount is too large. The resulting coverage ratio of the pool must not drop below 100%.'; } return 'Cannot determine value of shares'; } diff --git a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts index 150f6d1e..82866c2e 100644 --- a/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts +++ b/src/components/nabla/Pools/Swap/Redeem/useRedeem.ts @@ -63,7 +63,7 @@ function parseQuoteError(error: MessageCallErrorResult): string { case 'SwapPool#backstopBurn: TIMELOCK': return 'You cannot redeem tokens from the backstop pool yet.'; case 'SwapPool#backstopBurn():INSUFFICIENT_COVERAGE': - return 'The input amount is too large.'; + return 'The input amount is too large. The resulting coverage ratio of the pool must not exceed 100%.'; } return 'Cannot determine value of shares'; } diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index a5d6f1d1..c121661e 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -108,10 +108,10 @@ export function useTokenOutAmount({ case 'error': return 'Something went wrong'; case 'panic': - return error.errorCode === 0x11 ? 'The input amount is too large' : 'Something went wrong'; + return error.errorCode === 0x11 ? 'The input amount is too large.' : 'Something went wrong'; case 'reverted': return error.description === 'SwapPool: EXCEEDS_MAX_COVERAGE_RATIO' - ? 'The input amount is too large' + ? 'The input amount is too large. The resulting coverage ratio of the pools must not exceed 200%.' : 'Something went wrong'; } }, From d7abf15a73a7763f563cb60429c9b1172ee335c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Thu, 16 May 2024 15:37:06 -0300 Subject: [PATCH 52/58] Remove dev page --- src/app.tsx | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/app.tsx b/src/app.tsx index 5adc39dd..ce985fbc 100644 --- a/src/app.tsx +++ b/src/app.tsx @@ -24,7 +24,6 @@ const TransfersPage = import('./pages/bridge/Trans const BackstopPoolsPage = ( import('./pages/nabla/backstop-pools')} fallback={defaultPageLoader} /> ); -const DevPage = import('./pages/nabla/dev')} fallback={defaultPageLoader} />; const Bridge = import('./pages/bridge')} fallback={defaultPageLoader} />; const Staking = import('./pages/collators/Collators')} fallback={defaultPageLoader} />; @@ -51,7 +50,6 @@ export function App() { - {!config.isProd && } } /> From f78ffab144e32f6ee72b59ca48ebce77fecd1966 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Thu, 16 May 2024 16:26:17 -0300 Subject: [PATCH 53/58] Fix backstop pool withdrawal button enabled error --- .../nabla/Pools/Backstop/AddLiquidity/index.tsx | 2 +- .../nabla/Pools/Backstop/WithdrawLiquidity/index.tsx | 2 +- src/components/nabla/common/AmountSelector.tsx | 7 ++++++- src/helpers/calc.ts | 10 +++++++--- src/hooks/nabla/useTokenOutAmount.ts | 7 +++---- 5 files changed, 18 insertions(+), 10 deletions(-) diff --git a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx index 2948351d..6e8555fc 100644 --- a/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/AddLiquidity/index.tsx @@ -38,7 +38,7 @@ const AddLiquidity = ({ data }: AddLiquidityProps): JSX.Element | null => {
-

Deposit {data.token.symbol}

diff --git a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx index 92034e20..7cc55b67 100644 --- a/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx +++ b/src/components/nabla/Pools/Backstop/WithdrawLiquidity/index.tsx @@ -48,7 +48,7 @@ const WithdrawLiquidityBody = ({ nabla }: { nabla: NablaInstance }): JSX.Element const totalSupplyOfLpTokens = rawToDecimal(backstopPool.totalSupply, backstopPool.token.decimals); const poolToWithdraw = selectedPool ?? backstopPool; - const submitEnabled = !withdrawalQuote.isLoading && withdrawalQuote.enabled && Object.keys(errors).length > 0; + const submitEnabled = !withdrawalQuote.isLoading && withdrawalQuote.enabled && Object.keys(errors).length === 0; return (
diff --git a/src/components/nabla/common/AmountSelector.tsx b/src/components/nabla/common/AmountSelector.tsx index 638ab694..aab76fc4 100644 --- a/src/components/nabla/common/AmountSelector.tsx +++ b/src/components/nabla/common/AmountSelector.tsx @@ -7,6 +7,7 @@ import { NumberInput } from './NumberInput'; import { ChangeEvent, ReactNode } from 'preact/compat'; import { fractionOfValue } from '../../../shared/parseNumbers/metric'; import { ContractBalance } from '../../../helpers/contracts'; +import { calcSharePercentageNumber } from '../../../helpers/calc'; interface AmountSelectorProps> { maxBalance: ContractBalance | undefined; @@ -121,7 +122,11 @@ export function AmountSelector) => { if (maxBalance === undefined) return; setValue(formFieldName, fractionOfValue(maxBalance.preciseBigDecimal, Number(ev.currentTarget.value)) as K, { diff --git a/src/helpers/calc.ts b/src/helpers/calc.ts index 27b9633c..42caf5b8 100644 --- a/src/helpers/calc.ts +++ b/src/helpers/calc.ts @@ -4,10 +4,14 @@ import { NablaInstanceSwapPool } from '../hooks/nabla/useNablaInstance'; export type Percent = number; /** Calculate share percentage */ -export function calcSharePercentage(total: Big, share: Big) { +export function calcSharePercentage(total: Big, share: Big): string { + return calcSharePercentageNumber(total, share).toFixed(2); +} + +export function calcSharePercentageNumber(total: Big, share: Big): number { + if (total.eq(0)) return 0; const percentage = share.div(total).mul(new Big(100)).toNumber(); - const clampedPercentage = Math.max(Math.min(percentage, 100), 0); - return clampedPercentage.toFixed(2); + return Math.max(Math.min(percentage, 100), 0); } /** Calculate share percentage */ diff --git a/src/hooks/nabla/useTokenOutAmount.ts b/src/hooks/nabla/useTokenOutAmount.ts index c121661e..6ca6b158 100644 --- a/src/hooks/nabla/useTokenOutAmount.ts +++ b/src/hooks/nabla/useTokenOutAmount.ts @@ -90,10 +90,9 @@ export function useTokenOutAmount({ if (toToken === undefined || fromToken === undefined || debouncedAmountBigDecimal === undefined) return undefined; const amountOut = parseContractBalanceResponse(toToken.decimals, data[0]); - const effectiveExchangeRate = stringifyBigWithSignificantDecimals( - amountOut.preciseBigDecimal.div(debouncedAmountBigDecimal), - 6, - ); + const effectiveExchangeRate = debouncedAmountBigDecimal.gt(0) + ? stringifyBigWithSignificantDecimals(amountOut.preciseBigDecimal.div(debouncedAmountBigDecimal), 6) + : '0'; const minAmountOut = subtractBigDecimalPercentage(amountOut.preciseBigDecimal, slippage); return { From 553931d0367e45c7c4cbb114babc28c97ec80dd2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Thu, 16 May 2024 16:42:13 -0300 Subject: [PATCH 54/58] Use token icons --- src/components/nabla/Swap/From.tsx | 3 ++- src/components/nabla/Swap/To.tsx | 3 ++- src/components/nabla/common/PoolSelectorModal.tsx | 5 ++++- src/shared/AssetIcons.tsx | 4 ++-- 4 files changed, 10 insertions(+), 5 deletions(-) diff --git a/src/components/nabla/Swap/From.tsx b/src/components/nabla/Swap/From.tsx index 6b648d2e..f447a077 100644 --- a/src/components/nabla/Swap/From.tsx +++ b/src/components/nabla/Swap/From.tsx @@ -11,6 +11,7 @@ import { AmountSelector } from '../common/AmountSelector'; import { UseContractReadResult } from '../../../hooks/nabla/useContractRead'; import { ContractBalance } from '../../../helpers/contracts'; import { TokenBalance } from '../common/TokenBalance'; +import { getIcon } from '../../../shared/AssetIcons'; interface FromProps> { fromToken: NablaInstanceToken | undefined; @@ -51,7 +52,7 @@ export function From - Pendulum + Pendulum {fromToken?.symbol || 'Select'} diff --git a/src/components/nabla/Swap/To.tsx b/src/components/nabla/Swap/To.tsx index 4c6c9b65..df7d0d7d 100644 --- a/src/components/nabla/Swap/To.tsx +++ b/src/components/nabla/Swap/To.tsx @@ -14,6 +14,7 @@ import { NablaInstanceToken } from '../../../hooks/nabla/useNablaInstance'; import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; import { NablaTokenPrice } from '../common/NablaTokenPrice'; import { Erc20Balance } from '../common/Erc20Balance'; +import { getIcon } from '../../../shared/AssetIcons'; export interface ToProps { onOpenSelector: () => void; @@ -71,7 +72,7 @@ export function To({ type="button" > - Pendulum + Pendulum {toToken?.symbol || 'Select'} diff --git a/src/components/nabla/common/PoolSelectorModal.tsx b/src/components/nabla/common/PoolSelectorModal.tsx index c496bc11..595815d2 100644 --- a/src/components/nabla/common/PoolSelectorModal.tsx +++ b/src/components/nabla/common/PoolSelectorModal.tsx @@ -2,10 +2,13 @@ import { CheckIcon } from '@heroicons/react/20/solid'; import { matchSorter } from 'match-sorter'; import { ChangeEvent, useMemo, useState } from 'preact/compat'; import { Avatar, AvatarProps, Button, Input, Modal } from 'react-daisyui'; + +import pendulumIcon from '../../../assets/pendulum-icon.svg'; import { repeat } from '../../../helpers/general'; import ModalCloseButton from '../../Button/ModalClose'; import { Skeleton } from '../../Skeleton'; import { NablaInstanceBackstopPool, NablaInstanceSwapPool } from '../../../hooks/nabla/useNablaInstance'; +import { getIcon } from '../../../shared/AssetIcons'; export type PoolEntry = | { type: 'swapPool'; pool: NablaInstanceSwapPool } @@ -80,7 +83,7 @@ function PoolList({ swapPools, backstopPool, onSelect, selected }: PoolListProps diff --git a/src/shared/AssetIcons.tsx b/src/shared/AssetIcons.tsx index ecb64f04..7f5c0d1c 100644 --- a/src/shared/AssetIcons.tsx +++ b/src/shared/AssetIcons.tsx @@ -39,6 +39,6 @@ const icons: IconMap = { XLM, }; -export function getIcon(token: string | undefined) { - return token && Object.keys(icons).includes(token) ? icons[token] : DefaultIcon; +export function getIcon(token: string | undefined, defaultIcon = DefaultIcon) { + return token && Object.keys(icons).includes(token) ? icons[token] : defaultIcon; } From 64273f1825c52b38d88a74e646affca6d32dbb28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Fri, 17 May 2024 10:15:57 -0300 Subject: [PATCH 55/58] Rename Nabla to Forex AMM --- src/components/Layout/links.tsx | 2 +- src/components/nabla/Pools/Backstop/index.tsx | 4 +++- src/components/nabla/Pools/Swap/index.tsx | 2 ++ src/components/nabla/Swap/index.tsx | 2 ++ src/components/nabla/common/NablaFootnote.tsx | 12 ++++++++++++ 5 files changed, 20 insertions(+), 2 deletions(-) create mode 100644 src/components/nabla/common/NablaFootnote.tsx diff --git a/src/components/Layout/links.tsx b/src/components/Layout/links.tsx index b5cab85e..47acf854 100644 --- a/src/components/Layout/links.tsx +++ b/src/components/Layout/links.tsx @@ -102,7 +102,7 @@ export const links: Links = ({ tenantName }) => [ }, { link: '/nabla', - title: 'Nabla', + title: 'Forex AMM', hidden: (nablaConfig.environment && !nablaConfig.environment.includes(config.env)) || (tenantName && !nablaConfig.tenants.includes(tenantName)), diff --git a/src/components/nabla/Pools/Backstop/index.tsx b/src/components/nabla/Pools/Backstop/index.tsx index 802de7b6..e655875b 100644 --- a/src/components/nabla/Pools/Backstop/index.tsx +++ b/src/components/nabla/Pools/Backstop/index.tsx @@ -5,6 +5,7 @@ import { useNablaInstance } from '../../../../hooks/nabla/useNablaInstance'; import { backstopPoolAbi } from '../../../../contracts/nabla/BackstopPool'; import { Erc20Balance } from '../../common/Erc20Balance'; import { BackstopPoolModals, LiquidityModalProps } from './BackstopPoolModals'; +import { NablaFootnote } from '../../common/NablaFootnote'; const BackstopPoolsBody = (): JSX.Element | null => { const toggle = useModalToggle(); @@ -16,7 +17,7 @@ const BackstopPoolsBody = (): JSX.Element | null => { return ( <> -
+
@@ -59,6 +60,7 @@ const BackstopPoolsBody = (): JSX.Element | null => {
+
diff --git a/src/components/nabla/Pools/Swap/index.tsx b/src/components/nabla/Pools/Swap/index.tsx index ea9d40f5..4d24bb54 100644 --- a/src/components/nabla/Pools/Swap/index.tsx +++ b/src/components/nabla/Pools/Swap/index.tsx @@ -2,6 +2,7 @@ import { useNablaInstance } from '../../../../hooks/nabla/useNablaInstance'; import ModalProvider from '../../../../services/modal'; import { useSharedState } from '../../../../shared/Provider'; import Table, { SortingOrder } from '../../../Table'; +import { NablaFootnote } from '../../common/NablaFootnote'; import { SwapPoolModals } from './SwapPoolModals'; import { columnsWithMyAmount, columnsWithoutMyAmount, SwapPoolColumn } from './columns'; @@ -24,6 +25,7 @@ const SwapPools = (): JSX.Element | null => { search sortBy={{ name: SortingOrder.ASC }} /> + ); }; diff --git a/src/components/nabla/Swap/index.tsx b/src/components/nabla/Swap/index.tsx index 4a211472..6185bf49 100644 --- a/src/components/nabla/Swap/index.tsx +++ b/src/components/nabla/Swap/index.tsx @@ -9,6 +9,7 @@ import { PoolSelectorModal } from '../common/PoolSelectorModal'; import Validation from '../../Form/Validation'; import { TransactionSettingsDropdown } from '../common/TransactionSettingsDropdown'; import { SwapProgress } from '../common/SwapProgress'; +import { NablaFootnote } from '../common/NablaFootnote'; const Swap = (props: UseSwapComponentProps): JSX.Element | null => { const { @@ -100,6 +101,7 @@ const Swap = (props: UseSwapComponentProps): JSX.Element | null => { + + Powered by{' '} + + Nabla technology + +
+ ); +} From 0e693ea6ce8d69a24d020c4c9f9b89b6ddc4e83d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Thu, 16 May 2024 17:48:12 -0300 Subject: [PATCH 56/58] Enable Nabla for Pendulum --- src/components/Layout/links.tsx | 1 + src/config/apps/nabla.ts | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/components/Layout/links.tsx b/src/components/Layout/links.tsx index 47acf854..ba77d95d 100644 --- a/src/components/Layout/links.tsx +++ b/src/components/Layout/links.tsx @@ -105,6 +105,7 @@ export const links: Links = ({ tenantName }) => [ title: 'Forex AMM', hidden: (nablaConfig.environment && !nablaConfig.environment.includes(config.env)) || + !tenantName || (tenantName && !nablaConfig.tenants.includes(tenantName)), prefix: , props: { diff --git a/src/config/apps/nabla.ts b/src/config/apps/nabla.ts index e6b52825..25a98081 100644 --- a/src/config/apps/nabla.ts +++ b/src/config/apps/nabla.ts @@ -13,11 +13,16 @@ export type NablaConfig = AppConfigBase & >; export const nablaConfig: NablaConfig = { - tenants: [TenantName.Foucoco], - environment: ['staging', 'development'], + tenants: [TenantName.Foucoco, TenantName.Pendulum], + environment: ['staging', 'development', 'production'], foucoco: { indexerUrl: 'https://pendulum.squids.live/foucoco-squid/graphql', router: '6ijJtaZuwpZCiaVo6pSHRJbd8qejgywYsejnjfo2AVanN14E', oracle: '6jscuYjvoPesdnzdnUNYEntLmGY3R6F5hJoTum1oaV7VVcxE', }, + pendulum: { + indexerUrl: 'https://pendulum.squids.live/pendulum-squid/graphql', + router: '6buMJsFCbXpHRyacKTjBn3Jss241b2aA7CZf9tKzKHMJWpcJ', + oracle: '6d3R7qJNDUMFRDrbkhPe3UZpPwzE4y4PjqXxgK3uJD6PT91S', + }, }; From e9c8f43766d701ea498b48dd6e2b2c1f895afa34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Mon, 20 May 2024 06:30:26 -0300 Subject: [PATCH 57/58] Remove dev page --- src/pages/nabla/dev/index.tsx | 92 ------------------------------- src/shared/parseNumbers/metric.ts | 2 +- 2 files changed, 1 insertion(+), 93 deletions(-) delete mode 100644 src/pages/nabla/dev/index.tsx diff --git a/src/pages/nabla/dev/index.tsx b/src/pages/nabla/dev/index.tsx deleted file mode 100644 index 69714e6b..00000000 --- a/src/pages/nabla/dev/index.tsx +++ /dev/null @@ -1,92 +0,0 @@ -import { EllipsisVerticalIcon } from '@heroicons/react/20/solid'; -import { Button, Dropdown } from 'react-daisyui'; -import { useNavigate } from 'react-router-dom'; -import { config } from '../../../config'; -import { erc20WrapperAbi } from '../../../contracts/nabla/ERC20Wrapper'; -import { useGlobalState } from '../../../GlobalStateProvider'; -import { decimalToRaw } from '../../../shared/parseNumbers/metric'; -import { NablaInstanceToken, useNablaInstance } from '../../../hooks/nabla/useNablaInstance'; -import { useContractWrite } from '../../../hooks/nabla/useContractWrite'; - -const TokenItem = ({ token }: { token: NablaInstanceToken }) => { - const { address } = useGlobalState().walletAccount || {}; - const { mutate, isLoading } = useContractWrite({ - abi: erc20WrapperAbi, - address: token.id, - method: 'mint', - mutateOptions: { - onError: console.error, - }, - }); - return ( -
-
-

{token.name}

-

{token.id}

-
-
-
- - - - -
  • -
    mutate([address, decimalToRaw(10000, 12).toString()])} - > - 10000 -
    -
  • -
  • -
    mutate([address, decimalToRaw(100000, 12).toString()])} - > - 100000 -
    -
  • -
    -
    -
    -
    -
    - ); -}; - -const DevPage = () => { - const navigate = useNavigate(); - const wallet = useGlobalState().walletAccount; - const { nabla } = useNablaInstance(); - const tokens = nabla?.swapPools.map((pool) => pool.token) ?? []; - - if (config.isProd) navigate('/'); - if (!wallet?.address) { - return <>Please connect your wallet.; - } - return ( -
    -
    -
    -

    Tokens

    - {tokens?.map((token) => )} -
    -
    -
    - ); -}; - -export default DevPage; diff --git a/src/shared/parseNumbers/metric.ts b/src/shared/parseNumbers/metric.ts index 3627b397..e635928d 100644 --- a/src/shared/parseNumbers/metric.ts +++ b/src/shared/parseNumbers/metric.ts @@ -31,7 +31,7 @@ export const decimalToNative = (value: BigNumber | number | string, decimals: nu return bigIntValue.times(multiplier).round(0); }; -export const decimalToRaw = (value: BigNumber | number | string, decimals: number) => { +export const decimalToRaw = (value: BigNumber | string, decimals: number) => { return decimalToNative(value, decimals); }; From e60bc077d2afe222304cc95e2e566ed879249e2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torsten=20Stu=CC=88ber?= <15174476+TorstenStueber@users.noreply.github.com> Date: Thu, 4 Jul 2024 17:06:45 +0200 Subject: [PATCH 58/58] Switch to new price feed wrapper --- src/config/apps/nabla.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/config/apps/nabla.ts b/src/config/apps/nabla.ts index 25a98081..52035804 100644 --- a/src/config/apps/nabla.ts +++ b/src/config/apps/nabla.ts @@ -23,6 +23,6 @@ export const nablaConfig: NablaConfig = { pendulum: { indexerUrl: 'https://pendulum.squids.live/pendulum-squid/graphql', router: '6buMJsFCbXpHRyacKTjBn3Jss241b2aA7CZf9tKzKHMJWpcJ', - oracle: '6d3R7qJNDUMFRDrbkhPe3UZpPwzE4y4PjqXxgK3uJD6PT91S', + oracle: '6f9uHwN2r5w82Bjrywc4wmZYb6TN64bZH5Ev87qmJ675uFvq', }, };