From ef39ee52600ecf40a4eb42eb4e5bd7f4ceb9569e Mon Sep 17 00:00:00 2001 From: Dan Lynch Date: Fri, 5 Apr 2024 12:51:38 -0700 Subject: [PATCH] nft --- .github/workflows/run-tests.yaml | 6 ++++++ examples/nft/hooks/useTx.ts | 2 +- examples/nft/pages/_app.tsx | 5 ++++- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/run-tests.yaml b/.github/workflows/run-tests.yaml index a56794998..720e7cd5e 100644 --- a/.github/workflows/run-tests.yaml +++ b/.github/workflows/run-tests.yaml @@ -51,4 +51,10 @@ jobs: run: | cca --example provide-liquidity --name provide-liquidity cd provide-liquidity + yarn build + + - name: nft + run: | + cca --example nft --name nft + cd nft yarn build \ No newline at end of file diff --git a/examples/nft/hooks/useTx.ts b/examples/nft/hooks/useTx.ts index d88c9c466..9a917629b 100644 --- a/examples/nft/hooks/useTx.ts +++ b/examples/nft/hooks/useTx.ts @@ -64,7 +64,7 @@ export function useTx() { if (!client) return new TxResult({ error: new TxError('Invalid SigningCosmWasm client') }); if (!signed) return new TxResult({ error: new TxError('Invalid transaction') }); - const response = await client.broadcastTx(Uint8Array.from(txRaw.encode(signed).finish())); + const response: any = await client.broadcastTx(Uint8Array.from(txRaw.encode(signed).finish())); return isDeliverTxSuccess(response) ? new TxResult({ response }) : new TxResult({ response, error: new TxError(response.rawLog) }); diff --git a/examples/nft/pages/_app.tsx b/examples/nft/pages/_app.tsx index eddd496f4..a90d95a75 100644 --- a/examples/nft/pages/_app.tsx +++ b/examples/nft/pages/_app.tsx @@ -12,6 +12,7 @@ import { getSigningCosmosClientOptions } from 'stargaze-query'; import { GasPrice } from '@cosmjs/stargate'; import { Box, ThemeProvider, Toaster, useTheme, useColorModeValue } from '@interchain-ui/react'; +import { Chain } from '@chain-registry/types'; const queryClient = new QueryClient({ defaultOptions: { @@ -30,7 +31,8 @@ function CreateCosmosApp({ Component, pageProps }: AppProps) { signingStargate: () => { return getSigningCosmosClientOptions(); }, - signingCosmwasm: (chain) => { + // @ts-ignore + signingCosmwasm: (chain: Chain) => { switch (chain.chain_name) { case 'stargaze': return { @@ -63,6 +65,7 @@ function CreateCosmosApp({ Component, pageProps }: AppProps) { > + {/* @ts-ignore */}