lp_ui: update examples and lp_ui for latest sdk

Change-Id: I1cfe7678713667d70e86be30d54e4bd45633f454
This commit is contained in:
Evan Gray 2021-11-22 22:13:06 -05:00
parent 92aa657630
commit b08565da67
9 changed files with 1627 additions and 337 deletions

View File

@ -9,7 +9,7 @@
"version": "0.0.1", "version": "0.0.1",
"license": "Apache-2.0", "license": "Apache-2.0",
"dependencies": { "dependencies": {
"@certusone/wormhole-sdk": "^0.0.10", "@certusone/wormhole-sdk": "^0.1.0",
"@improbable-eng/grpc-web": "^0.14.0", "@improbable-eng/grpc-web": "^0.14.0",
"@solana/spl-token": "^0.1.8", "@solana/spl-token": "^0.1.8",
"@solana/web3.js": "^1.24.0", "@solana/web3.js": "^1.24.0",
@ -608,9 +608,9 @@
"dev": true "dev": true
}, },
"node_modules/@certusone/wormhole-sdk": { "node_modules/@certusone/wormhole-sdk": {
"version": "0.0.10", "version": "0.1.0",
"resolved": "https://registry.npmjs.org/@certusone/wormhole-sdk/-/wormhole-sdk-0.0.10.tgz", "resolved": "https://registry.npmjs.org/@certusone/wormhole-sdk/-/wormhole-sdk-0.1.0.tgz",
"integrity": "sha512-BGAi3qdgFjA3UO0XMefnn8aDBpQUj+eDcDfcN90sl26QqlC01YDVPz93FyLsNTTjM3X1WHNX0V66B6UzPDr6Vw==", "integrity": "sha512-/ZJQieDlPpx1BUxODyV95S/iHTY6dWyBxAasLlCycu3fckicWYW4itiVgxndmiNDyVmvaWoCC+SF7oiqDVcyDg==",
"dependencies": { "dependencies": {
"@improbable-eng/grpc-web": "^0.14.0", "@improbable-eng/grpc-web": "^0.14.0",
"@solana/spl-token": "^0.1.8", "@solana/spl-token": "^0.1.8",
@ -9031,9 +9031,9 @@
"dev": true "dev": true
}, },
"@certusone/wormhole-sdk": { "@certusone/wormhole-sdk": {
"version": "0.0.10", "version": "0.1.0",
"resolved": "https://registry.npmjs.org/@certusone/wormhole-sdk/-/wormhole-sdk-0.0.10.tgz", "resolved": "https://registry.npmjs.org/@certusone/wormhole-sdk/-/wormhole-sdk-0.1.0.tgz",
"integrity": "sha512-BGAi3qdgFjA3UO0XMefnn8aDBpQUj+eDcDfcN90sl26QqlC01YDVPz93FyLsNTTjM3X1WHNX0V66B6UzPDr6Vw==", "integrity": "sha512-/ZJQieDlPpx1BUxODyV95S/iHTY6dWyBxAasLlCycu3fckicWYW4itiVgxndmiNDyVmvaWoCC+SF7oiqDVcyDg==",
"requires": { "requires": {
"@improbable-eng/grpc-web": "^0.14.0", "@improbable-eng/grpc-web": "^0.14.0",
"@solana/spl-token": "^0.1.8", "@solana/spl-token": "^0.1.8",

View File

@ -44,7 +44,7 @@
"typescript": "^4.3.5" "typescript": "^4.3.5"
}, },
"dependencies": { "dependencies": {
"@certusone/wormhole-sdk": "^0.0.10", "@certusone/wormhole-sdk": "^0.1.0",
"@improbable-eng/grpc-web": "^0.14.0", "@improbable-eng/grpc-web": "^0.14.0",
"@solana/spl-token": "^0.1.8", "@solana/spl-token": "^0.1.8",
"@solana/web3.js": "^1.24.0", "@solana/web3.js": "^1.24.0",

View File

@ -58,7 +58,7 @@ export async function relay(
async function parseVaa(bytes: Uint8Array) { async function parseVaa(bytes: Uint8Array) {
//parse_vaa is based on wasm //parse_vaa is based on wasm
const { parse_vaa } = await import( const { parse_vaa } = await import(
"@certusone/wormhole-sdk/lib/solana/core/bridge" "@certusone/wormhole-sdk/lib/cjs/solana/core/bridge"
); );
return parse_vaa(bytes); return parse_vaa(bytes);
} }

View File

@ -6,7 +6,7 @@ import {
getEmitterAddressSolana, getEmitterAddressSolana,
getEmitterAddressTerra, getEmitterAddressTerra,
} from "@certusone/wormhole-sdk"; } from "@certusone/wormhole-sdk";
import getSignedVAAWithRetry from "@certusone/wormhole-sdk/lib/rpc/getSignedVAAWithRetry"; import getSignedVAAWithRetry from "@certusone/wormhole-sdk/lib/cjs/rpc/getSignedVAAWithRetry";
import { NodeHttpTransport } from "@improbable-eng/grpc-web-node-http-transport"; import { NodeHttpTransport } from "@improbable-eng/grpc-web-node-http-transport";
import { import {
getNFTBridgeAddressForChain, getNFTBridgeAddressForChain,

View File

@ -1,5 +1,5 @@
import { CHAIN_ID_ETH, CHAIN_ID_SOLANA } from "@certusone/wormhole-sdk"; import { CHAIN_ID_ETH, CHAIN_ID_SOLANA } from "@certusone/wormhole-sdk";
import { setDefaultWasm } from "@certusone/wormhole-sdk/lib/solana/wasm"; import { setDefaultWasm } from "@certusone/wormhole-sdk/cjs/esm/solana/wasm";
import { import {
ASSOCIATED_TOKEN_PROGRAM_ID, ASSOCIATED_TOKEN_PROGRAM_ID,
Token, Token,

File diff suppressed because it is too large Load Diff

View File

@ -42,7 +42,7 @@
"typescript": "^4.3.5" "typescript": "^4.3.5"
}, },
"dependencies": { "dependencies": {
"@certusone/wormhole-sdk": "file:../../sdk/js", "@certusone/wormhole-sdk": "^0.1.0",
"@improbable-eng/grpc-web": "^0.14.0", "@improbable-eng/grpc-web": "^0.14.0",
"@solana/spl-token": "^0.1.8", "@solana/spl-token": "^0.1.8",
"@solana/web3.js": "^1.24.0", "@solana/web3.js": "^1.24.0",

View File

@ -1,14 +1,14 @@
import addLiquidityTx from "@certusone/wormhole-sdk/lib/migration/addLiquidity"; import addLiquidityTx from "@certusone/wormhole-sdk/lib/esm/migration/addLiquidity";
import getAuthorityAddress from "@certusone/wormhole-sdk/lib/migration/authorityAddress"; import getAuthorityAddress from "@certusone/wormhole-sdk/lib/esm/migration/authorityAddress";
import claimSharesTx from "@certusone/wormhole-sdk/lib/migration/claimShares"; import claimSharesTx from "@certusone/wormhole-sdk/lib/esm/migration/claimShares";
import createPoolAccount from "@certusone/wormhole-sdk/lib/migration/createPool"; import createPoolAccount from "@certusone/wormhole-sdk/lib/esm/migration/createPool";
import getFromCustodyAddress from "@certusone/wormhole-sdk/lib/migration/fromCustodyAddress"; import getFromCustodyAddress from "@certusone/wormhole-sdk/lib/esm/migration/fromCustodyAddress";
import migrateTokensTx from "@certusone/wormhole-sdk/lib/migration/migrateTokens"; import migrateTokensTx from "@certusone/wormhole-sdk/lib/esm/migration/migrateTokens";
import parsePool from "@certusone/wormhole-sdk/lib/migration/parsePool"; import parsePool from "@certusone/wormhole-sdk/lib/esm/migration/parsePool";
import getPoolAddress from "@certusone/wormhole-sdk/lib/migration/poolAddress"; import getPoolAddress from "@certusone/wormhole-sdk/lib/esm/migration/poolAddress";
import removeLiquidityTx from "@certusone/wormhole-sdk/lib/migration/removeLiquidity"; import removeLiquidityTx from "@certusone/wormhole-sdk/lib/esm/migration/removeLiquidity";
import getShareMintAddress from "@certusone/wormhole-sdk/lib/migration/shareMintAddress"; import getShareMintAddress from "@certusone/wormhole-sdk/lib/esm/migration/shareMintAddress";
import getToCustodyAddress from "@certusone/wormhole-sdk/lib/migration/toCustodyAddress"; import getToCustodyAddress from "@certusone/wormhole-sdk/lib/esm/migration/toCustodyAddress";
import { import {
Button, Button,
CircularProgress, CircularProgress,
@ -25,7 +25,7 @@ import {
TOKEN_PROGRAM_ID, TOKEN_PROGRAM_ID,
} from "@solana/spl-token"; } from "@solana/spl-token";
import { Connection, PublicKey } from "@solana/web3.js"; import { Connection, PublicKey } from "@solana/web3.js";
//import { pool_address } from "@certusone/wormhole-sdk/lib/solana/migration/wormhole_migration"; //import { pool_address } from "@certusone/wormhole-sdk/lib/esm/solana/migration/wormhole_migration";
import { parseUnits } from "ethers/lib/utils"; import { parseUnits } from "ethers/lib/utils";
import { useCallback, useEffect, useMemo, useState } from "react"; import { useCallback, useEffect, useMemo, useState } from "react";
import LogWatcher from "../components/LogWatcher"; import LogWatcher from "../components/LogWatcher";

View File

@ -9,7 +9,7 @@ import {
TextField, TextField,
Typography, Typography,
} from "@material-ui/core"; } from "@material-ui/core";
//import { pool_address } from "@certusone/wormhole-sdk/lib/solana/migration/wormhole_migration"; //import { pool_address } from "@certusone/wormhole-sdk/lib/esm/solana/migration/wormhole_migration";
import { parseUnits } from "ethers/lib/utils"; import { parseUnits } from "ethers/lib/utils";
import { useCallback, useState } from "react"; import { useCallback, useState } from "react";
import EthereumSignerKey from "../components/EthereumSignerKey"; import EthereumSignerKey from "../components/EthereumSignerKey";