Skip to content

Commit

Permalink
update bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
daoauth committed Oct 9, 2024
1 parent 8eba528 commit 0183d13
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
3 changes: 1 addition & 2 deletions src/extension.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import * as vscode from 'vscode';
import { ExtensionContext } from 'vscode';
import { WebviewViewProvider } from './webviewPovider';

export function activate(context: ExtensionContext) {
export function activate(context: vscode.ExtensionContext) {
const provider = new WebviewViewProvider(context);
context.subscriptions.push(
vscode.window.registerWebviewViewProvider(
Expand Down
7 changes: 4 additions & 3 deletions src/webview/src/components/Account.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ export const Account = ({ client }: { client: SuiClient | undefined }) => {

useEffect(() => {
const updateBalance = async () => {
state.account && setNetwork(() => state.account!.nonce.network);
const balance = await getBalance(client, state.account);
setState((oldState) => ({ ...oldState, balance }));
};
Expand Down Expand Up @@ -183,9 +184,9 @@ export const Account = ({ client }: { client: SuiClient | undefined }) => {
setNetwork((e.target as HTMLInputElement).value as NETWORK);
}}
>
{NETWORKS.map((network, index) => (
<VSCodeOption key={index} value={network}>
{network}
{NETWORKS.map((item, index) => (
<VSCodeOption key={index} value={item}>
{item}
</VSCodeOption>
))}
</VSCodeDropdown>
Expand Down

0 comments on commit 0183d13

Please sign in to comment.